-
Notifications
You must be signed in to change notification settings - Fork 304
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
[WIP] Replace HK2/Types/Parser/Scanner with Jandex and cache in the domain #7165
base: main
Are you sure you want to change the base?
Conversation
void index(DeploymentContext deploymentContext) throws IOException; | ||
void reindex(DeploymentContext deploymentContext) throws IOException; | ||
boolean isJakartaEEApplication(DeploymentContext deploymentContext) throws IOException; | ||
Index getRootIndex(DeploymentContext deploymentContext); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You might want to avoid spreading the JBoss classes like i.e. Index
around in the Payara codebase.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Index
is kinda the whole point of this PR.
The issue is that current annotation scanning framework is not made for CDI, is slow, and can't be cached.
Jandex is a small, separate project, has no dependencies, and is tailor made for CDI.
While it did come from JBoss, it's no longer embedded in that ecosystem and can be used unencumbered.
Any effort to isolate Index
class will result in an unnecessary wrapper that would not add any value.
Do you have a specific suggestion? Am I missing something?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It would result in a wrapper class. I agree. But I would call it a useful one. It allows to control and limit the interface towards payara code and allows to switch technology if needed/wanted.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
And you could have convenience methods useful for payaras interaction with the index.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's see where this goes... I think it's only used in one place anyway
543e287
to
75c6091
Compare
bdfa809
to
aa27959
Compare
7ed90c6
to
c4b0809
Compare
c4b0809
to
e9093da
Compare
91a9a95
to
d11a3f6
Compare
…ssue" This reverts commit 52b79c5.
- delay Jandex cache writing until after deployment
…combined EAR CDI deployment
…d on the actual type of the injection point desired
Deploy performance improvements
This is an experiment (for now)
This PR achieves at least 1.5X improvement when dependencies are not cached, which is a worst-case scenario.
I have seen as much as 5X performance improvement on a warmed-up JVM with dependencies cached,
with many dependencies.
Feedback is appreciated
Thank you.
Fixes #7079
issue-reproducers/cdi-unknownbda
reproducer