2nd attempt to post, illegalstateexception when doing IO from server using netty front end.
I had a better post that was blocked by your spam filter but I guess my question is about this stack trace obtained while trying to do DB write from a custom server that happens to use a netty front end? I guess in actual fact this is a feature of netty, but may be of relevance here although my first post was simply asking about Couchbase. Note that I did have a problem earlier with conflicts in various jar files such as
jettison and apache jars due to existing websocket and aws components. I guess I should not be doing
anything blocking from this thread but I'm still amazed it is throwing exception.
CouchebaseDBLocation insert error java.lang.IllegalStateException: await*() in I/O thread causes a dead lock or sudden performance drop. Use addListener() instead or call await*() from a different thread. java.lang.IllegalStateException: await*() in I/O thread causes a dead lock or sudden performance drop. Use addListener() instead or call await*() from a different thread.
at org.jboss.netty.channel.DefaultChannelFuture.checkDeadLock(DefaultChannelFuture.java:296)
at org.jboss.netty.channel.DefaultChannelFuture.awaitUninterruptibly(DefaultChannelFuture.java:208)
at com.couchbase.client.vbucket.BucketMonitor.createChannel(BucketMonitor.java:195)
at com.couchbase.client.vbucket.BucketMonitor.startMonitor(BucketMonitor.java:163)
at com.couchbase.client.vbucket.ConfigurationProviderHTTP.subscribe(ConfigurationProviderHTTP.java:229)
at com.couchbase.client.CouchbaseClient.(CouchbaseClient.java:217)
at com.couchbase.client.CouchbaseClient.(CouchbaseClient.java:156)
at com.phluant.third.data.CouchebaseDBLocation.getTableClient(CouchebaseDBLocation.java:597)
at com.phluant.third.data.CouchebaseDBLocation.insert(CouchebaseDBLocation.java:400)
at com.phluant.service.SpuriousLogCheck.insert(SpuriousLogCheck.java:321)
at com.phluant.service.SpuriousLogCheck.check(SpuriousLogCheck.java:259)
at com.phluant.service.RTLog.huntAndGather(RTLog.java:577)
at com.phluant.service.RTLog.dolog(RTLog.java:873)
at com.phluant.duhpus.DuphusRTLog.consume(DuphusRTLog.java:158)
at com.phluant.duhpus.DuphusLogPage.(DuphusLogPage.java:281)
at com.phluant.duhpus.DuphusServlet.req(DuphusServlet.java:542)
at com.phluant.netty.HttpRequestHandler.page(HttpRequestHandler.java:203)
at com.phluant.netty.HttpRequestHandler.m(HttpRequestHandler.java:352)
at com.phluant.netty.HttpRequestHandler.messageReceived(HttpRequestHandler.java:364)
at org.jboss.netty.channel.SimpleChannelUpstreamHandler.handleUpstream(SimpleChannelUpstreamHandler.java:80)
at org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:564)
at org.jboss.netty.channel.DefaultChannelPipeline$DefaultChannelHandlerContext.sendUpstream(DefaultChannelPipeline.java:783)
at org.jboss.netty.handler.codec.http.HttpContentEncoder.messageReceived(HttpContentEncoder.java:83)
at org.jboss.netty.channel.SimpleChannelHandler.handleUpstream(SimpleChannelHandler.java:100)
at org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:564)
at org.jboss.netty.channel.DefaultChannelPipeline$DefaultChannelHandlerContext.sendUpstream(DefaultChannelPipeline.java:783)
at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:302)
at org.jboss.netty.handler.codec.replay.ReplayingDecoder.unfoldAndFireMessageReceived(ReplayingDecoder.java:527)
at org.jboss.netty.handler.codec.replay.ReplayingDecoder.callDecode(ReplayingDecoder.java:506)
at org.jboss.netty.handler.codec.replay.ReplayingDecoder.messageReceived(ReplayingDecoder.java:443)
at org.jboss.netty.channel.SimpleChannelUpstreamHandler.handleUpstream(SimpleChannelUpstreamHandler.java:80)
at org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:564)
at org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:559)
at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:274)
at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:261)
at org.jboss.netty.channel.socket.nio.NioWorker.read(NioWorker.java:351)
at org.jboss.netty.channel.socket.nio.NioWorker.processSelectedKeys(NioWorker.java:282)
at org.jboss.netty.channel.socket.nio.NioWorker.run(NioWorker.java:202)
at org.jboss.netty.util.ThreadRenamingRunnable.run(ThreadRenamingRunnable.java:108)
at org.jboss.netty.util.internal.DeadLockProofWorker$1.run(DeadLockProofWorker.java:44)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
at java.lang.Thread.run(Thread.java:722)
I think I was just trying to insert. The issue seems to be netty, it has a reason to complain but surprised it threw LOL. Sure, I should make the inserts asynchronous and in real life they are done off line but for this test I just worked around it by using our non-netty port ( this server has multiple listen ports for development and the thread-per-page model on the other port works fine for initial checkout until I can get the threading figured out, this let's use accomodate blocking pages until they are fixed and do various side by side tests ).
I guess the general question is about use of couchbase in various setting that use netty and if this
throw ever becomes a real problem. Sure you don't want to block this thread but still.
Can you describe what your application was doing here?