You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by James Strachan <ja...@gmail.com> on 2008/02/04 14:25:25 UTC

Re: more samples please!

On 31/01/2008, Roman Kalukiewicz <ro...@gmail.com> wrote:
> 2008/1/31, moller <jo...@moller.st>:
> > I'm looking for a sample that uses spring+camel+webcontainer (tomcat). The
> > idea is to consume the incoming http request and route it to a file. Does
> > anyone have a fully working sample that can be build and runs on tomcat
>
> What Camel gives you out-of-the-box is jetty component, that starts an
> embedded jetty server and exposes http endpoints. It work just in a
> way you want, but then it is not camel deployed to a web container --
> this is a web container launched from inside camel, while camel is
> stand alone application.
>
> then it should be enough to have a flow like
>
> from("jetty:http://localhost:1234/web").to("file:/someDirectory");
>
> I don't think we have a servlet that could be used as entry point to
> camel flows in tomcat (correct me if I'm wrong)

Agreed.

We could maybe do with a CamelServlet which is configured with the
Camel URI to dispatch to maybe; then the web.xml could configure the
CamelServlet to different URIs etc.

Or another approach could be to create some JAX-RS (JSR 311) resource
beans which when invoked delegate to a Camel endpoint URI?

Either way, a little demo WAR would be a good idea.

-- 
James
-------
http://macstrac.blogspot.com/

Open Source Integration
http://open.iona.com