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

Inconsistent behavior on logs page for different k8s master versions #423

Closed
floreks opened this issue Feb 25, 2016 · 5 comments
Closed
Assignees
Labels
kind/bug Categorizes issue or PR as related to a bug.

Comments

@floreks
Copy link
Member

floreks commented Feb 25, 2016

Issue details

I'm using local-up-cluster with newest kubernetes HEAD. After deploying some card with wrong containerImage pod stays in pending state with errors. Logs page show Internal error(500). On older cluster we can see normal log entry saying that pod is not started and is in state pending.

Environment
Dashboard version: HEAD
Kubernetes version: v.1.2.0-alpha-8 (Newest HEAD)
Steps to reproduce
  1. Deploy app with not existing containerImage.
  2. Wait for card to show error status.
  3. Go to logs page.
  4. Check same page on older kubernetes version.
Observed result

Inconsistent behavior for logs page between different kubernetes versions.

Comments

It's hard to say what is the expected behavior here. Pod is actually in pending state so the older version is correct to show this entry but there are some errors related to this pod and newer version actually displays internal error with event error message. For me newest behavior seems more convenient.

Here are some screens.

Newest k8s:
zrzut ekranu z 2016-02-25 09-57-39

Older k8s:
zrzut ekranu z 2016-02-25 10-01-48

What do you think? @bryk @maciaszczykm @cheld

@bryk
Copy link
Contributor

bryk commented Feb 25, 2016

To me there should be no 500 error. Backend should handle this case and either say that there are no logs or display message that is currently displayed.

@floreks floreks added kind/bug Categorizes issue or PR as related to a bug. priority/P2 labels Mar 8, 2016
@floreks
Copy link
Member Author

floreks commented Mar 10, 2016

I'll take a look at that.

@floreks
Copy link
Member Author

floreks commented Mar 10, 2016

Changing this https://github.com/kubernetes/dashboard/blob/master/src/app/backend/logs.go#L84
to return err.Error(), nil solves this issue and logs page is shown normally:

zrzut ekranu z 2016-03-10 14-46-13

Messages of course will differ between version so we shouldn't check for that. I'll have to adjust test also. Is this solution ok? I was also thinking about other solution but that would require complete redesign of logs backend :)

@floreks
Copy link
Member Author

floreks commented Mar 17, 2016

@bryk what do you think?

@bryk
Copy link
Contributor

bryk commented Mar 18, 2016

Sounds good to me. Ship it :)

@bryk bryk closed this as completed in #552 Mar 21, 2016
anvithks pushed a commit to anvithks/k8s-dashboard that referenced this issue Sep 27, 2021
Added customization key:value to view in profile card
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Categorizes issue or PR as related to a bug.
Projects
None yet
Development

No branches or pull requests

2 participants