You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by dfullarton <li...@gmail.com> on 2016/01/15 00:00:29 UTC
RestConfiguration with multiple ports
I know that via netty4-http I'm able to create multiple HTTP listeners on
multiple ports.
from("netty4-http:http://localhost:8088").to(...)
from("netty4-http:http://localhost:8087").to(...)
but when using rest configuration it seems I'm limited to the one listener
restConfiguration().component("netty4-http")...
Is there a way (within one context) that I can bring up multiple http
listeners and route them through to routes create by rest(PATH)?
--
View this message in context: http://camel.465427.n5.nabble.com/RestConfiguration-with-multiple-ports-tp5776265.html
Sent from the Camel - Users mailing list archive at Nabble.com.
Re: RestConfiguration with multiple ports
Posted by jjathman <jj...@gmail.com>.
Is this something that is possible? I'm looking to do the same thing. We
would like to have internal traffic run on a separate port from the
externally visible port to make firewall rules easier. Is this something
that is possible?
I have defined two separate RouteBuilder classes each with their own
restConfiguration running on different ports, but at runtime they just end
up using the same port.
--
View this message in context: http://camel.465427.n5.nabble.com/RestConfiguration-with-multiple-ports-tp5776265p5800085.html
Sent from the Camel - Users mailing list archive at Nabble.com.
Re: RestConfiguration with multiple ports
Posted by dfullarton <li...@gmail.com>.
Testing
--
View this message in context: http://camel.465427.n5.nabble.com/RestConfiguration-with-multiple-ports-tp5776265p5776336.html
Sent from the Camel - Users mailing list archive at Nabble.com.
Re: RestConfiguration with multiple ports
Posted by Claus Ibsen <cl...@gmail.com>.
As part of testing or to mock them in a real life situation?
On Fri, Jan 15, 2016 at 12:42 PM, dfullarton <li...@gmail.com> wrote:
> Thanks Claus,
>
> I was looking to mock different services on different ports in the same
> context. Completely understand this is a bit of an edge case and it makes
> sense it's not baked in.
>
> If you have any suggests on where to look in order to achieve this I'd still
> like to give it a shot.
>
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/RestConfiguration-with-multiple-ports-tp5776265p5776296.html
> Sent from the Camel - Users mailing list archive at Nabble.com.
--
Claus Ibsen
-----------------
http://davsclaus.com @davsclaus
Camel in Action 2: https://www.manning.com/ibsen2
Re: RestConfiguration with multiple ports
Posted by dfullarton <li...@gmail.com>.
Thanks Claus,
I was looking to mock different services on different ports in the same
context. Completely understand this is a bit of an edge case and it makes
sense it's not baked in.
If you have any suggests on where to look in order to achieve this I'd still
like to give it a shot.
--
View this message in context: http://camel.465427.n5.nabble.com/RestConfiguration-with-multiple-ports-tp5776265p5776296.html
Sent from the Camel - Users mailing list archive at Nabble.com.
Re: RestConfiguration with multiple ports
Posted by Claus Ibsen <cl...@gmail.com>.
Hi
Do you want to have different rest services for different ports? Or do
some of the rest services share the ports?
Either way its not currently baked in too well in the rest-dsl to
allow to pick which rest configuration to user per service.
The design was to keep it simple, 1 rest component for all the services.
On Fri, Jan 15, 2016 at 12:00 AM, dfullarton <li...@gmail.com> wrote:
> I know that via netty4-http I'm able to create multiple HTTP listeners on
> multiple ports.
>
> from("netty4-http:http://localhost:8088").to(...)
> from("netty4-http:http://localhost:8087").to(...)
>
> but when using rest configuration it seems I'm limited to the one listener
>
> restConfiguration().component("netty4-http")...
>
> Is there a way (within one context) that I can bring up multiple http
> listeners and route them through to routes create by rest(PATH)?
>
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/RestConfiguration-with-multiple-ports-tp5776265.html
> Sent from the Camel - Users mailing list archive at Nabble.com.
--
Claus Ibsen
-----------------
http://davsclaus.com @davsclaus
Camel in Action 2: https://www.manning.com/ibsen2