t0xa / gelfj

Graylog Extended Log Format (GELF) implementation in Java and log4j appender without any dependencies.
https://github.com/t0xa/gelfj/wiki
Other
187 stars 115 forks source link

Missing setter on GelfHandler for multiple additional fields #125

Open goedtim opened 6 years ago

goedtim commented 6 years ago

We are using the GelfHandler as part of a JBoss EAP6 application and create/configure it as a custom handler in the JBoss configuration. Furthermore we need to provide multiple additional fields.

Current issue is, that JBoss inspects the Handler class and for any property provided in the configuration, it expects a matching setter. Example property graylogHost needs a setter setGraylogHost().

For all supported properties there is a matching setter, also for a single additional field, but not for multiple additional fields. Also, JBoss configuration does not allow repeating the same property multiple times. So we would need a setter setAdditionalFields(String fields) with a parsing logic similar to what is currently done in the constructor.

I could provide a fix, just want to discuss here if that's fine or if I am on a wrong track. Also, if I provide a fix, how long would it take for a new release as we would probably not install custom build software in our PROD environment?