apache/dolphinscheduler · critical · IllegalArgumentException

resource.alibaba.cloud.obs.bucket.name is empty

Error message

resource.alibaba.cloud.obs.bucket.name is empty

What it means

ObsStorageOperator.ensureBucketSuccessfullyCreated throws IllegalArgumentException when the configured OBS bucket name is blank. Called from the constructor/init path, this fails operator initialization before any OBS request is made.

Source

Thrown at dolphinscheduler-storage-plugin/dolphinscheduler-storage-obs/src/main/java/org/apache/dolphinscheduler/plugin/storage/obs/ObsStorageOperator.java:246

                }
            }
            storageEntityList.addAll(tempList);
        }

        return storageEntityList;
    }

    @Override
    public StorageEntity getStorageEntity(String resourceAbsolutePath) {
        resourceAbsolutePath = transformObsKeyToAbsolutePath(resourceAbsolutePath);

        ObsObject object = obsClient.getObject(bucketName, resourceAbsolutePath);
        return transformObsObjectToStorageEntity(object);
    }

    private void ensureBucketSuccessfullyCreated(String bucketName) {
        if (StringUtils.isBlank(bucketName)) {
            throw new IllegalArgumentException("resource.alibaba.cloud.obs.bucket.name is empty");
        }

        boolean existsBucket = obsClient.headBucket(bucketName);
        if (!existsBucket) {
            throw new IllegalArgumentException(
                    "bucketName: " + bucketName + " is not exists, you need to create them by yourself");
        }

        log.info("bucketName: {} has been found", bucketName);
    }

    protected StorageEntity transformObsObjectToStorageEntity(ObsObject object) {
        ObjectMetadata metadata = object.getMetadata();
        String fileAbsolutePath = transformObsKeyToAbsolutePath(object.getObjectKey());
        ResourceMetadata resourceMetaData = getResourceMetaData(fileAbsolutePath);
        String fileExtension = com.google.common.io.Files.getFileExtension(resourceMetaData.getResourceAbsolutePath());

        return StorageEntity.builder()

View on GitHub (pinned to 02eac45a1b)

Solutions

  1. Set resource.alibaba.cloud.obs.bucket.name to a valid non-blank bucket name in the storage config
  2. Verify the config file actually loaded (check startup logs for resolved properties)
  3. If using env substitution, confirm the env var is exported in the scheduler's environment

Example fix

// before
resource.alibaba.cloud.obs.bucket.name=
// after
resource.alibaba.cloud.obs.bucket.name=my-dolphin-resources
Defensive patterns

Strategy: validation

Validate before calling

String bucket = config.get("resource.alibaba.cloud.obs.bucket.name");
if (bucket == null || bucket.isBlank()) {
    throw new IllegalStateException("resource.alibaba.cloud.obs.bucket.name must be set before init");
}

Try / catch

try {
    storageOperator = new ObsStorageOperator(cfg);
} catch (IllegalArgumentException e) {
    log.error("OBS storage misconfigured: {}", e.getMessage());
    throw e;
}

Prevention

When it happens

Trigger: Initializing ObsStorageOperator with resource.alibaba.cloud.obs.bucket.name unset or empty in the storage configuration (yaml/env).

Common situations: Missing or misnamed config key in common.properties / storage plugin config; environment variable not propagated; copying a config template and forgetting to fill in the bucket name.

Understand the failure class

Background: "is required", "must be set", "missing required field": configuration validation errors across open-source libraries — this error's family across 36 libraries.

Related errors


AI-assisted analysis of apache/dolphinscheduler@02eac45a1b (2026-09-06). Data as JSON: /api/errors/0e889acb1217c9bd. Report an issue: GitHub.