Class ProducerController.RequestNext<T>
A send instruction sent from the ProducerController to the Producer to request the next message to be sent.
Inherited Members
Namespace: Akka.Delivery
Assembly: Akka.dll
Syntax
public sealed class ProducerController.RequestNext<T> : ProducerController.IProducerCommand<T>, INoSerializationVerificationNeeded
Type Parameters
Name | Description |
---|---|
T |
Constructors
| Edit this page View SourceRequestNext(string, long, long, IActorRef)
Declaration
public RequestNext(string producerId, long currentSeqNr, long confirmedSeqNr, IActorRef sendNextTo)
Parameters
Type | Name | Description |
---|---|---|
string | producerId | |
long | currentSeqNr | |
long | confirmedSeqNr | |
IActorRef | sendNextTo |
Properties
| Edit this page View SourceConfirmedSeqNr
The highest confirmed seqNr observed by the producer controller.
Declaration
public long ConfirmedSeqNr { get; }
Property Value
Type | Description |
---|---|
long |
CurrentSeqNr
The current seqNr being handled by the producer controller.
Declaration
public long CurrentSeqNr { get; }
Property Value
Type | Description |
---|---|
long |
ProducerId
The message that will actually be delivered to consumers.
Declaration
public string ProducerId { get; }
Property Value
Type | Description |
---|---|
string |
SendNextTo
If this field is populated, confirmation messages containing the current SeqNo (long) will be sent to this actor.
Declaration
public IActorRef SendNextTo { get; }
Property Value
Type | Description |
---|---|
IActorRef |
Methods
| Edit this page View SourceAskNextTo(MessageWithConfirmation<T>)
Delivers a ProducerController.MessageWithConfirmation<T> to the SendNextTo actor.
The ReplyTo actor will receive a confirmation message containing the confirmed SeqNo (long) for this message once it's been successfully processed by the consumer.
Declaration
public void AskNextTo(ProducerController.MessageWithConfirmation<T> msgWithConfirmation)
Parameters
Type | Name | Description |
---|---|---|
ProducerController.MessageWithConfirmation<T> | msgWithConfirmation | The message and the replyTo address. |
Remarks
This method name is a bit misleading - we're actually performing a Tell, not an Ask.
The other overload does perform an Ask and uses the temporary Ask actor as the replyTo address.
AskNextTo(T, CancellationToken)
Uses an Ask{T} to send the message to the SendNextTo actor and returns an Ack(long).
Declaration
public Task<long> AskNextTo(T msg, CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
T | msg | The message to send with confirmation back to the temporary Ask actor. |
CancellationToken | cancellationToken | Optional - a CancellationToken.
|
Returns
Type | Description |
---|---|
Task<long> | A task that will complete once the message has been successfully persisted by the ProducerController. |