If you want Slider to allocate a port for you, use a
${COMPONENT_NAME.ALLOCATED_PORT} variable in the appConfig, like this:
https://github.com/apache/incubator-slider/blob/develop/app-packages/hbase/appConfig-default.json#L39

This is typically used for singleton / master ports that need to be known
by the client, whereas ports that are only used internally by the app can
be set to 0 so the app selects a random port (if the app supports that). To
publish the ALLOCATED_PORT, you would specify an export in the metainfo,
like this:
https://github.com/apache/incubator-slider/blob/develop/app-packages/hbase/metainfo.xml#L42

If there are multiple instances of a component and each one needs its own
port, you add {PER_CONTAINER}:
https://github.com/apache/incubator-slider/blob/develop/app-packages/accumulo/appConfig-default.json#L31
and then have a component export:
https://github.com/apache/incubator-slider/blob/develop/app-packages/accumulo/metainfo.xml#L147

On Mon, Apr 3, 2017 at 11:16 AM, David.Serafini <david.seraf...@target.com>
wrote:

> On the wiki in :
>
> https://slider.incubator.apache.org/docs/configuration/resources.html
>
> It says:
>
>     If the component were configured to request an explicit port for its
> REST endpoint
>
> How do you do this?  The docs and examples show various variables related
> to port number.  Which one(s) must I set explicitly?
>
> Also, does Slider check that the port is not in use on the compute node
> before launching the app?
>
> thanks,
> -david
>
>
>
>
>

Reply via email to