-
Notifications
You must be signed in to change notification settings - Fork 2.6k
Auto-generate jaeger-v2 config docs via AST #7064
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
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: AnmolxSingh <anmol7344@gmail.com>
Signed-off-by: Yuri Shkuro <yurishkuro@users.noreply.github.com>
Signed-off-by: Yuri Shkuro <github@ysh.us>
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #7064 +/- ##
==========================================
- Coverage 96.05% 95.83% -0.22%
==========================================
Files 355 358 +3
Lines 20995 21411 +416
==========================================
+ Hits 20166 20519 +353
- Misses 624 667 +43
- Partials 205 225 +20
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
"main": "index.js", | ||
"scripts": { | ||
"test": "echo \"Error: no test specified\" && exit 1", | ||
"docs": "jsonschema2md -d ./ -o ../../../cmd/jaeger/docs/migration/configdocs" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @yurishkuro
I worked on this issue before so I thought of reviewing this pr what I did wrong.
I think the command here for generating .md
file does not work for me here. When I generated the .md file I simply used
jsonschema2md cmd/jaeger/internal/configdocs/cmd/jaeger-config-schema.json cmd/jaeger/docs/migration/configdocs.md
I may be missing something please correct me if I am wrong
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it doesn't work for me either at the moment. Which jsonschema2md
did you use?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
but the reason this fails in the PR is because the generated schema is just wrong, it has dangling references.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it doesn't work for me either at the moment. Which
jsonschema2md
did you use?
I used
https://github.com/RalfG/jsonschema2md?tab=readme-ov-file
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does Jaeger community has a preference towards any jsonschema2md
tool like adobe or any implementation is fine as long as the output is correct?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We want stable and maintained dependencies. RalfG/jsonschema2md is already archived.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I worked on this issue before so I thought of reviewing this pr what I did wrong.
any conclusions? :-) I think the path forward to completion is pretty clear, but requires time investment, which I may not have. The main logic is currently broken, because the schema is generated in an invalid state, with dangling references, some types which are structs in Go are listed as string
type, etc. This is why it's useful to start with unit tests, to validate assumptions and edge cases.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We want stable and maintained dependencies. RalfG/jsonschema2md is already archived.
actually it is maintained by its fork https://github.com/sbrunner/jsonschema2md
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I worked on this issue before so I thought of reviewing this pr what I did wrong.
any conclusions? :-) I think the path forward to completion is pretty clear, but requires time investment, which I may not have. The main logic is currently broken, because the schema is generated in an invalid state, with dangling references, some types which are structs in Go are listed as
string
type, etc. This is why it's useful to start with unit tests, to validate assumptions and edge cases.
Thanks for the feedback, Yuri.
I'm currently working on the "restoring metrics" issue, and as you mentioned, this issue requires time. I’d like to continue focusing on that issue for now. I believe this issue can be resolved, and it might be best for someone else to take over.
Thanks for your understanding!
Signed-off-by: Yuri Shkuro <github@ysh.us>
Which problem is this PR solving?
Description of the changes
How was this change tested?
Checklist
jaeger
:make lint test
jaeger-ui
:npm run lint
andnpm run test