public final class SubscriberShutdownSettingsSettings for configuring the shutdown behavior of a Subscriber.
This class allows customization of how the subscriber handles outstanding messages during shutdown, including whether to wait for processing to complete or to immediately nack messages, and an optional timeout for the shutdown process.
Static Methods
newBuilder()
public static SubscriberShutdownSettings.Builder newBuilder()Returns a new builder for SubscriberShutdownSettings.
| Returns | |
|---|---|
| Type | Description |
SubscriberShutdownSettings.Builder |
|
Methods
getMode()
public SubscriberShutdownSettings.ShutdownMode getMode()Returns the configured shutdown mode.
| Returns | |
|---|---|
| Type | Description |
SubscriberShutdownSettings.ShutdownMode |
|
getTimeout()
public Duration getTimeout()Returns the configured shutdown timeout. A negative duration indicates no timeout.
| Returns | |
|---|---|
| Type | Description |
Duration |
|