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

cat-log: clean up processes on websocket disconnect #643

Open
oliver-sanders opened this issue Nov 7, 2024 · 0 comments
Open

cat-log: clean up processes on websocket disconnect #643

oliver-sanders opened this issue Nov 7, 2024 · 0 comments
Labels
bug Something isn't working
Milestone

Comments

@oliver-sanders
Copy link
Member

I suspect that cylc cat-log processes created to satisfy the LogData subscription, are not killed if the websocket is closed.

(investigation) Requires confirmation.

Ideally, we would detect the websocket close event, and kill the subprocess.

If this is not possible, a bandage might be to apply a (generous) timeout to the cylc cat-log process to ensure these processes are cleaned up eventually. This might actually be a good idea in general provided the default timeout is long enough not to cause user freustration.

@oliver-sanders oliver-sanders added the bug Something isn't working label Nov 7, 2024
@oliver-sanders oliver-sanders modified the milestones: 1.6.0, 1.5.x Nov 7, 2024
oliver-sanders added a commit to oliver-sanders/cylc-uiserver that referenced this issue Nov 11, 2024
* Partially addresses cylc#643
* Add a timeout to `cylc cat-log` processes:
  * Ensures we don't accumulate them by accident.
  * Improves efficiency by closing long-lived log streams
    (the user probably isn't looking at the log file any more and
    the log file has probably stopped growing anyway).
* At present, `cylc cat-log` processes may be left behind
  if the websocket is closed abruptly. This has been observed as
  the result of a proxy timeout.
oliver-sanders added a commit to oliver-sanders/cylc-uiserver that referenced this issue Nov 11, 2024
* Partially addresses cylc#643
* Add a timeout to `cylc cat-log` processes:
  * Ensures we don't accumulate them by accident.
  * Improves efficiency by closing long-lived log streams
    (the user probably isn't looking at the log file any more and
    the log file has probably stopped growing anyway).
* At present, `cylc cat-log` processes may be left behind
  if the websocket is closed abruptly. This has been observed as
  the result of a proxy timeout.
oliver-sanders added a commit to oliver-sanders/cylc-uiserver that referenced this issue Nov 12, 2024
* Partially addresses cylc#643
* Add a timeout to `cylc cat-log` processes:
  * Ensures we don't accumulate them by accident.
  * Improves efficiency by closing long-lived log streams
    (the user probably isn't looking at the log file any more and
    the log file has probably stopped growing anyway).
* At present, `cylc cat-log` processes may be left behind
  if the websocket is closed abruptly. This has been observed as
  the result of a proxy timeout.
oliver-sanders added a commit to oliver-sanders/cylc-uiserver that referenced this issue Nov 12, 2024
* Partially addresses cylc#643
* Add a timeout to `cylc cat-log` processes:
  * Ensures we don't accumulate them by accident.
  * Improves efficiency by closing long-lived log streams
    (the user probably isn't looking at the log file any more and
    the log file has probably stopped growing anyway).
* At present, `cylc cat-log` processes may be left behind
  if the websocket is closed abruptly. This has been observed as
  the result of a proxy timeout.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant