Class RetryableIndexQueryAction<Q extends InternalQuery<?,Q>,T>  
Instances of this class are created via RetryHelper.accountIndexQuery(String, IndexQueryAction) and RetryHelper.changeIndexQuery(String, IndexQueryAction).
 
In contrast to normal RetryableAction.Actions that are called via RetryableAction RetryableIndexQueryAction.IndexQueryActions get a InternalQuery provided.
 
In addition when an index query action is called any exception that is not an unchecked
 exception gets wrapped into an StorageException.
- 
Nested Class SummaryNested ClassesModifier and TypeClassDescriptionstatic interfaceNested classes/interfaces inherited from class com.google.gerrit.server.update.RetryableActionRetryableAction.Action<T>, RetryableAction.ActionType
- 
Method SummaryModifier and TypeMethodDescriptioncall()Executes this action with retry.defaultTimeoutMultiplier(int multiplier) Increases the default timeout by the given multiplier.listener(com.github.rholder.retry.RetryListener retryListener) Sets a listener that is invoked when the action is retried.onAutoTrace(Consumer<String> traceIdConsumer) Sets a callback that is invoked when auto-retry with tracing is triggered.Adds an additional condition that should trigger retries.retryWithTrace(Predicate<Throwable> exceptionPredicate) Sets a condition that should trigger auto-retry with tracing.
- 
Method Details- 
retryOnDescription copied from class:RetryableActionAdds an additional condition that should trigger retries.For some exceptions retrying is enabled globally (see ExceptionHook.shouldRetry(String, String, Throwable)). Conditions for those exceptions do not need to be specified here again.This method can be invoked multiple times to add further conditions that should trigger retries. - Overrides:
- retryOnin class- RetryableAction<T>
- Parameters:
- exceptionPredicate- predicate that decides if the action should be retried for a given exception
- Returns:
- this instance to enable chaining of calls
 
- 
retryWithTraceDescription copied from class:RetryableActionSets a condition that should trigger auto-retry with tracing.This condition is only relevant if an exception occurs that doesn't trigger (normal) retry. Auto-retry with tracing automatically captures traces for unexpected exceptions so that they can be investigated. Every call of this method overwrites any previously set condition for auto-retry with tracing. - Overrides:
- retryWithTracein class- RetryableAction<T>
- Parameters:
- exceptionPredicate- predicate that decides if the action should be retried with tracing for a given exception
- Returns:
- this instance to enable chaining of calls
 
- 
onAutoTraceDescription copied from class:RetryableActionSets a callback that is invoked when auto-retry with tracing is triggered.Via the callback callers can find out with trace ID was used for the retry. Every call of this method overwrites any previously set trace ID consumer. - Overrides:
- onAutoTracein class- RetryableAction<T>
- Parameters:
- traceIdConsumer- trace ID consumer
- Returns:
- this instance to enable chaining of calls
 
- 
listenerpublic RetryableIndexQueryAction<Q,T> listener(com.github.rholder.retry.RetryListener retryListener) Description copied from class:RetryableActionSets a listener that is invoked when the action is retried.Every call of this method overwrites any previously set listener. - Overrides:
- listenerin class- RetryableAction<T>
- Parameters:
- retryListener- retry listener
- Returns:
- this instance to enable chaining of calls
 
- 
defaultTimeoutMultiplierDescription copied from class:RetryableActionIncreases the default timeout by the given multiplier.Every call of this method overwrites any previously set timeout. - Overrides:
- defaultTimeoutMultiplierin class- RetryableAction<T>
- Parameters:
- multiplier- multiplier for the default timeout
- Returns:
- this instance to enable chaining of calls
 
- 
callDescription copied from class:RetryableActionExecutes this action with retry.- Overrides:
- callin class- RetryableAction<T>
- Returns:
- the result of the action
 
 
-