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

SPI - OpenShift Implementation - Show workspace Pod events in the IDE #6356

Closed
ghost opened this issue Sep 20, 2017 · 11 comments
Closed

SPI - OpenShift Implementation - Show workspace Pod events in the IDE #6356

ghost opened this issue Sep 20, 2017 · 11 comments
Assignees
Labels
kind/enhancement A feature request - must adhere to the feature request template.

Comments

@ghost
Copy link

ghost commented Sep 20, 2017

This is en enhancement request. I think it would be nice to show workspace pods events when a workspace is being started. Currently, when a workspace is starting no logs are streamed until pod is up and Che agents starts, it can take a while for pod image to be pulled, and pod to be created. For a user it may look like Che stopped responding.

@sleshchenko @akorneta @l0rd @ibuziuk what do you think?

@ghost ghost added kind/enhancement A feature request - must adhere to the feature request template. team/platform labels Sep 20, 2017
@ibuziuk
Copy link
Member

ibuziuk commented Sep 20, 2017

@eivantsov there is already a similar issue[1] for OpenShiftConector in rh-che , so huge +1 for having this in SPI

[1] redhat-developer/rh-che#148

@garagatyi
Copy link

Can you elaborate on which events OpenShift is firing except the pod creation events?

@ghost
Copy link
Author

ghost commented Sep 20, 2017

pulling image is one of them. I think it is most interesting for us:


4:02:03 PM | Normal | Created | Created container with docker id 27089818d453; Security:[seccomp=unconfined]
4:02:03 PM | Normal | Started | Started container with docker id 27089818d453
4:02:02 PM | Normal | Pulled | Successfully pulled image "rhche/centos_jdk8:latest"
4:02:01 PM | Normal | Pulling | pulling image "rhche/centos_jdk8:latest"
4:01:41 PM | Normal | Scheduled | Successfully assigned app to ip-172-31-53-149.ec2.internal


@garagatyi
Copy link

The feature looks interesting. This feature involves changes on both server and client side.

@sleshchenko
Copy link
Member

I think publishing text part of events to output channel would be enough. So it doesn't require changes on the client side.

@ghost
Copy link
Author

ghost commented Sep 21, 2017

Yeah, the idea is to show a user that smth's happening, rather than display a static message that workspace is being started.

@garagatyi
Copy link

I mean that AFAIK client doesn't subscribe to such events right now and doesn't display them.

@sleshchenko
Copy link
Member

As far as I know, the client subscribes on infrastructure output and display it. Docker infra and agents have already pushed own logs there.

@garagatyi
Copy link

It is not about logs it is about status events. We have RuntimeStatusEvent designed for such purposes. But it is used in a single place for now. We just need to add it on client side and on server side

@sleshchenko
Copy link
Member

sleshchenko commented Sep 21, 2017

I'd start with publishing messages of the pods' events to the output channel. Because pods images are pulling parallel, I don't think that runtime status should be changed when one of the images are pulling or pulled. I just have no idea to how to name this status.
I propose to implement publishing events message to output. And only then if it would not be enough then create an issue for investigating how RuntimeStatusEvents can help us, and how to implement it for such purpose.

@sleshchenko sleshchenko added the status/open-for-dev An issue has had its specification reviewed and confirmed. Waiting for an engineer to take it. label Oct 6, 2017
@sleshchenko sleshchenko self-assigned this Nov 2, 2017
@sleshchenko sleshchenko added status/in-progress This issue has been taken by an engineer and is under active development. and removed status/open-for-dev An issue has had its specification reviewed and confirmed. Waiting for an engineer to take it. labels Nov 2, 2017
@sleshchenko
Copy link
Member

Added publishing of events messages which are related to containers (where field path has the following format spec.container{CONTAINER_NAME}. Here is how it is displayed in IDE
screenshot_20171106_120528

But there is another Pod related event like no nodes available to schedule pods

full_event.json
{
  "metadata": {
    "name": "workspace4e9b8473ls0ge4et.db.14f475382eaf01be",
    "namespace": "workspace4e9b8473ls0ge4et",
    "selfLink": "/api/v1/namespaces/workspace4e9b8473ls0ge4et/events/workspace4e9b8473ls0ge4et.db.14f475382eaf01be",
    "uid": "32b1b279-c2d5-11e7-ad32-e6f47d235b4d",
    "resourceVersion": "127873",
    "creationTimestamp": "2017-11-06T09:30:59Z"
  },
  "involvedObject": {
    "kind": "Pod",
    "namespace": "workspace4e9b8473ls0ge4et",
    "name": "workspace4e9b8473ls0ge4et.db",
    "uid": "32b08de8-c2d5-11e7-ad32-e6f47d235b4d",
    "apiVersion": "v1",
    "resourceVersion": "127854"
  },
  "reason": "FailedScheduling",
  "message": "no nodes available to schedule pods",
  "source": {
    "component": "default-scheduler"
  },
  "firstTimestamp": "2017-11-06T09:30:59Z",
  "lastTimestamp": "2017-11-06T09:31:14Z",
  "count": 6,
  "type": "Warning"
}

So it is not related to the particular machine. It was decided not to publish it as machine log. And it there will be a necessity to listen or display such event, later will be able to publish it as a warning of the Runtime or infrastructure specific event.

@sleshchenko sleshchenko removed the status/in-progress This issue has been taken by an engineer and is under active development. label Nov 7, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/enhancement A feature request - must adhere to the feature request template.
Projects
None yet
Development

No branches or pull requests

3 participants