Table of Contents

Method GetEntryAsync

Namespace
NATS.Client.KeyValueStore
Assembly
NATS.Client.KeyValueStore.dll

GetEntryAsync<T>(string, ulong, INatsDeserialize<T>?, CancellationToken)

Get an entry from the bucket using the key

public ValueTask<NatsKVEntry<T>> GetEntryAsync<T>(string key, ulong revision = 0, INatsDeserialize<T>? serializer = null, CancellationToken cancellationToken = default)

Parameters

key string

Key of the entry

revision ulong

Revision to retrieve

serializer INatsDeserialize<T>

Optional serialized to override the default

cancellationToken CancellationToken

A CancellationToken used to cancel the API call.

Returns

ValueTask<NatsKVEntry<T>>

The entry

Type Parameters

T

Serialized value type

Exceptions

NatsKVException

There was an error with metadata