{"record":{"id":"e9f90659ac607927","repo":"conductor-oss/conductor","slug":"no-such-tasktype-found-by-name-s","errorCode":null,"errorMessage":"No such taskType found by name: %s","messagePattern":"No such taskType found by name: (.+?)","errorType":"exception","errorClass":"NotFoundException","httpStatus":404,"severity":"error","filePath":"core/src/main/java/com/netflix/conductor/service/MetadataServiceImpl.java","lineNumber":118,"sourceCode":"        metadataDAO.removeTaskDef(taskType);\n        metadataChangeListener.onTaskDefUnregistered(taskType);\n    }\n\n    /**\n     * @return List of all the registered tasks\n     */\n    public List<TaskDef> getTaskDefs() {\n        return metadataDAO.getAllTaskDefs();\n    }\n\n    /**\n     * @param taskType Task to retrieve\n     * @return Task Definition\n     */\n    public TaskDef getTaskDef(String taskType) {\n        TaskDef taskDef = metadataDAO.getTaskDef(taskType);\n        if (taskDef == null) {\n            throw new NotFoundException(\"No such taskType found by name: %s\", taskType);\n        }\n        return taskDef;\n    }\n\n    /**\n     * @param workflowDef Workflow definition to be updated\n     */\n    public void updateWorkflowDef(WorkflowDef workflowDef) {\n        workflowDef.setUpdateTime(System.currentTimeMillis());\n        metadataDAO.updateWorkflowDef(workflowDef);\n        metadataChangeListener.onWorkflowDefUpdated(workflowDef);\n    }\n\n    /**\n     * @param workflowDefList Workflow definitions to be updated.\n     */\n    public BulkResponse<String> updateWorkflowDef(List<WorkflowDef> workflowDefList) {\n        BulkResponse<String> bulkResponse = new BulkResponse<>();","sourceCodeStart":100,"sourceCodeEnd":136,"githubUrl":"https://github.com/conductor-oss/conductor/blob/cf7c3e4a8adfb158be778ab1ec525323c363cd3a/core/src/main/java/com/netflix/conductor/service/MetadataServiceImpl.java#L100-L136","documentation":"Thrown by MetadataServiceImpl.getTaskDef when metadataDAO.getTaskDef(taskType) returns null, meaning no TaskDef is registered under that name. It surfaces as an HTTP 404 (NotFoundException maps to NOT_FOUND) when a client requests a task definition that does not exist in the metadata store. The placeholder %s is filled with the requested taskType name.","triggerScenarios":"Calling GET /api/metadata/taskdefs/{taskType} with a name that was never registered, or that was unregistered. Also triggered internally by any code path that resolves a TaskDef by name and finds nothing (e.g. workflow referencing a task whose definition was removed).","commonSituations":"Typo in the taskType path segment; the task definition was registered under a different environment/cluster; the task def was deleted via unregisterTaskDef; a recently deployed workflow references a task name that has not yet been registered in that environment.","solutions":["Verify the exact taskType spelling against registered defs via GET /api/metadata/taskdefs (list all).","Register the missing definition with POST /api/metadata/taskdefs using the correct name.","If the def was deleted, re-register it from your definition-as-code source.","Confirm you are pointed at the correct cluster/environment metadata store."],"exampleFix":"// before\nTaskDef def = metadataService.getTaskDef(\"myTaskX\"); // throws\n\n// after\nList<TaskDef> all = metadataService.getTaskDefs();\nboolean exists = all.stream().anyMatch(t -> t.getName().equals(\"myTask\"));\nTaskDef def = exists ? metadataService.getTaskDef(\"myTask\") : null;","handlingStrategy":"validation","validationCode":"List<TaskDef> defs = metadataService.getTaskDefs();\nboolean exists = defs.stream().anyMatch(t -> t.getName().equals(taskType));\nif (!exists) {\n    // register or skip\n}","typeGuard":null,"tryCatchPattern":"try {\n    TaskDef def = metadataService.getTaskDef(taskType);\n} catch (NotFoundException e) {\n    // task not registered; handle gracefully\n}","preventionTips":["Validate task names against getTaskDefs() before lookup","Keep task definitions under version control and register them on deploy"],"tags":["metadata","task-def","not-found","conductor","java"],"backgroundTag":null,"analyzedSha":"cf7c3e4a8adfb158be778ab1ec525323c363cd3a","analyzedAt":"2026-08-14T03:33:19.897Z","schemaVersion":2},"datasetVersion":"2026-08-14T05:17:29.042Z"}