Interface WorkflowClientPlugin

  • All Known Implementing Classes:
    SimplePlugin

    @Experimental
    public interface WorkflowClientPlugin
    Plugin interface for customizing Temporal workflow client configuration.

    This interface is separate from io.temporal.serviceclient.WorkflowServiceStubs.ServiceStubsPlugin to allow plugins that only need to configure the workflow client without affecting the underlying gRPC connection.

    Plugins that implement both ServiceStubsPlugin and WorkflowClientPlugin will have their service stubs configuration applied when creating the service stubs, and their client configuration applied when creating the workflow client.

    Plugins that also implement WorkerPlugin are automatically propagated from the client to workers created from that client.

    Example implementation:

    {@code
     public class LoggingPlugin extends SimplePlugin {
         public LoggingPlugin() {
             super("my-org.logging");
         }
    See Also:
    io.temporal.serviceclient.WorkflowServiceStubs.ServiceStubsPlugin, WorkerPlugin, SimplePlugin
    • Method Detail

      • getName

        @Nonnull
        java.lang.String getName()
        Returns a unique name for this plugin. Used for logging and duplicate detection. Recommended format: "organization.plugin-name" (e.g., "io.temporal.tracing")
        Returns:
        fully qualified plugin name
      • configureWorkflowClient

        void configureWorkflowClient​(@Nonnull
                                     WorkflowClientOptions.Builder builder)
        Allows the plugin to modify workflow client options before the client is created. Called during configuration phase in forward (registration) order.
        Parameters:
        builder - the options builder to modify