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

functionality to abort running executions #69

Open
bolandka opened this issue Nov 23, 2015 · 1 comment
Open

functionality to abort running executions #69

bolandka opened this issue Nov 23, 2015 · 1 comment

Comments

@bolandka
Copy link
Member

Very useful e.g. when a sleep-deprived Kata starts a bootstrapping algorithm with threshold 0.0... Or a non-sleep-deprived evil non-Kata does similar things.

Desirable:

  1. being able to "delete" a running execution via swagger
  2. having automatized mechanisms to kill processes that exceed some specified processing time / memory usage / whatever

Opens up some other questions:

  • how to make sure a person may only disrupt his own executions? Do we want to require users to login before using? Or some other mechanism? ...
@bolandka bolandka added this to the asap after SWIB milestone Nov 23, 2015
@kba
Copy link
Contributor

kba commented Nov 30, 2015

Some comments by the not-sleep-deprived-anymore @kba:

  • Strongly against auth. I can see that we might need it, but then we should stop and discuss this thoroughly and implement something that is sustainable. Auth schemes that work within a User interface and the REST API (and the backend?), the modelling of users and permissions etc. take time to plan and implement.
  • From the infolis-web perspective, the functionality would be very thin: Handle some HTTP requests by the user on an execution and

In any case, some effort hast to be invested in the threadPool managing the executions on the backend to handle state updates, e.g. pausing/restoring/aborting threads.

Not hard, but tedious to test and catch all edge cases and make it work in a Servlet container.

I'd propose that we go about this in three steps:

  1. Implement and test execution state changes on the backend
  2. Implement a service endpoint on the backend (e.g. PATCH on /infoLink-1.0/infolis-web/execute) to expose this functionality
  3. Create an external-facing webservice to update the state of an execution or reuse the RESTful semantics
  4. Create either a client library (might be a good use case for the JS client) or a cronjob or similar that polls /api/monitor, retrieves status information via /api/execution/:id (such as When was the last time the log got updated? or the memory footprint which the backend would need to post).

Anyway, I think 2) and 3) are easy to implement (needs minor discussions on the protocol), 1) needs a lot of testing and 4) can be as simple or as complicated as necessary.

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

2 participants