Re: [mule-user] tcp error

4 wyświetlenia
Przejdź do pierwszej nieodczytanej wiadomości

PawanModi

nieprzeczytany,
1 sie 2008, 08:37:481.08.2008
do us...@mule.codehaus.org

Hello ,

I am also getting "ERROR Caught exception in Exception Strategy: Software
caused connection abort"
I am using Mule 2.0. I am opting mule services using RemoteDispatcher. Using
JMS connector in my mule config file & OpenMQ broker. I have JMS & Vm
endpoints in my config file.

In this thread i found 2 solutions for above mentioned error.

1. Using length protocol but that is valid for TCP connector. What is the
solution for JMS connector & how?

2. Using HTTP endpoints. How can i use HTTP endpoints with JMS connectors?

My question may sound very dumb but i have to put query accross forum, as
not able to find any solution for the following exception.


Following is the exception i am getting
---------------------------------------------
2008-08-01 13:27:49 BST [connector.tcp.0.receiver.9] ERROR Caught exception
in Exception Strategy: Software caused connection abort: so
cket write error
java.net.SocketException: Software caused connection abort: socket write
error
at java.net.SocketOutputStream.socketWrite0(Native Method)
at java.net.SocketOutputStream.socketWrite(Unknown Source)
at java.net.SocketOutputStream.write(Unknown Source)
at java.io.BufferedOutputStream.flushBuffer(Unknown Source)
at java.io.BufferedOutputStream.flush(Unknown Source)
at java.io.DataOutputStream.flush(Unknown Source)
at
org.mule.transport.tcp.protocols.LengthProtocol.writeByteArray(LengthProtocol.java:96)
at
org.mule.transport.tcp.protocols.AbstractByteProtocol.write(AbstractByteProtocol.java:81)
at
org.mule.transport.tcp.protocols.AbstractByteProtocol.write(AbstractByteProtocol.java:77)
at
org.mule.transport.tcp.protocols.SafeProtocol.write(SafeProtocol.java:56)
at
org.mule.transport.tcp.TcpMessageReceiver$TcpWorker.handleResults(TcpMessageReceiver.java:390)
at
org.mule.transport.AbstractReceiverWorker.doRun(AbstractReceiverWorker.java:132)
at
org.mule.transport.AbstractReceiverResourceWorker.doRun(AbstractReceiverResourceWorker.java:51)
at
org.mule.transport.AbstractReceiverWorker.run(AbstractReceiverWorker.java:62)
at org.mule.work.WorkerContext.run(WorkerContext.java:310)
at
edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1061)
at
edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:575)
at java.lang.Thread.run(Unknown Source)
2008-08-01 13:27:49 BST [connector.tcp.0.receiver.9] INFO Socket exception
occured: Software caused connection abort: recv failed


Please suggest how can i solve the above exception?

Thanks & regards,
Pawan Modi

Andrew Perepelytsya wrote:
>
> Juan,
>
> Yes, it definitely is. Mule TCK contains a test case, tcp-sync.xml, which
> shows how to solve this problem by using the LengthProtocol in
> TcpConnector.
> I'm not sure at the moment how you specify the length protocol for
> MuleClient (perhaps, set some properties?), browsing the code might help.
>
> BTW, I solved this problem in yet another way: use http endpoint for the
> admin connections. Http protocol inherently knows the size of the post
> request and content-length of the reply, so the problem is gone
> automagically.
>
> Andrew
>
> On 3/21/06, Juan M. Sanmarco <jsan...@luminaamericas.com> wrote:
>>
>> Hi, I'm invoking Mule using the remoteDispatcher instance of the
>> MuleClient. The mule server is configured to listen to a tcp port for
>> admin
>> messages:
>>
>> <mule-environment-properties synchronous="true"
>> serverUrl="tcp://machine1:12500"/>
>>
>>
>>
>> When performing a request-reply invocation, I get this error (at the
>> moment to send the reply back to the client) on the server side:
>>
>>
>>
>> ERROR 2006-03-21 15:52:59,998
>> [_tcpConnector#33017287._muleManagerEndpoint.receiver.2]
>> org.mule.impl.DefaultExceptionStrategy: Caught exception in Exception
>> Strategy: Software caused connection abort: socket write error
>>
>> java.net.SocketException: Software caused connection abort: socket write
>> error
>>
>> at java.net.SocketOutputStream.socketWrite0(Native Method)
>>
>> at java.net.SocketOutputStream.socketWrite(
>> SocketOutputStream.java:92)
>>
>> at java.net.SocketOutputStream.write(SocketOutputStream.java
>> :136)
>>
>> at java.io.BufferedOutputStream.write(
>> BufferedOutputStream.java:106)
>>
>> at java.io.DataOutputStream.write(DataOutputStream.java:85)
>>
>> at java.io.FilterOutputStream.write(FilterOutputStream.java
>> :80)
>>
>> at org.mule.providers.tcp.protocols.DefaultProtocol.write(
>> DefaultProtocol.java:82)
>>
>> at org.mule.providers.tcp.TcpMessageReceiver$TcpWorker.run(
>> TcpMessageReceiver.java:233)
>>
>> at org.mule.impl.work.WorkerContext.run(WorkerContext.java
>> :290)
>>
>> at
>> edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor$Worker.runTask
>> (ThreadPoolExecutor.java:643)
>>
>> at
>> edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor$Worker.run
>> (ThreadPoolExecutor.java:668)
>>
>> at java.lang.Thread.run(Thread.java:534)
>>
>> WARN 2006-03-21 15:52:59,998
>> [_tcpConnector#33017287._muleManagerEndpoint.receiver.2]
>> org.mule.config.ExceptionHelper: Failed to load error mappings from:
>> META-INF/services/org/mule/config/tcp-exception-mappings.properties. This
>> may be because there are no error code mappings for protocol: tcp
>>
>> DEBUG 2006-03-21 15:52:59,998
>> [_tcpConnector#33017287._muleManagerEndpoint.receiver.2]
>> org.mule.providers.tcp.TcpMessageReceiver: Closing listener:
>> 0.0.0.0/0.0.0.0:12500
>>
>>
>>
>> And this error on the client side:
>>
>>
>>
>> ERROR 2006-03-21 15:52:59,873 [main]
>> com.lumina.integration.MuleIntegrationAPI: Failed to route event via
>> endpoint: ImmutableMuleEndpoint{connector=
>> org.mule.providers.tcp.TcpConnector@125d61e,
>> endpointUri=tcp://localhost:12500,
>> transformer=Transformer{name='StringToByteArray', returnClass=false,
>> returnClass=false, sourceTypes=[class java.lang.String, class [B]},
>> name='_tcpEndpoint#-399972053', type='sender', properties={},
>> transactionConfig=Transaction{factory=null, action=NONE, timeout=30000},
>> filter=null, deleteUnacceptedMessages=false, initialised=false,
>> securityFilter=null, synchronous=true, initialState=started,
>> createConnector=0, remoteSync=true, remoteSyncTimeout=null,
>> endpointEncoding=null}. Message payload is of type: java.lang.String
>>
>> org.mule.umo.provider.DispatchException: Failed to route event via
>> endpoint: ImmutableMuleEndpoint{connector=
>> org.mule.providers.tcp.TcpConnector@125d61e,
>> endpointUri=tcp://localhost:12500,
>> transformer=Transformer{name='StringToByteArray', returnClass=false,
>> returnClass=false, sourceTypes=[class java.lang.String, class [B]},
>> name='_tcpEndpoint#-399972053', type='sender', properties={},
>> transactionConfig=Transaction{factory=null, action=NONE, timeout=30000},
>> filter=null, deleteUnacceptedMessages=false, initialised=false,
>> securityFilter=null, synchronous=true, initialState=started,
>> createConnector=0, remoteSync=true, remoteSyncTimeout=null,
>> endpointEncoding=null}. Message payload is of type: java.lang.String
>>
>> at org.mule.extras.client.RemoteDispatcher.dispatchAction(
>> RemoteDispatcher.java:297)
>>
>> at org.mule.extras.client.RemoteDispatcher.doToRemote(
>> RemoteDispatcher.java:246)
>>
>> at org.mule.extras.client.RemoteDispatcher.sendRemote(
>> RemoteDispatcher.java:171)
>>
>> at com.lumina.integration.MuleIntegrationAPI.requestReply(
>> MuleIntegrationAPI.java:131)
>>
>> at
>> com.lumina.silver.integration.IntegrationFacade.getAllEquitiesSpot(
>> IntegrationFacade.java:199)
>>
>> at
>> com.lumina.silver.integration.IntegrationFacadeTest.testGetEquitiesSpotFromFPA
>> (IntegrationFacadeTest.java:107)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>> Method)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke(
>> NativeMethodAccessorImpl.java:39)
>>
>> at sun.reflect.DelegatingMethodAccessorImpl.invoke(
>> DelegatingMethodAccessorImpl.java:25)
>>
>> at java.lang.reflect.Method.invoke(Method.java:324)
>>
>> at junit.framework.TestCase.runTest(TestCase.java:154)
>>
>> at junit.framework.TestCase.runBare(TestCase.java:127)
>>
>> at junit.framework.TestResult$1.protect(TestResult.java:106)
>>
>> at junit.framework.TestResult.runProtected(TestResult.java
>> :124)
>>
>> at junit.framework.TestResult.run(TestResult.java:109)
>>
>> at junit.framework.TestCase.run(TestCase.java:118)
>>
>> at junit.framework.TestSuite.runTest(TestSuite.java:208)
>>
>> at junit.framework.TestSuite.run(TestSuite.java:203)
>>
>> at junit.textui.TestRunner.doRun(TestRunner.java:116)
>>
>> at com.intellij.rt.execution.junit2.IdeaJUnitAgent.doRun(
>> IdeaJUnitAgent.java:58)
>>
>> at junit.textui.TestRunner.start(TestRunner.java:172)
>>
>> at
>> com.intellij.rt.execution.junit.TextTestRunner2.startRunnerWithArgs(
>> TextTestRunner2.java:23)
>>
>> at
>> com.intellij.rt.execution.junit2.JUnitStarter.prepareStreamsAndStart(
>> JUnitStarter.java:98)
>>
>> at com.intellij.rt.execution.junit2.JUnitStarter.main(
>> JUnitStarter.java:32)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
>> Method)
>>
>> at sun.reflect.NativeMethodAccessorImpl.invoke(
>> NativeMethodAccessorImpl.java:39)
>>
>> at sun.reflect.DelegatingMethodAccessorImpl.invoke(
>> DelegatingMethodAccessorImpl.java:25)
>>
>> at java.lang.reflect.Method.invoke(Method.java:324)
>>
>> at com.intellij.rt.execution.application.AppMain.main(
>> AppMain.java:90)
>>
>> Caused by: com.thoughtworks.xstream.converters.ConversionException: : no
>> more data available - expected end tags
>> </com.lumina.silver.integration.fpa.operations.vo.FPAEquitiesSpotVO></message></adapter></org.mule.impl.MuleMessage>
>> to close start tag <
>> com.lumina.silver.integration.fpa.operations.vo.FPAEquitiesSpotVO> from
>> line 803 and start tag <message> from line 3 and start tag <adapter> from
>> line 2 and start tag <org.mule.impl.MuleMessage> from line 1, parser
>> stopped on TEXT seen
>> ...</com.lumina.silver.integration.fpa.operations....
>> @819:54
>>
>> ---- Debugging information ----
>>
>> required-type :
>> com.lumina.silver.integration.fpa.operations.vo.FPAEquitiesSpotVO
>>
>> cause-message : : no more data available - expected end tags
>> </com.lumina.silver.integration.fpa.operations.vo.FPAEquitiesSpotVO></message></adapter></org.mule.impl.MuleMessage>
>> to close start tag <
>> com.lumina.silver.integration.fpa.operations.vo.FPAEquitiesSpotVO> from
>> line 803 and start tag <message> from line 3 and start tag <adapter> from
>> line 2 and start tag <org.mule.impl.MuleMessage> from line 1, parser
>> stopped on TEXT seen
>> ...</com.lumina.silver.integration.fpa.operations....
>> @819:54
>>
>> class : org.mule.impl.MuleMessage
>>
>> message : : *no more data available* - expected end tags
>> </com.lumina.silver.integration.fpa.operations.vo.FPAEquitiesSpotVO></message></adapter></org.mule.impl.MuleMessage>
>> to close start tag <
>> com.lumina.silver.integration.fpa.operations.vo.FPAEquitiesSpotVO> from
>> line 803 and start tag <message> from line 3 and start tag <adapter> from
>> line 2 and start tag <org.mule.impl.MuleMessage> from line 1, parser
>> stopped on TEXT seen
>> ...</com.lumina.silver.integration.fpa.operations....
>> @819:54
>>
>> line number : 819
>>
>> path :
>> /org.mule.impl.MuleMessage/adapter/message/com.lumina.silver.integration.fpa.operations.vo.FPAEquitiesSpotVO[48]
>>
>>
>> cause-exception : com.thoughtworks.xstream.io.StreamException
>>
>> -------------------------------
>>
>> at
>> com.thoughtworks.xstream.core.TreeUnmarshaller.convertAnother(
>> TreeUnmarshaller.java:45)
>>
>> at
>> com.thoughtworks.xstream.core.ReferenceByXPathUnmarshaller.convertAnother(
>> ReferenceByXPathUnmarshaller.java:39)
>>
>> at
>> com.thoughtworks.xstream.converters.collections.AbstractCollectionConverter.readItem
>> (AbstractCollectionConverter.java:82)
>>
>> at
>> com.thoughtworks.xstream.converters.collections.CollectionConverter.populateCollection
>> (CollectionConverter.java:60)
>>
>> at
>> com.thoughtworks.xstream.converters.collections.CollectionConverter.unmarshal
>> (CollectionConverter.java:53)
>>
>> at
>> com.thoughtworks.xstream.core.TreeUnmarshaller.convertAnother(
>> TreeUnmarshaller.java:38)
>>
>> at
>> com.thoughtworks.xstream.core.ReferenceByXPathUnmarshaller.convertAnother(
>> ReferenceByXPathUnmarshaller.java:39)
>>
>> at
>> com.thoughtworks.xstream.converters.reflection.ReflectionConverter.unmarshal
>> (ReflectionConverter.java:100)
>>
>> at
>> com.thoughtworks.xstream.core.TreeUnmarshaller.convertAnother(
>> TreeUnmarshaller.java:38)
>>
>> at
>> com.thoughtworks.xstream.core.ReferenceByXPathUnmarshaller.convertAnother(
>> ReferenceByXPathUnmarshaller.java:39)
>>
>> at
>> com.thoughtworks.xstream.converters.reflection.ReflectionConverter.unmarshal
>> (ReflectionConverter.java:100)
>>
>> at
>> com.thoughtworks.xstream.core.TreeUnmarshaller.convertAnother(
>> TreeUnmarshaller.java:38)
>>
>> at
>> com.thoughtworks.xstream.core.ReferenceByXPathUnmarshaller.convertAnother(
>> ReferenceByXPathUnmarshaller.java:39)
>>
>> at com.thoughtworks.xstream.core.TreeUnmarshaller.start(
>> TreeUnmarshaller.java:99)
>>
>> at
>> com.thoughtworks.xstream.core.ReferenceByXPathMarshallingStrategy.unmarshal
>> (ReferenceByXPathMarshallingStrategy.java:12)
>>
>> at com.thoughtworks.xstream.XStream.unmarshal(XStream.java
>> :521)
>>
>> at com.thoughtworks.xstream.XStream.unmarshal(XStream.java
>> :509)
>>
>> at com.thoughtworks.xstream.XStream.fromXML(XStream.java:475)
>>
>> at com.thoughtworks.xstream.XStream.fromXML(XStream.java:468)
>>
>> at org.mule.extras.client.RemoteDispatcher.dispatchAction(
>> RemoteDispatcher.java:285)
>>
>> ... 28 more
>>
>> Caused by: com.thoughtworks.xstream.io.StreamException: : no more data
>> available - expected end tags
>> </com.lumina.silver.integration.fpa.operations.vo.FPAEquitiesSpotVO></message></adapter></org.mule.impl.MuleMessage>
>> to close start tag <
>> com.lumina.silver.integration.fpa.operations.vo.FPAEquitiesSpotVO> from
>> line 803 and start tag <message> from line 3 and start tag <adapter> from
>> line 2 and start tag <org.mule.impl.MuleMessage> from line 1, parser
>> stopped on TEXT seen
>> ...</com.lumina.silver.integration.fpa.operations....
>> @819:54
>>
>> at com.thoughtworks.xstream.io.xml.XppReader.pullNextEvent(
>> XppReader.java:60)
>>
>> at
>> com.thoughtworks.xstream.io.xml.AbstractPullReader.readRealEvent(
>> AbstractPullReader.java:118)
>>
>> at
>> com.thoughtworks.xstream.io.xml.AbstractPullReader.readEvent(
>> AbstractPullReader.java:105)
>>
>> at
>> com.thoughtworks.xstream.io.xml.AbstractPullReader.hasMoreChildren(
>> AbstractPullReader.java:59)
>>
>> at com.thoughtworks.xstream.io.ReaderWrapper.hasMoreChildren(
>> ReaderWrapper.java:21)
>>
>> at
>> com.thoughtworks.xstream.converters.reflection.ReflectionConverter.unmarshal
>> (ReflectionConverter.java:91)
>>
>> at
>> com.thoughtworks.xstream.core.TreeUnmarshaller.convertAnother(
>> TreeUnmarshaller.java:38)
>>
>> ... 47 more
>>
>> Caused by: java.io.EOFException: no more data available - expected end
>> tags
>> </com.lumina.silver.integration.fpa.operations.vo.FPAEquitiesSpotVO></message></adapter></org.mule.impl.MuleMessage>
>> to close start tag <
>> com.lumina.silver.integration.fpa.operations.vo.FPAEquitiesSpotVO> from
>> line 803 and start tag <message> from line 3 and start tag <adapter> from
>> line 2 and start tag <org.mule.impl.MuleMessage> from line 1, parser
>> stopped on TEXT seen
>> ...</com.lumina.silver.integration.fpa.operations....
>> @819:54
>>
>> at org.xmlpull.mxp1.MXParser.fillBuf(MXParser.java:2987)
>>
>> at org.xmlpull.mxp1.MXParser.more(MXParser.java:2996)
>>
>> at org.xmlpull.mxp1.MXParser.parseEndTag(MXParser.java:1654)
>>
>> at org.xmlpull.mxp1.MXParser.nextImpl(MXParser.java:1130)
>>
>> at org.xmlpull.mxp1.MXParser.next(MXParser.java:1092)
>>
>> at com.thoughtworks.xstream.io.xml.XppReader.pullNextEvent(
>> XppReader.java:43)
>>
>> ... 53 more
>>
>>
>>
>> May this be caused because of the size of the response object (which is
>> pretty big in fact)?
>>
>>
>>
>> Best regards,
>>
>>
>>
>> Juan Manuel
>>
>>
>>
>>
>>
>
>

--
View this message in context: http://www.nabble.com/tcp-error-tp3519073p18773513.html
Sent from the Mule - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email


Odpowiedz wszystkim
Odpowiedz autorowi
Przekaż
Nowe wiadomości: 0