-
-
Notifications
You must be signed in to change notification settings - Fork 524
Property writer-with-order-by-keys not taken into account #1690
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
Comments
This PR should fix the issue: |
The sort is working fine. See test below: If you believe, you are facing any issue, make sure you provide a Minimal, Reproducible Example - with HelloController that reproduces the problem |
Hi @bnasslahsen. |
I've created a new PR with expectations fixed:
|
Thank you @mariusz-zawadzki for your contirbution to the project. |
Describe the bug
When springdoc.writer-with-order-by-keys is set to true, in the yaml generated file the keys are not sorted alphabetically
It seems related to this commit:
e77aec1#diff-f7a64fc1c3465d474089ceed1a982db7c484a3c23570ac637948999956614e6dL119
ObjectMapperProvider.java:119
As you can see the ObjectMapper is not configured anymore with MapperFeature.SORT_PROPERTIES_ALPHABETICALLY set to true.
To Reproduce
Steps to reproduce the behavior:
2.7.0
springdoc-openapi-webmvc-core 1.6.9
springdoc-openapi-webflux-core 1.6.9
springdoc-openapi-common 1.6.9
yaml
Expected behavior
I expect the yaml to be generated with keys sorted alphabetically
The text was updated successfully, but these errors were encountered: