@digitalocean/dots - v1.0.1
    Preparing search index...

    Builds and executes requests for operations under /v2/registries/{registry_name}/garbage-collection

    interface GarbageCollectionRequestBuilder {
        byGarbage_collection_uuid(
            garbage_collection_uuid: string,
        ): WithGarbage_collection_uuItemRequestBuilder;
        get(
            requestConfiguration?: RequestConfiguration<object>,
        ): Promise<undefined | GarbageCollectionGetResponse>;
        post(
            requestConfiguration?: RequestConfiguration<object>,
        ): Promise<undefined | GarbageCollectionPostResponse>;
        toGetRequestInformation(
            requestConfiguration?: RequestConfiguration<object>,
        ): RequestInformation;
        toPostRequestInformation(
            requestConfiguration?: RequestConfiguration<object>,
        ): RequestInformation;
        withUrl(rawUrl: string): GarbageCollectionRequestBuilder;
    }

    Hierarchy

    Index

    Methods

    • To get information about the currently-active garbage collection for a registry, send a GET request to /v2/registry/$REGISTRY_NAME/garbage-collection.

      Parameters

      • OptionalrequestConfiguration: RequestConfiguration<object>

        Configuration for the request such as headers, query parameters, and middleware options.

      Returns Promise<undefined | GarbageCollectionGetResponse>

      error when the service returns a 401 status code

      error when the service returns a 404 status code

      error when the service returns a 429 status code

      error when the service returns a 500 status code

      error when the service returns a 4XX or 5XX status code

    post

    • post(
          requestConfiguration?: RequestConfiguration<object>,
      ): Promise<undefined | GarbageCollectionPostResponse>

      Garbage collection enables users to clear out unreferenced blobs (layer &manifest data) after deleting one or more manifests from a repository. Ifthere are no unreferenced blobs resulting from the deletion of one or moremanifests, garbage collection is effectively a noop.See here for more informationabout how and why you should clean up your container registry periodically.To request a garbage collection run on your registry, send a POST request to/v2/registries/$REGISTRY_NAME/garbage-collection. This will initiate thefollowing sequence of events on your registry.* Set the registry to read-only mode, meaning no further write-scoped JWTs will be issued to registry clients. Existing write-scoped JWTs will continue to work until they expire which can take up to 15 minutes.* Wait until all existing write-scoped JWTs have expired.* Scan all registry manifests to determine which blobs are unreferenced.* Delete all unreferenced blobs from the registry.* Record the number of blobs deleted and bytes freed, mark the garbage collection status as success.* Remove the read-only mode restriction from the registry, meaning write-scoped JWTs will once again be issued to registry clients.

      Parameters

      • OptionalrequestConfiguration: RequestConfiguration<object>

        Configuration for the request such as headers, query parameters, and middleware options.

      Returns Promise<undefined | GarbageCollectionPostResponse>

      error when the service returns a 401 status code

      error when the service returns a 404 status code

      error when the service returns a 429 status code

      error when the service returns a 500 status code

      error when the service returns a 4XX or 5XX status code

    • To get information about the currently-active garbage collection for a registry, send a GET request to /v2/registry/$REGISTRY_NAME/garbage-collection.

      Parameters

      • OptionalrequestConfiguration: RequestConfiguration<object>

        Configuration for the request such as headers, query parameters, and middleware options.

      Returns RequestInformation

    • Garbage collection enables users to clear out unreferenced blobs (layer &manifest data) after deleting one or more manifests from a repository. Ifthere are no unreferenced blobs resulting from the deletion of one or moremanifests, garbage collection is effectively a noop.See here for more informationabout how and why you should clean up your container registry periodically.To request a garbage collection run on your registry, send a POST request to/v2/registries/$REGISTRY_NAME/garbage-collection. This will initiate thefollowing sequence of events on your registry.* Set the registry to read-only mode, meaning no further write-scoped JWTs will be issued to registry clients. Existing write-scoped JWTs will continue to work until they expire which can take up to 15 minutes.* Wait until all existing write-scoped JWTs have expired.* Scan all registry manifests to determine which blobs are unreferenced.* Delete all unreferenced blobs from the registry.* Record the number of blobs deleted and bytes freed, mark the garbage collection status as success.* Remove the read-only mode restriction from the registry, meaning write-scoped JWTs will once again be issued to registry clients.

      Parameters

      • OptionalrequestConfiguration: RequestConfiguration<object>

        Configuration for the request such as headers, query parameters, and middleware options.

      Returns RequestInformation