Class PluginUtils

java.lang.Object
io.temporal.internal.common.PluginUtils

public final class PluginUtils extends Object
Internal utilities for plugin management.
  • Method Details

    • mergePlugins

      public static <T> T[] mergePlugins(@Nullable T[] propagated, @Nullable T[] explicit, Function<T,String> nameExtractor, org.slf4j.Logger log, String propagatedSource, Class<T> pluginClass)
      Merges propagated plugins with explicitly specified plugins. Propagated plugins come first, followed by explicit plugins. Warns about duplicate plugin instances.
      Type Parameters:
      T - the plugin type
      Parameters:
      propagated - plugins propagated from a parent component (may be null or empty)
      explicit - plugins explicitly specified on this component (may be null or empty)
      nameExtractor - function to extract plugin name for logging
      log - logger for duplicate warnings
      propagatedSource - description of where propagated plugins come from (e.g., "service stubs", "client")
      Returns:
      merged array of plugins, never null