-
Notifications
You must be signed in to change notification settings - Fork 592
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
Performance issue with mpOpenAPI-4.0 #30002
Comments
@jdmcclur They did change a lot of the internal structures to be map-based, but we shouldn't be initializing many of them on every request. I did raise concerns upstream when this change was added, but was assured that they didn't see a noticeable impact, so hopefully it's something we're doing and can fix.
I assume either our code is doing something stupid, or the smallrye internals are doing something stupid. We will initialize a few objects per-request because the servers and sometimes the info are set dynamically, but it shouldn't be many. |
Hmm, with a look at that very last part, |
We've made a fix upstream: smallrye/smallrye-open-api#2050 I've sent you a snapshot build via slack to see if that fixes all the performance issues, or if there are more problems. I think this is the cause of all the issues you found above, but it would be good to be sure it's not hiding anything else. |
The snapshot build looks much better. The reported issue above seems to be resolved. The throughput is still slower, but looks to be a different issue. |
We should be able to close this when SmallRye OpenAPI 4.0.1 is released and included in liberty. |
4.0.1 is now available https://github.com/smallrye/smallrye-open-api/releases/tag/4.0.1 |
When comparing the performance of hitting the /openapi endpoint with mpOpenAP1-3.1 to mpOpenAPI-4.0 I see a significant throughput regression with mpOpenAPI-4.0.
I don't totally understand what is going on, but it looks like lots of openapi internal model properties are getting initialized on every request (and put into a hashmap).
Farther up the stack
And above that
The text was updated successfully, but these errors were encountered: