GitHub user nssalian opened a pull request:

    https://github.com/apache/spark/pull/8054

    [SPARK-4449][Core]Specify port range in spark

    Specify port range in spark
    JIRA link: https://issues.apache.org/jira/browse/SPARK-4449
    
    Goal: To add a port range to services
    Design: (Based on the input and the suggestions in t #3314 and #5722):
    1) Added variables maxPort and failedPorts to help the implementation
    2) The maxPort was explicitly assigned to be startPort + maxRetries to 
avoid Retries being lesser or greater than the specified port range.
    3) Added the failedPorts ArrayBuffer to catch the failedPorts (during 
retry) which are in the range of the maxPort - startPort ( see Random logic)
    4) This failedPorts list will be checked and the tryPort will not attempt 
those ports again in the random..
    5) If the randomized port does not belong to the failedPorts list and a 
privileged port, it will be tried. 
    6) There’s a if block to check if there are sufficient ports left to 
attempt within the range (not sure if this is needed)
    
    Requesting review.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/nssalian/spark SPARK-4449

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/spark/pull/8054.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #8054
    
----
commit 2450fefe49f0cd8a109b556e5b4efe4c3bf7d9fa
Author: Neelesh Srinivas Salian <[email protected]>
Date:   2015-08-08T21:10:36Z

    cleanUp unused imports and random import

commit dcd512627c48911228ed0f3649d486fdaa0b1ce8
Author: Neelesh Srinivas Salian <[email protected]>
Date:   2015-08-08T22:51:18Z

    Initialized port

commit cf4af1a76ddbda7e9f83a64d1d2c323ba6eeb82a
Author: Neelesh Srinivas Salian <[email protected]>
Date:   2015-08-09T01:12:32Z

    Added logic for port range

commit 52326701bef8e22ab70a6c050f210c71de234fd7
Author: Neelesh Srinivas Salian <[email protected]>
Date:   2015-08-09T01:49:21Z

    Modified logic to include privileged ports

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to