pekko/akka-samples/akka-sample-camel-java/src/main/java/sample/camel/route/CustomRouteBuilder.java
Patrik Nordwall 23dd957ba2 =doc #3689 Make activator templates for camel samples
* @rkuhn found the problems in the scala camel samples
  - HttpSample returns scrambled data
  - CustomRouteSample times out
2013-12-12 16:03:02 +01:00

15 lines
476 B
Java

package sample.camel.route;
import org.apache.camel.Exchange;
import org.apache.camel.Processor;
import org.apache.camel.builder.RouteBuilder;
public class CustomRouteBuilder extends RouteBuilder {
public void configure() throws Exception {
from("direct:welcome").process(new Processor() {
public void process(Exchange exchange) throws Exception {
exchange.getOut().setBody(String.format("Welcome %s", exchange.getIn().getBody()));
}
});
}
}