Class: Google::Apis::NetworkservicesV1beta1::HttpRouteFaultInjectionPolicyDelay

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/networkservices_v1beta1/classes.rb,
lib/google/apis/networkservices_v1beta1/representations.rb,
lib/google/apis/networkservices_v1beta1/representations.rb

Overview

Specification of how client requests are delayed as part of fault injection before being sent to a destination.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ HttpRouteFaultInjectionPolicyDelay

Returns a new instance of HttpRouteFaultInjectionPolicyDelay.



1166
1167
1168
# File 'lib/google/apis/networkservices_v1beta1/classes.rb', line 1166

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#fixed_delayString

Specify a fixed delay before forwarding the request. Corresponds to the JSON property fixedDelay

Returns:

  • (String)


1158
1159
1160
# File 'lib/google/apis/networkservices_v1beta1/classes.rb', line 1158

def fixed_delay
  @fixed_delay
end

#percentageFixnum

The percentage of traffic on which delay will be injected. The value must be between [0, 100] Corresponds to the JSON property percentage

Returns:

  • (Fixnum)


1164
1165
1166
# File 'lib/google/apis/networkservices_v1beta1/classes.rb', line 1164

def percentage
  @percentage
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1171
1172
1173
1174
# File 'lib/google/apis/networkservices_v1beta1/classes.rb', line 1171

def update!(**args)
  @fixed_delay = args[:fixed_delay] if args.key?(:fixed_delay)
  @percentage = args[:percentage] if args.key?(:percentage)
end