You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@slider.apache.org by Roshan Punnoose <ro...@gmail.com> on 2016/03/01 15:07:17 UTC

Global Allocated Ports Pool

Hi,

On my current application, we are looking to deploy jetty apps in Slider,
to allow the ability to provision them in Yarn and also to flex them as
needed. What I would like to do is have a separate slider application per
Jetty Base/WAR that I am deploying, and have Slider negotiate the ports
based on a global port pool. Is this possible? Basically, I just want to
make sure that multiple slider applications can use the same port pool
without stepping on each other.

Roshan

Re: Global Allocated Ports Pool

Posted by Jon Maron <jm...@hortonworks.com>.
On Mar 1, 2016, at 9:25 AM, Roshan Punnoose <ro...@gmail.com>> wrote:

Would I be able to specify a different WAR for each instance of the slider
package, and change the application name?

that would generally require either a different package or utilizing one of the command line launch options:  http://slider.apache.org/docs/slider_specs/simple_pkg.html

The name is specified during creation, so it could be changed.


Ok the port pool is interesting. So if I specify a port range here, can I
use the same port pool in a jetty configuration such as
${JETTY_PORT_POOL}{PER_CONTAINER} so that the different instances of the
slider application would pull from the same pool?

The port “pool” specifies a range of ports to select per host.  When the agent starts in a given container on a node, the agent will attempt to allocate a port in the specified range.  The setting would more than likely have the form of:

    "site.server.port": “${JETTY_SERVER.ALLOCATED_PORT}{PER_CONTAINER}"

where JETTY_SERVER is the defined component name for the server.


On Tue, Mar 1, 2016 at 9:18 AM Jon Maron <jm...@hortonworks.com>> wrote:


On Mar 1, 2016, at 9:07 AM, Roshan Punnoose <ro...@gmail.com>> wrote:

Hi,

On my current application, we are looking to deploy jetty apps in Slider,
to allow the ability to provision them in Yarn and also to flex them as
needed. What I would like to do is have a separate slider application per
Jetty Base/WAR that I am deploying, and have Slider negotiate the ports
based on a global port pool. Is this possible?

For the first requirement, would it be sufficient to define a jetty app
package and simply deploy multiple instances?  You’d be leveraging the same
jetty instance, but starting separate instances in the cluster (the app
name would be changed, and you could do some modification of the app
configuration and resources)

For the second - the port pool is a set of ports allocated across the
cluster, or a defined set of ports allowed on a per host basis?  for the
latter there is an existing configuration:
http://slider.apache.org/docs/configuration/core.html#controlling-assigned-port-ranges

Basically, I just want to
make sure that multiple slider applications can use the same port pool
without stepping on each other.

Roshan




Re: Global Allocated Ports Pool

Posted by Roshan Punnoose <ro...@gmail.com>.
Would I be able to specify a different WAR for each instance of the slider
package, and change the application name?

Ok the port pool is interesting. So if I specify a port range here, can I
use the same port pool in a jetty configuration such as
${JETTY_PORT_POOL}{PER_CONTAINER} so that the different instances of the
slider application would pull from the same pool?

On Tue, Mar 1, 2016 at 9:18 AM Jon Maron <jm...@hortonworks.com> wrote:

>
> > On Mar 1, 2016, at 9:07 AM, Roshan Punnoose <ro...@gmail.com> wrote:
> >
> > Hi,
> >
> > On my current application, we are looking to deploy jetty apps in Slider,
> > to allow the ability to provision them in Yarn and also to flex them as
> > needed. What I would like to do is have a separate slider application per
> > Jetty Base/WAR that I am deploying, and have Slider negotiate the ports
> > based on a global port pool. Is this possible?
>
> For the first requirement, would it be sufficient to define a jetty app
> package and simply deploy multiple instances?  You’d be leveraging the same
> jetty instance, but starting separate instances in the cluster (the app
> name would be changed, and you could do some modification of the app
> configuration and resources)
>
> For the second - the port pool is a set of ports allocated across the
> cluster, or a defined set of ports allowed on a per host basis?  for the
> latter there is an existing configuration:
> http://slider.apache.org/docs/configuration/core.html#controlling-assigned-port-ranges
>
> > Basically, I just want to
> > make sure that multiple slider applications can use the same port pool
> > without stepping on each other.
> >
> > Roshan
>
>

Re: Global Allocated Ports Pool

Posted by Jon Maron <jm...@hortonworks.com>.
> On Mar 1, 2016, at 9:07 AM, Roshan Punnoose <ro...@gmail.com> wrote:
> 
> Hi,
> 
> On my current application, we are looking to deploy jetty apps in Slider,
> to allow the ability to provision them in Yarn and also to flex them as
> needed. What I would like to do is have a separate slider application per
> Jetty Base/WAR that I am deploying, and have Slider negotiate the ports
> based on a global port pool. Is this possible?

For the first requirement, would it be sufficient to define a jetty app package and simply deploy multiple instances?  You’d be leveraging the same jetty instance, but starting separate instances in the cluster (the app name would be changed, and you could do some modification of the app configuration and resources)

For the second - the port pool is a set of ports allocated across the cluster, or a defined set of ports allowed on a per host basis?  for the latter there is an existing configuration:  http://slider.apache.org/docs/configuration/core.html#controlling-assigned-port-ranges

> Basically, I just want to
> make sure that multiple slider applications can use the same port pool
> without stepping on each other.
> 
> Roshan