3 ms·
Moving away from using regex to parse JSON, you can use Jsawk and Underscore-cli to manipulate JSON like Awk or JavaScript. https://github.com/micha/jsawk/ htt
by mgurlitz 14y ago
Moving away from using regex to parse JSON, you can use Jsawk and Underscore-cli to manipulate JSON like Awk or JavaScript.
https://github.com/micha/jsawk/ https://github.com/micha/jsawk/
https://github.com/ddopson/underscore-cli https://github.com/ddopson/underscore-cli
- gbog 14y agoBut the problem is speed. I found that if parsing logs is slow, bug hunting is far less efficient.
- robmil 14y agounderscore-cli is utterly brilliant for this, even better — dare I say it? — than traditional log files with cut/grep/awk. Being able to treat logs as a dataset that can be mapped/reduced/flattened/grouped/otherwise analysed is life-changingly good. About the strongest endorsement I can give is that it makes me wish more of my logs were in JSON format, rather than wishing that less were as I always had before.