Package io.pravega.client.stream
Class EventWriterConfig.EventWriterConfigBuilder
- java.lang.Object
-
- io.pravega.client.stream.EventWriterConfig.EventWriterConfigBuilder
-
- Enclosing class:
- EventWriterConfig
public static final class EventWriterConfig.EventWriterConfigBuilder extends java.lang.Object
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description EventWriterConfig.EventWriterConfigBuilder
automaticallyNoteTime(boolean automaticallyNoteTime)
Automatically invokeEventStreamWriter.noteTime(long)
passingSystem.currentTimeMillis()
on a regular interval.EventWriterConfig.EventWriterConfigBuilder
backoffMultiple(int backoffMultiple)
Backoff multiplier used in the retry logic of the writer.EventWriterConfig
build()
EventWriterConfig.EventWriterConfigBuilder
enableConnectionPooling(boolean enableConnectionPooling)
Enable or disable connection pooling for writer.EventWriterConfig.EventWriterConfigBuilder
initialBackoffMillis(int initialBackoffMillis)
Initial backoff in milli seconds used in the retry logic of the writer.EventWriterConfig.EventWriterConfigBuilder
maxBackoffMillis(int maxBackoffMillis)
Maximum backoff in milli seconds used in the retry logic of the writer.EventWriterConfig.EventWriterConfigBuilder
retryAttempts(int retryAttempts)
Maximum retry attempts performed by the writer before throwing aRetriesExhaustedException
.java.lang.String
toString()
EventWriterConfig.EventWriterConfigBuilder
transactionTimeoutTime(long transactionTimeoutTime)
-
-
-
Method Detail
-
build
public EventWriterConfig build()
-
initialBackoffMillis
public EventWriterConfig.EventWriterConfigBuilder initialBackoffMillis(int initialBackoffMillis)
Initial backoff in milli seconds used in the retry logic of the writer. The default value is 1ms.- Parameters:
initialBackoffMillis
- Initial backoff in milli seconds in the retry logic of the writer.- Returns:
this
.
-
maxBackoffMillis
public EventWriterConfig.EventWriterConfigBuilder maxBackoffMillis(int maxBackoffMillis)
Maximum backoff in milli seconds used in the retry logic of the writer. The default value is 20000.- Parameters:
maxBackoffMillis
- Maximum backoff in milli seconds used in the retry logic of the writer.- Returns:
this
.
-
retryAttempts
public EventWriterConfig.EventWriterConfigBuilder retryAttempts(int retryAttempts)
Maximum retry attempts performed by the writer before throwing aRetriesExhaustedException
. The default value is 10.- Parameters:
retryAttempts
- Maximum retry attempts performed by the writer before throwing aRetriesExhaustedException
.- Returns:
this
.
-
backoffMultiple
public EventWriterConfig.EventWriterConfigBuilder backoffMultiple(int backoffMultiple)
Backoff multiplier used in the retry logic of the writer. The default value is 10.- Parameters:
backoffMultiple
- Backoff multiplier used in the retry logic of the writer.- Returns:
this
.
-
enableConnectionPooling
public EventWriterConfig.EventWriterConfigBuilder enableConnectionPooling(boolean enableConnectionPooling)
Enable or disable connection pooling for writer. The default value is false.- Parameters:
enableConnectionPooling
- Enable or disable connection pooling for writer.- Returns:
this
.
-
transactionTimeoutTime
public EventWriterConfig.EventWriterConfigBuilder transactionTimeoutTime(long transactionTimeoutTime)
-
automaticallyNoteTime
public EventWriterConfig.EventWriterConfigBuilder automaticallyNoteTime(boolean automaticallyNoteTime)
Automatically invokeEventStreamWriter.noteTime(long)
passingSystem.currentTimeMillis()
on a regular interval.- Parameters:
automaticallyNoteTime
- Interval to regularly invokeEventStreamWriter.noteTime(long)
.- Returns:
this
.
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-