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

copy labels and anotations to pod from pod template #542

Merged
merged 1 commit into from
Apr 18, 2018

Conversation

u2takey
Copy link
Contributor

@u2takey u2takey commented Apr 17, 2018

there is no reason to drop pod's labels and annotations from tfjob's PodTemplateSpec


This change is Reviewable

@googlebot
Copy link

We found a Contributor License Agreement for you (the sender of this pull request), but were unable to find agreements for all the commit author(s) or Co-authors. If you authored these, maybe you used a different email address in the git commits than was used to sign the CLA (login here to double check)? If these were authored by someone else, then they will need to sign a CLA as well, and confirm that they're okay with these being contributed to Google.
In order to pass this check, please resolve this problem and have the pull request author add another comment and the bot will run again. If the bot doesn't comment, it means it doesn't think anything has changed.

@coveralls
Copy link

coveralls commented Apr 17, 2018

Coverage Status

Coverage increased (+2.6%) to 50.706% when pulling 76be44a on u2takey:master into 846fd38 on kubeflow:master.

@gaocegege
Copy link
Member

Thanks for your contribution!

Please fix the error in Travis CI

@gaocegege
Copy link
Member

And, your commit belongs to a unrecognised author, could you please commit it with your own git account?

@u2takey u2takey force-pushed the master branch 2 times, most recently from ef41842 to cb7b91b Compare April 17, 2018 09:41
@gaocegege
Copy link
Member

/ok-to-test

@u2takey
Copy link
Contributor Author

u2takey commented Apr 17, 2018

CLA updated

@gaocegege
Copy link
Member

@u2takey I think the commit author should be yourself, or it can not pass the CLA check.

@googlebot
Copy link

CLAs look good, thanks!

@u2takey
Copy link
Contributor Author

u2takey commented Apr 17, 2018

thx @gaocegege, cla issue fixed

@gaocegege
Copy link
Member

Generally LGTM, would you mind adding some unit test cases? If you have no time I can do it for you.

Thanks for your contribution!

@u2takey
Copy link
Contributor Author

u2takey commented Apr 18, 2018

@gaocegege some test added

Copy link
Member

@ScorpioCPH ScorpioCPH left a comment

Choose a reason for hiding this comment

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

@u2takey Thanks, can you show more use cases why we should copy labels and annotations to pod from tfjob? I think pod and tfjob can have different values of the same label key, for example, tfjob have a label "key"="value1", but pod have a label "key"="value2".

@gaocegege
Copy link
Member

@ScorpioCPH As for annotations I think it works for me. As for the labels, I think the labels used in pod are hardly used in jobs. But if they have the same key, it is indeed a problem.

@u2takey WDYT

@u2takey
Copy link
Contributor Author

u2takey commented Apr 18, 2018

@ScorpioCPH sorry to wrong commit message. Not copy labels from tfjob, but from tfjob's PodTemplateSpec. In tfjob, what we defined is a PodTemplateSpec, so, as a user, i expect pod tfoperator created also follow this PodTemplateSpec. And this is behaviour in old version of tfoperator .

@gaocegege gaocegege changed the title copy labels and anotations to pod from tfjob copy labels and anotations to pod from pod template Apr 18, 2018
@gaocegege
Copy link
Member

@ScorpioCPH

Does it LGTY?

@ScorpioCPH
Copy link
Member

@u2takey FYI, we have done this in v1alpha2, code is here.

SGTM to add this in master branch :)

@gaocegege
Copy link
Member

/lgtm

@k8s-ci-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: gaocegege

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 ff2958a into kubeflow:master Apr 18, 2018
yph152 pushed a commit to yph152/tf-operator that referenced this pull request Jun 18, 2018
jetmuffin pushed a commit to jetmuffin/tf-operator that referenced this pull request Jul 9, 2018
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.

6 participants