ShipperTrackingNumber does not update on OrderFulfillment message - amazon-mws

The tracking number does not refresh on the Amazon webshop after OrderFulfillment message. What could be the problem?
I send in this with the request
<?xml version="1.0" encoding="UTF-8"?>
<AmazonEnvelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="amzn-envelope.xsd">
<Header>
<DocumentVersion>1.01</DocumentVersion>
<MerchantIdentifier>A3R5BRHC1LSKJ2</MerchantIdentifier>
</Header>
<MessageType>OrderFulfillment</MessageType>
<Message>
<MessageID>1</MessageID>
<OrderFulfillment>
<AmazonOrderID>206-3080255-0391536</AmazonOrderID>
<FulfillmentDate>2022-03-29T19:10:29+01:00</FulfillmentDate>
<FulfillmentData>
<CarrierCode>Other</CarrierCode>
<CarrierName>Parcel Force - Next Day</CarrierName>
<ShippingMethod>Standard</ShippingMethod>
<ShipperTrackingNumber>776427581888</ShipperTrackingNumber>
</FulfillmentData>
</OrderFulfillment>
</Message>
</AmazonEnvelope>
I get back this
<SubmitFeedResponse xmlns="http://mws.amazonaws.com/doc/2009-01-01/">
<SubmitFeedResult>
<FeedSubmissionInfo>
<FeedSubmissionId>179552019080</FeedSubmissionId>
<FeedType>_POST_ORDER_FULFILLMENT_DATA_</FeedType>
<SubmittedDate>2022-03-29T18:10:32+00:00</SubmittedDate>
<FeedProcessingStatus>_SUBMITTED_</FeedProcessingStatus>
</FeedSubmissionInfo>
</SubmitFeedResult>
<ResponseMetadata>
<RequestId>0b785678-99f1-4687-a6b9-ac2a3e2b23ab</RequestId>
</ResponseMetadata>
</SubmitFeedResponse>

Related

bundle stays in GracePeriod status

I am trying to instantiate a "cxf:cxfEndpoint" in my camel route. But the bundle stays in "GracePeriod" status with following log:
2016-11-10 11:03:07,598 | INFO | rint Extender: 1 | BlueprintContainerImpl | ? ? | 21 - org.apache.aries.blueprint.core - 1.4.2 | Bundle com.entreprise.example is waiting for namespace handlers [http://camel.apache.org/schema/blueprint]
And my camelContext.xml file is :
<blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:cm="http://aries.apache.org/blueprint/xmlns/blueprint-cm/v1.0.0"
xmlns:jaxws="http://cxf.apache.org/blueprint/jaxws" xmlns:cxf="http://cxf.apache.org/blueprint/core"
xmlns:camel="http://camel.apache.org/schema/blueprint" xmlns:camelcxf="http://camel.apache.org/schema/blueprint/cxf"
xsi:schemaLocation=" http://www.osgi.org/xmlns/blueprint/v1.0.0 http://www.osgi.org/xmlns/blueprint/v1.0.0/blueprint.xsd
http://cxf.apache.org/blueprint/jaxws http://cxf.apache.org/schemas/blueprint/jaxws.xsd
http://cxf.apache.org/blueprint/core http://cxf.apache.org/schemas/blueprint/core.xsd">
<camelcxf:cxfEndpoint id="fist"
serviceClass="com.entreprise.example.services.firstService"
address="http://localhost:8181/cxf/example/firstMsg">
<camelcxf:properties>
<entry key="dataFormat" value="POJO" />
<entry key="loggingFeatureEnabled" value="true" />
</camelcxf:properties>
</camelcxf:cxfEndpoint>
<camelcxf:cxfEndpoint id="second"
serviceClass="com.entreprise.example.services.secondService"
address="http://localhost:8181/cxf/example/secondMessage">
<camelcxf:properties>
<entry key="dataFormat" value="POJO" />
<entry key="loggingFeatureEnabled" value="true" />
</camelcxf:properties>
</camelcxf:cxfEndpoint>
<camelContext trace="false" id="example"
xmlns="http://camel.apache.org/schema/blueprint">
<route>
<from uri="cxf:bean:first" />
<to uri="cxf:bean:second" />
</route>
</camelContext>
Seems like you have really messed up with your blueprint schema declartions. Replace blueprint declaration with something like below
<?xml version="1.0" encoding="UTF-8"?>
<blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
xmlns:cxf="http://camel.apache.org/schema/blueprint/cxf"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.osgi.org/xmlns/blueprint/v1.0.0 https://www.osgi.org/xmlns/blueprint/v1.0.0/blueprint.xsd
http://camel.apache.org/schema/blueprint http://camel.apache.org/schema/blueprint/camel-blueprint.xsd">
And use "cxf" instead of "camelcxf" as prefix for the Endpoint and Bean this will become more clear and redeable (though you are free to use any prefix you prefer to use).
Ok, to avoid confusion use as below, this will resolve the waiting for dependencies error:
<?xml version="1.0" encoding="UTF-8"?>
<blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
xmlns:cm="http://aries.apache.org/blueprint/xmlns/blueprint-cm/v1.2.0"
xmlns:cxf="http://camel.apache.org/schema/blueprint/cxf" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.osgi.org/xmlns/blueprint/v1.0.0 https://www.osgi.org/xmlns/blueprint/v1.0.0/blueprint.xsd
http://camel.apache.org/schema/blueprint http://camel.apache.org/schema/blueprint/camel-blueprint.xsd">
<cxf:cxfEndpoint id="fist"
serviceClass="com.entreprise.example.services.firstService" address="http://localhost:8181/cxf/example/firstMsg">
<cxf:properties>
<entry key="dataFormat" value="POJO" />
<entry key="loggingFeatureEnabled" value="true" />
</cxf:properties>
</cxf:cxfEndpoint>
<cxf:cxfEndpoint id="second"
serviceClass="com.entreprise.example.services.secondService" address="http://localhost:8181/cxf/example/secondMessage">
<cxf:properties>
<entry key="dataFormat" value="POJO" />
<entry key="loggingFeatureEnabled" value="true" />
</cxf:properties>
</cxf:cxfEndpoint>
<camelContext trace="false" id="example"
xmlns="http://camel.apache.org/schema/blueprint">
<route>
<from uri="cxf:bean:first" />
<to uri="cxf:bean:second" />
</route>
</blueprint>

_POST_FBA_INBOUND_CARTON_CONTENTS_ Error

The XML below for FBA carton information is set when we create a shipment.
<MessageType>CartonContentsRequest</MessageType>
<Message>
<MessageID>1</MessageID>
<CartonContentsRequest>
<ShipmentId>XXXXKQN8</ShipmentId>
<NumCartons>3</NumCartons>
<Carton>
<CartonId>1</CartonId>
<Item><SKU>FBA-XXX80</SKU>
<QuantityShipped>2</QuantityShipped>
<QuantityInCase>2</QuantityInCase>
</Item>
</Carton>
<Carton><CartonId>2</CartonId>
<Item><SKU>FBA-DDESXX11</SKU><QuantityShipped>5</QuantityShipped><QuantityInCase>5</QuantityInCase></Item>
</Carton>
<Carton><CartonId>3</CartonId><Item><SKU>FBA-XXX</SKU><QuantityShipped>5</QuantityShipped><QuantityInCase>5</QuantityInCase></Item></Carton></CartonContentsRequest></Message></AmazonEnvelope>
We passed the XML for carton information, but we're getting an error.
whats your error?
i'm uploading this feed Daily i can probably help you
this should work
<?xml version="1.0" encoding="utf-8" ?>
<AmazonEnvelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="amzn-envelope.xsd">
<Header> <DocumentVersion>1.01</DocumentVersion>
<MerchantIdentifier>[SellerID]</MerchantIdentifier>
</Header>
<MessageType>CartonContentsRequest</MessageType>
<Message>
<MessageID>1</MessageID>
<CartonContentsRequest>
<ShipmentId>[ShipmentID]</ShipmentId>
<NumCartons>2</NumCartons>
<Carton>
<CartonId>FBA001</CartonId>
<Item><SKU>sellerSKU1</SKU><QuantityShipped>55</QuantityShipped><QuantityInCase>1</QuantityInCase></Item>
</Carton>
<Carton>
<CartonId>FBA002</CartonId>
<Item><SKU>sellerSKU2</SKU><QuantityShipped>55</QuantityShipped><QuantityInCase>1</QuantityInCase></Item>
</Carton>
</CartonContentsRequest>
</Message>
</AmazonEnvelope>

SSAS - CUBE data getting deleted while running XMLA based job

I have two CUBEs which internally use few common dimensions. The CUBEs itself are having partitions based on the year of the data. Also, I have the following two jobs set-up to refresh the latest year partitions of each CUBE.
Problem: Once the first job completes and the second job is run, I see the data for the first CUBE getting wiped off.
Job#1 XMLA script
<Batch xmlns="http://schemas.microsoft.com/analysisservices/2003/engine">
<Parallel>
<Process xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ddl2="http://schemas.microsoft.com/analysisservices/2003/engine/2" xmlns:ddl2_2="http://schemas.microsoft.com/analysisservices/2003/engine/2/2" xmlns:ddl100_100="http://schemas.microsoft.com/analysisservices/2008/engine/100/100" xmlns:ddl200="http://schemas.microsoft.com/analysisservices/2010/engine/200" xmlns:ddl200_200="http://schemas.microsoft.com/analysisservices/2010/engine/200/200">
<Object>
<DatabaseID>MyDatabase</DatabaseID>
<DimensionID>Dimension1</DimensionID>
</Object>
<Type>ProcessUpdate</Type>
<WriteBackTableCreation>UseExisting</WriteBackTableCreation>
</Process>
<Process xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ddl2="http://schemas.microsoft.com/analysisservices/2003/engine/2" xmlns:ddl2_2="http://schemas.microsoft.com/analysisservices/2003/engine/2/2" xmlns:ddl100_100="http://schemas.microsoft.com/analysisservices/2008/engine/100/100" xmlns:ddl200="http://schemas.microsoft.com/analysisservices/2010/engine/200" xmlns:ddl200_200="http://schemas.microsoft.com/analysisservices/2010/engine/200/200">
<Object>
<DatabaseID>MyDatabase</DatabaseID>
<DimensionID>Dimension2</DimensionID>
</Object>
<Type>ProcessUpdate</Type>
<WriteBackTableCreation>UseExisting</WriteBackTableCreation>
</Process>
<Process xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ddl2="http://schemas.microsoft.com/analysisservices/2003/engine/2" xmlns:ddl2_2="http://schemas.microsoft.com/analysisservices/2003/engine/2/2" xmlns:ddl100_100="http://schemas.microsoft.com/analysisservices/2008/engine/100/100" xmlns:ddl200="http://schemas.microsoft.com/analysisservices/2010/engine/200" xmlns:ddl200_200="http://schemas.microsoft.com/analysisservices/2010/engine/200/200">
<Object>
<DatabaseID>MyDatabase</DatabaseID>
<DimensionID>Dimension3</DimensionID>
</Object>
<Type>ProcessUpdate</Type>
<WriteBackTableCreation>UseExisting</WriteBackTableCreation>
</Process>
<Parallel>
<Process xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ddl2="http://schemas.microsoft.com/analysisservices/2003/engine/2" xmlns:ddl2_2="http://schemas.microsoft.com/analysisservices/2003/engine/2/2" xmlns:ddl100_100="http://schemas.microsoft.com/analysisservices/2008/engine/100/100" xmlns:ddl200="http://schemas.microsoft.com/analysisservices/2010/engine/200" xmlns:ddl200_200="http://schemas.microsoft.com/analysisservices/2010/engine/200/200" xmlns:ddl300="http://schemas.microsoft.com/analysisservices/2011/engine/300" xmlns:ddl300_300="http://schemas.microsoft.com/analysisservices/2011/engine/300/300" xmlns:ddl400="http://schemas.microsoft.com/analysisservices/2012/engine/400" xmlns:ddl400_400="http://schemas.microsoft.com/analysisservices/2012/engine/400/400">
<Object>
<DatabaseID>MyDatabase</DatabaseID>
<CubeID>MyCUBE1</CubeID>
<MeasureGroupID>MyMeasureGroup1</MeasureGroupID>
<PartitionID>2016 Partition</PartitionID>
</Object>
<Type>ProcessFull</Type>
<WriteBackTableCreation>UseExisting</WriteBackTableCreation>
</Process>
</Parallel>
</Batch>
Job#2 XMLA script
<Batch xmlns="http://schemas.microsoft.com/analysisservices/2003/engine">
<Parallel>
<Process xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ddl2="http://schemas.microsoft.com/analysisservices/2003/engine/2" xmlns:ddl2_2="http://schemas.microsoft.com/analysisservices/2003/engine/2/2" xmlns:ddl100_100="http://schemas.microsoft.com/analysisservices/2008/engine/100/100" xmlns:ddl200="http://schemas.microsoft.com/analysisservices/2010/engine/200" xmlns:ddl200_200="http://schemas.microsoft.com/analysisservices/2010/engine/200/200">
<Object>
<DatabaseID>MyDatabase</DatabaseID>
<DimensionID>Dimension1</DimensionID>
</Object>
<Type>ProcessUpdate</Type>
<WriteBackTableCreation>UseExisting</WriteBackTableCreation>
</Process>
<Process xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ddl2="http://schemas.microsoft.com/analysisservices/2003/engine/2" xmlns:ddl2_2="http://schemas.microsoft.com/analysisservices/2003/engine/2/2" xmlns:ddl100_100="http://schemas.microsoft.com/analysisservices/2008/engine/100/100" xmlns:ddl200="http://schemas.microsoft.com/analysisservices/2010/engine/200" xmlns:ddl200_200="http://schemas.microsoft.com/analysisservices/2010/engine/200/200">
<Object>
<DatabaseID>MyDatabase</DatabaseID>
<DimensionID>Dimension2</DimensionID>
</Object>
<Type>ProcessUpdate</Type>
<WriteBackTableCreation>UseExisting</WriteBackTableCreation>
</Process>
<Parallel>
<Process xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ddl2="http://schemas.microsoft.com/analysisservices/2003/engine/2" xmlns:ddl2_2="http://schemas.microsoft.com/analysisservices/2003/engine/2/2" xmlns:ddl100_100="http://schemas.microsoft.com/analysisservices/2008/engine/100/100" xmlns:ddl200="http://schemas.microsoft.com/analysisservices/2010/engine/200" xmlns:ddl200_200="http://schemas.microsoft.com/analysisservices/2010/engine/200/200" xmlns:ddl300="http://schemas.microsoft.com/analysisservices/2011/engine/300" xmlns:ddl300_300="http://schemas.microsoft.com/analysisservices/2011/engine/300/300" xmlns:ddl400="http://schemas.microsoft.com/analysisservices/2012/engine/400" xmlns:ddl400_400="http://schemas.microsoft.com/analysisservices/2012/engine/400/400">
<Object>
<DatabaseID>MyDatabase</DatabaseID>
<CubeID>MyCUBE2</CubeID>
<MeasureGroupID>MyMeasureGroup2</MeasureGroupID>
<PartitionID>2016 Partition</PartitionID>
</Object>
<Type>ProcessFull</Type>
<WriteBackTableCreation>UseExisting</WriteBackTableCreation>
</Process>
</Parallel>
</Batch>
Can someone let me know what configuration I am missing so that the data does not get deleted? Can I re-arrange the jobs to avoid this?

Camel: using property placeholders for boolean attribute in CXF endpoint configuration

I like to use a property placeholder for a Boolean attribute in my CXF endpoint definition.I've read the doc about the placeholder prefix in http://camel.apache.org/using-propertyplaceholder.html but ik cannot figure out how to apply them in my endpoint configuration. String placeholders work fine. In the example below I use Boolean attribute ${ws-logging}, and the XML won't validate. How can I use a property placeholder for a Boolean attribute in a CXF endpoint configuration?
<blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:prop="http://camel.apache.org/schema/placeholder"
xmlns:camel-cxf="http://camel.apache.org/schema/blueprint/cxf"
xsi:schemaLocation="
http://www.osgi.org/xmlns/blueprint/v1.0.0 http://www.osgi.org/xmlns/blueprint/v1.0.0/blueprint.xsd
http://camel.apache.org/schema/blueprint http://camel.apache.org/schema/blueprint/camel-blueprint.xsd">
<property-placeholder persistent-id="test.config" id="test.config.placeholder" xmlns="http://aries.apache.org/blueprint/xmlns/blueprint-cm/v1.0.0">
<default-properties>
<property name="ws-logging" value="true"/>
</default-properties>
</property-placeholder>
<camel-cxf:cxfEndpoint id="update"
address="http://someaddress"
endpointName="ssp:someendpoint"
serviceName="ssp:someservice"
wsdlURL="http://someaddress/wsdl?targetURI=sometargeturi"
xmlns:ssp="somenamespace"
loggingFeatureEnabled="${ws-logging}">
<camel-cxf:properties>
<entry key="dataFormat" value="PAYLOAD"/>
</camel-cxf:properties>
</camel-cxf:cxfEndpoint>
<camelContext xmlns="http://camel.apache.org/schema/blueprint">
<route id="timerToLog">
<from uri="timer:foo?period=5000"/>
<to uri="mock:result"/>
</route>
</camelContext>
</blueprint>
I believe you're missing a schema reference and namespace: blueprint-cm. Try adding it like the example below.
<blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:camel-cxf="http://camel.apache.org/schema/cxf"
xmlns:cm="http://aries.apache.org/blueprint/xmlns/blueprint-cm/v1.0.0"
xsi:schemaLocation="http://camel.apache.org/schema/cxf http://camel.apache.org/schema/cxf/camel-cxf.xsd
http://aries.apache.org/blueprint/xmlns/blueprint-cm/v1.0.0 http://aries.apache.org/schemas/blueprint-cm/blueprint-cm-1.0.0.xsd
http://www.osgi.org/xmlns/blueprint/v1.0.0 http://www.osgi.org/xmlns/blueprint/v1.0.0/blueprint.xsd
http://camel.apache.org/schema/blueprint http://camel.apache.org/schema/blueprint/camel-blueprint.xsd">
<cm:property-placeholder persistent-id="com.example">
<cm:default-properties>
<property name="ws-logging" value="true"/>
</cm:default-properties>
</cm:property-placeholder>
</blueprint>

How to link a soap request and response in mule 3

I need to send a file to a external web service. When the response is 1, the file should be deleted, else the file should be kept.
I use the file connector to send the file, and insert a record into Oracle. When the file is sent out, the key is the message id of the file connect. I want to keep the message id so that I can update the record using this id when the response is back.
I tried to use MessagePropertiesTransformer to add a custom property, but the response doesn't preserve it. Is there any way to keep the message id?
My config:
<?xml version="1.0" encoding="UTF-8"?>
<mule xmlns="http://www.mulesoft.org/schema/mule/core"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:file="http://www.mulesoft.org/schema/mule/file"
xmlns:stdio="http://www.mulesoft.org/schema/mule/stdio"
xmlns:cxf="http://www.mulesoft.org/schema/mule/cxf"
xmlns:spring="http://www.springframework.org/schema/beans"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:jdbc="http://www.mulesoft.org/schema/mule/jdbc"
xmlns:mulexml="http://www.mulesoft.org/schema/mule/xml"
xsi:schemaLocation="
http://www.mulesoft.org/schema/mule/file http://www.mulesoft.org/schema/mule/file/3.1/mule-file.xsd
http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/3.1/mule.xsd
http://www.mulesoft.org/schema/mule/stdio http://www.mulesoft.org/schema/mule/stdio/3.1/mule-stdio.xsd
http://www.mulesoft.org/schema/mule/cxf http://www.mulesoft.org/schema/mule/cxf/3.1/mule-cxf.xsd
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.0.xsd
http://www.mulesoft.org/schema/mule/jdbc http://www.mulesoft.org/schema/mule/jdbc/3.1/mule-jdbc.xsd
http://www.mulesoft.org/schema/mule/xml http://www.mulesoft.org/schema/mule/xml/3.1/mule-xml.xsd
">
<spring:bean id="jdbcDataSource" class="org.enhydra.jdbc.standard.StandardDataSource" destroy-method="shutdown">
<spring:property name="driverName" value="oracle.jdbc.driver.OracleDriver"/>
<spring:property name="url" value="jdbc:oracle:thin:user/pass#ip:1521:orcl"/>
</spring:bean>
<file:connector name="output" outputAppend="true" outputPattern="#[function:datestamp]-#[header:originalFilename]" />
<file:connector name="input" streaming="false" recursive="true" autoDelete="false">
<service-overrides messageFactory="org.mule.transport.file.FileMuleMessageFactory" />
</file:connector>
<jdbc:connector name="jdbcConnector" pollingFrequency="10000" dataSource-ref="jdbcDataSource">
<jdbc:query key="outboundInsertStatement"
value="INSERT INTO TEST_MESSAGE (message_id, filename, done) VALUES (#[message:id],
#[header:originalFilename], #[string:0])"/>
</jdbc:connector>
<mulexml:namespace-manager includeConfigNamespaces="true">
<mulexml:namespace prefix="ns1" uri="http://www.iec.ch/TC57/2008/schema/message"/>
<mulexml:namespace prefix="soapenv" uri="http://schemas.xmlsoap.org/soap/envelope/"/>
<mulexml:namespace prefix="ns1" uri="http://www.iec.ch/TC57/2008/schema/message"/>
<mulexml:namespace prefix="fullmodel" uri="iesb.dongfang.com"/>
</mulexml:namespace-manager>
<flow name="fileTestFlow1">
<file:inbound-endpoint path="D:/data/in" moveToDirectory="D:/data/out" moveToPattern="#[message:id]-#[header:originalFilename]" connector-ref="input"/>
<component class="com.component.FileNameExtract"/>
<message-properties-transformer scope="outbound">
<add-message-property key="test" value="#[message:id]"/>
</message-properties-transformer>
<jdbc:outbound-endpoint queryKey="outboundInsertStatement"/>
<cxf:jaxws-client
clientClass="com.ws.IESBService"
port="IESBServiceEndpoint"
wsdlLocation="classpath:IESBService.wsdl"
operation="requestInfo"/>
<outbound-endpoint address="http://ip:8888/axis2/services/iESBService/" exchange-pattern="request-response">
</outbound-endpoint>
<xml-entity-decoder-transformer/>
<logger message=" #[header:test] !" level="INFO"></logger>
</flow>
</mule>
UPDATE:
I tried "session" scope and I think it works. New config:
<?xml version="1.0" encoding="UTF-8"?>
<mule xmlns="http://www.mulesoft.org/schema/mule/core"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:file="http://www.mulesoft.org/schema/mule/file"
xmlns:stdio="http://www.mulesoft.org/schema/mule/stdio"
xmlns:cxf="http://www.mulesoft.org/schema/mule/cxf"
xmlns:spring="http://www.springframework.org/schema/beans"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:jdbc="http://www.mulesoft.org/schema/mule/jdbc"
xmlns:mulexml="http://www.mulesoft.org/schema/mule/xml"
xsi:schemaLocation="
http://www.mulesoft.org/schema/mule/file http://www.mulesoft.org/schema/mule/file/3.1/mule-file.xsd
http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/3.1/mule.xsd
http://www.mulesoft.org/schema/mule/stdio http://www.mulesoft.org/schema/mule/stdio/3.1/mule-stdio.xsd
http://www.mulesoft.org/schema/mule/cxf http://www.mulesoft.org/schema/mule/cxf/3.1/mule-cxf.xsd
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.0.xsd
http://www.mulesoft.org/schema/mule/jdbc http://www.mulesoft.org/schema/mule/jdbc/3.1/mule-jdbc.xsd
http://www.mulesoft.org/schema/mule/xml http://www.mulesoft.org/schema/mule/xml/3.1/mule-xml.xsd
">
<spring:bean id="jdbcDataSource" class="org.enhydra.jdbc.standard.StandardDataSource" destroy-method="shutdown">
<spring:property name="driverName" value="oracle.jdbc.driver.OracleDriver"/>
<spring:property name="url" value="jdbc:oracle:thin:user/pass#ip:1521:orcl"/>
</spring:bean>
<file:connector name="output" outputAppend="true" outputPattern="#[function:datestamp]-#[header:originalFilename]" />
<file:connector name="input" streaming="false" recursive="true" autoDelete="false">
<service-overrides messageFactory="org.mule.transport.file.FileMuleMessageFactory" />
</file:connector>
<jdbc:connector name="jdbcConnector" pollingFrequency="10000" dataSource-ref="jdbcDataSource">
<jdbc:query key="outboundInsertStatement"
value="INSERT INTO TEST_MESSAGE (message_id, filename, done) VALUES (#[message:id],
#[header:originalFilename], #[string:0])"/>
<jdbc:query key="outboundUpdateStatement"
value="update TEST_MESSAGE set done='1' where message_id=#[header:SESSION:test] "/>
</jdbc:connector>
<mulexml:namespace-manager includeConfigNamespaces="true">
<mulexml:namespace prefix="ns1" uri="http://www.iec.ch/TC57/2008/schema/message"/>
<mulexml:namespace prefix="soapenv" uri="http://schemas.xmlsoap.org/soap/envelope/"/>
<mulexml:namespace prefix="ns1" uri="http://www.iec.ch/TC57/2008/schema/message"/>
<mulexml:namespace prefix="fullmodel" uri="iesb.dongfang.com"/>
</mulexml:namespace-manager>
<flow name="fileTestFlow1">
<file:inbound-endpoint path="D:/data/in" moveToDirectory="D:/data/out" moveToPattern="#[message:id]-#[header:originalFilename]" connector-ref="input"/>
<component class="com.component.FileNameExtract"/>
<message-properties-transformer scope="outbound">
<add-message-property key="test" value="#[message:id]"/>
</message-properties-transformer>
<logger message="first #[message:id] " level="INFO"></logger>
<jdbc:outbound-endpoint queryKey="outboundInsertStatement"/>
<cxf:jaxws-client
clientClass="com.ws.IESBService"
port="IESBServiceEndpoint"
wsdlLocation="classpath:IESBService.wsdl"
operation="requestInfo"/>
<outbound-endpoint address="http://ip:8888/axis2/services/iESBService/" exchange-pattern="request-response">
</outbound-endpoint>
<xml-entity-decoder-transformer/>
<jdbc:outbound-endpoint queryKey="outboundUpdateStatement"/>
<logger message="second #[header:SESSION:test] " level="INFO"></logger>
</flow>
</mule>
When I copy the file one by one, it's ok, but when I copy more than five files to the directory, some records can't be updated.
Executing SQL statement: 0 row(s) updated
Set your JDBC outbound endpoint to request-response in order to ensure the flow will execute in a single thread. With your current configuration, the 2 in-only JDBC requests are "detached" from the flow and executed in parallel from it.

Resources