[
https://issues.apache.org/jira/browse/IGNITE-20845?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Vadim Pakhnushev reassigned IGNITE-20845:
-----------------------------------------
Assignee: Vadim Pakhnushev
> Compute jobs cancellation
> -------------------------
>
> Key: IGNITE-20845
> URL: https://issues.apache.org/jira/browse/IGNITE-20845
> Project: Ignite
> Issue Type: Improvement
> Components: compute
> Reporter: Mikhail Pochatkin
> Assignee: Vadim Pakhnushev
> Priority: Major
> Labels: ignite-3
>
> As stated above, we must provide a mechanism for canceling jobs. Users can
> cancel jobs that have one of statuses {*}SUBMITTED{*}, {*}QUEUED{*},
> {*}EXECUTING{*}.
> # A job with status *SUBMITTED* should not be added to the execution queue.
> # A job in the *QUEUED* status after calling cancel should never change to
> the *EXECUTING* status and should immediately be removed from the execution
> queue.
> # A job with status *EXECUTING* should be interrupted but this is not
> possible in all cases.
> h3. Cooperative cancellation
> It is proposed to introduce a mechanism for cooperative cancellation. This
> means adding properties to the parameters of the job execution method, with
> the help of which the user can periodically check the job cancellation status
> in the job code itself. Thus, this will allow users to write more flexible
> code. However, it is worth noting that we will not depart from Java standards
> in this place and everything will also interrupt the job execution flow. That
> is, in a sense, this parameter will duplicate the mechanism
> *Thread.currentThread().isInterrupted();* however, it will do this more
> explicitly. Thus, we will achieve the effects that any standard IO operation
> on a Compute job stream will be interrupted at the moment the job is canceled
> and the user will be able to receive an exception.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)