[
https://issues.apache.org/jira/browse/SOLR-18145?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18132696#comment-18132696
]
Nick Shanin commented on SOLR-18145:
------------------------------------
I read the TaskManagement code at apache/solr main {{e59ce3c97d}}. The two v1
names are the public API, and the v2 API already uses one name for both
operations:
* {{queryUUID}} is the v1 cancel parameter
([TaskCancellationHandler.java:39|https://github.com/apache/solr/blob/e59ce3c97ddbe030eafadf0623fdcd80c4529c31/solr/core/src/java/org/apache/solr/handler/component/TaskCancellationHandler.java#L39],
[CommonParams.java:181|https://github.com/apache/solr/blob/e59ce3c97ddbe030eafadf0623fdcd80c4529c31/solr/solrj/src/java/org/apache/solr/common/params/CommonParams.java#L181]).
It is also how a caller sets its own query ID
([QueryComponent.java:1902|https://github.com/apache/solr/blob/e59ce3c97ddbe030eafadf0623fdcd80c4529c31/solr/core/src/java/org/apache/solr/handler/component/QueryComponent.java#L1902]).
* {{taskUUID}} is the v1 status parameter
([ActiveTasksListHandler.java:44|https://github.com/apache/solr/blob/e59ce3c97ddbe030eafadf0623fdcd80c4529c31/solr/core/src/java/org/apache/solr/handler/component/ActiveTasksListHandler.java#L44],
[CommonParams.java:184|https://github.com/apache/solr/blob/e59ce3c97ddbe030eafadf0623fdcd80c4529c31/solr/solrj/src/java/org/apache/solr/common/params/CommonParams.java#L184]).
* The v2 API takes the task ID as a path segment for both status and cancel
([TasksApi.java:44-61|https://github.com/apache/solr/blob/e59ce3c97ddbe030eafadf0623fdcd80c4529c31/solr/api/src/java/org/apache/solr/client/api/endpoint/TasksApi.java#L44-L61]).
* The ref guide documents the v1 names
([task-management.adoc:120|https://github.com/apache/solr/blob/e59ce3c97ddbe030eafadf0623fdcd80c4529c31/solr/solr-ref-guide/modules/deployment-guide/pages/task-management.adoc#L120]
and
[task-management.adoc:217|https://github.com/apache/solr/blob/e59ce3c97ddbe030eafadf0623fdcd80c4529c31/solr/solr-ref-guide/modules/deployment-guide/pages/task-management.adoc#L217]).
* Cross-shard forwarding sends both names
([ActiveTaskQuerySupport.java:104|https://github.com/apache/solr/blob/e59ce3c97ddbe030eafadf0623fdcd80c4529c31/solr/core/src/java/org/apache/solr/handler/component/ActiveTaskQuerySupport.java#L104]
and
[ActiveTaskQuerySupport.java:106|https://github.com/apache/solr/blob/e59ce3c97ddbe030eafadf0623fdcd80c4529c31/solr/core/src/java/org/apache/solr/handler/component/ActiveTaskQuerySupport.java#L106]),
so a rename changes that path too.
So the v2 side is already consistent. Renaming the v1 parameters would break
clients that use them.
Eric, is the v2 path naming ({{taskID}}) the target for this ticket, with the
v1 names left as documented? Or do you want a {{taskID}} alias added to the v1
handlers?
Possible states: close with no code change and a note in the guide; keep open
for a v1 alias; or keep open for a breaking v1 rename in a major release. The
recommendation is the first: the v2 API is already consistent, and an alias
adds surface without a clear user need.
🤖 _AI text above_ 🤖 _(reviewed by Nick Shanin)_
> Resolve the use of queryUUID and taskUUID in the TaskManagement API
> -------------------------------------------------------------------
>
> Key: SOLR-18145
> URL: https://issues.apache.org/jira/browse/SOLR-18145
> Project: Solr
> Issue Type: Sub-task
> Affects Versions: 10.1
> Reporter: Eric Pugh
> Priority: Minor
>
> The CancelTaskAPI uses queryUUID and the task list API uses taskUUID as param
> names. Need to clean this up.
> Â
> Â
--
This message was sent by Atlassian Jira
(v10.3.26#10030026)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]