-
-
Notifications
You must be signed in to change notification settings - Fork 536
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[do not merge] Add ability to generate JSON by passing an Object as the format #123
Conversation
As far as I can tell, all the code you added in the PR is 100% achievable in user-land and does not require a fork, right? Because the |
@dougwilson I guess it could be done in user land. Figured that having logs that are not easily searched as text blobs would be somewhat common. though I guess I would assume documentation would mean that the API for those functions would be stable? I can write some if it is not internal/likely to change. |
So my comment was really just to make sure I was understanding if I was missing something or not since you said you would need to fork, I was assuming there was something in there that required source code modification to function, but I didn't see anything.
I'm not 100% sure this comment means :) At least currently,
I'm not sure what that means? |
I'm piping data directly into Elasticsearch/Logstash and reading it via Kibana's UI dashboards (the ELK stack). Elasticsearch does not parse strings passed to it, and so it just appears as a big text blob which isn't very useful.
The docs mention that you can pass a function, but do not state what the function is/should do. Was just saying if thats the proper case I can document the |
Yes, absolutely! :) I just looked over the README and for some reason though it was better documented, but you're right: it just mentions you can give a function, but no real details. A pull request to add documentation around this would be useful indeed 👍 |
@dougwilson did that with #124 , which does docs and adds some tests explicitly to comply with existing behavior / what docs were added. |
Thanks! |
Various logging systems (notably the ELK stack) can use JSON metadata when creating queries and dashboards. This PR adds the ability to pass an Object as an
options.format
which will then be crawled and template all strings found in that Object.If this seems reasonable I will add tests and docs, but wanted to pass by and see if this is reasonable without creating a fork.
Example: