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 a human readable message to pod state. #2185

Merged
merged 1 commit into from
Nov 13, 2014

Conversation

brendandburns
Copy link
Contributor

@bgrant0607 @dchen1107

Partially addressing #1370

Once this seems reasonable to all, I will cut/paste into all of the API versions...

@lavalamp
Copy link
Member

lavalamp commented Nov 5, 2014

Please just wait for events, and don't add this field here?

@brendandburns
Copy link
Contributor Author

Hrm, I think this is different. I think this is so that the (for example) the replication controller can say why when it deletes a pod.

--brendan

@bgrant0607
Copy link
Member

@dchen1107 and @vishh are already working on things related to this, and @lavalamp is working on events. I'll assign #1370 to @dchen1107.

@bgrant0607
Copy link
Member

See also my last comment in #139. Termination info will go into ContainerStateTerminated.

@lavalamp
Copy link
Member

lavalamp commented Nov 5, 2014

Hrm, I think this is different. I think this is so that the (for example) the replication controller can say why when it deletes a pod.

No, that should be an event, too.

@brendandburns
Copy link
Contributor Author

It can be an event, but it also needs to be things that the client can pass in. Since the client may know why independent of the k8s API (e.g. upstream roll out, whatever)

So yes, there is a replication controller event, but there should also be a reason associated with the pod.

--brendan

@brendandburns
Copy link
Contributor Author

also @bgrant0607 this is pod level, not container level. ContainerStateTerminated seems to be container level information.

--brendan

@brendandburns
Copy link
Contributor Author

(and I chatted w/ Dawn about this, and we collaboratively identified this as a thing that she wasn't doing right now...)

@lavalamp
Copy link
Member

lavalamp commented Nov 5, 2014

If client wants to set some sort of information, client should make an event, not write to this field.

I think we do want to let people write a status message. I think that should be an event. We may want to cache the most recent one and expose it in PodState, but I'd rather we get the events hooked up and do the caching separately.

@dchen1107
Copy link
Member

I updated #1370 with latest information. I believe @brendandburns is trying to convey deleted pod status and reasons, which is a separate issue and should fork from #1370.

@brendandburns: @lavalamp's point is that we should use event to explain why a pod is terminated & deleted.

@brendandburns
Copy link
Contributor Author

Hrm, I think that is putting too much burden on the end user to make 2 api
calls instead of one.

--brendan

On Wed, Nov 5, 2014 at 3:56 PM, Daniel Smith notifications@github.com
wrote:

If client wants to set some sort of information, client should make an
event, not write to this field.

I think we do want to let people write a status message. I think that
should be an event. We may want to cache the most recent one and expose it
in PodState, but I'd rather we get the events hooked up and do the caching
separately.


Reply to this email directly or view it on GitHub
#2185 (comment)
.

@brendandburns
Copy link
Contributor Author

yes, Dawn is right. This is deleted pod status and reason.

--brendan

On Wed, Nov 5, 2014 at 3:59 PM, Brendan Burns bburns@google.com wrote:

Hrm, I think that is putting too much burden on the end user to make 2 api
calls instead of one.

--brendan

On Wed, Nov 5, 2014 at 3:56 PM, Daniel Smith notifications@github.com
wrote:

If client wants to set some sort of information, client should make an
event, not write to this field.

I think we do want to let people write a status message. I think that
should be an event. We may want to cache the most recent one and expose it
in PodState, but I'd rather we get the events hooked up and do the caching
separately.


Reply to this email directly or view it on GitHub
#2185 (comment)
.

@dchen1107
Copy link
Member

Yes, this is pod level reason, status, and events, not container level. For container level, I already update #1370 with the latest status.

@lavalamp
Copy link
Member

lavalamp commented Nov 6, 2014

Hrm, I think that is putting too much burden on the end user to make 2 api calls instead of one.

How is it two api calls? it's pretty easy to make an event.

@bgrant0607
Copy link
Member

Ok, thanks for the explanation. I'm fine with this. It needs to be added to the actual APIs. In v1beta3, it belongs in type PodStatus.

Yes, we also need events and we also need the container-level details.

@brendandburns
Copy link
Contributor Author

Ok, updated for all apis since this seems acceptable to folks. ptal.

Thanks!
--brendan

@bgrant0607
Copy link
Member

verify-gofmt barfed. Please run gofmt.

@brendandburns
Copy link
Contributor Author

This is now fixed. I can have mergez?

bgrant0607 added a commit that referenced this pull request Nov 13, 2014
Add a human readable message to pod state.
@bgrant0607 bgrant0607 merged commit 7cab32b into kubernetes:master Nov 13, 2014
@brendandburns brendandburns deleted the history branch August 7, 2015 04:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants