Open sandboxFocus

Method PerformFullCollectionAsync

PerformFullCollectionAsync(RedisCachingBackend, CancellationToken)

Performs a full garbage collection on all Redis servers. This operation enumerates and validates all keys in the database, and can possibly last several minutes and affect performance in production.

Declaration
public static Task PerformFullCollectionAsync(RedisCachingBackend backend, CancellationToken cancellationToken = default)
Parameters
Type Name Description
RedisCachingBackend backend

A RedisCachingBackend that supports dependencies.

CancellationToken cancellationToken

A CancellationToken.

Returns
Type Description
Task

A Task.

PerformFullCollectionAsync(RedisCachingBackend, IServer, CancellationToken)

Performs a full garbage collection on a given Redis server. This operation enumerates and validates all keys in the database, and can possibly last several minutes and affect performance in production.

Declaration
public static Task PerformFullCollectionAsync(RedisCachingBackend backend, IServer server, CancellationToken cancellationToken = default)
Parameters
Type Name Description
RedisCachingBackend backend

A RedisCachingBackend that supports dependencies.

IServer server

The Redis server whose keys will be enumerated and validated.

CancellationToken cancellationToken

A CancellationToken.

Returns
Type Description
Task

A Task.