Method DeleteConsumerAsync
DeleteConsumerAsync(string, CancellationToken)
Delete a consumer from this stream.
public ValueTask<bool> DeleteConsumerAsync(string consumer, CancellationToken cancellationToken = default)
Parameters
consumer
stringConsumer name to be deleted.
cancellationToken
CancellationTokenA CancellationToken used to cancel the API call.
Returns
Exceptions
- NatsJSException
There is an error retrieving the response or this consumer object isn't valid anymore because it was deleted earlier.
- NatsJSApiException
Server responded with an error.