Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Allow uploading JSON-per-line OTLP data (#2380)
OpenTelemetry specifies that JSON line files can contain valid JSON objects which are seperated with a newline character. The existing readJsonFile function couldn't handle those instances, this PR fixes that, along with test cases to verify. ## Which problem is this PR solving? Resolves #2225 ## Description of the changes A new try catch block was inserted, for files that weren't parsed by the usual JSON.parse, would be parsed by the catch block assuming the objects are seperated by newline (which is mentioned in opentelemetry) ## How was this change tested? Test cases, and manual testing ## Checklist - [ X ] I have read https://github.com/jaegertracing/jaeger/blob/master/CONTRIBUTING_GUIDELINES.md - [ X ] I have signed all commits - [ X ] I have added unit tests for the new functionality - [ X ] I have run lint and test steps successfully - for `jaeger`: `make lint test` - for `jaeger-ui`: `yarn lint` and `yarn test` --------- Signed-off-by: Muthukumar <muthuku37@gmail.com> Signed-off-by: Yuri Shkuro <github@ysh.us> Co-authored-by: Yuri Shkuro <github@ysh.us>
- Loading branch information