-
Notifications
You must be signed in to change notification settings - Fork 369
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
Support virtual threads #2311
Support virtual threads #2311
Conversation
fee6d10
to
d4a72ee
Compare
Signed-off-by: Achim Kraus <[email protected]>
Add connection to established connections before resume it. Signed-off-by: Achim Kraus <[email protected]>
761cf2b
to
c3603be
Compare
Remember to do |
Not clear, what you mean. In my experience, there is no need for that. The thread will either wait for a message or an "interrupt" on shutdown. For which use-case do you consider a socket timeout to be useful? |
Calling It may become the head of workQueue (depends on whether it overflows again when compareTo). If that happens, the unparker thread could park forever because getDelay is overflowed again to a very big number so everytime the head is peeked from queue, it will still have a positive delay and won't be executed(see java.util.concurrent.DelayQueue#poll()). See this jdk issue |
I tried virtual thread at Augest and succesfully started 60000 (limited by avaiable port of linux) with 7s communication period for 24-hours stress test. I write down what I do at this issue, please see if that helps. |
Not sure, at least The Is there a hidden mechanism, which uses a |
It's used by virtual thread unparker (java.lang.VirtualThread#UNPARKER) implictly. |
OK. Then it requires a "large timeout" smaller than |
I used something like 60 second,but maybe MAX_VALUE/2 is more general
…---Original---
From: "Achim ***@***.***>
Date: Tue, Dec 17, 2024 21:47 PM
To: ***@***.***>;
Cc: "Nick ***@***.******@***.***>;
Subject: Re: [eclipse-californium/californium] Support virtual threads (PR#2311)
OK. Then it requires a "large timeout" smaller than Long.MAX_VALUE? Which one did you use?
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you commented.Message ID: ***@***.***>
|
I added the socket timeout. |
It only happens when I start tens of thoudsands of client in very fast pace, and they all have short communication period (7s). Reproducing that maybe hard but at least setting a timeout won't have any bad effect. |
Signed-off-by: Achim Kraus <[email protected]>
Signed-off-by: Achim Kraus <[email protected]>
17b3199
to
ca3acd5
Compare
See using virtual threads for multiple client emulation.