Return-Path: Delivered-To: apmail-camel-dev-archive@www.apache.org Received: (qmail 10186 invoked from network); 11 Feb 2011 09:59:21 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 11 Feb 2011 09:59:21 -0000 Received: (qmail 8152 invoked by uid 500); 11 Feb 2011 09:59:21 -0000 Delivered-To: apmail-camel-dev-archive@camel.apache.org Received: (qmail 7934 invoked by uid 500); 11 Feb 2011 09:59:18 -0000 Mailing-List: contact dev-help@camel.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@camel.apache.org Delivered-To: mailing list dev@camel.apache.org Received: (qmail 7920 invoked by uid 99); 11 Feb 2011 09:59:18 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 11 Feb 2011 09:59:18 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED,T_RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 11 Feb 2011 09:59:17 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id 6021919FB4A for ; Fri, 11 Feb 2011 09:58:57 +0000 (UTC) Date: Fri, 11 Feb 2011 09:58:57 +0000 (UTC) From: "james strachan (JIRA)" To: dev@camel.apache.org Message-ID: <1696621643.10206.1297418337374.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] Commented: (CAMEL-3563) CamelContext should act like a Component (i.e. a TypeConverter of CamelContext -> CamelContextComponent) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/CAMEL-3563?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12993425#comment-12993425 ] james strachan commented on CAMEL-3563: --------------------------------------- See the documentation: https://cwiki.apache.org/confluence/display/CAMEL/Context > CamelContext should act like a Component (i.e. a TypeConverter of CamelContext -> CamelContextComponent) > -------------------------------------------------------------------------------------------------------- > > Key: CAMEL-3563 > URL: https://issues.apache.org/jira/browse/CAMEL-3563 > Project: Camel > Issue Type: Improvement > Components: camel-core > Reporter: james strachan > Assignee: james strachan > Fix For: 2.7.0 > > > Imagine you have a camelContext.xml for production use (e.g. you're creating an OSGi bundle with a camelContext.xml) but you want to create an integration test case that tests out your route. > So you want to create a new Camel XML file, testCamel.xml which includes the camelContext.xml and interacts with it. You now have 2 camelContexts. The test route needs to be able to refer to any endpoints inside the other camelContext.xml. > CamelContext has an ID (by default camelContext IIRC). > so if we have > camelContext.xml > {code} > > > > ... > {code} > testCamelContext.xml > {code} > > > > > > > > > > {code} > i.e. in the test case we are routing from our local CamelContext into the production camel context's "direct:start" endpoint and consuming from its "seda:bar" endpoint. > i.e. we use "prod" as a name, look it up in the IoC context (just like any other Component), but if its a CamelContext we (via TypeConverters) turn it into a Component that resolves the rest of the name -- This message is automatically generated by JIRA. - For more information on JIRA, see: http://www.atlassian.com/software/jira