|
From: Karthik K. V. <kar...@gm...> - 2017-07-23 05:20:12
|
It's a good idea, but I have these ideas on them: - JSON isn't an appendable format, and this sort of log will not be well formed JSON. - CSV and YAML are good ideas - and they do support incremental updates and parsing libraries are available. - TXT files do allow appending and incremental updates are possible - except, they require escaping \n s in Exceptions etc. On 23 July 2017 at 10:29, Y.Watanabe <na...@gm...> wrote: > Hi. > I hope that JSW have "JSON" format configuration on > "wrapper.console.format". > > Belong to "12-factor app" theory, (https://12factor.net/ ) > Our Java-Web application logs to STDOUT, > and JSW catches the stdout log, write into "wrapper.log" > > So, both of JSW log and application log into one file like below. > > STATUS | wrapper | 2015/11/01 13:45:33.560 | JVM start...... > {"severity":"INFO","datetime":"2015-11-01 17:05:27 -0700","msg":"foobar"} > > But it is not convinient to use jq command line tool like this. > > $ cat test.log | jq . > parse error: Invalid numeric literal at line 1, column 7 > > If JSW log format support JSON, > > {"STATUS":"wrapper","datetime":"2015/11/01 13:45:33.560", "msg":"JVM > start."} > {"severity":"INFO","datetime":"2015-11-01 17:05:27 -0700","msg":"foobar"} > > I can use "jq" or any other tool for json ! > > $ cat test.log | jq . > { > "STATUS": "wrapper", > "datetime": "2015/11/01 13:45:33.560", > "msg": "JVM start." > } > { > "severity": "INFO", > "datetime": "2015-11-01 17:05:27 -0700", > "msg": "foobar" > } > > > Regards. > > ---- > Watanabe. > > ------------------------------------------------------------ > ------------------ > Check out the vibrant tech community on one of the world's most > engaging tech sites, Slashdot.org! http://sdm.link/slashdot > _______________________________________________ > Wrapper-user mailing list > Wra...@li... > https://lists.sourceforge.net/lists/listinfo/wrapper-user > |