fuweng11 commented on code in PR #7689:
URL: https://github.com/apache/inlong/pull/7689#discussion_r1149953740


##########
inlong-manager/manager-web/src/main/java/org/apache/inlong/manager/web/controller/StreamSinkController.java:
##########
@@ -118,11 +118,14 @@ public Response<Boolean> 
deleteByKey(@RequestParam(required = false, defaultValu
         return Response.success(sinkService.deleteByKey(groupId, streamId, 
name, startProcess, username));
     }
 
-    @RequestMapping(value = "/sink/parseFields", method = RequestMethod.POST)
-    @ApiOperation(value = "parse stream sink fields from JSON string")
-    @ApiImplicitParam(name = "fieldsJson", dataTypeClass = String.class, 
required = true)
-    public Response<List<SinkField>> parseFields(@RequestBody String 
fieldsJson) {
-        return Response.success(sinkService.parseFields(fieldsJson));
+    @RequestMapping(value = "/sink/parseFields/{statementType}", method = 
RequestMethod.POST)
+    @ApiOperation(value = "parse stream sink fields from statement")
+    @ApiImplicitParams({
+            @ApiImplicitParam(name = "statement", dataTypeClass = 
String.class, required = true),
+            @ApiImplicitParam(name = "statementType", dataTypeClass = 
String.class, required = true)
+    })
+    public Response<List<SinkField>> parseFields(@PathVariable String 
statementType, @RequestBody String statement) {

Review Comment:
   Can we encapsulate all the parameters into an object without displaying the 
parameters in the path?



-- 
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]

Reply via email to