-
-
Notifications
You must be signed in to change notification settings - Fork 523
/v3/api-docs inconsistence of operationId #96
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
It affects also other fields... With my schema openAPi.yaml at first generation is correct, when I refresh swagger or openApi url new file is wrong. Eg. First invocation:
Second refresh:
On version 1.1.39 only changing operation id is affected. On newest 1.1.43 both error schema and operationId are wrong. Moreover the order of paths is different when I generate openApi.yaml/json with 1.1.39 vs 1.1.43 |
Hi maciejkujawski, The id operaration, generated dynamically should not have an impact on other fields. |
You can reproduce it with:
|
thx you guys i don't have time to demo this today :D |
When it comes to "flip-flopping" operationId or changing order of paths maybe it's not critical but I am using your library to generate openAPI.yaml during tests and based on fact: the file changed or not we may generate some documentation + verify the external API was changed or not. Btw: It is possible to force current implementation to preserve the operationId with annotation:
but I guess it's workaround ;-) |
I guess swagger openapi Paths should be sorted before you return OpenAPI because Paths is based on LinkedList, so the order of iterating over Controllers affects the order of paths that are presented on openAPI.yaml. So it seems it might be somehow different between runs of application. I guess it affects also models. |
Hi, The fix for this issue, will be available on v1.1.44 of springdoc-openapi. |
|
This issue does not seem to be fixed. This causes our code, which uses clients generated by swagger-codegen, to break. |
Please see the rules of Using GitHub Issues You should be using the last stable version, before repoting any issue. |
Using the latest version (1.1.42) the api returns "flip-flopping" the operation id with "_1" as a suffix
First Time:
After:
Then:
and again
thanks in advance
The text was updated successfully, but these errors were encountered: