Skip to content

Using case insensitive storage type names #996

Open
@kameshsampath

Description

@kameshsampath

Describe the bug

As developer configuring the storageTypeInfo of a Catalog, I see the storageType attribute is expected to be case sensitive e.g. s3 and S3 are treated differently. As a result my API call fails with message saying unsupported storage type.

To Reproduce

  1. Assuming you got Polaris server running
  2. Create a Catalog with
{
    "catalog": {
        "name": "my_catalog",
        "type": "INTERNAL",
        "readOnly": false,
        "properties": {
            "default-base-location": "s3://mycatalogs"
        },
        "storageConfigInfo": {
            "storageType": "s3",
            "allowedLocations": ["s3://mycatalogs"]
        }
    }
}
  1. The call will fail and checking logs you will find info saying s3 storage type is not support and supported types are ...
  2. Now update the JSON to be
{
    "catalog": {
        "name": "my_catalog",
        "type": "INTERNAL",
        "readOnly": false,
        "properties": {
            "default-base-location": "s3://mycatalogs"
        },
        "storageConfigInfo": {
            "storageType": "S3",
            "allowedLocations": ["s3://mycatalogs"]
        }
    }
}
  1. The API call will succeed.

Actual Behavior

Currently the API call succeeds only with S3 as storageType

Expected Behavior

It will be great if the system can handle the right case insensitive storage type names.

Additional context

No response

System information

OS: Linux Container
Object Storage: S3

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions