mengw15 commented on code in PR #8586:
URL: https://github.com/apache/texera/pull/8586#discussion_r4049764414
##########
amber/src/main/scala/org/apache/texera/web/service/WorkflowService.scala:
##########
@@ -89,6 +95,11 @@ object WorkflowService {
)
return None
}
+ if (warehouseId.isEmpty) {
Review Comment:
Good catch — and it bites earlier than the comment says:
`initExecutionService` unsubscribes the execution in flight before any
validation, so the refused request took the running one's subscriptions with
it. Both `uid` and the warehouse are now resolved before that teardown, so a
request that will be refused never touches the live execution. One place rather
than each caller, so a future third caller is covered too.
##########
frontend/src/app/workspace/service/agent/agent.service.ts:
##########
@@ -666,6 +668,12 @@ export class AgentService {
if (selectedUnit) {
body.computingUnitId = selectedUnit.computingUnit.cuid;
}
+ // Same for the warehouse the user picked: agent runs write into it
rather than
+ // shared storage, which the backend requires while the feature is on
(#7751).
+ const selectedWarehouseId =
this.warehouseService.getSelectedWarehouseIdValue();
Review Comment:
Right — and it was worse than stale: an agent created before the picker
loaded could never run at all. The pick now travels with each prompt
(`WsClientPromptCommand` carries it, and the agent adopts it before running)
instead of being fixed at creation, so a run always uses what the workspace has
selected now — including a warehouse chosen after the agent was created.
Covered by tests on both ends; note `computingUnitId` still has the original
staleness (fixed at creation), which I left alone here.
--
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]