Class PulsarReaderContainerProperties
java.lang.Object
org.springframework.pulsar.reader.PulsarReaderContainerProperties
Container properties for Pulsar
Reader
.- Author:
- Soby Chacko
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionorg.springframework.retry.support.RetryTemplate
Get the default template to use to retry startup when no custom retry template has been specified.org.apache.pulsar.client.api.Schema<?>
org.apache.pulsar.common.schema.SchemaType
org.apache.pulsar.client.api.MessageId
org.springframework.retry.support.RetryTemplate
void
setReaderListener
(Object readerListener) void
setReaderStartTimeout
(Duration readerStartTimeout) Set the timeout to wait for a reader thread to start before logging an error.void
setReaderTaskExecutor
(AsyncTaskExecutor readerExecutor) void
setSchema
(org.apache.pulsar.client.api.Schema<?> schema) void
setSchemaResolver
(SchemaResolver schemaResolver) void
setSchemaType
(org.apache.pulsar.common.schema.SchemaType schemaType) void
setStartMessageId
(org.apache.pulsar.client.api.MessageId startMessageId) void
setStartupFailurePolicy
(StartupFailurePolicy startupFailurePolicy) The action to take on the container when a failure occurs during startup.void
setStartupFailureRetryTemplate
(org.springframework.retry.support.RetryTemplate startupFailureRetryTemplate) Set the template to use to retry startup when an exception occurs during startup.void
-
Constructor Details
-
PulsarReaderContainerProperties
public PulsarReaderContainerProperties()
-
-
Method Details
-
getReaderListener
-
setReaderListener
-
getReaderTaskExecutor
-
setReaderTaskExecutor
-
getReaderStartTimeout
-
setReaderStartTimeout
Set the timeout to wait for a reader thread to start before logging an error. Default 30 seconds.- Parameters:
readerStartTimeout
- the reader start timeout.
-
getTopics
-
setTopics
-
getStartMessageId
public org.apache.pulsar.client.api.MessageId getStartMessageId() -
setStartMessageId
public void setStartMessageId(org.apache.pulsar.client.api.MessageId startMessageId) -
getSchema
public org.apache.pulsar.client.api.Schema<?> getSchema() -
setSchema
public void setSchema(org.apache.pulsar.client.api.Schema<?> schema) -
getSchemaType
public org.apache.pulsar.common.schema.SchemaType getSchemaType() -
setSchemaType
public void setSchemaType(org.apache.pulsar.common.schema.SchemaType schemaType) -
getSchemaResolver
-
setSchemaResolver
-
getStartupFailureRetryTemplate
-
getDefaultStartupFailureRetryTemplate
public org.springframework.retry.support.RetryTemplate getDefaultStartupFailureRetryTemplate()Get the default template to use to retry startup when no custom retry template has been specified.- Returns:
- the default retry template that will retry 3 times with a fixed delay of 10 seconds between each attempt.
- Since:
- 1.2.0
-
setStartupFailureRetryTemplate
public void setStartupFailureRetryTemplate(org.springframework.retry.support.RetryTemplate startupFailureRetryTemplate) Set the template to use to retry startup when an exception occurs during startup.- Parameters:
startupFailureRetryTemplate
- the retry template to use- Since:
- 1.2.0
-
getStartupFailurePolicy
-
setStartupFailurePolicy
The action to take on the container when a failure occurs during startup.- Parameters:
startupFailurePolicy
- action to take when a failure occurs during startup- Since:
- 1.2.0
-