Skip to content
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

[java]ThreadLocalFury has performance issues under virtual threads in jdk21 #1570

Open
gongziyiyi opened this issue Apr 24, 2024 · 3 comments
Labels
enhancement New feature or request

Comments

@gongziyiyi
Copy link

Is your feature request related to a problem? Please describe.

ThreadLocal has performance issues under virtual threads in jdk21

Describe the solution you'd like

maybe use CarrierThreadLocal ??

@gongziyiyi gongziyiyi added the enhancement New feature or request label Apr 24, 2024
@chaokunyang
Copy link
Collaborator

Will It create lots of Fury objects? For example, if we have million of virtual threads, will we have millions of Fury object?

@gongziyiyi
Copy link
Author

gongziyiyi commented Apr 26, 2024

@chaokunyang
Yes. CarrierThreadLocal can fix it, but unfortunately, it has not been leaked for external use and can only be opened with "--add-opens" at the moment

@chaokunyang
Copy link
Collaborator

We may need to add a new maven module to fury/java.

And I'm wondering whether can we use ThreadPoolFury, which use an object pool. This may be more friently to virtual thread

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants