-
Notifications
You must be signed in to change notification settings - Fork 2.8k
feat: generate JSON schemas for internal extensions #8089
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
Open
SoumyaRaikwar
wants to merge
4
commits into
jaegertracing:main
Choose a base branch
from
SoumyaRaikwar:issue-6186-schemagen-phase2
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 1 commit
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
8703c38
Add schema generation for internal extensions and Generate JSON sch…
SoumyaRaikwar 55901aa
added ADR for Configuration Schema Generation
SoumyaRaikwar 94f7bd5
updated ADR as per feedback
SoumyaRaikwar 1cb4162
Merge branch 'main' into issue-6186-schemagen-phase2
SoumyaRaikwar File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,9 @@ | ||
| mappings: | ||
| time: | ||
| Duration: | ||
| schemaType: string | ||
| format: duration | ||
| allowedRefs: | ||
| - go.opentelemetry.io/collector | ||
| - github.com/jaegertracing/jaeger | ||
| - github.com/open-telemetry/opentelemetry-collector-contrib |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| $defs: | ||
| config: | ||
| type: object | ||
| allOf: | ||
| - $ref: go.opentelemetry.io/collector/config/confighttp.server_config | ||
20 changes: 20 additions & 0 deletions
20
cmd/jaeger/internal/extension/jaegermcp/config.schema.yaml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,20 @@ | ||
| $defs: | ||
| config: | ||
| description: Config represents the configuration for the Jaeger MCP server extension. | ||
| type: object | ||
| properties: | ||
| http: | ||
| description: HTTP contains the HTTP server configuration for the MCP protocol endpoint. | ||
| $ref: go.opentelemetry.io/collector/config/confighttp.server_config | ||
| max_search_results: | ||
| description: MaxSearchResults limits the number of trace search results. | ||
| type: integer | ||
| max_span_details_per_request: | ||
| description: MaxSpanDetailsPerRequest limits the number of spans that can be fetched in a single request. | ||
| type: integer | ||
| server_name: | ||
| description: ServerName is the name of the MCP server for protocol identification. | ||
| type: string | ||
| server_version: | ||
| description: ServerVersion is the version of the MCP server. | ||
| type: string |
22 changes: 22 additions & 0 deletions
22
cmd/jaeger/internal/extension/jaegerquery/config.schema.yaml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,22 @@ | ||
| $defs: | ||
| config: | ||
| description: Config represents the configuration for jaeger-query, | ||
| type: object | ||
| properties: | ||
| storage: | ||
| description: Storage holds configuration related to the various data stores that are to be queried. | ||
| $ref: storage | ||
| allOf: | ||
| - $ref: ./internal.query_options | ||
| storage: | ||
| type: object | ||
| properties: | ||
| metrics: | ||
| description: Metrics contains the name of the metric storage that is being queried. | ||
| type: string | ||
| traces: | ||
| description: TracesPrimary contains the name of the primary trace storage that is being queried. | ||
| type: string | ||
| traces_archive: | ||
| description: TracesArchive contains the name of the archive trace storage that is being queried. | ||
| type: string |
6 changes: 6 additions & 0 deletions
6
cmd/jaeger/internal/extension/jaegerstorage/config.schema.yaml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,6 @@ | ||
| $defs: | ||
| config: | ||
| description: Config embeds the shared storage configuration. | ||
| type: object | ||
| allOf: | ||
| - $ref: github.com/jaegertracing/jaeger/cmd/internal/storageconfig.config |
39 changes: 39 additions & 0 deletions
39
cmd/jaeger/internal/extension/remotesampling/config.schema.yaml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,39 @@ | ||
| $defs: | ||
| adaptive_config: | ||
| type: object | ||
| properties: | ||
| sampling_store: | ||
| description: SamplingStore is the name of the storage defined in the jaegerstorage extension. | ||
| type: string | ||
| allOf: | ||
| - $ref: github.com/jaegertracing/jaeger/internal/sampling/samplingstrategy/adaptive.options | ||
| config: | ||
| type: object | ||
| properties: | ||
| adaptive: | ||
| x-optional: true | ||
| $ref: adaptive_config | ||
| file: | ||
| x-optional: true | ||
| $ref: file_config | ||
| grpc: | ||
| x-optional: true | ||
| $ref: go.opentelemetry.io/collector/config/configgrpc.server_config | ||
| http: | ||
| x-optional: true | ||
| $ref: go.opentelemetry.io/collector/config/confighttp.server_config | ||
| file_config: | ||
| type: object | ||
| properties: | ||
| default_sampling_probability: | ||
| description: DefaultSamplingProbability is the sampling probability used by the Strategy Store for static sampling | ||
| type: number | ||
| x-customType: float64 | ||
| path: | ||
| description: File specifies a local file as the source of sampling strategies. | ||
| type: string | ||
| reload_interval: | ||
| description: ReloadInterval is the time interval to check and reload sampling strategies file | ||
| type: string | ||
| x-customType: time.Duration | ||
| format: duration |
10 changes: 10 additions & 0 deletions
10
cmd/jaeger/internal/extension/remotestorage/config.schema.yaml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,10 @@ | ||
| $defs: | ||
| config: | ||
| type: object | ||
| properties: | ||
| multi_tenancy: | ||
| $ref: github.com/jaegertracing/jaeger/internal/tenancy.options | ||
| storage: | ||
| type: string | ||
| allOf: | ||
| - $ref: go.opentelemetry.io/collector/config/configgrpc.server_config |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
could you please create an ADR that outlines the overall plan? For example, how would this external ref be used?
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.
Done! added in the latest commit.