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

Catch chat timeouts #63

Open
Filnor opened this issue Oct 1, 2020 · 6 comments
Open

Catch chat timeouts #63

Filnor opened this issue Oct 1, 2020 · 6 comments
Labels
bug confirmed Reported bugs that are reproducible or are confirmed in other ways bug Something isn't working

Comments

@Filnor
Copy link
Member

Filnor commented Oct 1, 2020

Stack trace excerpt:

org.sobotics.chatexchange.chat.ChatOperationException: java.net.SocketTimeoutException: Read timeout
        at org.sobotics.chatexchange.chat.Room.getMessage(Room.java:500)
        at org.sobotics.chatexchange.chat.event.MessageEvent.<init>(MessageEvent.java:22)
        at org.sobotics.chatexchange.chat.event.MessagePostedEvent.<init>(MessagePostedEvent.java:14)
        at org.sobotics.chatexchange.chat.event.Events.lambda$fromJsonData$3(Events.java:41)
        at java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:195)
        at java.base/java.util.stream.ReferencePipeline$2$1.accept(ReferencePipeline.java:177)
        at java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:195)
        at java.base/java.util.ArrayList$Itr.forEachRemaining(ArrayList.java:1033)
        at java.base/java.util.Spliterators$IteratorSpliterator.forEachRemaining(Spliterators.java:1801)
        at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:484)
        at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:474)
        at java.base/java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:913)
        at java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
        at java.base/java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:578)
        at org.sobotics.chatexchange.chat.event.Events.fromJsonData(Events.java:52)
        at org.sobotics.chatexchange.chat.Room.lambda$handleChatEvent$7(Room.java:229)
        at java.base/java.util.Optional.ifPresent(Optional.java:183)
        at org.sobotics.chatexchange.chat.Room.handleChatEvent(Room.java:228)
        at org.sobotics.chatexchange.chat.Room.access$300(Room.java:67)
        at org.sobotics.chatexchange.chat.Room$2.lambda$onOpen$0(Room.java:202)
        at org.glassfish.tyrus.core.TyrusSession.notifyMessageHandlers(TyrusSession.java:576)
        at org.glassfish.tyrus.core.TyrusEndpointWrapper.onMessage(TyrusEndpointWrapper.java:879)
        at org.glassfish.tyrus.core.TyrusWebSocket.onMessage(TyrusWebSocket.java:216)
        at org.glassfish.tyrus.core.frame.TextFrame.respond(TextFrame.java:139)
        at org.glassfish.tyrus.core.ProtocolHandler.process(ProtocolHandler.java:807)
        at org.glassfish.tyrus.client.TyrusClientEngine$TyrusReadHandler.handle(TyrusClientEngine.java:747)
        at org.glassfish.tyrus.container.jdk.client.ClientFilter.processRead(ClientFilter.java:227)
        at org.glassfish.tyrus.container.jdk.client.Filter.onRead(Filter.java:134)
        at org.glassfish.tyrus.container.jdk.client.Filter.onRead(Filter.java:136)
        at org.glassfish.tyrus.container.jdk.client.SslFilter.handleRead(SslFilter.java:406)
        at org.glassfish.tyrus.container.jdk.client.SslFilter.processRead(SslFilter.java:368)
        at org.glassfish.tyrus.container.jdk.client.Filter.onRead(Filter.java:134)
        at org.glassfish.tyrus.container.jdk.client.Filter.onRead(Filter.java:136)
        at org.glassfish.tyrus.container.jdk.client.TransportFilter$4.completed(TransportFilter.java:299)
        at org.glassfish.tyrus.container.jdk.client.TransportFilter$4.completed(TransportFilter.java:283)
        at java.base/sun.nio.ch.Invoker.invokeUnchecked(Invoker.java:127)
        at java.base/sun.nio.ch.UnixAsynchronousSocketChannelImpl.finishRead(UnixAsynchronousSocketChannelImpl.java:439)
        at java.base/sun.nio.ch.UnixAsynchronousSocketChannelImpl.finish(UnixAsynchronousSocketChannelImpl.java:191)
        at java.base/sun.nio.ch.UnixAsynchronousSocketChannelImpl.onEvent(UnixAsynchronousSocketChannelImpl.java:213)
        at java.base/sun.nio.ch.EPollPort$EventHandlerTask.run(EPollPort.java:306)
        at java.base/sun.nio.ch.AsynchronousChannelGroupImpl$1.run(AsynchronousChannelGroupImpl.java:112)
        at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
        at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
        at java.base/java.lang.Thread.run(Thread.java:834)
Caused by: java.net.SocketTimeoutException: Read timeout
@Filnor Filnor added bug Something isn't working bug confirmed Reported bugs that are reproducible or are confirmed in other ways labels Oct 1, 2020
@double-beep
Copy link
Member

I've not experienced such exceptions with Belisarius, so something is wrong with CYF's code, probably.

@Filnor
Copy link
Member Author

Filnor commented Oct 1, 2020 via email

@double-beep
Copy link
Member

I'll take a look. The commands may need a refactor.

@Filnor
Copy link
Member Author

Filnor commented Oct 2, 2020

I'll take a look. The commands may need a refactor.

Why that? The Exception is most likely from QuestionService, the commands should be working fine.

@double-beep
Copy link
Member

Why that?

Because the commands use (mostly) Room.getMessage(). Can you post the full stack trace?

@Filnor
Copy link
Member Author

Filnor commented Oct 2, 2020

Here you go.
CheckYerFlags.2020-10-01.log

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug confirmed Reported bugs that are reproducible or are confirmed in other ways bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants