Mule 3.6.1 HTTPS ountbound GET/POST - https

Hi I am trying to use(Mule 3.6.1) https outbound endpoint in order to get a response. With this conditions I couldnt make any response. But however if I use
Mule 3.4.0 depricated http outbound(which is commented in below xml file) I can get a response. Is there any possible way to get the response from "https://httpbin.org/ip" by using Mule 3.6.1 https outbound endpoint.
<?xml version="1.0" encoding="UTF-8"?>
<mule xmlns:https="http://www.mulesoft.org/schema/mule/https"
xmlns:http="http://www.mulesoft.org/schema/mule/http" xmlns="http://www.mulesoft.org/schema/mule/core" xmlns:doc="http://www.mulesoft.org/schema/mule/documentation"
xmlns:spring="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.mulesoft.org/schema/mule/https http://www.mulesoft.org/schema/mule/https/current/mule-https.xsd http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-current.xsd http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/current/mule.xsd http://www.mulesoft.org/schema/mule/http http://www.mulesoft.org/schema/mule/http/current/mule-http.xsd">
<http:listener-config name="HTTP_Listener_Configuration" host="0.0.0.0" port="8081" basePath="miraj" doc:name="HTTP Listener Configuration"/>
<http:request-config name="HTTP_Request_Configuration" protocol="HTTPS" host="httpbin.org" port="443" doc:name="HTTP Request Configuration"/>
<!-- <https:connector name="HTTPS_Connector" cookieSpec="netscape" validateConnections="false" sendBufferSize="0" receiveBufferSize="0" receiveBacklog="0" sendTcpNoDelay="true" clientSoTimeout="40000" serverSoTimeout="40000" socketSoLinger="0" doc:name="HTTP\HTTPS">
</https:connector> -->
<flow name="testmulehttpsFlow">
<http:listener config-ref="HTTP_Listener_Configuration" path="hamid" doc:name="HTTP"/>
<logger message="Hiiiii" level="INFO" doc:name="Logger"/>
<http:request config-ref="HTTP_Request_Configuration" path="ip" method="GET" doc:name="HTTPS"/>
<!--<https:outbound-endpoint exchange-pattern="request-response" method="GET" connector-ref="HTTPS_Connector" address="https://httpbin.org/ip" doc:name="HTTPS" contentType="application/xml">
</https:outbound-endpoint> -->
</flow>
</mule>

I found the solution.
We need to remove a jar called async-http-client from you CE Runtime located at /Eclipse/plugins/org.mule.tooling.server.3.8.1_6.0.0.201612271237/mule/lib/user folder.
Restart mule and it will work fine.

It works fine, when I changed http request config to HTTP instead of HTTPS
<http:listener-config name="HTTP_Listener_Configuration" host="0.0.0.0" port="8081" basePath="miraj" doc:name="HTTP Listener Configuration"/>
<http:request-config name="HTTP_Request_Configuration" host="httpbin.org" port="80" doc:name="HTTP Request Configuration"/>
<flow name="testmulehttpsFlow">
<http:listener config-ref="HTTP_Listener_Configuration" path="hamid" doc:name="HTTP"/>
<logger message="Hiiiii" level="INFO" doc:name="Logger"/>
<http:request config-ref="HTTP_Request_Configuration" path="ip" method="GET" doc:name="HTTPS"/>
</flow>
For HTTPS try to add TLS configuration to request config.
Hope this helps.

Related

Mule Https request response timeout

Im trying to config a response timeout for https request component.
My http connector is calling a URL, I want to set a time for example after 5 second if there is no response back from the URL close this https connection.
But I've been searched on google and mule site there are no related information.
This webservice i am calling resets password, if after certain time I don't get response I want to close it and DO NOT want to reset it.
Here is the sample code:
<http:request-config name="HTTP_Request_Configuration" protocol="HTTPS" host="10.255.255.1." port="2446" doc:name="HTTP Request Configuration" responseTimeout="1" usePersistentConnections="false">
The responseTimeout is not doing anything, I've tried using SOAPUI to test the time is still the same no matter what I put.
Thanks in advance
I have set the responseTimeout property in the Http- request config and it works for me.
Please find the code below
<!--Http Listener Config for calling Service-->
<http:listener-config name="HTTP_Listener_Configuration1" host="0.0.0.0" port="8092" doc:name="HTTP Listener Configuration"/>
<http:request-config name="HTTP_Request_Configuration" host="localhost" port="8092" doc:name="HTTP Request Configuration" responseTimeout="5000"/>
<flow name="testtimeoutFlow">
<http:listener config-ref="HTTP_Listener_Configuration" path="/" doc:name="HTTP"/>
<http:request config-ref="HTTP_Request_Configuration" path="/test" method="GET" doc:name="HTTP"/>
<catch-exception-strategy doc:name="Catch Exception Strategy">
<logger message="#[message.exception]" level="INFO" doc:name="Logger"/>
<set-payload value="#['Time out Error']" doc:name="Set Payload"/>
</catch-exception-strategy>
</flow>
<!-- Flow which has delay in responding the data-->
<flow name="testtimeoutFlow1">
<http:listener config-ref="HTTP_Listener_Configuration1" path="/test" doc:name="HTTP" allowedMethods="GET"/>
<set-payload value="#['HelloWorld']" doc:name="Set Payload"/>
<logger message="#[payload]" level="INFO" doc:name="Logger"/>
<!-- Delay for 10 seconds-->
<scripting:component doc:name="Groovy">
<scripting:script engine="Groovy"><![CDATA[sleep(10000);
return message.payload;]]>
</scripting:script>
</scripting:component>
<logger message="After Script : #[payload]" level="INFO" doc:name="Logger"/>
</flow>
Hope this helps.

cvc-complex-type.2.4.a: Invalid content was found starting with element 'dw:transform-message'

I am trying to deploy a mule app on mule standalone 3.7.0 EE, but
when running I occur this error: cvc-complex-type.2.4.a: Invalid content was found starting with element 'dw:transform-message'
This is my flow:
<?xml version="1.0" encoding="UTF-8"?>
<mule xmlns:magento="http://www.mulesoft.org/schema/mule/magento" xmlns:dw="http://www.mulesoft.org/schema/mule/ee/dw" xmlns:http="http://www.mulesoft.org/schema/mule/http" xmlns:json="http://www.mulesoft.org/schema/mule/json" xmlns="http://www.mulesoft.org/schema/mule/core" xmlns:doc="http://www.mulesoft.org/schema/mule/documentation"
xmlns:spring="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-current.xsd
http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/current/mule.xsd
http://www.mulesoft.org/schema/mule/http http://www.mulesoft.org/schema/mule/http/current/mule-http.xsd
http://www.mulesoft.org/schema/mule/magento http://www.mulesoft.org/schema/mule/magento/current/mule-magento.xsd
http://www.mulesoft.org/schema/mule/json http://www.mulesoft.org/schema/mule/json/current/mule-json.xsd">
<http:listener-config name="HTTP_Listener_Configuration" host="0.0.0.0" port="8081" doc:name="HTTP Listener Configuration"/>
<magento:config name="Magento" username="test" password="test" address="http://127.0.0.1:8000/api/v2_soap/" doc:name="Magento"/>
<flow name="proFlow">
<http:listener config-ref="HTTP_Listener_Configuration" path="test" doc:name="HTTP"/>
<magento:get-order config-ref="Magento" orderId="100000000" doc:name="Magento"/>
<dw:transform-message doc:name="Transform Message">
<dw:set-payload><![CDATA[%dw 1.0
%output application/json
---
{
orderId: payload.increment_id
}]]></dw:set-payload>
</dw:transform-message>
<set-payload value="#[payload]" doc:name="Set Payload"/>
</flow>
</mule>
also, I have this dependency in pom.xml:
<dependency>
<groupId>com.mulesoft.weave</groupId>
<artifactId>mule-plugin-weave_2.11</artifactId>
<version>${mule.version}</version>
<scope>provided</scope>
</dependency>
Looks like you are missing this schema locations:
http://www.mulesoft.org/schema/mule/ee/dw
http://www.mulesoft.org/schema/mule/ee/dw/current/dw.xsd
Try to add it in xsi:schemaLocation list.
Hope this helps
Regards

Mule- error: cvc-complex-type.2.4.a: Invalid content was found starting with element 'magento:config'

I am trying to run in Anypoint Studio a project with maven using magento connector ver 2.2.0.
This is my project's xml file:
<mule xmlns:json="http://www.mulesoft.org/schema/mule/json" xmlns:magento="http://www.mulesoft.org/schema/mule/magento" xmlns:http="http://www.mulesoft.org/schema/mule/http" xmlns="http://www.mulesoft.org/schema/mule/core" xmlns:doc="http://www.mulesoft.org/schema/mule/documentation"
xmlns:spring="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-current.xsd
http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/current/mule.xsd
http://www.mulesoft.org/schema/mule/http http://www.mulesoft.org/schema/mule/http/current/mule-http.xsd
http://www.mulesoft.org/schema/mule/magento http://www.mulesoft.org/schema/mule/magento/current/mule-magento.xsd
http://www.mulesoft.org/schema/mule/json http://www.mulesoft.org/schema/mule/json/current/mule-json.xsd">
<http:listener-config name="HTTP_Listener_Configuration" host="0.0.0.0" port="8081" doc:name="HTTP Listener Configuration"/>
<magento:config name="Magento" username="test" password="test$" address="http://127.0.0.1:8000.com/api/v2_soap/" doc:name="Magento"/>
<flow name="magentoFlow">
<http:listener config-ref="HTTP_Listener_Configuration" path="/magento" doc:name="HTTP"/>
<magento:get-product config-ref="Magento" doc:name="Magento" productId="1"/>
<json:object-to-json-transformer doc:name="Object to JSON"/>
</flow>
</mule>
and this is the error:
Caused by: org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content was found starting with element 'magento:config'. One of '{"http://www.springframework.org/schema/beans":beans, "http://www.springframework.org/schema/beans":bean, "http://www.springframework.org/schema/context":property-placeholder, "http://www.springframework.org/schema/beans":ref, "http://www.mulesoft.org/schema/mule/core":global-property, "http://www.mulesoft.org/schema/mule/core":configuration, "http://www.mulesoft.org/schema/mule/core":notifications, "http://www.mulesoft.org/schema/mule/core":abstract-extension, "http://www.mulesoft.org/schema/mule/core":abstract-shared-extension, "http://www.mulesoft.org/schema/mule/core":abstract-mixed-content-extension, "http://www.mulesoft.org/schema/mule/core":abstract-agent, "http://www.mulesoft.org/schema/mule/core":abstract-security-manager, "http://www.mulesoft.org/schema/mule/core":abstract-transaction-manager, "http://www.mulesoft.org/schema/mule/core":abstract-shared-transaction-manager, "http://www.mulesoft.org/schema/mule/core":abstract-connector, "http://www.mulesoft.org/schema/mule/core":abstract-shared-connector, "http://www.mulesoft.org/schema/mule/core":abstract-global-endpoint, "http://www.mulesoft.org/schema/mule/core":abstract-exception-strategy, "http://www.mulesoft.org/schema/mule/core":abstract-flow-construct, "http://www.mulesoft.org/schema/mule/core":flow, "http://www.mulesoft.org/schema/mule/core":sub-flow, "http://www.mulesoft.org/schema/mule/core":abstract-model, "http://www.mulesoft.org/schema/mule/core":abstract-interceptor-stack, "http://www.mulesoft.org/schema/mule/core":abstract-filter, "http://www.mulesoft.org/schema/mule/core":abstract-transformer, "http://www.mulesoft.org/schema/mule/core":processor-chain, "http://www.mulesoft.org/schema/mule/core":custom-processor, "http://www.mulesoft.org/schema/mule/core":abstract-empty-processor, "http://www.mulesoft.org/schema/mule/core":invoke, "http://www.mulesoft.org/schema/mule/core":set-payload, "http://www.mulesoft.org/schema/mule/core":abstract-global-intercepting-message-processor, "http://www.mulesoft.org/schema/mule/core":custom-queue-store, "http://www.mulesoft.org/schema/mule/core":abstract-processing-strategy}' is expected.
What's missing?
Does the following work?
<?xml version="1.0" encoding="UTF-8"?>
<mule
xmlns:json="http://www.mulesoft.org/schema/mule/json"
xmlns:magento="http://www.mulesoft.org/schema/mule/magento"
xmlns:http="http://www.mulesoft.org/schema/mule/http"
xmlns="http://www.mulesoft.org/schema/mule/core"
xmlns:doc="http://www.mulesoft.org/schema/mule/documentation"
xmlns:spring="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-current.xsd
http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/3.7/mule.xsd
http://www.mulesoft.org/schema/mule/http http://www.mulesoft.org/schema/mule/http/3.7/mule-http.xsd
http://www.mulesoft.org/schema/mule/magento http://www.mulesoft.org/schema/mule/magento/1.2/mule-magento.xsd
http://www.mulesoft.org/schema/mule/json http://www.mulesoft.org/schema/mule/json/3.7/mule-json.xsd">
<http:listener-config name="HTTP_Listener_Configuration" host="0.0.0.0" port="8081" doc:name="HTTP Listener Configuration"/>
<magento:config name="Magento" username="test" password="test$" address="http://127.0.0.1:8000.com/api/v2_soap/" doc:name="Magento"/>
<flow name="magentoFlow">
<http:listener config-ref="HTTP_Listener_Configuration" path="/magento" doc:name="HTTP"/>
<magento:get-product config-ref="Magento" doc:name="Magento" productId="1"/>
<json:object-to-json-transformer doc:name="Object to JSON"/>
</flow>
</mule>
Changes from your snippet:
Added the XML declaration line
Changed the location of the XSDs to specific versions instead of 'current'.
(Am not sure if this is needed since the XSDs might be coming from jars on the classpath)

Magento Connector in Mule 3.5

I have tried creating Megento connector example program as given in the Megento connector vedio link.http://www.youtube.com/watch?v=GCbuqHLCiOg
My flow is:
<magento:config name="MagentoConnector" username="${magento.username}" password="${magento.password}" address="${magento.address}" doc:name="Magento">
<magento:connection-pooling-profile initialisationPolicy="INITIALISE_ONE" exhaustedAction="WHEN_EXHAUSTED_GROW"/>
</magento:config>
<flow name="ShoppingCartOPerations" doc:name="ShoppingCartOPerations">
<http:inbound-endpoint exchange-pattern="request-response" host="localhost" port="8081" path="shoppingCartOperation" doc:name="HTTP"/>
<flow-ref name="CreateProduct" doc:name="Flow Reference"/>
<set-payload value="Product Id is #[groovy:message.getProperty('productId')]" doc:name="Set Payload"/>
</flow>
<sub-flow name="CreateProduct" doc:name="CreateProduct">
<magento:create-product config-ref="MagentoConnector" type="simple" set="1" sku="simple_sku" storeViewIdOrCode="4" doc:name="Create Product" address="https://sashistore.gostorego.com/api/v2_soap" password="gdskey" username="gdssrao">
<magento:attributes name="SampleProduct" description="TestProduct" short_description="creating sample product" weight="100" status="1" visibility="4" price="100" tax_class_id="1"/>
</magento:create-product>
<set-property propertyName="productId" value="#[payload]" doc:name="Store Product id"/>
<magento:update-inventory-stock-item config-ref="MagentoConnector" productId="#[groovy:message.getProperty('productId')]" doc:name="Update Stock">
<magento:catalog-inventory-stock-item qty="33" is_in_stock="100" min_qty="10"/>
</magento:update-inventory-stock-item>
</sub-flow>
ERROR 2014-01-29 23:48:48,521 [[magentotest].connector.http.mule.default.receiver.02] org.mule.retry.notifiers.ConnectNotifier: Failed to connect/reconnect: Work Descriptor. Root Exception was: null. Type: class org.mule.api.ConnectionException
ERROR 2014-01-29 23:48:48,524 [[magentotest].connector.http.mule.default.receiver.02] org.mule.exception.DefaultMessagingExceptionStrategy:
<magento:config name="MagentoConnector" username="gdssrao" password="gdskey" address="https://sashistore.gostorego.com/api/v2_soap" doc:name="Magento">
<magento:connection-pooling-profile initialisationPolicy="INITIALISE_ONE" exhaustedAction="WHEN_EXHAUSTED_GROW"/>
</magento:config>
<flow name="ShoppingCartOPerationsFlow" doc:name="ShoppingCartOPerationsFlow">
<http:inbound-endpoint exchange-pattern="request-response" host="localhost" port="8081" path="shoppingCartOperation" doc:name="HTTP"/>
<logger level="INFO" doc:name="Logger"/>
<flow-ref name="CreateProductFlow" doc:name="Flow Reference"/>
<logger level="INFO" doc:name="Logger"/>
<set-payload value="Product Id is #[groovy:message.getProperty('productId')]" doc:name="Set Payload"/>
</flow>
<sub-flow name="CreateProductFlow" doc:name="CreateProductFlow">
<magento:create-product config-ref="MagentoConnector" type="simple" set="1" sku="simple_sku" storeViewIdOrCode="4" doc:name="Create Product">
<magento:attributes name="SampleProduct" description="TestProduct" short_description="creating sample product" weight="100" visibility="4" />
</magento:create-product>
<logger level="INFO" doc:name="Logger"/>
<set-property propertyName="productId" value="#[payload]" doc:name="Store Product id"/>
<logger level="INFO" doc:name="Logger"/>
<magento:update-inventory-stock-item config-ref="MagentoConnector" productId="#[groovy:message.getProperty('productId')]" doc:name="Update Stock">
<magento:catalog-inventory-stock-item />
</magento:update-inventory-stock-item>
</sub-flow>
You have defined your plaintext connection attributes (username, password, address) in magento:create-product and then you have them as application properties in magento:config. That does not really make sense, as you only need to define the attributes once (in the config element) when you use config-ref in the other elements. Since you are having a connection failure, I would guess that you have incorrect properties in the config element. Try using the attributes from magento:create-product, instead.
EDIT: I checked the WSDL for your Magento API, and it seems that you have incorrect address
Try using https://sashistore.gostorego.com/index.php/api/v2_soap/index/ instead.
EDIT2: I got the WSDL URL for Magento API v2 from the Magento documentation. See this page for explanation on how to get the address for Web services from WSDL.

Durable flag on my topic consumer doesn't work?

trying to implement the Durable feature on a Topic consumer.
Placed a name to the jms consumer and also clientID. (Obviously added the durable="true")
Now as far as i've read. The Topic will register the consumer as "durable" when it gets running for the first time.
So basically i did this, deployed the producer and consumer. It gets registered as a durable consumer. Publish a message to the topic, the consumer gets it. Now i undeploy the consumer and publish another message the consumer should be receive whenever gets up. When I deploy the consumer again, i get the common temp-topic://XXXXXXXXXXXX destination doesn't exist.
Why is this happening? Shouldn't i be getting the "lost" message?
This is my current jms activemq connector configuration for the publisher:
<?xml version="1.0" encoding="UTF-8"?>
<mule xmlns:jbossts="http://www.mulesoft.org/schema/mule/jbossts" xmlns="http://www.mulesoft.org/schema/mule/core" xmlns:http="http://www.mulesoft.org/schema/mule/http" xmlns:jms="http://www.mulesoft.org/schema/mule/jms" xmlns:doc="http://www.mulesoft.org/schema/mule/documentation" xmlns:spring="http://www.springframework.org/schema/beans" xmlns:core="http://www.mulesoft.org/schema/mule/core" version="CE-3.3.1" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="
http://www.mulesoft.org/schema/mule/http http://www.mulesoft.org/schema/mule/http/current/mule-http.xsd
http://www.mulesoft.org/schema/mule/jms http://www.mulesoft.org/schema/mule/jms/current/mule-jms.xsd
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-current.xsd
http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/current/mule.xsd
http://www.mulesoft.org/schema/mule/jbossts http://www.mulesoft.org/schema/mule/jbossts/current/mule-jbossts.xsd ">
<jms:activemq-connector name="Active_MQ" specification="1.1" brokerURL="tcp://localhost:61616" validateConnections="false" doc:name="Active MQ" maxRedelivery="1" persistentDelivery="true" durable="true" clientId="RoutingTopic">
<reconnect count="5" />
</jms:activemq-connector>
<message-properties-transformer name="MessagePropertiesTransformer" doc:name="Message Properties" overwrite="true">
<add-message-property key="BACKEND_SUBSCRIBER" value="#[flowVars['backend']]"/>
<add-message-property key="MULE_EVENT_TIMEOUT" value="60000"/>
</message-properties-transformer>
<flow name="jmsFlow1" doc:name="jmsFlow1">
<http:inbound-endpoint exchange-pattern="request-response" host="localhost" port="8081" path="jms" doc:name="HTTP"/>
<set-variable variableName="#['id']" value="#[message.inboundProperties['id']]" doc:name="set dynamic id"/>
<set-variable variableName="#['backend']" value="#[message.inboundProperties['backend']]" doc:name="setting backend"/>
<set-payload value="#['This is a message test for id '] #[flowVars['id']]" doc:name="set random string as payload"/>
<choice doc:name="Choice">
<when expression="#[true]">
<processor-chain>
<jms:outbound-endpoint exchange-pattern="request-response" connector-ref="Active_MQ" doc:name="JMS Topic Requestor" transformer-refs="MessagePropertiesTransformer" topic="ESB.Topic">
</jms:outbound-endpoint>
</processor-chain>
</when>
<otherwise>
<processor-chain>
<logger message="This is the default case" level="INFO" doc:name="Logger"/>
</processor-chain>
</otherwise>
</choice>
</flow>
</mule>
This is one of the consumers, i got 2, but both are basically the same thing
<?xml version="1.0" encoding="UTF-8"?>
<mule xmlns:jbossts="http://www.mulesoft.org/schema/mule/jbossts" xmlns="http://www.mulesoft.org/schema/mule/core" xmlns:jms="http://www.mulesoft.org/schema/mule/jms" xmlns:doc="http://www.mulesoft.org/schema/mule/documentation" xmlns:spring="http://www.springframework.org/schema/beans" xmlns:core="http://www.mulesoft.org/schema/mule/core" version="CE-3.3.1" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="
http://www.mulesoft.org/schema/mule/jms http://www.mulesoft.org/schema/mule/jms/current/mule-jms.xsd
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-current.xsd
http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/current/mule.xsd
http://www.mulesoft.org/schema/mule/jbossts http://www.mulesoft.org/schema/mule/jbossts/current/mule-jbossts.xsd ">
<jms:activemq-connector name="UpCity_Connector" specification="1.1" brokerURL="tcp://localhost:61616" validateConnections="false" maxRedelivery="0" doc:name="Active MQ" clientId="RandomName" durable="true"/>
<flow name="jmsAdapterConsumerFlow1" doc:name="fmsAdapterConsumerFlow1">
<jms:inbound-endpoint exchange-pattern="request-response" connector-ref="UpCity_Connector" doc:name="JMS Replier Consumer" topic="ESB.Topic">
<jms:selector expression="BACKEND_SUBSCRIBER='randombackend'"/>
</jms:inbound-endpoint>
<set-payload value="#[payload + ' returned from a random backend']" doc:name="Add string to payload"/>
<logger message="#[payload]" level="INFO" doc:name="Logger"/>
</flow>
</mule>
Thanks.
Durable Messaging is a little tricky in JMS, as your config/code will have to meet several criteria to get this to work correctly:
enable persistence in your broker's config (in ActiveMQ this is either done in the connection string as David posted, or in your configuration xml
create a durable subscriber (ActiveMQ API)
I'm not sure that mule creates durable subscribers. However, you can check that in ActiveMQ's web console. There you can get a list of the current durable subscriptions.

Resources