public enum FlowControlMode extends Enum<FlowControlMode>
| Enum Constant and Description |
|---|
AUTOMATIC
In this mode,
Mutation and Deletion events are automatically acknowledged
prior to dispatch to the DatabaseChangeListener. |
MANUAL
In this mode, the listener is responsible for calling
DocumentChange.flowControlAck()
after each Mutation and Deletion event is processed. |
| Modifier and Type | Method and Description |
|---|---|
static FlowControlMode |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static FlowControlMode[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final FlowControlMode AUTOMATIC
Mutation and Deletion events are automatically acknowledged
prior to dispatch to the DatabaseChangeListener.
Suitable for listeners whose DatabaseChangeListener.onMutation(Mutation)
and DatabaseChangeListener.onDeletion(Deletion) methods either completely process
the event (for example, by writing it to disk) or implictly generate backpressure (for example,
by writing the event to a bounded blocking queue).
public static final FlowControlMode MANUAL
DocumentChange.flowControlAck()
after each Mutation and Deletion event is processed.
NOTE: This mode is not recommended, since it can be difficult to ensure events are acknowledged on all code paths, and failure to ACK can cause the server to stop sending events.
public static FlowControlMode[] values()
for (FlowControlMode c : FlowControlMode.values()) System.out.println(c);
public static FlowControlMode valueOf(String name)
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant with the specified nameNullPointerException - if the argument is nullCopyright © 2021 Couchbase, Inc.. All rights reserved.