Uploaded image for project: 'Kogito'
  1. Kogito
  2. KOGITO-6485

User Task - serialisation error

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major Major
    • 1.16.0.Final
    • None
    • Core Engine
    • None
    • False
    • False
    • Hide
      1. Download the attached "sample_workflow.bpmn" and "keycloak-user-creation.drl" files to "src/main/resources/" directory in a Kogito project
      2. Download the attached "Person.java" file to "src/main/java/org/kie/kogito/hr/" directory in the same Kogito project
      3. Restart the services
      4. Run the following cURL command (updating the IP and PORT details) from terminal/command-line: curl H "Content-Type: application/json" -H "Accept: application/json" -X POST http://localhost:8080/sample_workflow -d @ << EOF 
        {
        "person": { "name": "Harry1 Potter1", "email": "harry1potter1@example.com", "salary": 200001, "realm": "kogito" }

        }
        EOF

      Show
      Download the attached "sample_workflow.bpmn" and "keycloak-user-creation.drl" files to "src/main/resources/" directory in a Kogito project Download the attached "Person.java" file to "src/main/java/org/kie/kogito/hr/" directory in the same Kogito project Restart the services Run the following cURL command (updating the IP and PORT details) from terminal/command-line: curl H "Content-Type: application/json" -H "Accept: application/json" -X POST http://localhost:8080/sample_workflow -d @ << EOF  { "person": { "name": "Harry1 Potter1", "email": "harry1potter1@example.com", "salary": 200001, "realm": "kogito" } } EOF
    • 2021 Week 49-51 (from Dec 6th)

      When a "user task" with notification is created in a bpmn workflow, an UnsupportedOperationException is thrown because some data is inserted into an "UnmodifiableMap". After analysing the code, it appears that the implementation is broken.

       

      Stack trace:

      Caused by: java.lang.UnsupportedOperationException
      at java.base/java.util.Collections$UnmodifiableMap.putAll(Collections.java:1463)
      at org.kie.kogito.serialization.process.impl.ProtobufProcessInstanceWriter.buildDeadlines(ProtobufProcessInstanceWriter.java:575)
      at org.kie.kogito.serialization.process.impl.ProtobufProcessInstanceWriter.buildHumanTaskWorkItemData(ProtobufProcessInstanceWriter.java:532)
      at org.kie.kogito.serialization.process.impl.ProtobufProcessInstanceWriter.buildHumanTaskNodeInstance(ProtobufProcessInstanceWriter.java:433)
      at org.kie.kogito.serialization.process.impl.ProtobufProcessInstanceWriter.buildNodeInstanceContent(ProtobufProcessInstanceWriter.java:257)
      at org.kie.kogito.serialization.process.impl.ProtobufProcessInstanceWriter.buildNodeInstances(ProtobufProcessInstanceWriter.java:224)
      at org.kie.kogito.serialization.process.impl.ProtobufProcessInstanceWriter.buildWorkflowContext(ProtobufProcessInstanceWriter.java:196)
      at org.kie.kogito.serialization.process.impl.ProtobufProcessInstanceWriter.writeProcessInstance(ProtobufProcessInstanceWriter.java:149)
      at org.kie.kogito.serialization.process.impl.ProtobufProcessInstanceMarshaller.writeProcessInstance(ProtobufProcessInstanceMarshaller.java:39)
      at org.kie.kogito.serialization.process.ProcessInstanceMarshallerService.marshallProcessInstance(ProcessInstanceMarshallerService.java:108)

        1. keycloak-user-creation.drl
          0.3 kB
        2. Person.java
          2 kB
        3. sample_workflow.bpmn
          19 kB
        4. user_task_sample.tar.gz
          1.27 MB

              cnicolai@redhat.com Cristiano Nicolai (Inactive)
              varunshastrycoder Varun Shastry (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: