{"record":{"id":"94dd480209e867fc","repo":"flowable/flowable-engine","slug":"could-no-handle-signal-no-start-activity-found-wi","errorCode":null,"errorMessage":"Could no handle signal: no start activity found with id ${eventSubscription.getActivityId()}","messagePattern":"Could no handle signal: no start activity found with id (.+?)","errorType":"exception","errorClass":"ActivitiException","httpStatus":null,"severity":"error","filePath":"modules/flowable5-engine/src/main/java/org/activiti/engine/impl/event/SignalEventHandler.java","lineNumber":60,"sourceCode":"    @Override\r\n    public void handleEvent(EventSubscriptionEntity eventSubscription, Object payload, CommandContext commandContext) {\r\n        if (eventSubscription.getExecutionId() != null) {\r\n            super.handleEvent(eventSubscription, payload, commandContext);\r\n        } else if (eventSubscription.getProcessDefinitionId() != null) {\r\n            // Start event\r\n            String processDefinitionId = eventSubscription.getProcessDefinitionId();\r\n            DeploymentManager deploymentCache = Context\r\n                    .getProcessEngineConfiguration()\r\n                    .getDeploymentManager();\r\n\r\n            ProcessDefinitionEntity processDefinition = (ProcessDefinitionEntity) deploymentCache.findDeployedProcessDefinitionById(processDefinitionId);\r\n            if (processDefinition == null) {\r\n                throw new ActivitiObjectNotFoundException(\"No process definition found for id '\" + processDefinitionId + \"'\", ProcessDefinition.class);\r\n            }\r\n\r\n            ActivityImpl startActivity = processDefinition.findActivity(eventSubscription.getActivityId());\r\n            if (startActivity == null) {\r\n                throw new ActivitiException(\"Could no handle signal: no start activity found with id \" + eventSubscription.getActivityId());\r\n            }\r\n            ExecutionEntity processInstance = processDefinition.createProcessInstance(null, startActivity);\r\n            if (processInstance == null) {\r\n                throw new ActivitiException(\"Could not handle signal: no process instance started\");\r\n            }\r\n\r\n            if (payload != null) {\r\n                if (payload instanceof Map) {\r\n                    Map<String, Object> variables = (Map<String, Object>) payload;\r\n                    processInstance.setVariables(variables);\r\n                }\r\n            }\r\n\r\n            processInstance.start();\r\n        } else {\r\n            throw new ActivitiException(\"Invalid signal handling: no execution nor process definition set\");\r\n        }\r\n    }\r","sourceCodeStart":42,"sourceCodeEnd":78,"githubUrl":"https://github.com/flowable/flowable-engine/blob/d6d39ce1c69ff244f2d9dc6af756a9b95e865586/modules/flowable5-engine/src/main/java/org/activiti/engine/impl/event/SignalEventHandler.java#L42-L78","documentation":"Thrown by SignalEventHandler.handleEvent when the event subscription's activityId does not match any start activity in the resolved process definition, i.e. processDefinition.findActivity(activityId) returns null. The signal was supposed to start/continue at a specific activity that no longer exists in the deployed model. Note the message's typo 'Could no handle signal' exists in the source.","triggerScenarios":"A signal start-event subscription is handled but its activityId (stored when the subscription was created) is absent from the currently deployed process definition — e.g. the start event id was renamed in a new model version while the old subscription persisted.","commonSituations":"Renaming or removing a signal start event id in the BPMN XML and redeploying while old subscriptions survive in the runtime tables; DB restored from a snapshot with mismatched deployments; hand-crafted signal subscriptions.","solutions":["Align the event subscription's activityId with the deployed model: redeploy the original BPMN or update/delete the stale subscription.","Keep signal start event ids stable across versions of the process definition.","Purge orphaned ACT_RU_EVENT_SUBSCRIBER rows whose activityId no longer exists in ACT_RE_PROCDEF's model.","If the signal should start a fresh instance, verify the subscription was created for the correct (current) definition version."],"exampleFix":"// before: renaming the start signal event id in the BPMN\n<signal id=\"orderSignal\"/>\n<startEvent id=\"oldStartId\"><signalEventDefinition signalRef=\"orderSignal\"/></startEvent>\n// after: keep the id stable across versions\n<startEvent id=\"orderStart\"><signalEventDefinition signalRef=\"orderSignal\"/></startEvent>","handlingStrategy":"validation","validationCode":"// keep signal start event ids stable; before redeploy, diff the BPMN ids\nSet<String> startIds = model.getStartActivities().stream()\n    .map(ActivityImpl::getId).collect(Collectors.toSet());\nif (!startIds.contains(subscriptionActivityId)) {\n    throw new IllegalStateException(\"Start activity missing in deployed model\");\n}","typeGuard":null,"tryCatchPattern":"try {\n    runtimeService.signalEventReceived(\"orderSignal\");\n} catch (org.activiti.engine.ActivitiException e) {\n    if (e.getMessage().contains(\"no start activity\")) {\n        LOGGER.error(\"BPMN start event id changed; fix subscription/model\");\n    }\n}","preventionTips":["Never rename BPMN element ids across versions.","Version-diff BPMN models in CI before deployment.","Clean stale ACT_RU_EVENT_SUBSCRIBER rows after model changes."],"tags":["bpmn","signal","activity","model-mismatch"],"backgroundTag":"entity-not-found","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"}