{"record":{"id":"1137d48796ed4575","repo":"conductor-oss/conductor","slug":"error-creating-workflow-s","errorCode":null,"errorMessage":"Error creating workflow: %s","messagePattern":"Error creating workflow: (.+?)","errorType":"exception","errorClass":"TransientException","httpStatus":500,"severity":"error","filePath":"cassandra-persistence/src/main/java/com/netflix/conductor/cassandra/dao/CassandraExecutionDAO.java","lineNumber":433,"sourceCode":"            List<TaskModel> tasks = workflow.getTasks();\n            workflow.setTasks(new LinkedList<>());\n            String payload = toJson(workflow);\n\n            recordCassandraDaoRequests(\"createWorkflow\", \"n/a\", workflow.getWorkflowName());\n            recordCassandraDaoPayloadSize(\n                    \"createWorkflow\", payload.length(), \"n/a\", workflow.getWorkflowName());\n            session.execute(\n                    insertWorkflowStatement.bind(\n                            UUID.fromString(workflow.getWorkflowId()), 1, \"\", payload, 0, 1));\n\n            workflow.setTasks(tasks);\n            return workflow.getWorkflowId();\n        } catch (DriverException e) {\n            Monitors.error(CLASS_NAME, \"createWorkflow\");\n            String errorMsg =\n                    String.format(\"Error creating workflow: %s\", workflow.getWorkflowId());\n            LOGGER.error(errorMsg, e);\n            throw new TransientException(errorMsg, e);\n        }\n    }\n\n    @Override\n    public String updateWorkflow(WorkflowModel workflow) {\n        try {\n            List<TaskModel> tasks = workflow.getTasks();\n            workflow.setTasks(new LinkedList<>());\n            String payload = toJson(workflow);\n            recordCassandraDaoRequests(\"updateWorkflow\", \"n/a\", workflow.getWorkflowName());\n            recordCassandraDaoPayloadSize(\n                    \"updateWorkflow\", payload.length(), \"n/a\", workflow.getWorkflowName());\n            session.execute(\n                    updateWorkflowStatement.bind(\n                            payload, UUID.fromString(workflow.getWorkflowId())));\n            workflow.setTasks(tasks);\n            return workflow.getWorkflowId();\n        } catch (DriverException e) {","sourceCodeStart":415,"sourceCodeEnd":451,"githubUrl":"https://github.com/conductor-oss/conductor/blob/cf7c3e4a8adfb158be778ab1ec525323c363cd3a/cassandra-persistence/src/main/java/com/netflix/conductor/cassandra/dao/CassandraExecutionDAO.java#L415-L451","documentation":"Thrown by CassandraExecutionDAO.createWorkflow when inserting a new workflow row fails. DriverException during the insert (plus toJson serialization of the workflow) is wrapped in TransientException. Reports the workflowId.","triggerScenarios":"Calling createWorkflow(WorkflowModel) when Cassandra is unavailable, the workflowId is not a valid UUID (UUID.fromString inside the try), toJson fails, or the write times out.","commonSituations":"Cassandra connectivity loss. Non-UUID workflow ID from a custom generator. Write timeout. Schema drift in the workflows table.","solutions":["Ensure workflow.getWorkflowId() is a valid UUID.","Confirm Cassandra is reachable and the workflows table exists.","Retry — TransientException is retryable; ensure createWorkflow is idempotent on the workflowId before retrying.","Inspect the wrapped DriverException for timeout vs unavailable."],"exampleFix":null,"handlingStrategy":"validation","validationCode":"// Ensure workflow id is a UUID before createWorkflow\nif (!isUuid(workflow.getWorkflowId()))\n    throw new IllegalArgumentException(\"non-UUID workflow id: \" + workflow.getWorkflowId());","typeGuard":"static boolean isUuid(String s) {\n    try { java.util.UUID.fromString(s); return true; } catch (IllegalArgumentException e) { return false; }\n}","tryCatchPattern":"try {\n    return dao.createWorkflow(workflow);\n} catch (TransientException e) {\n    log.warn(\"Transient createWorkflow failure for {}; retrying idempotently\", workflow.getWorkflowId());\n    throw e;","preventionTips":["Validate the workflow ID is a UUID before create.","Keep createWorkflow idempotent on workflowId so retries are safe.","Confirm Cassandra health and retry TransientException with backoff."],"tags":["cassandra","workflow","write","transient","persistence"],"backgroundTag":null,"analyzedSha":"cf7c3e4a8adfb158be778ab1ec525323c363cd3a","analyzedAt":"2026-08-14T03:33:19.897Z","schemaVersion":2},"datasetVersion":"2026-08-14T05:17:29.042Z"}