Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add leader election #110

Merged
merged 2 commits into from
May 30, 2019
Merged

Add leader election #110

merged 2 commits into from
May 30, 2019

Conversation

fisherxu
Copy link
Member

@fisherxu fisherxu commented May 29, 2019

This change is Reviewable

@k8s-ci-robot
Copy link

Hi @fisherxu. Thanks for your PR.

I'm waiting for a kubeflow member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

return fmt.Errorf("failed to get hostname: %v", err)
}
// add a uniquifier so that two processes on the same host don't accidentally both become active
id = id + "_" + string(uuid.NewUUID())
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if don't add uuid to id, when the host has same hostname, the process will all become active.

@fisherxu
Copy link
Member Author

/assign @rongou @terrytangyuan

Just add K8s leader election code, and have tested, ptal.

Copy link
Member

@gaocegege gaocegege left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

Should do the similar change to tf and pytorch?

Thanks for your contribution! 🎉 👍

@gaocegege
Copy link
Member

/ok-to-test

@fisherxu
Copy link
Member Author

Should do the similar change to tf and pytorch?

add uuid to id? @gaocegege

@gaocegege
Copy link
Member

@fisherxu Yeah. I think if mpi operator has the problem, then tf-operator and pytorch-operator will have the same problem, too.

Copy link
Member

@terrytangyuan terrytangyuan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/approve

Thanks!

@k8s-ci-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: terrytangyuan

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot merged commit b619d48 into kubeflow:master May 30, 2019
@fisherxu fisherxu deleted the add_leader branch May 30, 2019 03:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants