public static class AxonServerEventScheduler.Builder extends Object
AxonServerEventScheduler
.
The requestTimeout
is defaulted to 15000
millis.
The Serializer
and AxonServerConnectionManager
are hard requirements and as such should be
provided.
Constructor and Description |
---|
Builder() |
Modifier and Type | Method and Description |
---|---|
AxonServerEventScheduler |
build()
Initializes a
AxonServerEventScheduler as specified through this Builder. |
AxonServerEventScheduler.Builder |
connectionManager(AxonServerConnectionManager axonServerConnectionManager)
Sets the
AxonServerConnectionManager used to create connections between this application and an Axon
Server instance. |
AxonServerEventScheduler.Builder |
defaultContext(String defaultContext)
Sets the default context for this event scheduler to connect to.
|
AxonServerEventScheduler.Builder |
eventSerializer(Serializer eventSerializer)
Sets the
Serializer used to de-/serialize events. |
AxonServerEventScheduler.Builder |
requestTimeout(long timeout,
TimeUnit unit)
Sets the timeout in which a confirmation of the scheduling interaction is expected.
|
protected void |
validate() |
public AxonServerEventScheduler.Builder requestTimeout(long timeout, TimeUnit unit)
timeout
- the time to wait at most for a confirmationunit
- the unit in which the timeout is expressedpublic AxonServerEventScheduler.Builder eventSerializer(Serializer eventSerializer)
Serializer
used to de-/serialize events.eventSerializer
- a Serializer
used to de-/serialize eventspublic AxonServerEventScheduler.Builder connectionManager(AxonServerConnectionManager axonServerConnectionManager)
AxonServerConnectionManager
used to create connections between this application and an Axon
Server instance.axonServerConnectionManager
- an AxonServerConnectionManager
used to create connections between
this application and an Axon Server instancepublic AxonServerEventScheduler.Builder defaultContext(String defaultContext)
defaultContext
- for this scheduler to connect to.public AxonServerEventScheduler build()
AxonServerEventScheduler
as specified through this Builder.AxonServerEventScheduler
as specified through this Builderprotected void validate() throws AxonConfigurationException
AxonConfigurationException
Copyright © 2010–2024. All rights reserved.