Hi, I have now integrated the bulk of this series, thank you. Everything I felt was good for integration is already on master. The rest is sitting on my cast-typehint branch on github.com/balabit/syslog-ng-3.5.git I have split [PATCH 4/6] value-pairs: Type hinting support, and removed the questionable parts into a separate patch. The two issues I have are: 1) This is just a question is configuration style, I have some doubts about the consistency of the type-cast(on-error()) configuration syntax and would welcome feedback from the community + the docteam. As implemented this would look like this: options { type-cast(on-error(silently-drop-message)); }; So far options were not structured deeply and although we do have the tls() option block within a tcp() destination, IIRC that's the only one where we nest options. For a single option, especially if we won't have others in this namespace, I'd prefer something like: options { on-type-cast-error(drop-message) }; As an additional note, this should probably be made available on a per-destination basis too. 2) The other is code related, I don't really like the code change in driver.c, especially the part that it tries to dereference the global variable "configuration" which is only available during parsing. I'm on the run, so won't continue integrating the rest of your merge queue, but I'm not putting the rest on hold, just didn't have time to continue cherry-picking ... :) Thanks again. -- Bazsi On Wed, 2013-09-04 at 14:35 +0200, Gergely Nagy wrote:
The following patchset introduces type hinting support, for mongodb and format-json for the time being, along with a couple of cleanups done prior to the introduction.
The code passes unit and func tests, and is the result of a pair programming session by Balazs Scheidler <bazsi@balabit.hu> and myself, I rearranged the result and split it up into individual, mostly self-contained commits.
To use type hinting with value-pairs: value-pair(pair("SOME-INTEGER" int("1234")) pair("SOME-DATETIME" datetime("$UNIXTIME")));
Simiarly, with format-json: template("$(format-json some-integer=int(1234) some-datetime=datetime($UNIXTIME))\n")
Further documentation will follow later, most likely in a form of a blog post.
______________________________________________________________________________ Member info: https://lists.balabit.hu/mailman/listinfo/syslog-ng Documentation: http://www.balabit.com/support/documentation/?product=syslog-ng FAQ: http://www.balabit.com/wiki/syslog-ng-faq