Skip to content

Skip body building when HTTP call body is absent - #1649

Merged
fjtirado merged 1 commit into
open-workflow-specification:mainfrom
mcruzdev:issue-1648
Sep 2, 2026
Merged

Skip body building when HTTP call body is absent#1649
fjtirado merged 1 commit into
open-workflow-specification:mainfrom
mcruzdev:issue-1648

Conversation

@mcruzdev

@mcruzdev mcruzdev commented Sep 2, 2026

Copy link
Copy Markdown
Collaborator

Many thanks for submitting your Pull Request ❤️!

What this PR does / why we need it:

Special notes for reviewers:

Additional information (if needed):

Closes #1648

Signed-off-by: Matheus Cruz <matheuscruz.dev@gmail.com>
Copilot AI lite review requested due to automatic review settings September 2, 2026 03:25
@mcruzdev
mcruzdev requested a review from fjtirado as a code owner September 2, 2026 03:25

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

The code change affects POST/PUT/PATCH but test coverage was only added for POST, leaving PUT/PATCH no-body behavior unverified.

Once you've addressed the issues Copilot identified, you can request another Copilot review.

Pull request overview

Fixes HTTP call handling so POST/PUT/PATCH workflows without with.body no longer throw an IllegalArgumentException, aligning behavior with the Serverless Workflow HTTP call spec.

Changes:

  • Skip creating a body-based request executor when the HTTP call body is absent for POST/PUT/PATCH.
  • Add a workflow sample that performs an HTTP POST without a body.
  • Add a regression test asserting that a POST without with.body does not throw and sends an empty request body.
File summaries
File Description
impl/http/src/main/java/io/serverlessworkflow/impl/executors/http/HttpExecutorBuilder.java Selects a no-body request executor for POST/PUT/PATCH when body is null.
impl/test/src/test/java/io/serverlessworkflow/impl/test/HTTPWorkflowDefinitionTest.java Adds a regression test for POST calls without with.body.
impl/test/src/test/resources/workflows-samples/call-http-post-no-body.yaml Adds a minimal workflow sample for POST without a body.
Review details
  • Files reviewed: 3/3 changed files
  • Comments generated: 1
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@fjtirado
fjtirado merged commit dba6c98 into open-workflow-specification:main Sep 2, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Call http using POST/PATCH/PUT methods without with.body throws IllegalArgumentException

3 participants