Skip to content

Instantly share code, notes, and snippets.

@ddossot
Created February 1, 2011 17:21
Show Gist options
  • Save ddossot/806200 to your computer and use it in GitHub Desktop.
Save ddossot/806200 to your computer and use it in GitHub Desktop.
<?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:quartz="http://www.mulesoft.org/schema/mule/quartz"
xmlns:http="http://www.mulesoft.org/schema/mule/http"
xmlns:amqp="http://www.mulesoft.org/schema/mule/amqp"
xmlns:file="http://www.mulesoft.org/schema/mule/file"
xmlns:context="http://www.springframework.org/schema/context"
xsi:schemaLocation="
http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/3.1/mule.xsd
http://www.mulesoft.org/schema/mule/quartz http://www.mulesoft.org/schema/mule/quartz/3.1/mule-quartz.xsd
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/http http://www.mulesoft.org/schema/mule/http/3.1/mule-http.xsd
http://www.mulesoft.org/schema/mule/amqp http://www.mulesoft.org/schema/mule/amqp/3.1/mule-amqp.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-2.5.xsd">
<context:property-placeholder location="financial-pollers.properties" />
<amqp:connector name="amqpConnector"
host="${amqp.host}"
port="${amqp.port}"
fallbackAddresses="${amqp.fallbackAddresses}"
virtualHost="${amqp.virtualHost}"
username="${amqp.username}"
password="${amqp.password}" />
<amqp:endpoint name="financialExchange"
exchangeName="financial"
exchangeAutoDelete="false"
exchangeDurable="true"
exchangeType="topic" />
<bridge name="currencyRatePoller"
exchange-pattern="one-way">
<quartz:inbound-endpoint cronExpression="* 0 * * * ?"
jobName="hourlyCurrencyRatePoller">
<quartz:endpoint-polling-job>
<quartz:job-endpoint address="${currency.feed.url}" />
</quartz:endpoint-polling-job>
</quartz:inbound-endpoint>
<amqp:outbound-endpoint ref="financialExchange"
routingKey="currency.rates" />
</bridge>
<bridge name="financialExchangeAuditTrail"
exchange-pattern="one-way">
<amqp:inbound-endpoint exchangeName="financial"
exchangeAutoDelete="false"
exchangeDurable="true"
exchangeType="topic"
queueName="audit-trail"
queueAutoDelete="false"
queueDurable="true"
routingKey="#"
consumerTag="mule-audit-trail" />
<file:outbound-endpoint path="${financial.audit.dir}"
outputPattern="#[string:#[header:INBOUND:routing-key]_#[function:datestamp:dd-MM-yyyy_HH-mm-ss]]" />
</bridge>
</mule>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment