| Summary: | NotYetConnectedException on first request to Jetty | ||
|---|---|---|---|
| Product: | [RT] Jetty | Reporter: | qquit27 |
| Component: | websocket | Assignee: | Jan Bartel <janb> |
| Status: | CLOSED WORKSFORME | QA Contact: | |
| Severity: | normal | ||
| Priority: | P3 | CC: | janb, jetty-inbox |
| Version: | unspecified | ||
| Target Milestone: | 7.5.x | ||
| Hardware: | Other | ||
| OS: | Linux | ||
| Whiteboard: | |||
|
Description
qquit27
Could you explain the test scenario a little more? How are you able to receive a request on a channel that is not connected? thanks Jan I only see the exceptions on our slow embedded device, running jamvm/ Java 1.5, roughly on every second/third startup, never on my local machine. Actually, I see them beeing thrown also in other lines of the ChannelEndPoint Class, where IO Operations are executed on _channel, however only in the first request right after starting jetty. E.g. java.nio.channels.NotYetConnectedException at gnu.java.nio.SocketChannelImpl.read(SocketChannelImpl.java:217) at gnu.java.net.PlainSocketImpl$SocketInputStream.read(PlainSocketImpl.java:587) at java.io.DataInputStream.readFully(DataInputStream.java:286) at java.io.DataInputStream.readInt(DataInputStream.java:323) at ch.belimo.bd.admin.SessionHandler.run(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:679) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:704) at java.lang.Thread.run(Thread.java:745) Might we run into race conditions on start up, because our device is so slow? Where is channel connect actually called? The exceptions sometimes result in jetty delivering incomplete documents on that first request, which on browser side results in quite unpredictable behavior. Thanks for your effort! Can you run jetty on your local machine using the jamvm and see if the problem occurs? I still can't see how its possible for a read to succeed on a socket that is not connected, unless there is something funny going on with the jvm. Jan (In reply to comment #2) > I only see the exceptions on our slow embedded device, running jamvm/ Java 1.5, > roughly on every second/third startup, never on my local machine. Actually, I > see them beeing thrown also in other lines of the ChannelEndPoint Class, where > IO Operations are executed on _channel, however only in the first request right > after starting jetty. E.g. > > java.nio.channels.NotYetConnectedException > at gnu.java.nio.SocketChannelImpl.read(SocketChannelImpl.java:217) > at > gnu.java.net.PlainSocketImpl$SocketInputStream.read(PlainSocketImpl.java:587) > at java.io.DataInputStream.readFully(DataInputStream.java:286) > at java.io.DataInputStream.readInt(DataInputStream.java:323) > at ch.belimo.bd.admin.SessionHandler.run(Unknown Source) > at > java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:679) > at > java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:704) > at java.lang.Thread.run(Thread.java:745) > > Might we run into race conditions on start up, because our device is so slow? > Where is channel connect actually called? The exceptions sometimes result in > jetty delivering incomplete documents on that first request, which on browser > side results in quite unpredictable behavior. > Thanks for your effort! Any more info on this? For example, running it with the same jvm on your local machine as on the embedded device? Indications are that this is something strange with the particular jvm in use. As the poster has not provided any further details, I will close this issue for now. If more details are provided that point to a problem with the jetty code, then please reopen. thanks Jan |