-
Notifications
You must be signed in to change notification settings - Fork 271
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
Add OpenAPI compatibility checker #5106
Add OpenAPI compatibility checker #5106
Conversation
Thank you for creating a pull request! Pinging @jsenko to respond or triage. |
Thanks @simonnepomuk - we'll have a look at this asap and discuss. Using the diff as the basis for the compatibility check makes sense, and this could be a nice first step for OpenAPI compatibility. The problem with full OpenAPI compatibility checking is that there are lots of ways the API definition could change, and it's actually pretty hard to determine which of those changes are incompatible. I'll give you an example: If you add a new required property to a schema type, is that a compatible change? It probably depends on whether that schema type is used as an input to an operation (INCOMPATIBLE) or an output (COMPATIBLE). This is the kind of thing that has made us hesitate to implement the feature. That said, it could be argued that having at least some compatibility checking is better than none! |
Quick note to @simonnepomuk : could you please run |
@EricWittmann I've tried to apply the codestyles, hopefully the CI will run now :) Regarding your general concerns: I get your hesitation, thats why I delegated the "hard" work to the library provided through OpenAPI which also comes with compatibility checks. I'm not sure wether the tricky situations you described are picked up through the library or not, I would argue that the best way to go about it would be to resolve them over there though. Glancing through the library code gave me a solid impression though. If you have a list of hard to determine compatibility issues, I'd be happy to assist in analysing the OpenAPI diff library. Still, I would also agree with your last argument, that some checks are better than none. That should be noted in the documentation though, so people don't put too much trust in the compatibility checking mechanism. |
@EricWittmann Could you maybe retrigger the failed integration test workflow? Looks like some CI issue to me. I would need help in addressing the native image build errors as I have no clue whats going on there. |
Yeah we are having some issues with inconsistent CI results. We are working on that. As for the native image issues, I'll have @carlesarnal take a look. 😁 |
84c1cfc
to
41603fd
Compare
@carlesarnal Could you rerun the workflows? I think I fixed the native build issue, at least it runs on my machine now. |
41603fd
to
b18b370
Compare
Sorry, formatting was off again. Maybe we could add a pre-commit hook to run |
I was thinking the same thing recently actually. @andreaTP wdyt? |
@simonnepomuk Update: CI is failing for a new reason. Give us a day or two more, we're actively working on fixing CI. Once we do you can |
3c0043c
to
93f0e32
Compare
@simonnepomuk CI should be more reliable now, I recommend rebasing main (and I will approve the execution). |
93f0e32
to
37dc916
Compare
Done :) |
All green. Noice. @jsenko Any concerns? |
Thanks for the contribution @simonnepomuk - apologies it took so long to get merged. :) |
Hi guys,
this would be useful for many projects I'm facing with enterprise customers. Would be happy if someone would be able to review.
This should close #15