};
if ("JAXB".equals(configuration.getMarshaller())) {
rb.from("direct:with-session-jaxb").to("drools:" + smId + "/" + configuration.getSessionId() + "?dataFormat=drools-jaxb");
}
else if ("XSTREAM".equals(configuration.getMarshaller())) {
rb.from("direct:with-session-xstream").to("drools:" + smId + "/" + configuration.getSessionId() + "?dataFormat=drools-xstream");
}
else {
throw new IllegalArgumentException("Invalid marshaller value on camel routes creation: " + configuration.getMarshaller());
}
camelContext.addRoutes(rb);