Package io.temporal.spring.boot
Interface WorkerOptionsCustomizer
-
- All Superinterfaces:
TemporalOptionsCustomizer<io.temporal.worker.WorkerOptions.Builder>
public interface WorkerOptionsCustomizer extends TemporalOptionsCustomizer<io.temporal.worker.WorkerOptions.Builder>
Bean of this class can be added to Spring context to get a fine control over WorkerOptions objects that are created by Temporal Spring Boot Autoconfigure module.Only one bean of this or
TemporalOptionsCustomizer<WorkerOptions.Builder>
type can be added to Spring context.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default io.temporal.worker.WorkerOptions.Builder
customize(io.temporal.worker.WorkerOptions.Builder optionsBuilder)
This method can modify some fields of the provided builder or create a new builder altogether and return it back to be used.io.temporal.worker.WorkerOptions.Builder
customize(io.temporal.worker.WorkerOptions.Builder optionsBuilder, java.lang.String workerName, java.lang.String taskQueue)
This method can modify some fields of the providedWorkerOptions.Builder
or create a new builder altogether and return it back to be used.
-
-
-
Method Detail
-
customize
@Nonnull default io.temporal.worker.WorkerOptions.Builder customize(@Nonnull io.temporal.worker.WorkerOptions.Builder optionsBuilder)
Description copied from interface:TemporalOptionsCustomizer
This method can modify some fields of the provided builder or create a new builder altogether and return it back to be used. This method is called after the*Options.Builder
is initialized by the Temporal Spring Boot module, so changes done by this method will override Spring Boot configuration values.- Specified by:
customize
in interfaceTemporalOptionsCustomizer<io.temporal.worker.WorkerOptions.Builder>
- Parameters:
optionsBuilder
-*Options.Builder
to customize- Returns:
- modified
optionsBuilder
or a new builder to be used by the caller code.
-
customize
@Nonnull io.temporal.worker.WorkerOptions.Builder customize(@Nonnull io.temporal.worker.WorkerOptions.Builder optionsBuilder, @Nonnull java.lang.String workerName, @Nonnull java.lang.String taskQueue)
This method can modify some fields of the providedWorkerOptions.Builder
or create a new builder altogether and return it back to be used. This method is called after theWorkerOptions.Builder
is initialized by the Temporal Spring Boot module, so changes done by this method will override Spring Boot configuration values.- Parameters:
optionsBuilder
-*Options.Builder
to customizeworkerName
- name of a Worker that will be created using theWorkerOptions
produced by this calltaskQueue
- Task Queue of a Worker that will be created using theWorkerOptions
produced by this call- Returns:
- modified
optionsBuilder
or a new builder instance to be used by the caller code
-
-