Compute V1 Client - Class HttpFaultDelay (1.29.0)

Reference documentation and code samples for the Compute V1 Client class HttpFaultDelay.

Specifies the delay introduced by the load balancer before forwarding the request to the backend service as part of fault injection.

Generated from protobuf message google.cloud.compute.v1.HttpFaultDelay

Namespace

Google \ Cloud \ Compute \ V1

Methods

__construct

Constructor.

Parameters
NameDescription
dataarray

Optional. Data for populating the Message object.

↳ fixed_delayDuration

Specifies the value of the fixed delay interval.

↳ percentagefloat

The percentage of traffic for connections, operations, or requests for which a delay is introduced as part of fault injection. The value must be from 0.0 to 100.0 inclusive.

getFixedDelay

Specifies the value of the fixed delay interval.

Returns
TypeDescription
Duration|null

hasFixedDelay

clearFixedDelay

setFixedDelay

Specifies the value of the fixed delay interval.

Parameter
NameDescription
varDuration
Returns
TypeDescription
$this

getPercentage

The percentage of traffic for connections, operations, or requests for which a delay is introduced as part of fault injection. The value must be from 0.0 to 100.0 inclusive.

Returns
TypeDescription
float

hasPercentage

clearPercentage

setPercentage

The percentage of traffic for connections, operations, or requests for which a delay is introduced as part of fault injection. The value must be from 0.0 to 100.0 inclusive.

Parameter
NameDescription
varfloat
Returns
TypeDescription
$this