[
https://issues.apache.org/jira/browse/CAMEL-16986?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Thorsten Roemer updated CAMEL-16986:
------------------------------------
Environment:
Maven dependencies:
* camel-openapi-java-starter:3.11.2
* camel-openapi-java:3.11.2
* swagger-core: 2.1.10
was:
Maven dependencies:
* camel-openapi-java-starter:3.11.2
* camel-openapi-java:3.11.2
* swagger-core: 2.1.20
> Add support for description and example in @Schema annotation
> -------------------------------------------------------------
>
> Key: CAMEL-16986
> URL: https://issues.apache.org/jira/browse/CAMEL-16986
> Project: Camel
> Issue Type: Improvement
> Components: camel-openapi-java
> Affects Versions: 3.11.2
> Environment: Maven dependencies:
> * camel-openapi-java-starter:3.11.2
> * camel-openapi-java:3.11.2
> * swagger-core: 2.1.10
> Reporter: Thorsten Roemer
> Priority: Minor
>
> When using the @Schema annotation for OpenAPI documentation, the
> "description" and "example" parameters are apparently ignored because the
> generated JSON file does not contain any of these elements.
> E.g.:
> {code:java}
> @io.swagger.v3.oas.annotations.media.Schema(description = "The transaction
> id", example = "id-123")
> String id;
> {code}
> Current generated JSON:
> {noformat}
> [...]
> "components" : {
> "schemas" : {
> "Example" : {
> "type" : "object",
> "properties" : {
> "id" : {
> "type" : "string"
> },
> [...]
> {noformat}
> Expected generated JSON:
> {noformat}
> [...]
> "components" : {
> "schemas" : {
> "Example" : {
> "type" : "object",
> "properties" : {
> "id" : {
> "description" : "The transaction id",
> "type" : "string",
> "example" : "id-123"
> },
> [...]
> {noformat}
--
This message was sent by Atlassian Jira
(v8.3.4#803005)