[ML] make more GET and heavier processing APIs cancellable#88142
[ML] make more GET and heavier processing APIs cancellable#88142benwtrent merged 6 commits intoelastic:masterfrom
Conversation
|
Pinging @elastic/ml-core (Team:ML) |
36e1e06 to
f83534e
Compare
There was a problem hiding this comment.
I added this request object (just a copy of PutDataFrameAnalytics) as the PUT object was being reused here, but I didn't want to make that request's task cancellable (as PUT isn't cancellable).
There was a problem hiding this comment.
Also, I added a BWC test for explain in a mixed cluster to ensure this doesn't break anything. Ran it many many times and its all good since the explain request and the put request can be serialized to each other without issue.
There was a problem hiding this comment.
I am not sure if task.getParentTaskId() was strictly correct. task is indeed the transport action task (created via our request object) that is being executed here. It SHOULD have a parent task that is the original HTTP request (I think?) but it seems that the prevailing pattern is to rely on this task object instead of its parent.
There was a problem hiding this comment.
This was a nice idea, but since the task being created by the request was never cancellable (and neither was the http request), the cascade effect of cancellations was missed :/
f83534e to
bd28f76
Compare
|
@elasticmachine update branch |
|
@elasticmachine update branch |
...gin/ml/src/main/java/org/elasticsearch/xpack/ml/action/TransportGetModelSnapshotsAction.java
Outdated
Show resolved
Hide resolved
...gin/ml/src/main/java/org/elasticsearch/xpack/ml/action/TransportGetModelSnapshotsAction.java
Outdated
Show resolved
Hide resolved
x-pack/plugin/ml/src/main/java/org/elasticsearch/xpack/ml/job/JobManager.java
Outdated
Show resolved
Hide resolved
Co-authored-by: David Roberts <dave.roberts@elastic.co>
|
@elasticmachine update branch |
This commit makes the following APIs cancellable: