flowable/flowable-engine · error · FlowableIllegalArgumentException

No resource name provided

Error message

No resource name provided

What it means

getDeploymentResourceData validates that a resourceName was supplied after checking the deploymentId. A null resourceName throws FlowableIllegalArgumentException. Resource content can only be fetched when both the deployment and the resource name identify the artifact.

Solutions

  1. Supply the full resource name from GET /repository/deployments/{deploymentId}/resources in the URL.
  2. URL-encode resource names containing slashes or special characters.
  3. Validate resourceName non-null/non-empty before issuing the request.

Example fix

// before
GET /repository/deployments/2501/resourcedata/
// after
GET /repository/deployments/2501/resourcedata/processes.bpmn20.xml
Defensive patterns

Strategy: validation

Validate before calling

if (!resourceName) throw new Error('resourceName is required');

Try / catch

try { ... } catch (e) { if (e.status === 400) log.error('Missing resource name'); throw e; }

Prevention

When it happens

Trigger: Requesting resource data with a null resourceName (e.g. empty {resourceName} path segment or direct call to the helper with null).

Common situations: Resource name lost during URL encoding/splitting (names often contain slashes like 'bpmn/process.bpmn20.xml'); client builds URL with missing resource segment; custom code calling the protected method directly.

Understand the failure class

Background: "missing required argument" and "the following required arguments were not provided": what required-argument errors mean and how to fix them — this error's family across 20 libraries.

Related errors


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

Appendix: source

Thrown at modules/flowable-rest/src/main/java/org/flowable/rest/service/api/repository/BaseDeploymentResourceDataResource.java:51

 */
public class BaseDeploymentResourceDataResource {

    @Autowired
    protected ContentTypeResolver contentTypeResolver;

    @Autowired
    protected RepositoryService repositoryService;
    
    @Autowired(required=false)
    protected BpmnRestApiInterceptor restApiInterceptor;

    protected byte[] getDeploymentResourceData(String deploymentId, String resourceName, HttpServletResponse response) {

        if (deploymentId == null) {
            throw new FlowableIllegalArgumentException("No deployment id provided");
        }
        if (resourceName == null) {
            throw new FlowableIllegalArgumentException("No resource name provided");
        }

        // Check if deployment exists
        Deployment deployment = repositoryService.createDeploymentQuery().deploymentId(deploymentId).singleResult();
        if (deployment == null) {
            throw new FlowableObjectNotFoundException("Could not find a deployment with id '" + deploymentId + "'.", Deployment.class);
        }
        
        if (restApiInterceptor != null) {
            restApiInterceptor.accessDeploymentById(deployment);
        }

        List<String> resourceList = repositoryService.getDeploymentResourceNames(deploymentId);

        if (resourceList.contains(resourceName)) {
            String contentType = contentTypeResolver.resolveContentType(resourceName);
            response.setContentType(contentType);
            try (final InputStream resourceStream = repositoryService.getResourceAsStream(deploymentId, resourceName)) {

View on GitHub (pinned to d6d39ce1c6)