Search Results for

    Show / Hide Table of Contents

    Interface IReindexRequest<TSource, TTarget>

    A reindex implementation that uses ScrollAll() BulkAll() to compose a reindex pipeline.

    This differs from ReindexOnServer() in that documents are fetched from OpenSearch, transformed on the client side, then sent back to OpenSearch.

    This will create the target index if it doesn't exist already. If CreateIndexRequest is not specified and the source of the reindex points to a single index we try and reuse the settings from source. You can completely opt out of all of this using OmitIndexCreation

    Namespace: OpenSearch.Client
    Assembly: OpenSearch.Client.dll
    Syntax
    public interface IReindexRequest<TSource, TTarget> where TSource : class where TTarget : class
    Type Parameters
    Name Description
    TSource
    TTarget

    Properties

    | Edit this page View Source

    BackPressureFactor

    The scroll typically outperforms the bulk operations by a long shot. If we'd leave things unbounded you'd quickly have way too many pending scroll requests. What this property allows you to express is that for each bucket in the max concurrency of the minimum max concurrency between producer and consumer amply the maximum overal pending of the other side by this factor. Typically the concurrency of the consumer (bulkall) will be lower and with this factor we can dampen the overall pending scroll requests while we are still processing bulk requests.

    defaults to 4 if not provided

    Declaration
    int? BackPressureFactor { get; set; }
    Property Value
    Type Description
    int?
    | Edit this page View Source

    BulkAll

    Provide a factory for the bulk all request, the first argument is the lazy collection of scroll results which is a mandatory argument to create BulkAllRequest<T> or BulkAllDescriptor<T>

    Note that BufferToBulk is always overriden as well as BackPressure

    Declaration
    Func<IEnumerable<IHitMetadata<TTarget>>, IBulkAllRequest<IHitMetadata<TTarget>>> BulkAll { get; set; }
    Property Value
    Type Description
    Func<IEnumerable<IHitMetadata<TTarget>>, IBulkAllRequest<IHitMetadata<TTarget>>>
    | Edit this page View Source

    CreateIndexRequest

    Describe how the newly created index should be created. Remember you can also register Index Templates for more dynamic usecases.

    Declaration
    ICreateIndexRequest CreateIndexRequest { get; set; }
    Property Value
    Type Description
    ICreateIndexRequest
    | Edit this page View Source

    Map

    Declaration
    Func<TSource, TTarget> Map { get; set; }
    Property Value
    Type Description
    Func<TSource, TTarget>
    | Edit this page View Source

    OmitIndexCreation

    Do not send a create index call on the target index, assume the index has been created outside of the reindex. Reindex will never create the index if it already exists however this will also omit the IndexExists call.

    Declaration
    bool OmitIndexCreation { get; set; }
    Property Value
    Type Description
    bool
    | Edit this page View Source

    ScrollAll

    Describes the scroll operation where we need to fetch the documents from.

    Note that BackPressure can be overriden by our own.

    Declaration
    IScrollAllRequest ScrollAll { get; set; }
    Property Value
    Type Description
    IScrollAllRequest

    Extension Methods

    SuffixExtensions.Suffix(object, string)
    • Edit this page
    • View Source
    In this article
    • Properties
      • BackPressureFactor
      • BulkAll
      • CreateIndexRequest
      • Map
      • OmitIndexCreation
      • ScrollAll
    • Extension Methods
    Back to top Generated by DocFX