jerqi commented on code in PR #9283:
URL: https://github.com/apache/gravitino/pull/9283#discussion_r2570718003


##########
server/src/main/java/org/apache/gravitino/server/web/rest/JobOperations.java:
##########
@@ -158,8 +180,14 @@ public Response registerJobTemplate(
   @Produces("application/vnd.gravitino.v1+json")
   @Timed(name = "get-job-template." + MetricNames.HTTP_PROCESS_DURATION, 
absolute = true)
   @ResponseMetered(name = "get-job-template", absolute = true)
+  @AuthorizationExpression(
+      expression =
+          "METALAKE::OWNER || JOB_TEMPLATE::OWNER || 
METALAKE::USE_JOB_TEMPLATE || JOB_TEMPLATE::USE_JOB_TEMPLATE")

Review Comment:
   Fixed.



##########
server/src/main/java/org/apache/gravitino/server/web/rest/JobOperations.java:
##########
@@ -297,7 +345,14 @@ public Response getJob(@PathParam("metalake") String 
metalake, @PathParam("jobId
   @Produces("application/vnd.gravitino.v1+json")
   @Timed(name = "run-job." + MetricNames.HTTP_PROCESS_DURATION, absolute = 
true)
   @ResponseMetered(name = "run-job", absolute = true)
-  public Response runJob(@PathParam("metalake") String metalake, JobRunRequest 
request) {
+  @AuthorizationExpression(
+      expression =
+          "METALAKE::OWNER || (METALAKE::RUN_JOB || 
(METALAKE::USE_JOB_TEMPLATE || JOB_TEMPLATE::USE_JOB_TEMPLATE))")

Review Comment:
   Fixed.



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