{"record":{"id":"2d412a04fb648a51","repo":"conductor-oss/conductor","slug":"this-method-is-not-currently-implemented-in-cassan","errorCode":null,"errorMessage":"This method is not currently implemented in CassandraExecutionDAO. Please use RedisDAO mode instead now for using TTLs.","messagePattern":"This method is not currently implemented in CassandraExecutionDAO\\. Please use RedisDAO mode instead now for using TTLs\\.","errorType":"exception","errorClass":"UnsupportedOperationException","httpStatus":500,"severity":"error","filePath":"cassandra-persistence/src/main/java/com/netflix/conductor/cassandra/dao/CassandraExecutionDAO.java","lineNumber":490,"sourceCode":"                removed = resultSet.wasApplied();\n            } catch (DriverException e) {\n                Monitors.error(CLASS_NAME, \"removeWorkflow\");\n                String errorMsg = String.format(\"Failed to remove workflow: %s\", workflowId);\n                LOGGER.error(errorMsg, e);\n                throw new TransientException(errorMsg);\n            }\n            workflow.getTasks().forEach(this::removeTaskLookup);\n        }\n        return removed;\n    }\n\n    /**\n     * This is a dummy implementation and this feature is not yet implemented for Cassandra backed\n     * Conductor\n     */\n    @Override\n    public boolean removeWorkflowWithExpiry(String workflowId, int ttlSeconds) {\n        throw new UnsupportedOperationException(\n                \"This method is not currently implemented in CassandraExecutionDAO. Please use RedisDAO mode instead now for using TTLs.\");\n    }\n\n    /**\n     * No-op: Cassandra does not maintain a pending-workflows structure, so there is nothing to\n     * remove. This used to throw UnsupportedOperationException, which turned every\n     * completeWorkflow/terminateWorkflow call that hits the already-terminal branch into an HTTP\n     * 500 — the workflow write paths cannot be allowed to fail on a bookkeeping call whose state\n     * does not exist on this backend.\n     */\n    @Override\n    public void removeFromPendingWorkflow(String workflowType, String workflowId) {}\n\n    @Override\n    public WorkflowModel getWorkflow(String workflowId) {\n        return getWorkflow(workflowId, true);\n    }\n","sourceCodeStart":472,"sourceCodeEnd":508,"githubUrl":"https://github.com/conductor-oss/conductor/blob/cf7c3e4a8adfb158be778ab1ec525323c363cd3a/cassandra-persistence/src/main/java/com/netflix/conductor/cassandra/dao/CassandraExecutionDAO.java#L472-L508","documentation":"CassandraExecutionDAO.removeWorkflowWithExpiry throws UnsupportedOperationException because TTL-based workflow removal is not implemented on the Cassandra backend (Cassandra does not natively TTL its workflow row in this schema). The DAO is a dummy stub by design; the message points users to the Redis-backed ExecutionDAO, which supports per-row expiry. This is a backend-capability gap, not a transient fault.","triggerScenarios":"Calling executionDAO.removeWorkflowWithExpiry(workflowId, ttlSeconds) while the active ExecutionDAO bean is CassandraExecutionDAO. This is reached by code paths (e.g. archival/cleanup) that request a TTL on removal.","commonSituations":"Selecting the cassandra-persistence module as the execution store (`conductor.cassandra.enabled`) and then enabling a workflow-removal-with-TTL feature, or porting code from a Redis deployment that relied on expiring rows.","solutions":["Switch the execution persistence layer to Redis (redis-persistence) if you require TTL-based workflow removal.","Call removeWorkflow(workflowId, archiveWorkflow) instead of removeWorkflowWithExpiry; Cassandra removes the row immediately without a TTL.","If you must stay on Cassandra and need expiry, schedule removal externally (a reaper job) rather than relying on the DAO TTL.","Guard the call site with a check for the concrete DAO type and skip/disable the TTL path on Cassandra."],"exampleFix":"// before\nexecutionDAO.removeWorkflowWithExpiry(workflowId, ttlSeconds);\n\n// after\nif (executionDAO instanceof CassandraExecutionDAO) {\n    executionDAO.removeWorkflow(workflowId); // no TTL on Cassandra\n} else {\n    executionDAO.removeWorkflowWithExpiry(workflowId, ttlSeconds);\n}","handlingStrategy":"validation","validationCode":"// Before requesting TTL-based removal, check the backend capability\nboolean supportsExpiry = !(executionDAO instanceof CassandraExecutionDAO);\nif (!supportsExpiry) {\n    LOGGER.warn(\"TTL removal unsupported on {} — removing immediately\",\n        executionDAO.getClass().getSimpleName());\n    executionDAOFacade.removeWorkflow(workflowId, false);\n} else {\n    executionDAO.removeWorkflowWithExpiry(workflowId, ttlSeconds);\n}","typeGuard":"// capability check for TTL removal\npublic boolean supportsWorkflowExpiry(ExecutionDAO dao) {\n    return !(dao instanceof CassandraExecutionDAO);\n}","tryCatchPattern":"try {\n    executionDAO.removeWorkflowWithExpiry(workflowId, ttlSeconds);\n} catch (UnsupportedOperationException e) {\n    LOGGER.warn(\"TTL removal unsupported, falling back to immediate remove\", e);\n    executionDAOFacade.removeWorkflow(workflowId, false);\n}","preventionTips":["Prefer ExecutionDAOFacade over the raw CassandraExecutionDAO at all call sites.","Document which backends support TTL removal when selecting a persistence module.","Add an integration test that asserts the unsupported path degrades gracefully on Cassandra."],"tags":["cassandra","persistence","dao","ttl","unsupported-operation","backend-capability"],"backgroundTag":null,"analyzedSha":"cf7c3e4a8adfb158be778ab1ec525323c363cd3a","analyzedAt":"2026-08-14T03:33:19.897Z","schemaVersion":2},"datasetVersion":"2026-08-14T05:17:29.042Z"}