-
Bug
-
Resolution: Done
-
Major
-
None
-
False
-
None
-
False
-
---
-
---
-
-
Environment: using platform artifacts from main branch, with embedded postgres, data index and job services.
While running SWF instances that contain a callback state, the framework attempts to insert more than once the SWF entry in the definitions table of the `data_index` database.
DB status before running another instanceof ticket-escalation SWF:
data_index=# select id from definitions; id -------------------- ticket-escalation2 hello ticket-escalation
Log messages after the new instance is triggered:
2023-10-23 09:08:19,779 dmartino-mac INFO [org.kie.kogito.serverless.workflow.devservices.DevModeServerlessWorkflowLogger:64] (executor-thread-16) Triggered node 'approvalEvent' for process 'ticket-escalation' (fa669882-13e5-41c5-a3c2-6f50cb013294) 2023-10-23 09:08:19,780 dmartino-mac INFO [org.kie.kogito.serverless.workflow.devservices.DevModeServerlessWorkflowLogger:50] (executor-thread-16) Workflow 'ticket-escalation' (fa669882-13e5-41c5-a3c2-6f50cb013294) was started, now 'Active' 2023-10-23 09:08:19,821 dmartino-mac WARN [org.hibernate.engine.jdbc.spi.SqlExceptionHelper:137] (executor-thread-16) SQL Error: 0, SQLState: 23505 2023-10-23 09:08:19,821 dmartino-mac ERROR [org.hibernate.engine.jdbc.spi.SqlExceptionHelper:142] (executor-thread-16) ERROR: duplicate key value violates unique constraint "definitions_pkey" Detail: Key (id, version)=(ticket-escalation, 0.0.1) already exists.
As a result, the client invoking the POST request receives 500 error:
< HTTP/1.1 500 Internal Server Error < Content-Type: application/json < Content-Length: 44 < * Connection #0 to host localhost left intact {"message":"Error invoking subclass method"}
Example SWF attached.
Snippet of log attached.
- is depended on by
-
FLPATH-634 Generalize escalation mechanism
- Closed
- is incorporated by
-
KOGITO-9674 Workflow definitions on Data-Index
- Resolved
- relates to
-
KOGITO-9920 Runtimes to Data Index eventing concurrency issues
- Resolved
-
KOGITO-9921 Concurrent events consumption and indexing to a given Process Instance
- Resolved