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

   ### Describe the bug
   
   For an end node with produceEvents in one of the states like below, build 
fails to parse the produceEvent element.
   
   {
         "name": "ErrorWithCompensation",
         "type": "operation",
         "actions": [
           {
             "functionRef": "logProcessContext"
           }
         ],
         "end": {
           "terminate": true,
           "compensate": true,
           "produceEvents": [{
             "eventRef": "FailureEvent",
             "data": {
               "error": ".error",
               "replay": true
             },
             "contextAttributes": {
               "correlationid": ".someId"
             }
           }]
         }
       }
   
   ### Expected behavior
   
   Build should pass and event produced at end node should contain the data 
object as defined.
   
   ### Actual behavior
   
   Build fails parsing the sw definition with following error.
   
   Failed to build quarkus application: io.quarkus.builder.BuildException: 
Build failure: Build failed due to errors
   [ERROR]         [error]: Build step 
org.kie.kogito.quarkus.common.deployment.KogitoAssetsProcessor#generateSources 
threw an exception: org.kie.kogito.codegen.process.ProcessCodegenException: 
Processes with errors are Invalid process: 'xxx.sw.json'. Found error: 
com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException: Unrecognized 
field "error" (class io.serverlessworkflow.api.produce.ProduceEvent), not 
marked as ignorable (3 known properties: "eventRef", "data", 
"contextAttributes"])
   [ERROR]  at [Source: UNKNOWN; byte offset: #UNKNOWN] (through reference 
chain: 
io.serverlessworkflow.api.Workflow["states"]->java.util.ArrayList[1]->io.serverlessworkflow.api.states.OperationState["end"]->io.serverlessworkflow.api.produce.ProduceEvent["error"])
   
   ### How to Reproduce?
   
   _No response_
   
   ### Output of `uname -a` or `ver`
   
   Windows 11
   
   ### Output of `java -version`
   
   java 17
   
   ### 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)
   
   999-snapshot
   
   ### Build tool (ie. output of `mvnw --version` or `gradlew --version`)
   
   gradle 8.6
   
   ### Additional information
   
   _No response_


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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to