Dela via


RedisHubLifetimeManager<THub> Class

Definition

The Redis scaleout provider for multi-server support.

generic <typename THub>
 where THub : Hubpublic ref class RedisHubLifetimeManager : Microsoft::AspNetCore::SignalR::HubLifetimeManager<THub>, IDisposable
public class RedisHubLifetimeManager<THub> : Microsoft.AspNetCore.SignalR.HubLifetimeManager<THub>, IDisposable where THub : Hub
type RedisHubLifetimeManager<'Hub (requires 'Hub :> Hub)> = class
    inherit HubLifetimeManager<'Hub (requires 'Hub :> Hub)>
    interface IDisposable
Public Class RedisHubLifetimeManager(Of THub)
Inherits HubLifetimeManager(Of THub)
Implements IDisposable

Type Parameters

THub

The type of Hub to manage connections for.

Inheritance
RedisHubLifetimeManager<THub>
Implements

Constructors

RedisHubLifetimeManager<THub>(ILogger<RedisHubLifetimeManager<THub>>, IOptions<RedisOptions>, IHubProtocolResolver, IOptions<HubOptions>, IOptions<HubOptions<THub>>)

Constructs the RedisHubLifetimeManager<THub> with types from Dependency Injection.

RedisHubLifetimeManager<THub>(ILogger<RedisHubLifetimeManager<THub>>, IOptions<RedisOptions>, IHubProtocolResolver)

Constructs the RedisHubLifetimeManager<THub> with types from Dependency Injection.

Methods

AddToGroupAsync(String, String, CancellationToken)

Adds a connection to the specified group.

Dispose()

Cleans up the Redis connection.

InvokeConnectionAsync<T>(String, String, Object[], CancellationToken)

Sends an invocation message to the specified connection and waits for a response.

InvokeConnectionAsync<T>(String, String, Object[], CancellationToken)

Sends an invocation message to the specified connection and waits for a response.

(Inherited from HubLifetimeManager<THub>)
OnConnectedAsync(HubConnectionContext)

Called when a connection is started.

OnDisconnectedAsync(HubConnectionContext)

Called when a connection is finished.

RemoveFromGroupAsync(String, String, CancellationToken)

Removes a connection from the specified group.

SendAllAsync(String, Object[], CancellationToken)

Sends an invocation message to all hub connections.

SendAllExceptAsync(String, Object[], IReadOnlyList<String>, CancellationToken)

Sends an invocation message to all hub connections excluding the specified connections.

SendConnectionAsync(String, String, Object[], CancellationToken)

Sends an invocation message to the specified connection.

SendConnectionsAsync(IReadOnlyList<String>, String, Object[], CancellationToken)

Sends an invocation message to the specified connections.

SendGroupAsync(String, String, Object[], CancellationToken)

Sends an invocation message to the specified group.

SendGroupExceptAsync(String, String, Object[], IReadOnlyList<String>, CancellationToken)

Sends an invocation message to the specified group excluding the specified connections.

SendGroupsAsync(IReadOnlyList<String>, String, Object[], CancellationToken)

Sends an invocation message to the specified groups.

SendUserAsync(String, String, Object[], CancellationToken)

Sends an invocation message to the specified user.

SendUsersAsync(IReadOnlyList<String>, String, Object[], CancellationToken)

Sends an invocation message to the specified users.

SetConnectionResultAsync(String, CompletionMessage)

Sets the connection result for an in progress InvokeConnectionAsync<T>(String, String, Object[], CancellationToken) call.

SetConnectionResultAsync(String, CompletionMessage)

Sets the connection result for an in progress InvokeConnectionAsync<T>(String, String, Object[], CancellationToken) call.

(Inherited from HubLifetimeManager<THub>)
TryGetReturnType(String, Type)

Tells IHubProtocol implementations what the expected type from a connection result is.

TryGetReturnType(String, Type)

Tells IHubProtocol implementations what the expected type from a connection result is.

(Inherited from HubLifetimeManager<THub>)

Applies to