camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Claus Ibsen <claus.ib...@gmail.com>
Subject Re: Classpath resource endpoint?
Date Fri, 03 Sep 2010 04:39:17 GMT
If you projects are running in the same JVM then you can use intra-vm
communications such as: direct, seda components.

If you run your projects in separate JVMs then you need "remoting" to
share data between them. For example files, a shared database,
messaging, http, rmi etc.

And you can use placeholders in the uri so you can easily switch
endpoints, but keeping the route as is.
http://camel.apache.org/properties
http://camel.apache.org/how-do-i-use-spring-property-placeholder-with-camel-xml.html



On Thu, Sep 2, 2010 at 4:17 PM, Meise, Christoph
<christoph.meise@immobilienscout24.de> wrote:
> Hi all,
>
> We have several projects (B, C and D) which rely on testdata coming from project A. Up
to now for example project B resolved project A and put the provided testdata into some defined
spot (inputFileOrDirectoryName) which was on the eclipse classpath. Than in a testcase a route
could be built like this one:
>
>    new RouteBuilder() {
>      @Override
>      public void configure() throws Exception {
>        from("file:" + inputFileOrDirectoryName + "?noop=true").to("log:before.transformation.log").to(
>          "xslt:" + transformationFile).to("mock:checkpoint").to("log:after.transformation.log");
>      }
>    };
>
> Basically it loaded an xml-file, transformed it and did some logging. Now the question
arises whether there exists component that can load a resource from the classpath (using either
a provided A.jar or the eclipse project A):
>       ... from("classpath:" + inputFile).to("log:before.transformation.log").to( ...
> I would be glad to receive any help on this issue even stating something like: "No, there
is not". If there was nothing, would there be a wish provide it?
>
> Kind Regards,
> Christoph Meise
> IT Systems&Services, Team SAT
>
> Immobilien Scout GmbH
> Andreasstraße 10
> 10243 Berlin
> Fon +49 (0)30 24301-1378
> Fax +49 (0)30 24301-1110
> christoph.meise@immobilienscout24.de
>
> ---------------------------------------------------------------
> Immobilien Scout GmbH
> Beirat: Dr. Martin Enderle (Vorsitzender)
> Geschäftsführer: Dirk Hoffmann, Marc Stilke (Sprecher)
> Handelsgericht: Amtsgericht Charlottenburg, HRB 69108
> Sitz der Gesellschaft: Berlin
> ---------------------------------------------------------------
>
> http://www.immobilienscout24.de
> Der Marktführer: Deutschlands größter Immobilienmarkt
>



-- 
Claus Ibsen
Apache Camel Committer

Author of Camel in Action: http://www.manning.com/ibsen/
Open Source Integration: http://fusesource.com
Blog: http://davsclaus.blogspot.com/
Twitter: http://twitter.com/davsclaus

Mime
View raw message