carloea2 opened a new pull request, #8164:
URL: https://github.com/apache/texera/pull/8164
### What changes were proposed in this PR?
Route workflow WebSocket deserialization failures through the endpoint's
existing error handler.
JSON parsing currently happens before the `try` block, so malformed frames
are logged by the container but never become a `WorkflowErrorEvent`. Moving
that one line into the guarded block gives the editor the same structured error
event used for other workflow request failures.
Before: malformed frame sends no error event and the client waits.
After: malformed frame immediately sends `WorkflowErrorEvent` with the parse
failure.
Valid frames are unchanged.
### Any related issues, documentation, discussions?
Closes #8163
### How was this PR tested?
Focused tests:
`sbt -no-colors "WorkflowExecutionService/testOnly
org.apache.texera.web.resource.WorkflowWebsocketResourceSpec"`
Result: 16 tests passed.
Checks:
`sbt -no-colors scalafmtCheckAll`
`sbt -no-colors "scalafixAll --check"`
Localhost verification against the computing unit master:
1. Connected to the workflow WebSocket with workflow and computing unit
parameters.
2. Sent the incomplete JSON frame `{`.
3. Before the change, only startup events arrived and the client timed out.
4. After the change, `WorkflowErrorEvent` arrived immediately with
`Unexpected end-of-input`.
### Was this PR authored or co-authored using generative AI tooling?
Generated-by: Codex GPT-5
--
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]