flowable/flowable-engine · error · FlowableIllegalArgumentException

appDefinitionId is null

Error message

appDefinitionId is null

What it means

Null-argument guard at the top of the GetAppModelCmd command execution: the appDefinitionId passed to the constructor was null, so the command refuses to look up the app model before touching the persistence layer. The caller (typically AppRepositoryService.getAppModel) forwarded a null id.

Solutions

  1. Pass the id returned by an app definition query
  2. Null-check the argument in the calling service before constructing the command
Defensive patterns

Strategy: validation

When it happens

Trigger: Thrown at modules/flowable-app-engine/src/main/java/org/flowable/app/engine/impl/cmd/GetAppModelCmd.java:37 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of flowable/flowable-engine@d6d39ce1c6 (2026-09-11). Data as JSON: /api/errors/cd2415d94c77ac92. Report an issue: GitHub.

Appendix: source

Thrown at modules/flowable-app-engine/src/main/java/org/flowable/app/engine/impl/cmd/GetAppModelCmd.java:37

import org.flowable.common.engine.api.FlowableIllegalArgumentException;
import org.flowable.common.engine.impl.interceptor.Command;
import org.flowable.common.engine.impl.interceptor.CommandContext;

/**
 * @author Tijs Rademakers
 */
public class GetAppModelCmd implements Command<AppModel> {

    protected String appDefinitionId;

    public GetAppModelCmd(String appDefinitionId) {
        this.appDefinitionId = appDefinitionId;
    }

    @Override
    public AppModel execute(CommandContext commandContext) {
        if (appDefinitionId == null) {
            throw new FlowableIllegalArgumentException("appDefinitionId is null");
        }
        
        AppDeploymentManager deploymentManager = CommandContextUtil.getAppEngineConfiguration(commandContext).getDeploymentManager();
        AppDefinition appDefinition = deploymentManager.findDeployedAppDefinitionById(appDefinitionId);
        if (appDefinition != null) {
            return deploymentManager.resolveAppDefinition(appDefinition).getAppModel();
        }
        return null;
    }
}

View on GitHub (pinned to d6d39ce1c6)