Added handling of list of timestamp #17
Draft
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
In GelfTcp there is already the possibility to have list of messages, i've added also list of timestamp so that, only in case of list of messages, they can be sent each with their message. Is also possible to have a list of messages with only 1 timestamp so also that possibility is handled.
In GelfHttp is a bit more complicated.
There was not a list handling but, according to graylog documentation, they introduced a way to handle bulk http GELF post. https://go2docs.graylog.org/5-0/getting_in_log_data/ingest_gelf.html So i've added the same list handling from Tcp but, as the bulking is made appending dumped JSON with \n\r at the end, and, most important, must be avoided to have \n or \r inside the dumped messages, i had to make some cases that handle all the above. To keep the rest as it is i've jumped the single message before so only 1 variable needs to be handled.
I know it's not clean, but i hope to have contributed with some interesting feature.
Have not tested it yet. Don't expect to have it merged as is