Class PipelineDefinitionMergeUtil

java.lang.Object
com.lucidworks.apollo.pipeline.PipelineDefinitionMergeUtil

public class PipelineDefinitionMergeUtil extends Object
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static <T extends com.lucidworks.apollo.pipeline.PipelineDefinition<T>>
    void
    clearRedactionFromPipeline(T targetPipeline, com.lucidworks.apollo.pipeline.schema.SchemaProcessorFactory schemaProcessorFactory)
    Traverse a Pipeline's stages and their properties, removing "xXx-Redacted-xXx" as they are found.
    static <T extends com.lucidworks.apollo.pipeline.PipelineDefinition<T>>
    T
    copyPipelineSecretsFromOldSelf(T oldPipeline, T newPipeline)
    Traverse into the Pipeline's stages and copy secrets over from an existing copy.
    static <T extends com.lucidworks.apollo.pipeline.PipelineDefinition<T>>
    T
    copyPipelineSecretsFromOldSelf(T oldPipeline, T newPipeline, com.fasterxml.jackson.databind.ObjectMapper mapper)
     
    static <T extends com.lucidworks.apollo.pipeline.PipelineDefinition<T>>
    void
    copySecretsFromOther(T sourcePipeline, T targetPipeline)
    Copy decrypted secrets from one pipelines to another.
    static <T extends com.lucidworks.apollo.pipeline.PipelineDefinition<T>>
    void
    copySecretsFromOther(T sourcePipeline, T targetPipeline, com.fasterxml.jackson.databind.ObjectMapper mapper, com.lucidworks.apollo.pipeline.schema.SchemaProcessorFactory schemaProcessorFactory)
     
    static void
    copyStageSecretsFromOldSelf(com.fasterxml.jackson.databind.node.ObjectNode oldNode, com.fasterxml.jackson.databind.node.ObjectNode newNode)
    Copy the secrets from oldNode onto newNode, recursively.
    static <T extends com.lucidworks.apollo.pipeline.PipelineDefinition<T>>
    Map<String,com.lucidworks.apollo.pipeline.StageConfig>
    stagesAsMap(T pipeline)
    Index StageConfigs into a Map for easy lookup

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • PipelineDefinitionMergeUtil

      public PipelineDefinitionMergeUtil()
  • Method Details

    • stagesAsMap

      public static <T extends com.lucidworks.apollo.pipeline.PipelineDefinition<T>> Map<String,com.lucidworks.apollo.pipeline.StageConfig> stagesAsMap(T pipeline)
      Index StageConfigs into a Map for easy lookup
      Parameters:
      pipeline -
      Returns:
    • copyStageSecretsFromOldSelf

      public static void copyStageSecretsFromOldSelf(com.fasterxml.jackson.databind.node.ObjectNode oldNode, com.fasterxml.jackson.databind.node.ObjectNode newNode)
      Copy the secrets from oldNode onto newNode, recursively. newNode is modified in place
      Parameters:
      oldNode - The "old" version of this object, typically whatever is persisted
      newNode - The "new" version of this object, typically coming from the API
    • copyPipelineSecretsFromOldSelf

      public static <T extends com.lucidworks.apollo.pipeline.PipelineDefinition<T>> T copyPipelineSecretsFromOldSelf(T oldPipeline, T newPipeline)
      Traverse into the Pipeline's stages and copy secrets over from an existing copy. This methods creates a new PipelineDefinition instance
      Parameters:
      oldPipeline - the "old" version of the pipeline, typically whatever is persisted
      newPipeline - the "new" version of the pipeline, typically from the API
    • copyPipelineSecretsFromOldSelf

      public static <T extends com.lucidworks.apollo.pipeline.PipelineDefinition<T>> T copyPipelineSecretsFromOldSelf(T oldPipeline, T newPipeline, com.fasterxml.jackson.databind.ObjectMapper mapper)
    • copySecretsFromOther

      public static <T extends com.lucidworks.apollo.pipeline.PipelineDefinition<T>> void copySecretsFromOther(@Nullable T sourcePipeline, T targetPipeline)
      Copy decrypted secrets from one pipelines to another. The target stage must have an extra "secretSourceStageId" property which must match the stage ID of the source pipeline stage
      Parameters:
      sourcePipeline - Pipeline to source secrets from
      targetPipeline - Pipeline to copy secrets into
    • copySecretsFromOther

      public static <T extends com.lucidworks.apollo.pipeline.PipelineDefinition<T>> void copySecretsFromOther(@Nullable T sourcePipeline, T targetPipeline, com.fasterxml.jackson.databind.ObjectMapper mapper, com.lucidworks.apollo.pipeline.schema.SchemaProcessorFactory schemaProcessorFactory)
    • clearRedactionFromPipeline

      public static <T extends com.lucidworks.apollo.pipeline.PipelineDefinition<T>> void clearRedactionFromPipeline(T targetPipeline, com.lucidworks.apollo.pipeline.schema.SchemaProcessorFactory schemaProcessorFactory)
      Traverse a Pipeline's stages and their properties, removing "xXx-Redacted-xXx" as they are found. The pipeline is modified in place This prevents the redacted string from being persisted in cases where the secrets copying or merging have missed any.
      Parameters:
      targetPipeline -