Synapse
  1. Synapse
  2. SYNAPSE-168

java.lang.IllegalStateException: I/O reactor has been shut down

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Critical Critical
    • Resolution: Fixed
    • Affects Version/s: 1.1-RC1
    • Fix Version/s: 1.1.1-QA-B2
    • Component/s: Transports
    • Labels:
      None
    • Environment:
      java 1.5.0_07, Mac OS X 10.4.10, endpoint made with Spring-WS deployed on JBoss 4.2.1

      Description

      Synapse configuration:

      <definitions xmlns="http://ws.apache.org/ns/synapse">

      <in>
      <log level="full"/>

      <send>
      <endpoint>
      <wsdl uri="http://hostname:2006/echo/echo.wsdl" service="EchoService" port="EchoPort">

      <suspendDurationOnFailure>5</suspendDurationOnFailure>
      <timeout>
      <duration>3</duration>
      <action>fault</action>
      </timeout>

      </wsdl>
      </endpoint>
      </send>

      </in>
      <out>
      <send/>
      </out>
      </definitions>

      When simple 'echo' endpoint is deployed and working - everything is OK.
      But when I undeploy it and ask Synapse, I've got series of exception:

      First query:
      2007-11-05 10:06:18,460 [ CUT ] [HttpServerWorker-5] INFO LogMediator To: /soap, WSAction: , SOAPAction: , Direction: request, Envelope: <?xml version='1.0' encoding='utf-8'?><soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:echo="http://www.springframework.org/spring-ws/samples/echo"><soapenv:Body>
      <echo:echoRequest>test123</echo:echoRequest>
      </soapenv:Body></soapenv:Envelope>
      Exception in thread "HttpCoreNIOSender" java.lang.NullPointerException
      at org.apache.synapse.transport.nhttp.ClientHandler.inputReady(ClientHandler.java:225)
      at org.apache.synapse.transport.nhttp.LoggingNHttpClientHandler.inputReady(LoggingNHttpClientHandler.java:113)
      at org.apache.http.impl.nio.DefaultNHttpClientConnection.consumeInput(DefaultNHttpClientConnection.java:135)
      at org.apache.synapse.transport.nhttp.PlainClientIOEventDispatch.inputReady(PlainClientIOEventDispatch.java:71)
      at org.apache.http.impl.nio.reactor.BaseIOReactor.readable(BaseIOReactor.java:94)
      at org.apache.http.impl.nio.reactor.AbstractIOReactor.processEvent(AbstractIOReactor.java:189)
      at org.apache.http.impl.nio.reactor.AbstractIOReactor.processEvents(AbstractIOReactor.java:174)
      at org.apache.http.impl.nio.reactor.AbstractIOReactor.execute(AbstractIOReactor.java:137)
      at org.apache.http.impl.nio.reactor.BaseIOReactor.execute(BaseIOReactor.java:69)
      at org.apache.http.impl.nio.reactor.AbstractMultiworkerIOReactor$Worker.run(AbstractMultiworkerIOReactor.java:281)
      at java.lang.Thread.run(Thread.java:613)

      Second query:
      2007-11-05 10:20:25,461 [ CUT ] [HttpServerWorker-14] ERROR Axis2Sender Unexpected error during sending message out
      java.lang.IllegalStateException: I/O reactor has been shut down
      at org.apache.http.impl.nio.reactor.DefaultConnectingIOReactor.connect(DefaultConnectingIOReactor.java:164)
      at org.apache.synapse.transport.nhttp.HttpCoreNIOSender.sendAsyncRequest(HttpCoreNIOSender.java:285)
      at org.apache.synapse.transport.nhttp.HttpCoreNIOSender.invoke(HttpCoreNIOSender.java:208)
      at org.apache.axis2.engine.AxisEngine.send(AxisEngine.java:396)
      at org.apache.synapse.core.axis2.DynamicAxisOperation$DynamicOperationClient.send(DynamicAxisOperation.java:192)
      at org.apache.synapse.core.axis2.DynamicAxisOperation$DynamicOperationClient.executeImpl(DynamicAxisOperation.java:176)
      at org.apache.axis2.client.OperationClient.execute(OperationClient.java:163)
      at org.apache.synapse.core.axis2.Axis2FlexibleMEPClient.send(Axis2FlexibleMEPClient.java:250)
      at org.apache.synapse.core.axis2.Axis2Sender.sendOn(Axis2Sender.java:55)
      at org.apache.synapse.core.axis2.Axis2SynapseEnvironment.send(Axis2SynapseEnvironment.java:200)
      at org.apache.synapse.endpoints.WSDLEndpoint.send(WSDLEndpoint.java:140)
      at org.apache.synapse.mediators.builtin.SendMediator.mediate(SendMediator.java:100)
      at org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:60)
      at org.apache.synapse.mediators.filters.InMediator.mediate(InMediator.java:60)
      at org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:60)
      at org.apache.synapse.mediators.base.SequenceMediator.mediate(SequenceMediator.java:122)
      at org.apache.synapse.core.axis2.Axis2SynapseEnvironment.injectMessage(Axis2SynapseEnvironment.java:154)
      at org.apache.synapse.core.axis2.SynapseMessageReceiver.receive(SynapseMessageReceiver.java:89)
      at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:145)
      at org.apache.axis2.transport.http.HTTPTransportUtils.processHTTPPostRequest(HTTPTransportUtils.java:275)
      at org.apache.synapse.transport.nhttp.ServerWorker.processPost(ServerWorker.java:218)
      at org.apache.synapse.transport.nhttp.ServerWorker.run(ServerWorker.java:182)
      at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675)
      at java.lang.Thread.run(Thread.java:613)

      End every next query ends with this exception.
      Even if I redeploy echo endpoint, Synapse does not process my requests and responses with 0 bytes:

      Mon Nov 05 10:13:59 CET 2007:INFO:Got response for [EchoBinding.echo:Request 1] in 18ms (0 bytes)

      And after a few seconds in logs I have:

      2007-11-05 10:19:06,408 [ CUT ] [Timer-0] INFO LogMediator To: /soap, WSAction: , SOAPAction: , Direction: request, Envelope: <?xml version='1.0' encoding='utf-8'?><soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:echo="http://www.springframework.org/spring-ws/samples/echo"><soapenv:Body>
      <echo:echoRequest>dupa123</echo:echoRequest>
      </soapenv:Body></soapenv:Envelope>

      After restarting Synapse everything backs to normal - so it isn't endpoint's issue.

      1. response_after_permgen.txt
        0.1 kB
        Maciej Majewski
      2. query.txt
        0.5 kB
        Maciej Majewski
      3. normal_response.txt
        0.6 kB
        Maciej Majewski
      4. error_response.txt
        1 kB
        Maciej Majewski
      5. echo.zip
        6.73 MB
        Maciej Majewski

        Activity

        Asankha C. Perera made changes -
        Resolution Fixed [ 1 ]
        Assignee Asankha C. Perera [ asankha ]
        Status Open [ 1 ] Resolved [ 5 ]
        Ruwan Linton made changes -
        Fix Version/s 1.1.1 [ 12312894 ]
        Maciej Majewski made changes -
        Attachment echo.zip [ 12369239 ]
        Maciej Majewski made changes -
        Attachment response_after_permgen.txt [ 12369238 ]
        Maciej Majewski made changes -
        Field Original Value New Value
        Attachment query.txt [ 12369235 ]
        Attachment normal_response.txt [ 12369236 ]
        Attachment error_response.txt [ 12369237 ]
        Maciej Majewski created issue -

          People

          • Assignee:
            Asankha C. Perera
            Reporter:
            Maciej Majewski
          • Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development