-
-
Notifications
You must be signed in to change notification settings - Fork 493
Give Love to JSONPath Implementation #1022
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
Comments
Nobody's working on this right now! Though I'm a little curious about your intent. The |
I suggest rewriting the codebase, improving path parsing with a robust parser and tokenizer, improving type handling for consistent formatting of all JSON types, structuring the code for reusable parsed paths, and strengthening error handling with detailed messages. I find it difficult to achieve these improvements with the current codebase, especially regarding future extensibility with the missing features you mention. In addition, I'd like to add more tests and try to optimize performance, for example by reducing string operations. |
Couldn't agree more, the JSONPath is a bit of a nightmare to maintain. |
Thanks @ImTheCurse! It's still WIP but the core implementation is done in #1024 and the core implementation passes all unit tests. You can already review the code structure, if you like. It needs some tweaks to pass the integration tests especially when no valid JSON is present. |
Seing this issue, I am reminded that I have several endpoints where I need to do some JSON transformations from the API I want to monitor. For example, to count items in a JSON, or do some filters. To do that currently, I have intermediate simple services just doing a bit of |
I'd like to tackle the comment in https://github.com/TwiN/gatus/blob/master/jsonpath/jsonpath.go#L10
Eval is a half-baked json path implementation that needs some love
Rough Plan:
I do not intend to change or add functionality in the first place with the reimplementation but am eager to do so in the future since I could use it well myself.
This should provide a solid foundation for solving e.g. #335 or #225.
@TwiN Please confirm nobody's working on this already.
Thank you for your great work so far!
The text was updated successfully, but these errors were encountered: