rahulgoswami commented on code in PR #3903:
URL: https://github.com/apache/solr/pull/3903#discussion_r2678400013


##########
solr/api/src/java/org/apache/solr/client/api/model/UpgradeCoreIndexRequestBody.java:
##########
@@ -0,0 +1,33 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.solr.client.api.model;
+
+import com.fasterxml.jackson.annotation.JsonProperty;
+import io.swagger.v3.oas.annotations.media.Schema;
+
+public class UpgradeCoreIndexRequestBody {
+
+  @Schema(description = "Request ID to track this action which will be 
processed asynchronously.")
+  @JsonProperty
+  public String async;

Review Comment:
   I have tested this with only V1 api so far, but have tried to follow the 
pattern for V2 as well. There might be gaps which @gerlowskija could point out 
(?). In case of v1, the async is handled by the 
CoreAdminHandler.handleRequestBody() itself by adding to CoreAdminAsyncTracker 
https://github.com/apache/solr/blob/main/solr/core/src/java/org/apache/solr/handler/admin/CoreAdminHandler.java#L231
   
   Right now unlike the SolrJerseyResponse, the *RequestBody classes don't 
inherit from a common parent. Perhaps a case for refactoring and pushing 
"async" into the parent class? I'd argue though if we are to do that 
refactoring, that could be for another PR?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to