mengw15 opened a new issue, #6977:
URL: https://github.com/apache/texera/issues/6977

   ### What happened?
   
   In `WorkflowExecutionsResource` 
([WorkflowExecutionsResource.scala:662-665](https://github.com/apache/texera/blob/main/amber/src/main/scala/org/apache/texera/web/resource/dashboard/user/workflow/WorkflowExecutionsResource.scala#L662)),
 `retrieveWorkflowRuntimeStatistics` (`GET /executions/{wid}/stats/{eid}`) 
declares neither `@RolesAllowed` nor an `@Auth sessionUser` parameter. Every 
other `@GET` in the class does:
   
   - `/{wid}/latest`, `/{wid}/interactions/{eid}`, `/{wid}`, 
`/set_execution_bookmarks` — all have `@RolesAllowed(Array("REGULAR", 
"ADMIN"))` + `@Auth sessionUser`.
   
   The class has no class-level `@RolesAllowed` either, so this one handler is 
inconsistent with the rest. Looks like an oversight when it was added.
   
   **Fix:** add `@RolesAllowed(Array("REGULAR", "ADMIN"))` and an `@Auth 
sessionUser: SessionUser` parameter to match the sibling endpoints.
   
   ### How to reproduce?
   
   Compare the annotations on `retrieveWorkflowRuntimeStatistics` (662-665) 
against the other `@GET` handlers in the same class — it is the only one 
without `@RolesAllowed` / `@Auth`.
   
   ### Version
   
   1.1.0-incubating (Pre-release/Master)


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