Created
May 7, 2013 22:59
-
-
Save ddossot/5536875 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<flow name="fileToMqttBridge"> | |
<file:inbound-endpoint path="/tmp/mule/in" /> | |
<object-to-string-transformer /> | |
<!-- extract attendee info and transform to JSON payload --> | |
<expression-transformer | |
expression="#[extractAttendeeData(message.payload, '${boothId}')]" /> | |
<json:object-to-json-transformer /> | |
<mqtt:publish topicName="scans/booths" /> | |
<blink1:start-pattern deviceId="${blink1.device.id}" /> | |
<logger level="INFO" | |
message="Booth ${boothId} has scanned attendee #[attendeeId]" /> | |
<expression-component>Thread.sleep(1000);</expression-component> | |
<blink1:stop-pattern deviceId="${blink1.device.id}" /> | |
<blink1:set-color deviceId="${blink1.device.id}" color="off" /> | |
</flow> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment