[mule-user] how to handle exception in aix:outbound service

10 views
Skip to first unread message

dp mallia

unread,
May 19, 2009, 7:58:35 AM5/19/09
to us...@mule.codehaus.org
When i executing the web service using mule axis:outbound it is working fine for success scenarios. But for exception scenario i am getting below error

ERROR 2009-05-19 16:38:05,454 [http://connector.VM.0.dispatcher.1] org.mule.service.DefaultServiceExceptionStrategy:
********************************************************************************
Message : Failed to route event via endpoint: DefaultOutboundEndpoint{endpointUri=http://localhost:8080/Web/services/webUpdate?method=updateInfo, connector=AxisConnector{this=78dc4c, started=true, initialised=true, name='connector.axis.0', disposed=false, numberOfConcurrentTransactedReceivers=4, createMultipleTransactedReceivers=true, connected=true, supportedProtocols=axis, axis:http, axis:https, axis:servlet, axis:vm, axis:jms, axis:xmpp, axis:ssl, axis:tcp, axis:smtp, axis:smtps, axis:pop3, axis:pop3s, axis:imap, axis:imaps, axis:http, axis:https, axis:servlet, axis:vm, axis:jms, axis:xmpp, axis:ssl, axis:tcp, axis:smtp, axis:smtps, axis:pop3, axis:pop3s, axis:imap, axis:imaps, serviceOverrides=null}, transformer=http://forums.mulesource.org/, name='endpoint.http.localhost.8080.Web.services.webUpdate.method.updateInfo', properties={style=rpc, soapMethods=merged: {qname{updateInfo:{[http://localhost:8080/Web/services/webUpdate]}=--token;string;IN, username;string;IN, alertid;string;IN, action;string;IN, comment;string;IN, return;qname{com.InvalidCredentialException:{[http://schemas.xmlsoap.org/soap/envelope/]}--}, soapAction=methodNamespace, method=updateInfo}, transactionConfig=Transaction{factory=null, action=NONE, timeout=0}, filter=null, deleteUnacceptedMessages=false, securityFilter=null, synchronous=true, initialState=started, remoteSync=false, remoteSyncTimeout=3000, endpointEncoding=UTF-8}. Message payload is of type: String[--
Type : org.mule.api.transport.DispatchException
Code : MULE_ERROR-42999
Fault Role : null
Fault Reason : com.InvalidCredentialException: Invalid user session/session has expired
Payload : [Ljava.lang.String;@ba8fce
Fault Dump : AxisFault
faultCode: {[http://schemas.xmlsoap.org/soap/envelope/]}Server.userException
faultSubcode:
faultString: com.InvalidCredentialException: Invalid user session/session has expired
faultActor:
faultNode:
faultDetail:
{[http://xml.apache.org/axis/]}hostname:localhost

Fault Node : null
Fault Code : {[http://schemas.xmlsoap.org/soap/envelope/]}Server.userException
JavaDoc : [http://mule.mulesource.org/docs/apidocs/org/mule/api/transport/DispatchException.html]
Fault Actor : null
Fault : com.InvalidCredentialException: Invalid user session/session has expired
********************************************************************************
Exception stack is:
1. com.InvalidCredentialException: Invalid user session/session has expired(Fault Role: null, Fault Reason: com.InvalidCredentialException: Invalid user session/session has expired, Fault Dump: AxisFault
faultCode: {[http://schemas.xmlsoap.org/soap/envelope/]}Server.userException
faultSubcode:
faultString: com.InvalidCredentialException: Invalid user session/session has expired
faultActor:
faultNode:
faultDetail:
{[http://xml.apache.org/axis/]}hostname:localhost
, Fault Node: null, Fault Code: {[http://schemas.xmlsoap.org/soap/envelope/]}Server.userException, Fault Actor: null, Fault: com.InvalidCredentialException: Invalid user session/session has expired, ) (org.apache.axis.AxisFault)
org.apache.axis.message.SOAPFaultBuilder:222 (null)
2. Failed to route event via endpoint: DefaultOutboundEndpoint{endpointUri=http://localhost:8080/Web/services/webUpdate?method=updateInfo, connector=AxisConnector{this=78dc4c, started=true, initialised=true, name='connector.axis.0', disposed=false, numberOfConcurrentTransactedReceivers=4, createMultipleTransactedReceivers=true, connected=true, supportedProtocols=axis, axis:http, axis:https, axis:servlet, axis:vm, axis:jms, axis:xmpp, axis:ssl, axis:tcp, axis:smtp, axis:smtps, axis:pop3, axis:pop3s, axis:imap, axis:imaps, axis:http, axis:https, axis:servlet, axis:vm, axis:jms, axis:xmpp, axis:ssl, axis:tcp, axis:smtp, axis:smtps, axis:pop3, axis:pop3s, axis:imap, axis:imaps, serviceOverrides=null}, transformer=http://forums.mulesource.org/, name='endpoint.http.localhost.8080.Web.services.webUpdate.method.updateInfo', properties={style=rpc, soapMethods=merged: {qname{updatePARInfo:{[http://localhost:8080/Web/services/webUpdate]}=--token;string;IN, username;string;IN, alertid;string;IN, action;string;IN, comment;string;IN, return;qname{com.InvalidCredentialException:{[http://schemas.xmlsoap.org/soap/envelope/]}--}, soapAction=methodNamespace, method=updateInfo}, transactionConfig=Transaction{factory=null, action=NONE, timeout=0}, filter=null, deleteUnacceptedMessages=false, securityFilter=null, synchronous=true, initialState=started, remoteSync=false, remoteSyncTimeout=3000, endpointEncoding=UTF-8}. Message payload is of type: String[-- (org.mule.api.transport.DispatchException)
org.mule.transport.AbstractMessageDispatcher:188 ([http://mule.mulesource.org/docs/apidocs/org/mule/api/transport/DispatchException.html])

when i execute below mule code iam getting the above errors
<inbound>
<inbound-endpoint address="vm://openServiceCall" transformer-refs="StringToObjectArray"
synchronous="true" />
</inbound>

<outbound>
<outbound-pass-through-router>
<axis:outbound-endpoint address="http://localhost:8080/Web/services/webUpdate?method=updateInfo"
style="RPC" responseTransformer-refs="ToString"
soapAction="methodNamespacemethod" synchronous="true">
<axis:soap-method method="qname{updateInfo:{[http://localhost:8080/Web/services/webUpdate]}">
<axis:soap-parameter parameter="token" type="string" mode="IN"/>
<axis:soap-parameter parameter="username" type="string" mode="IN"/>
<axis:soap-parameter parameter="alertid" type="string" mode="IN"/>
<axis:soap-parameter parameter="action" type="string" mode="IN"/>
<axis:soap-parameter parameter="comment" type="string" mode="IN"/>
-<axis:soap-parameter parameter="updateInfoResponse" type="string" mode="OUT"/>
</axis:soap-method>
</axis:outbound-endpoint>
</outbound-pass-through-router>
</outbound>

can any body suggest the answer, how to handle exception in aix:outbound service

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

http://xircles.codehaus.org/manage_email


Antoine Borg

unread,
May 25, 2009, 3:06:08 AM5/25/09
to us...@mule.codehaus.org
Have you tried exception strategies?

http://www.mulesource.org/display/MULE2USER/Error+Handling

A

--

Antoine Borg, Senior Consultant | Tel: +32 28 504 696
ricston Ltd., BP 2, 1180 Uccle, Brussels, BELGIUM

See our full schedule of Mule and Android courses:
http://www.ricston.com/courses/schedules/

email: _antoin...@ricston.com <mailto:antoin...@ricston.com> |
blog: blog.ricston.com <http://blog.ricston.com> | web: ricston.com
<http://www.ricston.com/>

dp mallia

unread,
May 28, 2009, 1:37:12 AM5/28/09
to us...@mule.codehaus.org
i tried must not able to catch the exception. can u help me how to define the exception block for below code.

&lt;service name="expservice"&gt;
&lt;inbound&gt;
&lt;stdio:inbound-endpoint system="IN"/&gt;
&lt;/inbound&gt;
&lt;outbound&gt;
&lt;forwarding-catch-all-strategy&gt;


&lt;vm:outbound-endpoint path="caseCompletionService" /&gt;


&lt;/forwarding-catch-all-strategy&gt;
&lt;static-recipient-list-router&gt;


&lt;vm:outbound-endpoint path="errorHandler"&gt;&lt;/vm:outbound-endpoint&gt;


&lt;payload-type-filter expectedType="java.lang.Exception" /&gt;


&lt;/static-recipient-list-router&gt;
&lt;/outbound&gt;
&lt;async-reply&gt;
&lt;inbound-endpoint address="vm://ProcessAlert-reply"/&gt;


&lt;single-async-reply-router/&gt;
&lt;/async-reply&gt;

&lt;/service&gt;

&lt;service name="caseCompletion"&gt;
&lt;inbound&gt;


&lt;vm:inbound-endpoint path="caseCompletionService" synchronous="true"/&gt;


&lt;/inbound&gt;
&lt;outbound&gt;
&lt;outbound-pass-through-router&gt;


&lt;outbound-endpoint ref="esbShowCaseProcess"/&gt;
&lt;/outbound-pass-through-router&gt;
&lt;/outbound&gt;
&lt;/service&gt;


&lt;service name="fromBPM"&gt;
&lt;inbound&gt;


&lt;inbound-endpoint ref="esbShowCaseProcess" synchronous="true" /&gt;


&lt;/inbound&gt;
&lt;outbound&gt;
&lt;outbound-pass-through-router&gt;

&lt;outbound-endpoint address="vm://openServiceCall"/&gt;


&lt;reply-to address="vm://ProcessAlert-reply" /&gt;
&lt;/outbound-pass-through-router&gt;

&lt;/outbound&gt;
&lt;/service&gt;

&lt;service name="openServiceCall"&gt;

&lt;inbound&gt;
&lt;inbound-endpoint address="vm://openServiceCall" transformer-refs="StringToObjectArray"
synchronous="true" /&gt;
&lt;/inbound&gt;

&lt;outbound&gt;
&lt;outbound-pass-through-router&gt;
&lt;axis:outbound-endpoint address="http://localhost:8080/Web/services/webUpdate?method=updateInfo"
style="RPC" responseTransformer-refs="ToString"
soapAction="methodNamespacemethod" synchronous="true"&gt;
&lt;axis:soap-method method="qname{updateInfo:{[http://localhost:8080/Web/services/webUpdate]}"&gt;
&lt;axis:soap-parameter parameter="token" type="string" mode="IN"/&gt;
&lt;axis:soap-parameter parameter="username" type="string" mode="IN"/&gt;
&lt;axis:soap-parameter parameter="alertid" type="string" mode="IN"/&gt;
&lt;axis:soap-parameter parameter="action" type="string" mode="IN"/&gt;
&lt;axis:soap-parameter parameter="comment" type="string" mode="IN"/&gt;

&lt;axis:soap-parameter parameter="updateInfoResponse" type="string" mode="OUT"/&gt;
&lt;/axis:soap-method&gt;
&lt;/axis:outbound-endpoint&gt;
&lt;/outbound-pass-through-router&gt;
&lt;/outbound&gt;

&lt;/service&gt;

Antoine Borg

unread,
May 28, 2009, 8:14:29 AM5/28/09
to us...@mule.codehaus.org
Hello there,

Where is the exception raised? Where do you want to catch it?

A

--

Antoine Borg, Senior Consultant | Tel: +32 28 504 696
ricston Ltd., BP 2, 1180 Uccle, Brussels, BELGIUM

See our full schedule of Mule and Android courses:
http://www.ricston.com/courses/schedules/

---------------------------------------------------------------------

dp mallia

unread,
May 29, 2009, 6:14:16 AM5/29/09
to us...@mule.codehaus.org
Hello Antoine,

If i enter wrong input then the axis:outbound-endpoint endpoint is throwing Exception. i tried to put exception handle but not able to catch that exception.

ERROR 2009-05-29 15:40:16,602 [connector.VM.0.dispatcher.1] org.mule.service.DefaultServiceExceptionStrategy:
********************************************************************************
Message : Failed to route event via endpoint: DefaultOutboundEndpoint{endpointUri=http://localhost:7030/Web/services/Update?method=updateInfo, connector=AxisConnector{this=14e0e90, started=true, initialised=true, name='connector.axis.0', disposed=false, numberOfConcurrentTransactedReceivers=4, createMultipleTransactedReceivers=true, connected=true, supportedProtocols=[axis, axis:http, axis:https, axis:servlet, axis:vm, axis:jms, axis:xmpp, axis:ssl, axis:tcp, axis:smtp, axis:smtps, axis:pop3, axis:pop3s, axis:imap, axis:imaps, axis:http, axis:https, axis:servlet, axis:vm, axis:jms, axis:xmpp, axis:ssl, axis:tcp, axis:smtp, axis:smtps, axis:pop3, axis:pop3s, axis:imap, axis:imaps], serviceOverrides=null}, transformer=[], name='endpoint.http.localhost.7030.Web.services.Update.method.PARInfo', properties={style=rpc, soapMethods=merged: {qname{updateInfo:{http://localhost:7030/Web/services/Update}=[token;string;IN, username;string;IN, alertid;string;IN, action;string;IN, comment;string;IN, updateInfoResponse;string;OUT]}, soapAction=[methodNamespace][method], method=updatePARInfo}, transactionConfig=Transaction{factory=null, action=NONE, timeout=0}, filter=null, deleteUnacceptedMessages=false, securityFilter=null, synchronous=true, initialState=started, remoteSync=true, remoteSyncTimeout=3000, endpointEncoding=UTF-8}. Message payload is of type: String[]


Type : org.mule.api.transport.DispatchException
Code : MULE_ERROR-42999
Fault Role : null
Fault Reason : com.InvalidCredentialException: Invalid user session/session has expired

Payload : [Ljava.lang.String;@101e081


Fault Dump : AxisFault
faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException
faultSubcode:
faultString: com.InvalidCredentialException: Invalid user session/session has expired
faultActor:
faultNode:
faultDetail:

{http://xml.apache.org/axis/}hostname:loalhost


can u please suggest me the answer how i ll handle the exception

Antoine Borg

unread,
Jun 2, 2009, 4:12:14 AM6/2/09
to us...@mule.codehaus.org
Ok - Does a service exception strategy work?

http://ricston.com/blog/?p=300

A

--

Antoine Borg, Senior Consultant | Tel: +32 28 504 696
ricston Ltd., BP 2, 1180 Uccle, Brussels, BELGIUM

See our full schedule of Mule and Android courses:
http://www.ricston.com/courses/schedules/

dp mallia

unread,
Jun 3, 2009, 2:03:47 AM6/3/09
to us...@mule.codehaus.org
No. Not able to handle the exception.

Antoine Borg

unread,
Jun 3, 2009, 3:24:43 AM6/3/09
to us...@mule.codehaus.org
There are two places where you can catch exceptions - on a service or on
a connector. Since the service exception strategy did not work, I would
suggest creating an exception strategy for the VM connector

A

--

Antoine Borg, Senior Consultant | Tel: +32 28 504 696
ricston Ltd., BP 2, 1180 Uccle, Brussels, BELGIUM

See our full schedule of Mule and Android courses:
http://www.ricston.com/courses/schedules/

---------------------------------------------------------------------

dp mallia

unread,
Jun 5, 2009, 3:04:18 AM6/5/09
to us...@mule.codehaus.org
i tried with below code but not able to catch the exception. can u help me how to define the exception block for below code.

<service name="expservice">
<inbound>
<stdio:inbound-endpoint system="IN"/>
</inbound>
<outbound><forwarding-catch-all-strategy>

<vm:outbound-endpoint path="caseCompletionService" />
</outbound>
<async-reply>
<inbound-endpoint address="vm://ProcessAlert-reply"/>
<single-async-reply-router/>
</async-reply>

</service>

<service name="caseCompletion">
<inbound>


<vm:inbound-endpoint path="caseCompletionService" synchronous="true"/>

</inbound>
<outbound>
<outbound-pass-through-router>
<outbound-endpoint ref="esbShowCaseProcess"/>
</outbound-pass-through-router>
</outbound>
</service>

<service name="fromBPM">
<inbound>


<inbound-endpoint ref="esbShowCaseProcess" synchronous="true" />

</inbound>
<outbound>
<outbound-pass-through-router>
<outbound-endpoint address="vm://openServiceCall"/>
<reply-to address="vm://ProcessAlert-reply" />

</forwarding-catch-all-strategy>
<static-recipient-list-router>

<vm:outbound-endpoint path="errorHandler"></vm:outbound-endpoint>
<payload-type-filter expectedType="java.lang.Exception" />

</static-recipient-list-router>
</outbound-pass-through-router>

</outbound>
</service>

<service name="openServiceCall">

<inbound>


<inbound-endpoint address="vm://openServiceCall" transformer-refs="StringToObjectArray"
synchronous="true" />

</inbound>

<outbound>
<outbound-pass-through-router>


<axis:outbound-endpoint address="http://localhost:8080/Web/services/webUpdate?method=updateInfo"
style="RPC" responseTransformer-refs="ToString"
soapAction="methodNamespacemethod" synchronous="true">

<axis:soap-method method="qname{updateInfo:{http://localhost:8080/Web/services/webUpdate}">

<axis:soap-parameter parameter="token" type="string" mode="IN"/>

<axis:soap-parameter parameter="username" type="string" mode="IN"/>

<axis:soap-parameter parameter="alertid" type="string" mode="IN"/>

<axis:soap-parameter parameter="action" type="string" mode="IN"/>

<axis:soap-parameter parameter="comment" type="string" mode="IN"/>

<axis:soap-parameter parameter="updateInfoResponse" type="string" mode="OUT"/>

</axis:soap-method>
</axis:outbound-endpoint>
</outbound-pass-through-router>
</outbound>
</service>

Antoine Borg

unread,
Jun 9, 2009, 3:03:45 AM6/9/09
to us...@mule.codehaus.org
The code you have here does not have an exception strategy at all ...
where do you think you are catching it?

You can read up on exception strategies here:
http://ricston.com/blog/?p=300 and there are some code samples on the
MuleSource wiki here:
http://www.mulesource.org/display/MULE2USER/Error+Handling

A

--

Antoine Borg, Senior Consultant | Tel: +32 28 504 696
ricston Ltd., BP 2, 1180 Uccle, Brussels, BELGIUM

See our full schedule of Mule and Android courses:
http://www.ricston.com/courses/schedules/

---------------------------------------------------------------------

dp mallia

unread,
Jun 17, 2009, 2:06:52 AM6/17/09
to us...@mule.codehaus.org

</service>

</outbound-pass-through-router>

</outbound>
</service>

<service name="openServiceCall">

<inbound>
<inbound-endpoint address="vm://openServiceCall" transformer-refs="StringToObjectArray"
synchronous="true" />
</inbound>

<outbound>
<outbound-pass-through-router>
<axis:outbound-endpoint address="http://localhost:8080/Web/services/webUpdate?method=updateInfo"
style="RPC" responseTransformer-refs="ToString"
soapAction="methodNamespacemethod" synchronous="true">
<axis:soap-method method="qname{updateInfo:{http://localhost:8080/Web/services/webUpdate}">
<axis:soap-parameter parameter="token" type="string" mode="IN"/>
<axis:soap-parameter parameter="username" type="string" mode="IN"/>
<axis:soap-parameter parameter="alertid" type="string" mode="IN"/>
<axis:soap-parameter parameter="action" type="string" mode="IN"/>
<axis:soap-parameter parameter="comment" type="string" mode="IN"/>
<axis:soap-parameter parameter="updateInfoResponse" type="string" mode="OUT"/>
</axis:soap-method>
</axis:outbound-endpoint>
</outbound-pass-through-router>
</outbound>

<default-service-exception-strategy>
<vm:outbound-endpoint path="errorHandler"/>
</default-service-exception-strategy>
</service>

<service name="ErrorHandler">
<inbound>
<vm:inbound-endpoint path="errorHandler"
responseTransformer-refs="ExceptionToFaultTransformer" />
</inbound>
</service>


i modified the my code. Now i am getting below error. Can u please tell me how to handle this.

Exception stack is:
1. Could not find a transformer to transform "org.apache.activemq.command.ActiveMQTextMessage" to "org.mule.api.transport.OutputHandler". (org.mule.api.transformer.TransformerException)
org.mule.registry.AbstractRegistry:288 (http://mule.mulesource.org/docs/apidocs/org/mule/api/transformer/TransformerException.html)
********************************************************************************
Root Exception stack trace:
org.mule.api.transformer.TransformerException: Could not find a transformer to transform "org.apache.activemq.command.ActiveMQTextMessage" to "org.mule.api.transport.OutputHandler".
at org.mule.registry.AbstractRegistry.lookupTransformer(AbstractRegistry.java:288)
at org.mule.DefaultMuleMessage.getPayload(DefaultMuleMessage.java:160)
at org.mule.DefaultMuleMessage.getPayload(DefaultMuleMessage.java:118)
at org.mule.transport.http.HttpResponse.setBody(HttpResponse.java:288)
at org.mule.transport.http.transformers.MuleMessageToHttpResponse.createResponse(MuleMessageToHttpResponse.java:268)
at org.mule.transport.http.transformers.MuleMessageToHttpResponse.transform(MuleMessageToHttpResponse.java:100)
at org.mule.transformer.AbstractMessageAwareTransformer.doTransform(AbstractMessageAwareTransformer.java:68)
at org.mule.transformer.AbstractTransformer.transform(AbstractTransformer.java:254)
at org.mule.DefaultMuleMessage.applyAllTransformers(DefaultMuleMessage.java:564)
at org.mule.DefaultMuleMessage.applyTransformers(DefaultMuleMessage.java:524)
at org.mule.DefaultMuleMessage.applyTransformers(DefaultMuleMessage.java:517)
at org.mule.transport.AbstractMessageReceiver$DefaultInternalMessageListener.onMessage(AbstractMessageReceiver.java:613)
at org.mule.transport.AbstractMessageReceiver.routeMessage(AbstractMessageReceiver.java:346)
at org.mule.transport.AbstractMessageReceiver.routeMessage(AbstractMessageReceiver.java:287)
at org.mule.transport.http.HttpMessageReceiver$HttpWorker.doRequest(HttpMessageReceiver.java:239)
at org.mule.transport.http.HttpMessageReceiver$HttpWorker.processRequest(HttpMessageReceiver.java:197)
at org.mule.transport.http.HttpMessageReceiver$HttpWorker.run(HttpMessageReceiver.java:163)
at org.mule.work.WorkerContext.run(WorkerContext.java:310)
at edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650)
at edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675)
at java.lang.Thread.run(Unknown Source)

********************************************************************************

INFO 2009-06-17 11:32:43,067 [connector.http.0.receiver.2] org.mule.transport.http.HttpMessageReceiver: Closing HTTP connection.
INFO 2009-06-17 11:32:43,083 [ActiveMQ Session Task] org.mule.transport.soap.axis.extensions.UniversalSender: Making Axis soap request on: updatePARInfo
INFO 2009-06-17 11:32:43,083 [ActiveMQ Session Task] org.mule.transport.http.HttpClientMessageDispatcher: Connected: HttpClientMessageDispatcher{this=bb6086, endpoint=http://131.127.166.131:7030/pARWeb/services/PARUpdate?method=updatePARInfo, disposed=false}
INFO 2009-06-17 11:32:44,145 [ActiveMQ Session Task] org.mule.transport.soap.axis.AxisMessageDispatcher: Disconnected: AxisMessageDispatcher{this=2af8f5, endpoint=http://131.127.166.131:7030/pARWeb/services/PARUpdate?method=updatePARInfo, disposed=false}
ERROR 2009-06-17 11:32:44,161 [ActiveMQ Session Task] org.mule.service.DefaultServiceExceptionStrategy:

Antoine Borg

unread,
Jun 17, 2009, 9:31:05 AM6/17/09
to us...@mule.codehaus.org
Not having access to your full config, I'm assuming that this endpoint:

esbShowCaseProcess

is a JMS endpoint.


The error that you see suggests that the JMS transformer is unavailable
- do you have the JMS namespaces/schemas included in the XML? Do you
have the JARs included in your project?

Note that the exception strategy in this config will not catch this
exception in the fromBPM service.

HTH

A

--

Antoine Borg, Senior Consultant | Tel: +32 28 504 696
ricston Ltd., BP 2, 1180 Uccle, Brussels, BELGIUM

See our full schedule of Mule and Android courses:
http://www.ricston.com/courses/schedules/

---------------------------------------------------------------------

dp mallia

unread,
Jun 18, 2009, 12:33:20 AM6/18/09
to us...@mule.codehaus.org
Thanks for your response. in my config file already i have JMS namespaces/schemas. Ithe below error is maintaining in response.queue object in Active MQ. For your reference please find the below mule-config.

<?xml version="1.0" encoding="UTF-8"?>
<mule xmlns="http://www.mulesource.org/schema/mule/core/2.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:spring="http://www.springframework.org/schema/beans"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:stdio="http://www.mulesource.org/schema/mule/stdio/2.0"
xmlns:vm="http://www.mulesource.org/schema/mule/vm/2.0"
xmlns:axis="http://www.mulesource.org/schema/mule/axis/2.0"
xmlns:https="http://www.mulesource.org/schema/mule/https/2.0"
xmlns:xm="http://www.mulesource.org/schema/mule/xml/2.0"
xmlns:soap="http://www.mulesource.org/schema/mule/soap/2.0"
xmlns:http="http://www.mulesource.org/schema/mule/http/2.0"
xmlns:jms="http://www.mulesource.org/schema/mule/jms/2.0"
xmlns:bpm="http://www.mulesource.org/schema/mule/bpm/2.0"
xmlns:client="http://www.mulesource.org/schema/mule/client/2.0"
xsi:schemaLocation="
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-2.5.xsd
http://www.mulesource.org/schema/mule/client/2.0 http://www.mulesource.org/schema/mule/client/2.0/mule-client.xsd
http://www.mulesource.org/schema/mule/core/2.0 http://www.mulesource.org/schema/mule/core/2.0/mule.xsd
http://www.mulesource.org/schema/mule/stdio/2.0 http://www.mulesource.org/schema/mule/stdio/2.0/mule-stdio.xsd
http://www.mulesource.org/schema/mule/vm/2.0 http://www.mulesource.org/schema/mule/vm/2.0/mule-vm.xsd
http://www.mulesource.org/schema/mule/axis/2.0 http://www.mulesource.org/schema/mule/axis/2.0/mule-axis.xsd
http://www.mulesource.org/schema/mule/https/2.0 http://www.mulesource.org/schema/mule/https/2.0/mule-https.xsd
http://www.mulesource.org/schema/mule/xml/2.0 http://www.mulesource.org/schema/mule/xml/2.0/mule-xml.xsd
http://www.mulesource.org/schema/mule/soap/2.0 http://www.mulesource.org/schema/mule/soap/2.0/mule-soap.xsd
http://www.mulesource.org/schema/mule/jms/2.0 http://www.mulesource.org/schema/mule/jms/2.0/mule-jms.xsd
http://www.mulesource.org/schema/mule/bpm/2.0 http://www.mulesource.org/schema/mule/bpm/2.0/mule-bpm.xsd
http://www.mulesource.org/schema/mule/http/2.0 http://www.mulesource.org/schema/mule/http/2.0/mule-http.xsd">

<custom-transformer name="StringToObjectArray"
class="com.test.StringToObjectArray" />

<custom-transformer name="HttpRequestToNameString"
class="com.test.HttpRequestToNameString" />
<custom-transformer name="ExceptionToFaultTransformer"
class="com.test.ExceptionToFaultTransformer" />


<xm:xml-to-object-transformer name="XmlToObject"/>
<xm:xslt-transformer name="Xslt" xsl-file="test.xsl"/>
<xml-entity-decoder-transformer name="XmlDecoder"/>
<object-to-string-transformer name="ToString"/>


<http:message-to-http-response-transformer name="MessageToHttpResponse" />

<spring:bean id="activeMqResponseFactory"
class="org.apache.activemq.ActiveMQConnectionFactory">
<spring:property name="brokerURL" value="tcp://localhost:61616" />
</spring:bean>

<jms:connector name="jmsResponseConnector"
connectionFactory-ref="activeMqResponseFactory">
</jms:connector>

<jms:jmsmessage-to-object-transformer name="JMSMessageToObject" />

<endpoint name="esbShowCaseProcess" address="jms://response.queue"
connector-ref="jmsResponseConnector" />

<model name="soapDotNetSample">

<service name="openServiceCall">

---------------------------------------------------------------------

Antoine Borg

unread,
Jun 30, 2009, 3:35:49 AM6/30/09
to us...@mule.codehaus.org
Hi,

Why do you do this:

<outbound>
<forwarding-catch-all-strategy>
<vm:outbound-endpoint path="caseCompletionService" />
</outbound>


Having an outbound router collection with no routers means that all
messages would be dropped, I suppose and then sent to this VM endpoint.
Why not have a pass-through router in the first place?

A

--

Antoine Borg, Senior Consultant | Tel: +32 28 504 696
ricston Ltd., BP 2, 1180 Uccle, Brussels, BELGIUM

See our full schedule of Mule and Android courses:
http://www.ricston.com/courses/schedules/

---------------------------------------------------------------------

dp mallia

unread,
Jul 8, 2009, 5:32:56 AM7/8/09
to us...@mule.codehaus.org
Hi
After modifying the code as

<vm:outbound-endpoint path="caseCompletionService" />
</outbound>
<async-reply>
<inbound-endpoint address="vm://ProcessAlert-reply"/>
<single-async-reply-router/>
</async-reply>
</service>

<service name="caseCompletion">
<inbound>
<vm:inbound-endpoint path="caseCompletionService" synchronous="true"/>
</inbound>
<outbound>
<outbound-pass-through-router>
<outbound-endpoint ref="esbShowCaseProcess"/>
</outbound-pass-through-router>
</outbound>
</service>

<service name="fromBPM">
<inbound>
<inbound-endpoint ref="esbShowCaseProcess" synchronous="true" />
</inbound>
<outbound>
<outbound-pass-through-router>
<outbound-endpoint address="vm://openServiceCall"/>

</outbound-pass-through-router>
</outbound>
</service>

<service name="openServiceCall">

<service name="ErrorHandler">


<inbound>
<vm:inbound-endpoint path="errorHandler"
responseTransformer-refs="ExceptionToFaultTransformer" />
</inbound>
</service>

</model>
</mule>

I am getting below error. can u help me how to fix this error.

ERROR 2009-07-08 14:52:20,733 [connector.http.0.dispatcher.1] org.mule.transport.http.HttpClientMessageDispatcher: <?xml version="1.0" encoding="UTF-8"?><soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><soapenv:Body><soapenv:Fault><faultcode>soapenv:Server.userException</faultcode><faultstring>com.test.InvalidCredentialException: Invalid user session has expired</faultstring><detail><ns1:hostname xmlns:ns1="http://xml.apache.org/axis/">localhost</ns1:hostname></detail></soapenv:Fault></soapenv:Body></soapenv:Envelope>
ERROR 2009-07-08 14:52:20,733 [connector.http.0.dispatcher.1] org.mule.DefaultExceptionStrategy:
********************************************************************************
Message : Failed to route event via endpoint: DefaultOutboundEndpoint{endpointUri=http://localhost:8080/Web/services/webUpdate?method=updateInfo, connector=HttpConnector{this=1353249, started=true, initialised=true, name='connector.http.0', disposed=false, numberOfConcurrentTransactedReceivers=4, createMultipleTransactedReceivers=true, connected=true, supportedProtocols=[http], serviceOverrides=null}, transformer=[ObjectToHttpClientMethodRequest{this=1af328, name='null', ignoreBadInput=false, returnClass=interface org.apache.commons.httpclient.HttpMethod, sourceTypes=[interface org.mule.api.MuleMessage, class [B, class java.lang.String, class java.io.InputStream, interface org.mule.api.transport.OutputHandler]}], name='endpoint.http.localhost.8080.Web.services/webUpdate.updateInfo', properties={method=updatePARInfo}, transactionConfig=Transaction{factory=null, action=NONE, timeout=0}, filter=null, deleteUnacceptedMessages=false, securityFilter=null, synchronous=false, initialState=started, remoteSync=false, remoteSyncTimeout=3000, endpointEncoding=UTF-8}. Message payload is of type: PostMethod
Type : org.mule.api.transport.DispatchException
Code : MULE_ERROR-42999
Payload : org.apache.commons.httpclient.methods.PostMethod@19f9c7a
JavaDoc : http://mule.mulesource.org/docs/apidocs/org/mule/api/transport/DispatchException.html
********************************************************************************
Exception stack is:
1. Http call returned a status of: 500 Internal Server Error (java.lang.Exception)
org.mule.transport.http.HttpClientMessageDispatcher:87 (null)
2. Failed to route event via endpoint: DefaultOutboundEndpoint{endpointUri=http://localhost:8080/Web/services/webUpdate?method=updatePARInfo, connector=HttpConnector{this=1353249, started=true, initialised=true, name='connector.http.0', disposed=false, numberOfConcurrentTransactedReceivers=4, createMultipleTransactedReceivers=true, connected=true, supportedProtocols=[http], serviceOverrides=null}, transformer=[ObjectToHttpClientMethodRequest{this=1af328, name='null', ignoreBadInput=false, returnClass=interface org.apache.commons.httpclient.HttpMethod, sourceTypes=[interface org.mule.api.MuleMessage, class [B, class java.lang.String, class java.io.InputStream, interface org.mule.api.transport.OutputHandler]}], name='endpoint.http.localhost.8080.Web.services.webUpdate.updateInfo', properties={method=updatePARInfo}, transactionConfig=Transaction{factory=null, action=NONE, timeout=0}, filter=null, deleteUnacceptedMessages=false, securityFilter=null, synchronous=false, initialState=started, remoteSync=false, remoteSyncTimeout=3000, endpointEncoding=UTF-8}. Message payload is of type: PostMethod (org.mule.api.transport.DispatchException)
org.mule.transport.http.HttpClientMessageDispatcher:87 (http://mule.mulesource.org/docs/apidocs/org/mule/api/transport/DispatchException.html)


********************************************************************************
Root Exception stack trace:

java.lang.Exception: Http call returned a status of: 500 Internal Server Error
at org.mule.transport.http.HttpClientMessageDispatcher.doDispatch(HttpClientMessageDispatcher.java:87)
at org.mule.transport.AbstractMessageDispatcher$Worker.run(AbstractMessageDispatcher.java:262)


at org.mule.work.WorkerContext.run(WorkerContext.java:310)
at edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650)
at edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675)
at java.lang.Thread.run(Unknown Source)

********************************************************************************

---------------------------------------------------------------------

Antoine Borg

unread,
Jul 10, 2009, 3:28:44 AM7/10/09
to us...@mule.codehaus.org
Are you sure this config works well?

This looks odd:

<outbound>
<vm:outbound-endpoint path="caseCompletionService" />
</outbound>

HTH

A

--

Antoine Borg, Senior Consultant | Tel: +32 28 504 696
ricston Ltd., BP 2, 1180 Uccle, Brussels, BELGIUM

See our full schedule of Mule and Android courses:
http://www.ricston.com/courses/schedules/

dp mallia

unread,
Jul 13, 2009, 8:37:02 AM7/13/09
to us...@mule.codehaus.org
I wrongly enter the contents of config file. plz find the updated one.

<outbound-pass-through-router>


<vm:outbound-endpoint path="caseCompletionService" />

</outbound-pass-through-router>

<service name="openServiceCall">

Success scenario is working file. I am unable to catch the exception scenario.

Mario Klaver

unread,
Jul 13, 2009, 9:08:33 AM7/13/09
to us...@mule.codehaus.org
Have you tried setting a custom response transformer on the inbound endpoint of service "openServiceCall" as suggested by Puneet Gupta in another question on this forum:

http://forums.mulesource.org/message.jspa?messageID=3068

For me it works great this way.

HTH
Mario

Reply all
Reply to author
Forward
0 new messages