Skip to content

Instantly share code, notes, and snippets.

@johndemic
Created September 24, 2013 15:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save johndemic/6686952 to your computer and use it in GitHub Desktop.
Save johndemic/6686952 to your computer and use it in GitHub Desktop.
An example of using the CassandraDbObjectStore to distribute the state of an idempotent-message-filter.
<spring:bean id="cassandraObjectStore" class="com.mulesoft.mule.cassandradb.CassandraDBObjectStore"
scope="singleton">
<spring:property name="host" value="cassandradb.acmesoft.com"/>
<spring:property name="port" value="9160"/>
<spring:property name="keyspace" value="MuleState"/>
<spring:property name="consistencyLevel" value="ALL"/>
<spring:property name="defaultPartitionName"
value="idempotentFlow_#[new java.text.SimpleDateFormat('yyyy_MM_dd').format(new Date())]"/>
</spring:bean>
<flow name="idempotentReception">
<http:inbound-endpoint address="http://0.0.0.0:8080/orders" exchange-patter="one-way"/>
<idempotent-message-filter idExpression="#[payload]">
<spring-object-store ref="cassandraObjectStore"/>
</idempotent-message-filter>
<vm:outbound-endpoint path="order.process"/>
</flow>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment