You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by Charles Moulliard <cm...@gmail.com> on 2010/06/07 16:36:52 UTC

Strange error reported by camle

Hi,

I use @EndpointInject in my camel 2.3 route and during initialisation,
spring generates the following error :

karaf@root> Exception in thread "SpringOsgiExtenderThread-20"
org.springframework.beans.factory.BeanCreationException: Error
creating bean with n
ame 'camelContext': Invocation of init method failed; nested exception
is org.springframework.beans.factory.BeanCreationException: Error
creating
 bean with name
'com.fusesource.camel.exercises.jms.transaction.TransactionalJMSMessageProcessor':
Invocation of init method failed; nested excep
tion is org.springframework.beans.factory.BeanInitializationException:
You must set a value for incomingQueue

public class TransactionalJMSMessageProcessor extends RouteBuilder {
	
	private static final Logger logger =
LoggerFactory.getLogger(TransactionalJMSMessageProcessor.class);
	
	@EndpointInject(uri="activemq:queue:incomingPayments")
	private Endpoint sourceUri;
	
	@EndpointInject(uri="activemq:queue:outgoingPayments")
	private Endpoint targetUri;
	
	private JaxbDataFormat jaxb;
	private JdbcTemplate jdbcTemplate;
	private DataSource dataSource;
	
	public void configure() throws Exception {
		jaxb = new JaxbDataFormat();
		jaxb.setContextPath(Payments.class.getPackage().getName());
		jaxb.setPrettyPrint(true);
		
		// From the incoming queue.
		from(sourceUri)	
                ...

KR,

Charles Moulliard

Senior Enterprise Architect (J2EE, .NET, SOA)
Apache Camel/ServiceMix Committer

*******************************************************************
- Blog : http://cmoulliard.blogspot.com
- Twitter : http://twitter.com/cmoulliard
- Linkedlin : http://www.linkedin.com/in/charlesmoulliard