GitHub user vanzin opened a pull request:

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

    [SPARK-11131] [core] Fix race in worker registration protocol.

    Because the registration RPC was not really an RPC, but a bunch of
    disconnected messages, it was possible for other messages to be
    sent before the reply to the registration arrived, and that would
    confuse the Worker. Especially in local-cluster mode, the worker was
    succeptible to receiving an executor request before it received a
    message from the master saying registration succeeded.
    
    On top of the above, the change also fixes a ClassCastException when
    the registration fails, which also affects the executor registration
    protocol. Because the `ask` was issued with a specific return type,
    if the error message (of a different type) was returned instead, the
    code will just die with an exception. This is fixed by having a common
    base trait for these reply messages.

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

    $ git pull https://github.com/vanzin/spark SPARK-11131

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

    https://github.com/apache/spark/pull/9138.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 #9138
    
----
commit cb3f972b3e95d70edf16f2b6f04d8b3c48365590
Author: Marcelo Vanzin <[email protected]>
Date:   2015-10-15T00:43:07Z

    [SPARK-11131] [core] Fix race in worker registration protocol.
    
    Because the registration RPC was not really an RPC, but a bunch of
    disconnected messages, it was possible for other messages to be
    sent before the reply to the registration arrived, and that would
    confuse the Worker. Especially in local-cluster mode, the worker was
    succeptible to receiving an executor request before it received a
    message from the master saying registration succeeded.
    
    On top of the above, the change also fixes a ClassCastException when
    the registration fails, which also affects the executor registration
    protocol. Because the `ask` was issued with a specific return type,
    if the error message (of a different type) was returned instead, the
    code will just die with an exception. This is fixed by having a common
    base trait for these reply messages.

----


---
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