Skip to content

Process management for running odo cli instances #1425

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

Open
dgolovin opened this issue Mar 3, 2020 · 1 comment
Open

Process management for running odo cli instances #1425

dgolovin opened this issue Mar 3, 2020 · 1 comment

Comments

@dgolovin
Copy link
Collaborator

dgolovin commented Mar 3, 2020

From @jeffmaury.

While working on the odo based explorer to JBoss Tools, I noticed that we are starting long running process and those processes are not managed / controlled once launched.
I think we should do and I will explain my proposition.
The long processes are the following:

  • watch
  • follow log
  • debug

Less critical , we also have describe, list services and component and in general each time we launch odo in a terminal. This is less critical because they are less long living.
The problem that we have is:

  • we should stop them when context is switched
  • we should stop them when tooling stops (seems VSCode is handling that properly)
  • we should stop them when we undeploy/delete a component

Another plus is that managing them will prevent multiple executions of the same task and control of state for the debug.

Here is my proposition: each time we start a long running process we keep it at the OdoCli (for JBoss Tools / IJ) level in a map that is keyed by project / application / component / action-type.
Then, we can:

  • while processing delete / undeploy, scan the map to find proper processes to stop
  • while processing debug we can check that debug is already running or not
  • for cleanup before tooling exit or context switch we should add a reset method (this is required btw for proxy support as we need to recompute the HTTPS_PROXY env variable that will be passed to future odo executions
@girishramnani
Copy link
Contributor

girishramnani commented Mar 16, 2020

to check if there is a debug session already active, odo now has odo debug info command which gives information on an already running session. We have the json output PR in review redhat-developer/odo#2653

@dgolovin dgolovin modified the milestones: devex #181, devex #182 Apr 1, 2020
@dgolovin dgolovin modified the milestones: devex #182, devex #183 Apr 22, 2020
@dgolovin dgolovin modified the milestones: devex #183, devex #184 May 13, 2020
@dgolovin dgolovin modified the milestones: devex #184, devex #185 Jun 3, 2020
@dgolovin dgolovin modified the milestones: devex #185, Sprint #186 Jun 23, 2020
dgolovin added a commit to dgolovin/vscode-openshift-tools that referenced this issue Jul 6, 2020
Watch commands can be executed for different components at the same time
and that is done in terminal veiw. Over time terminal is getting
polluted with different commands and it is getting not easy to nawigate
and search for watch sessions to see the log or stop them.

This fix shows all components under watch in a view so devs can:
1. See the logs
2. Stop active watch commands

Related to redhat-developer#1425.

Signed-off-by: Denis Golovin <[email protected]>
@dgolovin dgolovin modified the milestones: Sprint #186, devex #187 Jul 15, 2020
@mohitsuman mohitsuman removed this from the devex #187 milestone Jul 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants