{"record":{"id":"4fcfcf72b4da9209","repo":"flowable/flowable-engine","slug":"cannot-find-app-definition-with-id","errorCode":null,"errorMessage":"Cannot find app definition with id ","messagePattern":"Cannot find app definition with id ","errorType":"exception","errorClass":"FlowableObjectNotFoundException","httpStatus":404,"severity":"error","filePath":"modules/flowable-app-engine/src/main/java/org/flowable/app/engine/impl/cmd/NeedsAppDefinitionCmd.java","lineNumber":49,"sourceCode":"    private static final long serialVersionUID = 1L;\n\n    protected String appDefinitionId;\n\n    public NeedsAppDefinitionCmd(String appDefinitionId) {\n        this.appDefinitionId = appDefinitionId;\n    }\n\n    @Override\n    public T execute(CommandContext commandContext) {\n\n        if (appDefinitionId == null) {\n            throw new FlowableIllegalArgumentException(\"appDefinitionId is null\");\n        }\n\n        AppDefinition appDefinition = CommandContextUtil.getAppRepositoryService().getAppDefinition(appDefinitionId);\n\n        if (appDefinition == null) {\n            throw new FlowableObjectNotFoundException(\"Cannot find app definition with id \" + appDefinitionId, AppDefinition.class);\n        }\n\n        return execute(commandContext, appDefinition);\n    }\n\n    /**\n     * Subclasses must implement in this method their normal command logic.\n     */\n    protected abstract T execute(CommandContext commandContext, AppDefinition appDefinition);\n\n}\n","sourceCodeStart":31,"sourceCodeEnd":61,"githubUrl":"https://github.com/flowable/flowable-engine/blob/d6d39ce1c69ff244f2d9dc6af756a9b95e865586/modules/flowable-app-engine/src/main/java/org/flowable/app/engine/impl/cmd/NeedsAppDefinitionCmd.java#L31-L61","documentation":"Lookup failure in NeedsAppDefinitionCmd.execute: an appDefinitionId was supplied but the repository service finds no app definition with that id (deleted, wrong engine, or typo), so the subclass command cannot proceed.","triggerScenarios":"Thrown at modules/flowable-app-engine/src/main/java/org/flowable/app/engine/impl/cmd/NeedsAppDefinitionCmd.java:49 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["List app definitions to confirm the id exists in this engine","Re-deploy the app if the definition was removed"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"d6d39ce1c69ff244f2d9dc6af756a9b95e865586","analyzedAt":"2026-09-11T06:41:19.413Z","contentChangedAt":"2026-09-11T06:41:19.413Z","schemaVersion":2},"datasetVersion":"2026-09-18T11:17:12.947Z"}