-
Notifications
You must be signed in to change notification settings - Fork 536
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
Deadlock in OpenAPI RouterBuilder #2383
Comments
Hi, there is a complete new rebuild of the OpenAPI Router [1], which hopefully solves the problem. Please check out if this works for you. |
We've been watching the new openapi router work. I'd like to move to the newer json schema versions for sure. I tried a first integration pass, but we're stuck on the loading of the OpenAPIContract because it doesn't support json schemas in the additional contract files. I made a comment on a relevant issue in the verx-openapi project. We have a bunch of json schemas that are separate from our openapi files. Once all of that works for us then I think this issue loses relevance. We were able to get around the deadlock by refactoring the schemas a bit. |
@pk-work Do you know if the smallrye-mutiny wrapper is available? |
@tnmtechnologies it doesn't look like that [1]. @jponge what do I need to do, to have mutiny bindings? [1] https://github.com/smallrye/smallrye-mutiny-vertx-bindings/tree/main/vertx-mutiny-clients |
@jponge can you check if this commit fits? smallrye/smallrye-mutiny-vertx-bindings#926 |
MR is merged, I guess with the next release the mutiny bindings will be created. I close this issue now. |
Hello, could please someone clarify, the fix of the issue is included in https://github.com/vert-x3/vertx-web/releases/tag/4.5.8 ? |
There was an issue with visibility in vertx-openapi. Because of this the change was reverted [1]. Maybe you keep track of this issue [2]. [1] smallrye/smallrye-mutiny-vertx-bindings#930 |
@pk-work Oh, thanks. I followed-up in smallrye/smallrye-mutiny-vertx-bindings#920. |
Hi @pk-work, We have tried the new rebuild of the OpenAPI Router. In our project, we work with more than 100 OpenAPI files, most of them are very large with several dozen of operations. All our OpenAPI documents are OpenAPI 3.0 compliant. To sum up, the behavior of the new library is very restrictive compared to that of the previous library for our use case. We can understand restrictive use cases for safety reasons, for example, but there are also use cases where this is not necessary like for our use case. I hope that the description of our use case and our needs are well described. Please let us know your point of view. Kind Regards.
|
@tnmtechnologies I think this is related to eclipse-vertx/vertx-openapi#74 isn't it? If this is truem let's continue there, to avoid to spread the discussion into multiple threads. I just posted my opinion on relative references there. |
Questions
N/A
Version
4.3.4 to 4.3.8
Context
We're seeing deadlocks (probably), but only in my CI pipeline that's running unit tests. We're using a gitlab runner in an AWS T3-medium, EC2 instance for our CI pipeline. Vertx starts up completely fine on our dev machines and works in our production environments as well. I've done a lot of experimenting and diagnosing to pinpoint where the issue is occurring and I'm very confident that something weird is going on in Vertx with some of the weirder json schemas that we have.
The deadlock/hanging happens when we're standing up our Vertx server and specifically when we're using the OpenAPI RouterBuilder for reading in an OpenAPI spec. It has something to do with the Json Schemas that we're referencing in that spec and specifically with combinations of "oneOf" and "$ref" in those schemas. I've seen the deadlock/hanging occur on different OpenAPI specs after reordering them in our actual project. It's like Vertx gets overloaded with $refs and is unable to continue processing the json schemas.
Do you have a reproducer?
I was able to reproduce the issue with this project. Similarly, tests run just fine on a dev machine, but the deadlock/hanging occurs in our CI pipeline when the tests are ran.
https://github.com/jawaff/vert-test
Here's some suspicious exception from Vertx's
OpenAPIHolderImpl
that was repeatedly printed in our CI pipeline (the process has been getting killed by the gitlab-runner after one hour due to a timeout, but taks ~9 seconds to run locally):Steps to reproduce
Extra
We're using Java 8 and OSX for development. I don't have a lot of information about our CI environment, but I can look further into that if it's needed.
The text was updated successfully, but these errors were encountered: