Skip to content

vllm.v1.kv_offload.tiering.obj.config

Connection configuration for the object store secondary tier.

Classes:

  • ObjStoreConfig

    Connection parameters for an object store backend.

ObjStoreConfig dataclass

Connection parameters for an object store backend.

When access_key and secret_key are left empty the NIXL OBJ plugin falls back to the AWS SDK default credential provider chain (IAM roles, environment variables, credential files, etc.), which enables workload-identity based auth on Kubernetes.

Methods:

Source code in vllm/v1/kv_offload/tiering/obj/config.py
@dataclass
class ObjStoreConfig:
    """Connection parameters for an object store backend.

    When ``access_key`` and ``secret_key`` are left empty the NIXL OBJ
    plugin falls back to the AWS SDK default credential provider chain
    (IAM roles, environment variables, credential files, etc.), which
    enables workload-identity based auth on Kubernetes.
    """

    bucket: str
    endpoint_override: str
    access_key: str = field(default="", repr=False)
    secret_key: str = field(default="", repr=False)
    session_token: str = field(default="", repr=False)
    region: str = ""
    scheme: str = "http"
    ca_bundle: str = ""

    def to_nixl_params(self) -> dict[str, str]:
        """Build the NIXL backend params dict.

        Credential and optional fields are only included when non-empty
        so that the AWS SDK default credential chain can activate.
        """
        params: dict[str, str] = {
            "bucket": self.bucket,
            "endpoint_override": self.endpoint_override,
            "scheme": self.scheme,
        }
        # Omit empty optional fields so the NIXL OBJ plugin's underlying
        # AWS SDK can fall back to its default credential provider chain
        # (IAM roles, env vars, credential files, etc.).
        # https://github.com/ai-dynamo/nixl/blob/main/src/plugins/obj/README.md
        for key in ("access_key", "secret_key", "session_token", "region", "ca_bundle"):
            value = getattr(self, key)
            if value:
                params[key] = value
        return params

to_nixl_params()

Build the NIXL backend params dict.

Credential and optional fields are only included when non-empty so that the AWS SDK default credential chain can activate.

Source code in vllm/v1/kv_offload/tiering/obj/config.py
def to_nixl_params(self) -> dict[str, str]:
    """Build the NIXL backend params dict.

    Credential and optional fields are only included when non-empty
    so that the AWS SDK default credential chain can activate.
    """
    params: dict[str, str] = {
        "bucket": self.bucket,
        "endpoint_override": self.endpoint_override,
        "scheme": self.scheme,
    }
    # Omit empty optional fields so the NIXL OBJ plugin's underlying
    # AWS SDK can fall back to its default credential provider chain
    # (IAM roles, env vars, credential files, etc.).
    # https://github.com/ai-dynamo/nixl/blob/main/src/plugins/obj/README.md
    for key in ("access_key", "secret_key", "session_token", "region", "ca_bundle"):
        value = getattr(self, key)
        if value:
            params[key] = value
    return params