-
Notifications
You must be signed in to change notification settings - Fork 2
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
Accepting new connections gets stuck after too many threads have disconnected uncleanly #5
Comments
Reproduce should be trivially done with
|
Tracelog when in failed state
|
Maybe related teragrep/net_01#10 |
Extra logs
|
|
Fairly sure this is fixed with
|
this is expected when a connection is interrupted uncleanly, only beautification available for the exception and nothing else. |
create a pull request of the patch |
|
[to-9]$ git remote -v
origin https://github.com/kortemik/cfe_35.git (fetch)
origin https://github.com/kortemik/cfe_35.git (push)
[to-9]$ git pull
Already up to date. Results for "pool-2-thread-7" #46 [1856731] prio=5 os_prio=0 cpu=21540.78ms elapsed=983.26s tid=0x00007f715c1f1fb0 nid=1856731 waiting on condition [0x00007f721ebf5000]
java.lang.Thread.State: WAITING (parking)
at jdk.internal.misc.Unsafe.park(java.base@21.0.4/Native Method)
- parking to wait for <0x00000006a96af4e8> (a java.util.concurrent.CompletableFuture$Signaller)
at java.util.concurrent.locks.LockSupport.park(java.base@21.0.4/LockSupport.java:221)
at java.util.concurrent.CompletableFuture$Signaller.block(java.base@21.0.4/CompletableFuture.java:1864)
at java.util.concurrent.ForkJoinPool.unmanagedBlock(java.base@21.0.4/ForkJoinPool.java:3780)
at java.util.concurrent.ForkJoinPool.managedBlock(java.base@21.0.4/ForkJoinPool.java:3725)
at java.util.concurrent.CompletableFuture.waitingGet(java.base@21.0.4/CompletableFuture.java:1898)
at java.util.concurrent.CompletableFuture.get(java.base@21.0.4/CompletableFuture.java:2072)
at com.teragrep.cfe_35.router.ParallelTargetRouting.close(ParallelTargetRouting.java:182)
at com.teragrep.cfe_35.router.MessageParser.close(MessageParser.java:202)
at com.teragrep.rlp_03.frame.delegate.EventDelegate.close(EventDelegate.java:83)
at com.teragrep.rlp_03.frame.delegate.SequencingDelegate.close(SequencingDelegate.java:94)
at com.teragrep.rlp_03.frame.delegate.DefaultFrameDelegate.close(DefaultFrameDelegate.java:81)
at com.teragrep.rlp_03.frame.FrameDelegationClock.close(FrameDelegationClock.java:122)
at com.teragrep.net_01.channel.context.IngressImpl.close(IngressImpl.java:299)
at com.teragrep.net_01.channel.context.EstablishedContextImpl.close(EstablishedContextImpl.java:101)
at com.teragrep.net_01.channel.context.IngressImpl.run(IngressImpl.java:191)
at java.util.concurrent.Executors$RunnableAdapter.call(java.base@21.0.4/Executors.java:572)
at java.util.concurrent.FutureTask.run(java.base@21.0.4/FutureTask.java:317)
at java.util.concurrent.ThreadPoolExecutor.runWorker(java.base@21.0.4/ThreadPoolExecutor.java:1144)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(java.base@21.0.4/ThreadPoolExecutor.java:642)
at java.lang.Thread.runWith(java.base@21.0.4/Thread.java:1596)
at java.lang.Thread.run(java.base@21.0.4/Thread.java:1583) Server command and logs [to-9]$ java -DserverThreads=8 -Dcfe07LookupPath=src/test/resources/cfe_07 -Dcfe16LookupPath=src/test/resources/cfe_16 -Dkin02LookupPath=src/test/resources/kin_02 -DroutingTargetsConfig=src/test/resources/targetsPerformanceTest.json -DlistenPort=4600 -jar target/cfe_35.jar
WARNING: sun.reflect.Reflection.getCallerClass is not supported. This will impact performance.
12:25:52.993 [pool-2-thread-2] ERROR com.teragrep.net_01.channel.context.IngressImpl - run() threw
java.net.SocketException: Connection reset
at sun.nio.ch.SocketChannelImpl.throwConnectionReset(SocketChannelImpl.java:401) ~[?:?]
at sun.nio.ch.SocketChannelImpl.read(SocketChannelImpl.java:478) ~[?:?]
at java.nio.channels.SocketChannel.read(SocketChannel.java:630) ~[?:?]
at com.teragrep.net_01.channel.socket.PlainSocket.read(PlainSocket.java:65) ~[cfe_35.jar:0.0.1-SNAPSHOT]
at com.teragrep.net_01.channel.context.IngressImpl.readData(IngressImpl.java:237) ~[cfe_35.jar:0.0.1-SNAPSHOT]
at com.teragrep.net_01.channel.context.IngressImpl.run(IngressImpl.java:103) ~[cfe_35.jar:0.0.1-SNAPSHOT]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:572) ~[?:?]
at java.util.concurrent.FutureTask.run(FutureTask.java:317) ~[?:?]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1144) ~[?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:642) ~[?:?]
at java.lang.Thread.run(Thread.java:1583) ~[?:?]
12:25:56.973 [pool-2-thread-1] ERROR com.teragrep.net_01.channel.context.IngressImpl - run() threw
java.net.SocketException: Connection reset
at sun.nio.ch.SocketChannelImpl.throwConnectionReset(SocketChannelImpl.java:401) ~[?:?]
at sun.nio.ch.SocketChannelImpl.read(SocketChannelImpl.java:478) ~[?:?]
at java.nio.channels.SocketChannel.read(SocketChannel.java:630) ~[?:?]
at com.teragrep.net_01.channel.socket.PlainSocket.read(PlainSocket.java:65) ~[cfe_35.jar:0.0.1-SNAPSHOT]
at com.teragrep.net_01.channel.context.IngressImpl.readData(IngressImpl.java:237) ~[cfe_35.jar:0.0.1-SNAPSHOT]
at com.teragrep.net_01.channel.context.IngressImpl.run(IngressImpl.java:103) ~[cfe_35.jar:0.0.1-SNAPSHOT]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:572) ~[?:?]
at java.util.concurrent.FutureTask.run(FutureTask.java:317) ~[?:?]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1144) ~[?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:642) ~[?:?]
at java.lang.Thread.run(Thread.java:1583) ~[?:?] |
Describe the bug
cfe_35 output
Expected behavior
Can connect normally
How to reproduce
Launch server:
java -DserverThreads=8 -Dcfe07LookupPath=src/test/resources/cfe_07 -Dcfe16LookupPath=src/test/resources/cfe_16 -Dkin02LookupPath=src/test/resources/kin_02 -DroutingTargetsConfig=src/test/resources/targetsPerformanceTest.json -DlistenPort=4600 -jar target/cfe_35.jar
Spam tcpflood and cancel it with
^C
continuouslytcpflood -t 127.0.0.1 -T relp-plain -p 4600 -m 1000000 -M "<14>1 2020-05-15T13:24:03.603Z performance-test-host performance-test-tag - - - hello" -c 10 -Y
Screenshots
Software version
commit 2eba9c65400b1496ca23d4a295378b2c59891d00 (HEAD -> to-9, origin/to-9)
https://github.com/kortemik/cfe_35/tree/to-9
Desktop (please complete the following information if relevant):
Additional context
This COULD be rlp_03 issue but same version of server is implemented in rlp_08 and that does not suffer from this same issue.
The text was updated successfully, but these errors were encountered: