You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm probably missing something really obvious, but I'd like to use this library to validate an incoming request against a schema defined in an OpenAPI document which has references to things in components.
The ugly version is to take the components field from the OpenAPI document and shove it into the specific schema, but surely there's a better way, where I can provide a document with refs and a path to the specific schema in it?
I feel like JsonSchemaFactory.create(ValidationContext validationContext, String schemaPath, JsonNode schemaNode, JsonSchema parentSchema) is a potential case here, but I have to build the ValidationContext myself which is non-trivial (JsonSchemaFactory.createValidationContext is protected).
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hi,
I'm probably missing something really obvious, but I'd like to use this library to validate an incoming request against a schema defined in an OpenAPI document which has references to things in components.
The ugly version is to take the
components
field from the OpenAPI document and shove it into the specific schema, but surely there's a better way, where I can provide a document with refs and a path to the specific schema in it?I feel like
JsonSchemaFactory.create(ValidationContext validationContext, String schemaPath, JsonNode schemaNode, JsonSchema parentSchema)
is a potential case here, but I have to build theValidationContext
myself which is non-trivial (JsonSchemaFactory.createValidationContext
isprotected
).Beta Was this translation helpful? Give feedback.
All reactions