You have to register a transaction policy in the registry and with the transaction manager. In straight java it looks like this.
final JmsTransactionManager txMgr = new JmsTransactionManager(amqcf); registry.bind(KEY_AMQ_TXMANAGER, txMgr); final SpringTransactionPolicy txPolicyRequired = newSpringTransactionPolicy(); txPolicyRequired.setTransactionManager(txMgr); txPolicyRequired.setPropagationBehaviorName("PROPAGATION_REQUIRED"); registry.bind(KEY_TXPOLICY_REQUIRED, txPolicyRequired); It can also be done with spring. Refer to this page for more information: http://camel.apache.org/transactional-client.html *Robert Simmons Jr. MSc. - Lead Java Architect @ EA* *Author of: Hardcore Java (2003) and Maintainable Java (2012)* *LinkedIn: **http://www.linkedin.com/pub/robert-simmons/40/852/a39 <http://www.linkedin.com/pub/robert-simmons/40/852/a39>* On Thu, Jan 2, 2014 at 6:45 AM, fkfausa <frode.fa...@cgi.com> wrote: > Hi! > > I get the following error: > Caused by: org.apache.camel.RuntimeCamelException: > org.apache.camel.FailedToCreateRouteException: Failed to create route > BAS.G8.workorders.processJMSMessageRoute at: >>> Policy[ref:required] <<< > in > route: Route[[From[activemq:queue:bas-integration.workorders.incomi... > because of No bean could be found in the registry for: required of type: > org.apache.camel.spi.Policy > > from this route: > > private void processJMSMessage() { > > > from("activemq:queue:bas-integration.workorders.incomingFromISCustomer"). > id("BAS.G8.workorders.processJMSMessageRoute"). > > > errorHandler(deadLetterChannel("activemq:queue:bas-integration.workorders.deadLetter"). > useOriginalMessage(). > logHandled(true)). > end(). > onException(ConnectException.class). > maximumRedeliveries(2). > backOffMultiplier(2). > redeliveryDelay(5000). > useOriginalMessage(). > logExhausted(true). > logHandled(true). > logRetryStackTrace(true). > logStackTrace(true). > handled(true). > log("Putting message back to > 'activemq:queue:bas-integration.workorders.incomingFromISCustomer' due to a > ConnectionException. Server is probably down"). > > to("activemq:queue:bas-integration.workorders.incomingFromISCustomer"). > end(). > transacted("required"). > choice(). > > > when(header("JMSType").isEqualTo("application/vnd.com.infosynergi.iscustomer.event.WorkOrderInitiatedEvent-v1+xml")). > process(extractWorkOrderInitiatedEvent). > > > when(header("JMSType").isEqualTo("application/vnd.com.infosynergi.iscustomer.event.WorkOrderUpdatedEvent-v1+xml")). > process(extractWorkOrderUpdatedEvent). > > > when(header("JMSType").isEqualTo("application/vnd.com.infosynergi.iscustomer.event.TechnicianWorkOrderUpdatedEvent-v1+xml")). > process(extractTechnicianWorkOrderUpdatedEvent). > end(). > to("bean://getTechnicianOrderProcessor?method=process"). > choice(). > when(header("TechnicianOrder").isNotNull()). > log(LoggingLevel.DEBUG, "Work Order Event will be handled > by > this integration since technician order data exists for this work order"). > to("bean://getActorAssetProcessor?method=process"). > to("bean://getWorkOrderDetailsProcessor?method=process"). > > to("bean://createXellentCI_WorkOrderSoapRequestProcessor?method=process"). > > to("bean://sendXellentCI_WorkOrderSoapRequestProcessor?method=process"). > otherwise(). > log(LoggingLevel.DEBUG, "Work Order Event will NOT be > handled by this integration since NO technician order data exists for this > work order"). > end(). > log(LoggingLevel.DEBUG, "Successful routing"); > } > > Any suggestions on what the error is telling me? > > > > -- > View this message in context: > http://camel.465427.n5.nabble.com/Failed-to-create-route-tp5745435.html > Sent from the Camel - Users mailing list archive at Nabble.com. >