Menu

got IllegalThreadStateException

Help
2006-12-08
2013-04-29
  • flyingforce

    flyingforce - 2006-12-08

    got IllegalThreadStateException exception many times.

    The exception will be thrown when i try to add friend, send message, connect, can you tell me how to do to decrease its frequency?

     
    • Daniel Henninger

      Hrm, unfortunately I've never seen this happen before so I don't have a base for any suggestions.  Can you provide full stack traces or any further info?

       
    • flyingforce

      flyingforce - 2006-12-08

      Sorry, I think i had post the wront exception, the exception should be "IllegalStateException", not the "IllegalThreadStateException"

      Unfortunately, i had remove the error log by mistake, and now i am waiting for the new exception thrown.

       
    • flyingforce

      flyingforce - 2006-12-12

      Exception in thread "Thread-1113" java.lang.IllegalStateException: session is not available
              at net.sf.cindy.impl.ChannelSession.blockWrite(ChannelSession.java:340)
              at net.sf.jml.protocol.MsnSession.sendSynchronousMessage(MsnSession.java:187)
              at net.sf.jml.impl.BasicMessenger.send(BasicMessenger.java:110)
              at net.sf.jml.impl.AbstractMessenger.send(AbstractMessenger.java:103)
              at net.sf.jml.protocol.incoming.IncomingUSR$1.run(IncomingUSR.java:206)

      The staketrace for the IllegalStateException is this, can you help me to figure out what's wrong?

      Many thanks for your support.

       
      • Daniel Henninger

        Ug, sorry for the delay, I'm not getting notifications when folk post to the forums for some reason.  =/

        Is this only occuring during the addFriend and did the patch you submitted silence it?  It looks like something caused MSN to kill your connection and that that sever wasn't picked up.  Are you able to do anything after the errors start showing up?

         
    • flyingforce

      flyingforce - 2006-12-12

      Another 2 staketrace for the exception, they were threw when I try to add friend:

      java.lang.IllegalStateException: session is not available
              at net.sf.cindy.impl.ChannelSession.blockWrite(ChannelSession.java:340)
              at net.sf.jml.protocol.MsnSession.sendSynchronousMessage(MsnSession.java:187)
              at net.sf.jml.impl.BasicMessenger.send(BasicMessenger.java:110)
              at net.sf.jml.impl.AbstractMessenger.send(AbstractMessenger.java:103)
              at net.sf.jml.impl.SimpleMessenger.addFriend(SimpleMessenger.java:100)
              at net.sf.jml.impl.SimpleMessenger.addFriend(SimpleMessenger.java:155)
              at com.Laifan.MSN.MSNThread.addUser(MSNThread.java:337)
              at com.Laifan.MSN.MSNThread.setConnected(MSNThread.java:222)
              at com.Laifan.MSN.OrderRobot$OrderMsnListener.contactListInitCompleted(OrderRobot.java:206)
              at net.sf.jml.impl.AbstractMessenger.fireContactListInitCompleted(AbstractMessenger.java:230)
              at net.sf.jml.protocol.outgoing.OutgoingPNG.receivedResponse(OutgoingPNG.java:64)
              at net.sf.jml.protocol.MsnSession$1.messageReceived(MsnSession.java:112)
              at net.sf.cindy.impl.AbstractSession$6.doRun(AbstractSession.java:341)
              at net.sf.cindy.impl.AbstractSession$DispatchObject.run(AbstractSession.java:395)
              at net.sf.cindy.impl.SimpleDispatcher.dispatch(SimpleDispatcher.java:35)
              at net.sf.cindy.impl.AbstractSession.dispatch(AbstractSession.java:249)
              at net.sf.cindy.impl.AbstractSession.dispatchMessageReceived(AbstractSession.java:335)
              at net.sf.cindy.impl.StreamChannelSession.recognizeMessageAndDispatch(StreamChannelSession.java:77)
              at net.sf.cindy.impl.StreamChannelSession.readFromChannel(StreamChannelSession.java:53)
              at net.sf.cindy.impl.ChannelSession.onReadable(ChannelSession.java:212)
              at net.sf.cindy.impl.ChannelSession.onEvent(ChannelSession.java:134)
              at net.sf.cindy.impl.SocketSession.onEvent(SocketSession.java:119)
              at net.sf.cindy.impl.SimpleEventGenerator.processKey(SimpleEventGenerator.java:212)
              at net.sf.cindy.impl.SimpleEventGenerator.run(SimpleEventGenerator.java:192)
              at net.sf.cindy.impl.SimpleEventGenerator.access$000(SimpleEventGenerator.java:54)
              at net.sf.cindy.impl.SimpleEventGenerator$1.run(SimpleEventGenerator.java:115)

      java.lang.IllegalStateException: session is not available
              at net.sf.cindy.impl.ChannelSession.blockWrite(ChannelSession.java:340)
              at net.sf.jml.protocol.MsnSession.sendSynchronousMessage(MsnSession.java:187)
              at net.sf.jml.impl.BasicMessenger.send(BasicMessenger.java:110)
              at net.sf.jml.impl.AbstractMessenger.send(AbstractMessenger.java:103)
              at net.sf.jml.impl.SimpleMessenger.addFriend(SimpleMessenger.java:100)
              at net.sf.jml.impl.SimpleMessenger.addFriend(SimpleMessenger.java:155)
              at com.Laifan.MSN.MSNThread.addUser(MSNThread.java:337)
              at com.Laifan.MSN.MSNThread.setConnected(MSNThread.java:222)
              at com.Laifan.MSN.OrderRobot$OrderMsnListener.contactListInitCompleted(OrderRobot.java:206)
              at net.sf.jml.impl.AbstractMessenger.fireContactListInitCompleted(AbstractMessenger.java:230)
              at net.sf.jml.protocol.outgoing.OutgoingPNG.receivedResponse(OutgoingPNG.java:64)
              at net.sf.jml.protocol.MsnSession$1.messageReceived(MsnSession.java:112)
              at net.sf.cindy.impl.AbstractSession$6.doRun(AbstractSession.java:341)
              at net.sf.cindy.impl.AbstractSession$DispatchObject.run(AbstractSession.java:395)
              at net.sf.cindy.impl.SimpleDispatcher.dispatch(SimpleDispatcher.java:35)
              at net.sf.cindy.impl.AbstractSession.dispatch(AbstractSession.java:249)
              at net.sf.cindy.impl.AbstractSession.dispatchMessageReceived(AbstractSession.java:335)
              at net.sf.cindy.impl.StreamChannelSession.recognizeMessageAndDispatch(StreamChannelSession.java:77)
              at net.sf.cindy.impl.StreamChannelSession.readFromChannel(StreamChannelSession.java:53)
              at net.sf.cindy.impl.ChannelSession.onReadable(ChannelSession.java:212)
              at net.sf.cindy.impl.ChannelSession.onEvent(ChannelSession.java:134)
              at net.sf.cindy.impl.SocketSession.onEvent(SocketSession.java:119)
              at net.sf.cindy.impl.SimpleEventGenerator.processKey(SimpleEventGenerator.java:212)
              at net.sf.cindy.impl.SimpleEventGenerator.run(SimpleEventGenerator.java:192)
              at net.sf.cindy.impl.SimpleEventGenerator.access$000(SimpleEventGenerator.java:54)
              at net.sf.cindy.impl.SimpleEventGenerator$1.run(SimpleEventGenerator.java:115)

       
    • flyingforce

      flyingforce - 2006-12-18

      Yes, u r right.

      It seems my other process run the msn, and it break the current msn connection.

      I am working on fix the bug and will upate u if i think there is something can be updated for the JMSN library. Many thanks for your help.

       

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.