You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kie.apache.org by "ricardozanini (via GitHub)" <gi...@apache.org> on 2025/11/06 20:00:47 UTC

[I] POST endpoint returns null schema when no output schema is defined — should default to JsonNodeModelOutput [incubator-kie-kogito-runtimes]

ricardozanini opened a new issue, #4124:
URL: https://github.com/apache/incubator-kie-kogito-runtimes/issues/4124

   ### Describe the bug
   
   When a SonataFlow workflow does not define an outputSchema, the generated OpenAPI for the POST endpoint leaves the response schema null/unspecified. It should default to `JsonNodeModelOutput`, which matches the runtime’s default payload shape:
   
   ```json
   {
     "workflowdata": {},
     "id": "string"
   }
   ```
   
   ### Expected behavior
   
   POST response schema defaults to JsonNodeModelOutput with:
   
   - id: string (process instance id)
   - workflowdata: object (arbitrary map)
   
   ### Actual behavior
   
   Response schema is missing (null), causing client codegen to produce Void/null types.
   
   ### How to Reproduce?
   
   1. Define a workflow without extensions.workflow-output-schema.
   2. Generate OpenAPI (Quarkus OpenAPI/Swagger).
   3. Inspect `POST /{workflow}` response schema → it’s missing/null.
   
   ### Output of `uname -a` or `ver`
   
   _No response_
   
   ### Output of `java -version`
   
   _No response_
   
   ### GraalVM version (if different from Java)
   
   _No response_
   
   ### Kogito version or git rev (or at least Quarkus version if you are using Kogito via Quarkus platform BOM)
   
   _No response_
   
   ### Build tool (ie. output of `mvnw --version` or `gradlew --version`)
   
   _No response_
   
   ### Additional information
   
   In the OpenAPI generator, when no outputSchema is present, set the POST response schema to `#/components/schemas/JsonNodeModelOutput` (or inline equivalent).
   
   Ensure `JsonNodeModelOutput` is always present in `components.schemas`.


-- 
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: commits-unsubscribe@kie.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org
For additional commands, e-mail: commits-help@kie.apache.org


Re: [I] POST endpoint returns null schema when no output schema is defined — should default to JsonNodeModelOutput [incubator-kie-kogito-runtimes]

Posted by "fjtirado (via GitHub)" <gi...@apache.org>.
fjtirado closed issue #4124: POST endpoint returns null schema when no output schema is defined — should default to JsonNodeModelOutput
URL: https://github.com/apache/incubator-kie-kogito-runtimes/issues/4124


-- 
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: commits-unsubscribe@kie.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org
For additional commands, e-mail: commits-help@kie.apache.org