public class ReadAllOptions
extends java.lang.Object
| Modifier and Type | Method and Description |
|---|---|
T |
authenticated(java.lang.String login,
java.lang.String password)
Sets user credentials for the request
|
T |
authenticated(UserCredentials credentials)
Sets user credentials for the request
|
ReadAllOptions |
backwards()
Reads stream in revision-descending order.
|
T |
batchSize(int batchSize)
The maximum number of events to read from the server at the time.
|
T |
deadline(long durationInMs)
A length of time (in milliseconds) to use for gRPC deadlines.
|
ReadAllOptions |
direction(Direction direction)
Reads stream in the given direction.
|
ReadAllOptions |
forwards()
Reads stream in revision-ascending order.
|
T |
fromEnd()
Starts from the end of the $all stream.
|
T |
fromPosition(Position position)
Starts from the given transaction log position.
|
T |
fromStart()
Starts from the beginning of the $all stream.
|
static ReadAllOptions |
get()
Returns options with default values.
|
T |
header(java.lang.String key,
java.lang.String value)
Adds a custom HTTP header that will be added to the request.
|
ReadAllOptions |
maxCount(long maxCount)
The maximum event count KurrentDB will return.
|
T |
notRequireLeader()
Do not require the request to be performed by the leader of the cluster.
|
T |
notResolveLinkTos()
Don't resolve linkTo events to their linked events.
|
T |
requiresLeader()
Requires the request to be performed by the leader of the cluster.
|
T |
requiresLeader(boolean value)
If true, requires the request to be performed by the leader of the cluster.
|
T |
resolveLinkTos()
Resolve linkTo events to their linked events.
|
T |
resolveLinkTos(boolean value)
Whether the subscription should resolve linkTo events to their linked events.
|
T |
thresholdRatio(float ratio)
The ratio of the batch size at which more events should be requested from the server.
|
public static ReadAllOptions get()
public ReadAllOptions direction(Direction direction)
public ReadAllOptions forwards()
public ReadAllOptions backwards()
public ReadAllOptions maxCount(long maxCount)
public T fromStart()
public T fromEnd()
public T fromPosition(Position position)
position - transaction log position.public T batchSize(int batchSize)
public T thresholdRatio(float ratio)
public T resolveLinkTos(boolean value)
public T resolveLinkTos()
public T notResolveLinkTos()
public T authenticated(UserCredentials credentials)
credentials - UserCredentialspublic T authenticated(java.lang.String login,
java.lang.String password)
login - password - public T requiresLeader()
public T notRequireLeader()
public T requiresLeader(boolean value)
value - public T deadline(long durationInMs)
durationInMs - public T header(java.lang.String key,
java.lang.String value)