Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[RCI] Add IndexShardOperationPermits.asyncBlockOperations(ActionListener<Releasable>) #34902

Merged
merged 4 commits into from
Nov 8, 2018

Commits on Nov 7, 2018

  1. [RCI] Add IndexShardOperationPermits.asyncBlockOperations(ActionListe…

    …ner<Releasable>)
    
    The current implementation of asyncBlockOperations() can be used to
    execute some code once all indexing operations permits have been acquired,
     then releases all permits immediately after the code execution. This
     immediate release is not suitable for treatments that need to keep all
     permits over multiple execution steps.
    
    This commit adds a new asyncBlockOperations() that exposes a Releasable,
     making it possible to acquire all permits and only release them all
     when needed by closing the Releasable.
    
    This method is aimed to be used in a TransportReplicationAction that
     will acquire all permits on the primary shard.
    
    The existing blockOperations() and asyncBlockOperations() methods have
    been modified to delegate permit acquisition/releasing to this new
    method.
    
    Relates to elastic#33888
    tlrx committed Nov 7, 2018
    Configuration menu
    Copy the full SHA
    4d792af View commit details
    Browse the repository at this point in the history
  2. Apply feedback

    tlrx committed Nov 7, 2018
    Configuration menu
    Copy the full SHA
    b15647b View commit details
    Browse the repository at this point in the history
  3. Apply feedback

    tlrx committed Nov 7, 2018
    Configuration menu
    Copy the full SHA
    ef1a506 View commit details
    Browse the repository at this point in the history
  4. throw new AssertionError(e);

    tlrx committed Nov 7, 2018
    Configuration menu
    Copy the full SHA
    338b6ae View commit details
    Browse the repository at this point in the history