[ 
https://issues.apache.org/jira/browse/IGNITE-19192?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17711062#comment-17711062
 ] 

Mikhail Pochatkin commented on IGNITE-19192:
--------------------------------------------

In the progress of updating found several problems:
1. Backward incompatible in micronaut-openapi-generator. 
*micronaut.openapi.property.naming.strategy* changed from *CAMEL_CASE* to 
*LOWER_CAMEL_CASE*. Introduced *micronaut.openapi.field.visibility.level* with 
default value *PUBLIC* that produce problem with all private fields. 
2. *@Produces* annotation start processing by openapi-generator annotation 
processor and generate redundant response statuses to cover all produces media 
types. 
For example if presented 
{code:java}
@Produces({MediaType.TEXT_PLAIN, MediaType.PROBLEM_JSON})
{code}
then openapi.yml for annotated method will contain both types for 200 status 
response. This is not corrent, because PROBLEM_JSON used only for 4** and 5** 
responses.
3. *require* attribute deprecated and introduced new enum attribute 
*requiredMode*.
4. In some cases, the name from the *@Schema* annotation is ignored, this is 
important for DTO objects. Thus, if any controller method has a reference to a 
DTO object as an implementation attribute of the *@Schema* annotation, the 
generator resolves the DTO name as the class name instead of the annotation 
name. This is counter-intuitive and as a solution the Dto suffix has been 
removed from all classes and the class name must be used as the object name in 
the public API specification.

> Bump OpenApi spec generator version
> -----------------------------------
>
>                 Key: IGNITE-19192
>                 URL: https://issues.apache.org/jira/browse/IGNITE-19192
>             Project: Ignite
>          Issue Type: Improvement
>          Components: rest
>            Reporter: Mikhail Pochatkin
>            Assignee: Mikhail Pochatkin
>            Priority: Major
>              Labels: ignite-3
>          Time Spent: 10m
>  Remaining Estimate: 0h
>
> Currently micronaut openapi generator version is 3.2.0, but latest release is 
> 4.8.6. So, need to use latest version, but between these versions exists 
> non-backward compatibility changes. Need to fix spec definitions and 
> generator propeties for correct spec generation. Ideally, spec should not be 
> changed.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to