Guest User

Untitled

a guest
Jan 24th, 2018
90
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.79 KB | None | 0 0
  1. public static void main(String... args) throws MuleException {
  2. Mule myMule = Mule.newInstance(new AbstractModule() { //creates a new mule instance using an anonymous inner AbstractModule based class
  3. @Override
  4. protected void configure() {
  5. flow("multipleFileMove")
  6. .from("file:///opt/my_app/out") // source folder
  7. .transformTo(byte[].class) //transform file to byte[]
  8. .broadcast() //broadcast the payload to
  9. .send("file:///opt/other_app/in") //destiny folder
  10. .send("file:///opt/crm/in") //destiny folder
  11. .send("file:///opt/billing/in") //destiny folder
  12. .endBroadcast();
  13. }
  14. });
  15.  
  16. myMule.start(); //start mule
  17. }
Add Comment
Please, Sign In to add comment