-
Notifications
You must be signed in to change notification settings - Fork 272
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
Rename reporting plugin to telemetry #651
Conversation
This comment has been minimized.
This comment has been minimized.
As we are now inlining subschemas the generation does not need to include references.
❌ Deploy Preview for apollo-router-docs failed. 🔨 Explore the source changes: 2692eaf 🔍 Inspect the deploy log: https://app.netlify.com/sites/apollo-router-docs/deploys/623081a0a86327000929f54e |
This way we can leave a plugins section in the config but have it empty.
@@ -131,26 +133,10 @@ impl FromStr for Configuration { | |||
} | |||
|
|||
fn gen_schema(plugins: schemars::Map<String, Schema>) -> Schema { | |||
let plugins_refs = plugins |
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.
This section is no longer needed because we switched to incline schemas.
})), | ||
subschemas: Some(Box::new(SubschemaValidation { | ||
any_of: Some(plugins_refs), | ||
additional_properties: Option::Some(Box::new(Schema::Bool(false))), |
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 do however want to prevent random new properties being added.
@@ -79,6 +79,7 @@ struct Rhai { | |||
} | |||
|
|||
#[derive(Deserialize, JsonSchema)] | |||
#[serde(deny_unknown_fields)] |
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.
🎉 🙏
Renames
reporting
totelemetry
Also fixes related json schema generation.
Also allows plugins section to be empty by making the map inside
UserPlugins
optional.