Advertisement
Guest User

dummy

a guest
Oct 20th, 2014
177
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
XML 1.36 KB | None | 0 0
  1.     <camelContext xmlns="http://camel.apache.org/schema/spring">
  2.         <route>
  3.             <from uri="direct:hello" />
  4.             <enrich uri="http://localhost:8080/hello?a=b" />
  5.             <convertBodyTo type="java.lang.String" />
  6.         </route>
  7.  
  8.         <route>
  9.             <from uri="direct:another" />
  10.             <enrich uri="http://localhost:8080/another?a=b" />
  11.             <convertBodyTo type="java.lang.String" />
  12.         </route>
  13.  
  14.         <route>
  15.             <from uri="direct:multi" />
  16.             <multicast parallelProcessing="true" strategyRef="aggregator">
  17.                 <enrich uri="direct:hello" />
  18.                 <enrich uri="direct:another" />
  19.             </multicast>
  20.         </route>
  21.  
  22.         <route>
  23.             <from uri="timer://foo?period=10000" />
  24.             <to uri="direct:multi" />
  25.  
  26.             <setBody>
  27.                 <simple>
  28.             ${property[CamelGroupedExchange]}
  29.         </simple>
  30.             </setBody>
  31.             <camel:transform>
  32.                 <camel:groovy>
  33.         import groovy.json.*
  34.          def slurper = new JsonSlurper()
  35.    
  36.         print "debubggyg\n"
  37.         print request.getBody()[1].getIn()
  38.         print "\n"
  39.         print request.getBody()[1].getIn().getBody()
  40.         def res = request.getBody().inject("") { result, i -> result +i.getIn().getBody()};
  41.         request =res;
  42.        
  43.          </camel:groovy>
  44.  
  45.             </camel:transform>
  46.          <from uri="spring-amqp:ex2:q2?durable=true&amp;type=topic&amp;autodelete=false&amp;routingKey=r2"/>
  47.             <to uri="log:marsha_3?multiline=true" />
  48.         </route>
  49.  
  50.     </camelContext>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement