-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Places to potentially find startup performance improvements #45436
Comments
@dmlloyd I wanted to move the relevant fields into a holder, but the need to support serialization prevents this approach. |
Another "big" (relatively) one @geoand is this -> smallrye/smallrye-common#370 this is very easy: just use 64 bytes cache line as other known projects does i.e. https://github.com/ziglang/zig/blob/master/lib/std/atomic.zig#L429 (which for both arm and x86 uses 2 * 64 bytes due to jbossas/jboss-threads#191) We are reading from a proc file, in linux, performing both a syscall, parsing and creating garbage for such. It looks an easy win with low impact. |
Just for posterity, the comment above should be handled by jbossas/jboss-threads#216 |
It also has to be handled here: I did a quick return with the expected bytes, and on my Mac I noticed around 20 ms improvement in the JVM startup time. |
What's the plan with |
With the change from @franz1981, I think that |
I was hoping @dmlloyd has an idea as my original idea won't work. |
Regarding this, we also do something for async initialize the JPA components. Should we have a unified/consistent approach? Just flagging it for awareness. |
Right, that thought did cross my mind |
2/3 ms for host name or for process name? or both? That seems like a pretty crazy number. Perhaps for host name, we should track the time and print a warning if it seems like DNS may be misconfigured (check your |
@radcortez do you plan on taking this one on soon? Asking because it definitely has a measurable impact. |
@dmlloyd any ideas about tackling this one? |
Yes, but only next week. |
🙏 |
I did mention this:
Another idea is to add access to the |
But if I'm not mistaken, the default Quarkus logging pattern does not use the hostname (or any process info), so wouldn't it be better if we didn't try to load it eagerly? |
That is an option. But I think it works be best to understand why it is slow and see if it can be fixed before jumping to that. |
On my machine (Linux), it definitely does not take nearly as long as @radcortez, but both the call to HostName and Process are noticeable: Looking at the flamegraph and the code, there don't seem to be any obvious wins for my case. |
Description
quarkus.uuid
provided eagerly -> Producequarkus.uuid
lazily #45434application.properties
/META-INF/microprofile-config.properties
reading from classpathExtLogRecord
looking upHostName
and Process related data that aren't needed by the default logging patternDefaultChannelId
)/etc/resolv.conf
handling -> Use simple parser instead of regex for parsing resolv.conf eclipse-vertx/vert.x#5439These ideas come from looking at this flamegraph
The text was updated successfully, but these errors were encountered: