This is an automated email from the ASF dual-hosted git repository.
epugh pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/solr.git
The following commit(s) were added to refs/heads/main by this push:
new 142b22b SOLR-15278: allow the flush parameter to be passed when doing
a DELETE (second take) (#362)
142b22b is described below
commit 142b22be05ebd5c2e7267cc34e0277eb78b3b9a4
Author: Eric Pugh <[email protected]>
AuthorDate: Sat Oct 23 07:41:33 2021 -0400
SOLR-15278: allow the flush parameter to be passed when doing a DELETE
(second take) (#362)
* Add a V2 equivalent to the V1 api for deleting async operation list of
statuses.
---
solr/CHANGES.txt | 2 ++
solr/core/src/java/org/apache/solr/handler/ClusterAPI.java | 7 +++++++
solr/solr-ref-guide/src/collections-api.adoc | 3 +--
3 files changed, 10 insertions(+), 2 deletions(-)
diff --git a/solr/CHANGES.txt b/solr/CHANGES.txt
index 9279c94..340c88d 100644
--- a/solr/CHANGES.txt
+++ b/solr/CHANGES.txt
@@ -160,6 +160,8 @@ when told to. The admin UI now tells it to. (Nazerke
Seidan, David Smiley)
* SOLR-15617: Add kerberos.name.rules.mechanism support to KerberosPlugin
(Kevin Risden)
+* SOLR-15278: Add V2 equivalent to allow deleting async collection list of
statuses. (Eric Pugh)
+
Build
---------------------
diff --git a/solr/core/src/java/org/apache/solr/handler/ClusterAPI.java
b/solr/core/src/java/org/apache/solr/handler/ClusterAPI.java
index aa50f69..be5c7de 100644
--- a/solr/core/src/java/org/apache/solr/handler/ClusterAPI.java
+++ b/solr/core/src/java/org/apache/solr/handler/ClusterAPI.java
@@ -104,6 +104,13 @@ public class ClusterAPI {
v1Params.put(REQUESTID, req.getPathTemplateValues().get("id"));
collectionsHandler.handleRequestBody(wrapParams(req, v1Params), rsp);
}
+
+ @EndPoint(method = DELETE,
+ path = "/cluster/command-status",
+ permission = COLL_EDIT_PERM)
+ public void flushCommandStatus(SolrQueryRequest req, SolrQueryResponse rsp)
throws Exception {
+ CollectionsHandler.CollectionOperation.DELETESTATUS_OP.execute(req, rsp,
collectionsHandler);
+ }
@EndPoint(method = DELETE,
path = "/cluster/configs/{name}",
diff --git a/solr/solr-ref-guide/src/collections-api.adoc
b/solr/solr-ref-guide/src/collections-api.adoc
index a57a8c2..93a1e46 100644
--- a/solr/solr-ref-guide/src/collections-api.adoc
+++ b/solr/solr-ref-guide/src/collections-api.adoc
@@ -215,7 +215,7 @@ curl -X DELETE
http://localhost:8983/api/cluster/command-status/1000
Flush out all stored completed and failed async request responses:
[source,bash]
----
-curl -X DELETE http://localhost:8983/api/cluster/command-status
+curl -X DELETE http://localhost:8983/api/cluster/command-status?flush=true
----
====
--
@@ -239,7 +239,6 @@ The request ID of the asynchronous call whose stored
response should be cleared.
|===
+
Set to `true` to clear all stored completed and failed async request responses.
-This is required only with the V1 API.
=== Examples using DELETESTATUS