public sealed class PollSettings
Settings controlling repeated polling, for example when waiting for a long-running operation to complete.
Namespace
GoogleGoogle.ApiGaxAssembly
Google.Api.Gax.dll
Constructors
PollSettings(Expiration, TimeSpan)
public PollSettings(Expiration expiration, TimeSpan delay)
Creates poll settings from the given expiration and constant delay.
Parameters | |
---|---|
Name | Description |
expiration | Expiration The expiration to use in order to know when to stop polling. Must not be null. |
delay | TimeSpan The constant delay between RPC calls. Must be non-negative. |
PollSettings(Expiration, TimeSpan, double, TimeSpan)
public PollSettings(Expiration expiration, TimeSpan delay, double delayMultiplier, TimeSpan maxDelay)
Creates poll settings from the given expiration, delay, delay multiplier and maximum delay.
Parameters | |
---|---|
Name | Description |
expiration | Expiration The expiration to use in order to know when to stop polling. Must not be null. |
delay | TimeSpan The delay between RPC calls. Must be non-negative. |
delayMultiplier | double The multiplier to apply to the delay on each iteration; must be greater or equal to 1.0. |
maxDelay | TimeSpan The maximum delay to use. |
Properties
Delay
public TimeSpan Delay { get; }
The delay between RPC calls when fetching the operation status. This is never negative. There is no exponential backoff between calls; the same delay is used for each call.
Property Value | |
---|---|
Type | Description |
TimeSpan |
This is the delay between the a successful RPC response being received and the next RPC request being sent.
DelayMultiplier
public double DelayMultiplier { get; }
The multiplier to apply to the delay on each iteration; must be greater or equal to 1.0.
Property Value | |
---|---|
Type | Description |
double |
Expiration
public Expiration Expiration { get; }
How long to wait before giving up. This is never null.
Property Value | |
---|---|
Type | Description |
Expiration |
MaxDelay
public TimeSpan MaxDelay { get; }
The maximum delay to use. If the increasing delay due to the delay multiplier exceeds this, this maximum is used instead.
Property Value | |
---|---|
Type | Description |
TimeSpan |