Class: Google::Cloud::NetworkServices::V1::ServiceLbPolicy

Inherits:
Object
  • Object
show all
Extended by:
Protobuf::MessageExts::ClassMethods
Includes:
Protobuf::MessageExts
Defined in:
proto_docs/google/cloud/networkservices/v1/service_lb_policy.rb

Overview

ServiceLbPolicy holds global load balancing and traffic distribution configuration that can be applied to a BackendService.

Defined Under Namespace

Modules: IsolationGranularity, IsolationMode, LoadBalancingAlgorithm Classes: AutoCapacityDrain, FailoverConfig, IsolationConfig, LabelsEntry

Instance Attribute Summary collapse

Instance Attribute Details

#auto_capacity_drain::Google::Cloud::NetworkServices::V1::ServiceLbPolicy::AutoCapacityDrain

Returns Optional. Configuration to automatically move traffic away for unhealthy IG/NEG for the associated Backend Service.

Returns:



58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
# File 'proto_docs/google/cloud/networkservices/v1/service_lb_policy.rb', line 58

class ServiceLbPolicy
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Option to specify if an unhealthy IG/NEG should be considered for global
  # load balancing and traffic routing.
  # @!attribute [rw] enable
  #   @return [::Boolean]
  #     Optional. If set to 'True', an unhealthy IG/NEG will be set as drained.
  #     - An IG/NEG is considered unhealthy if less than 25% of the
  #     instances/endpoints in the IG/NEG are healthy.
  #     - This option will never result in draining more than 50% of the
  #     configured IGs/NEGs for the Backend Service.
  class AutoCapacityDrain
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Option to specify health based failover behavior.
  # This is not related to Network load balancer FailoverPolicy.
  # @!attribute [rw] failover_health_threshold
  #   @return [::Integer]
  #     Optional. The percentage threshold that a load balancer will begin to
  #     send traffic to failover backends. If the percentage of endpoints in a
  #     MIG/NEG is smaller than this value, traffic would be sent to failover
  #     backends if possible. This field should be set to a value between 1
  #     and 99. The default value is 50 for Global external HTTP(S) load balancer
  #     (classic) and Proxyless service mesh, and 70 for others.
  class FailoverConfig
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Configuration to provide isolation support for the associated Backend
  # Service.
  # @!attribute [rw] isolation_granularity
  #   @return [::Google::Cloud::NetworkServices::V1::ServiceLbPolicy::IsolationGranularity]
  #     Optional. The isolation granularity of the load balancer.
  # @!attribute [rw] isolation_mode
  #   @return [::Google::Cloud::NetworkServices::V1::ServiceLbPolicy::IsolationMode]
  #     Optional. The isolation mode of the load balancer.
  class IsolationConfig
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::String]
  class LabelsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # The global load balancing algorithm to be used.
  module LoadBalancingAlgorithm
    # The type of the loadbalancing algorithm is unspecified.
    LOAD_BALANCING_ALGORITHM_UNSPECIFIED = 0

    # Balance traffic across all backends across the world proportionally based
    # on capacity.
    SPRAY_TO_WORLD = 3

    # Direct traffic to the nearest region with endpoints and capacity before
    # spilling over to other regions and spread the traffic from each client to
    # all the MIGs/NEGs in a region.
    SPRAY_TO_REGION = 4

    # Direct traffic to the nearest region with endpoints and capacity before
    # spilling over to other regions. All MIGs/NEGs within a region are evenly
    # loaded but each client might not spread the traffic to all the MIGs/NEGs
    # in the region.
    WATERFALL_BY_REGION = 5

    # Attempt to keep traffic in a single zone closest to the client, before
    # spilling over to other zones.
    WATERFALL_BY_ZONE = 6
  end

  # The granularity of this isolation restriction.
  module IsolationGranularity
    # No isolation is configured for the backend service. Traffic can overflow
    # based on the load balancing algorithm.
    ISOLATION_GRANULARITY_UNSPECIFIED = 0

    # Traffic for this service will be isolated at the cloud region level.
    REGION = 1
  end

  # The mode of this isolation restriction, defining whether clients in a given
  # region are allowed to reach out to another region.
  module IsolationMode
    # No isolation mode is configured for the backend service.
    ISOLATION_MODE_UNSPECIFIED = 0

    # Traffic will be sent to the nearest region.
    NEAREST = 1

    # Traffic will fail if no serving backends are available in the same region
    # as the load balancer.
    STRICT = 2
  end
end

#create_time::Google::Protobuf::Timestamp (readonly)

Returns Output only. The timestamp when this resource was created.

Returns:



58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
# File 'proto_docs/google/cloud/networkservices/v1/service_lb_policy.rb', line 58

class ServiceLbPolicy
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Option to specify if an unhealthy IG/NEG should be considered for global
  # load balancing and traffic routing.
  # @!attribute [rw] enable
  #   @return [::Boolean]
  #     Optional. If set to 'True', an unhealthy IG/NEG will be set as drained.
  #     - An IG/NEG is considered unhealthy if less than 25% of the
  #     instances/endpoints in the IG/NEG are healthy.
  #     - This option will never result in draining more than 50% of the
  #     configured IGs/NEGs for the Backend Service.
  class AutoCapacityDrain
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Option to specify health based failover behavior.
  # This is not related to Network load balancer FailoverPolicy.
  # @!attribute [rw] failover_health_threshold
  #   @return [::Integer]
  #     Optional. The percentage threshold that a load balancer will begin to
  #     send traffic to failover backends. If the percentage of endpoints in a
  #     MIG/NEG is smaller than this value, traffic would be sent to failover
  #     backends if possible. This field should be set to a value between 1
  #     and 99. The default value is 50 for Global external HTTP(S) load balancer
  #     (classic) and Proxyless service mesh, and 70 for others.
  class FailoverConfig
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Configuration to provide isolation support for the associated Backend
  # Service.
  # @!attribute [rw] isolation_granularity
  #   @return [::Google::Cloud::NetworkServices::V1::ServiceLbPolicy::IsolationGranularity]
  #     Optional. The isolation granularity of the load balancer.
  # @!attribute [rw] isolation_mode
  #   @return [::Google::Cloud::NetworkServices::V1::ServiceLbPolicy::IsolationMode]
  #     Optional. The isolation mode of the load balancer.
  class IsolationConfig
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::String]
  class LabelsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # The global load balancing algorithm to be used.
  module LoadBalancingAlgorithm
    # The type of the loadbalancing algorithm is unspecified.
    LOAD_BALANCING_ALGORITHM_UNSPECIFIED = 0

    # Balance traffic across all backends across the world proportionally based
    # on capacity.
    SPRAY_TO_WORLD = 3

    # Direct traffic to the nearest region with endpoints and capacity before
    # spilling over to other regions and spread the traffic from each client to
    # all the MIGs/NEGs in a region.
    SPRAY_TO_REGION = 4

    # Direct traffic to the nearest region with endpoints and capacity before
    # spilling over to other regions. All MIGs/NEGs within a region are evenly
    # loaded but each client might not spread the traffic to all the MIGs/NEGs
    # in the region.
    WATERFALL_BY_REGION = 5

    # Attempt to keep traffic in a single zone closest to the client, before
    # spilling over to other zones.
    WATERFALL_BY_ZONE = 6
  end

  # The granularity of this isolation restriction.
  module IsolationGranularity
    # No isolation is configured for the backend service. Traffic can overflow
    # based on the load balancing algorithm.
    ISOLATION_GRANULARITY_UNSPECIFIED = 0

    # Traffic for this service will be isolated at the cloud region level.
    REGION = 1
  end

  # The mode of this isolation restriction, defining whether clients in a given
  # region are allowed to reach out to another region.
  module IsolationMode
    # No isolation mode is configured for the backend service.
    ISOLATION_MODE_UNSPECIFIED = 0

    # Traffic will be sent to the nearest region.
    NEAREST = 1

    # Traffic will fail if no serving backends are available in the same region
    # as the load balancer.
    STRICT = 2
  end
end

#description::String

Returns Optional. A free-text description of the resource. Max length 1024 characters.

Returns:

  • (::String)

    Optional. A free-text description of the resource. Max length 1024 characters.



58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
# File 'proto_docs/google/cloud/networkservices/v1/service_lb_policy.rb', line 58

class ServiceLbPolicy
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Option to specify if an unhealthy IG/NEG should be considered for global
  # load balancing and traffic routing.
  # @!attribute [rw] enable
  #   @return [::Boolean]
  #     Optional. If set to 'True', an unhealthy IG/NEG will be set as drained.
  #     - An IG/NEG is considered unhealthy if less than 25% of the
  #     instances/endpoints in the IG/NEG are healthy.
  #     - This option will never result in draining more than 50% of the
  #     configured IGs/NEGs for the Backend Service.
  class AutoCapacityDrain
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Option to specify health based failover behavior.
  # This is not related to Network load balancer FailoverPolicy.
  # @!attribute [rw] failover_health_threshold
  #   @return [::Integer]
  #     Optional. The percentage threshold that a load balancer will begin to
  #     send traffic to failover backends. If the percentage of endpoints in a
  #     MIG/NEG is smaller than this value, traffic would be sent to failover
  #     backends if possible. This field should be set to a value between 1
  #     and 99. The default value is 50 for Global external HTTP(S) load balancer
  #     (classic) and Proxyless service mesh, and 70 for others.
  class FailoverConfig
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Configuration to provide isolation support for the associated Backend
  # Service.
  # @!attribute [rw] isolation_granularity
  #   @return [::Google::Cloud::NetworkServices::V1::ServiceLbPolicy::IsolationGranularity]
  #     Optional. The isolation granularity of the load balancer.
  # @!attribute [rw] isolation_mode
  #   @return [::Google::Cloud::NetworkServices::V1::ServiceLbPolicy::IsolationMode]
  #     Optional. The isolation mode of the load balancer.
  class IsolationConfig
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::String]
  class LabelsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # The global load balancing algorithm to be used.
  module LoadBalancingAlgorithm
    # The type of the loadbalancing algorithm is unspecified.
    LOAD_BALANCING_ALGORITHM_UNSPECIFIED = 0

    # Balance traffic across all backends across the world proportionally based
    # on capacity.
    SPRAY_TO_WORLD = 3

    # Direct traffic to the nearest region with endpoints and capacity before
    # spilling over to other regions and spread the traffic from each client to
    # all the MIGs/NEGs in a region.
    SPRAY_TO_REGION = 4

    # Direct traffic to the nearest region with endpoints and capacity before
    # spilling over to other regions. All MIGs/NEGs within a region are evenly
    # loaded but each client might not spread the traffic to all the MIGs/NEGs
    # in the region.
    WATERFALL_BY_REGION = 5

    # Attempt to keep traffic in a single zone closest to the client, before
    # spilling over to other zones.
    WATERFALL_BY_ZONE = 6
  end

  # The granularity of this isolation restriction.
  module IsolationGranularity
    # No isolation is configured for the backend service. Traffic can overflow
    # based on the load balancing algorithm.
    ISOLATION_GRANULARITY_UNSPECIFIED = 0

    # Traffic for this service will be isolated at the cloud region level.
    REGION = 1
  end

  # The mode of this isolation restriction, defining whether clients in a given
  # region are allowed to reach out to another region.
  module IsolationMode
    # No isolation mode is configured for the backend service.
    ISOLATION_MODE_UNSPECIFIED = 0

    # Traffic will be sent to the nearest region.
    NEAREST = 1

    # Traffic will fail if no serving backends are available in the same region
    # as the load balancer.
    STRICT = 2
  end
end

#failover_config::Google::Cloud::NetworkServices::V1::ServiceLbPolicy::FailoverConfig

Returns Optional. Configuration related to health based failover.

Returns:



58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
# File 'proto_docs/google/cloud/networkservices/v1/service_lb_policy.rb', line 58

class ServiceLbPolicy
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Option to specify if an unhealthy IG/NEG should be considered for global
  # load balancing and traffic routing.
  # @!attribute [rw] enable
  #   @return [::Boolean]
  #     Optional. If set to 'True', an unhealthy IG/NEG will be set as drained.
  #     - An IG/NEG is considered unhealthy if less than 25% of the
  #     instances/endpoints in the IG/NEG are healthy.
  #     - This option will never result in draining more than 50% of the
  #     configured IGs/NEGs for the Backend Service.
  class AutoCapacityDrain
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Option to specify health based failover behavior.
  # This is not related to Network load balancer FailoverPolicy.
  # @!attribute [rw] failover_health_threshold
  #   @return [::Integer]
  #     Optional. The percentage threshold that a load balancer will begin to
  #     send traffic to failover backends. If the percentage of endpoints in a
  #     MIG/NEG is smaller than this value, traffic would be sent to failover
  #     backends if possible. This field should be set to a value between 1
  #     and 99. The default value is 50 for Global external HTTP(S) load balancer
  #     (classic) and Proxyless service mesh, and 70 for others.
  class FailoverConfig
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Configuration to provide isolation support for the associated Backend
  # Service.
  # @!attribute [rw] isolation_granularity
  #   @return [::Google::Cloud::NetworkServices::V1::ServiceLbPolicy::IsolationGranularity]
  #     Optional. The isolation granularity of the load balancer.
  # @!attribute [rw] isolation_mode
  #   @return [::Google::Cloud::NetworkServices::V1::ServiceLbPolicy::IsolationMode]
  #     Optional. The isolation mode of the load balancer.
  class IsolationConfig
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::String]
  class LabelsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # The global load balancing algorithm to be used.
  module LoadBalancingAlgorithm
    # The type of the loadbalancing algorithm is unspecified.
    LOAD_BALANCING_ALGORITHM_UNSPECIFIED = 0

    # Balance traffic across all backends across the world proportionally based
    # on capacity.
    SPRAY_TO_WORLD = 3

    # Direct traffic to the nearest region with endpoints and capacity before
    # spilling over to other regions and spread the traffic from each client to
    # all the MIGs/NEGs in a region.
    SPRAY_TO_REGION = 4

    # Direct traffic to the nearest region with endpoints and capacity before
    # spilling over to other regions. All MIGs/NEGs within a region are evenly
    # loaded but each client might not spread the traffic to all the MIGs/NEGs
    # in the region.
    WATERFALL_BY_REGION = 5

    # Attempt to keep traffic in a single zone closest to the client, before
    # spilling over to other zones.
    WATERFALL_BY_ZONE = 6
  end

  # The granularity of this isolation restriction.
  module IsolationGranularity
    # No isolation is configured for the backend service. Traffic can overflow
    # based on the load balancing algorithm.
    ISOLATION_GRANULARITY_UNSPECIFIED = 0

    # Traffic for this service will be isolated at the cloud region level.
    REGION = 1
  end

  # The mode of this isolation restriction, defining whether clients in a given
  # region are allowed to reach out to another region.
  module IsolationMode
    # No isolation mode is configured for the backend service.
    ISOLATION_MODE_UNSPECIFIED = 0

    # Traffic will be sent to the nearest region.
    NEAREST = 1

    # Traffic will fail if no serving backends are available in the same region
    # as the load balancer.
    STRICT = 2
  end
end

#isolation_config::Google::Cloud::NetworkServices::V1::ServiceLbPolicy::IsolationConfig

Returns Optional. Configuration to provide isolation support for the associated Backend Service.

Returns:



58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
# File 'proto_docs/google/cloud/networkservices/v1/service_lb_policy.rb', line 58

class ServiceLbPolicy
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Option to specify if an unhealthy IG/NEG should be considered for global
  # load balancing and traffic routing.
  # @!attribute [rw] enable
  #   @return [::Boolean]
  #     Optional. If set to 'True', an unhealthy IG/NEG will be set as drained.
  #     - An IG/NEG is considered unhealthy if less than 25% of the
  #     instances/endpoints in the IG/NEG are healthy.
  #     - This option will never result in draining more than 50% of the
  #     configured IGs/NEGs for the Backend Service.
  class AutoCapacityDrain
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Option to specify health based failover behavior.
  # This is not related to Network load balancer FailoverPolicy.
  # @!attribute [rw] failover_health_threshold
  #   @return [::Integer]
  #     Optional. The percentage threshold that a load balancer will begin to
  #     send traffic to failover backends. If the percentage of endpoints in a
  #     MIG/NEG is smaller than this value, traffic would be sent to failover
  #     backends if possible. This field should be set to a value between 1
  #     and 99. The default value is 50 for Global external HTTP(S) load balancer
  #     (classic) and Proxyless service mesh, and 70 for others.
  class FailoverConfig
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Configuration to provide isolation support for the associated Backend
  # Service.
  # @!attribute [rw] isolation_granularity
  #   @return [::Google::Cloud::NetworkServices::V1::ServiceLbPolicy::IsolationGranularity]
  #     Optional. The isolation granularity of the load balancer.
  # @!attribute [rw] isolation_mode
  #   @return [::Google::Cloud::NetworkServices::V1::ServiceLbPolicy::IsolationMode]
  #     Optional. The isolation mode of the load balancer.
  class IsolationConfig
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::String]
  class LabelsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # The global load balancing algorithm to be used.
  module LoadBalancingAlgorithm
    # The type of the loadbalancing algorithm is unspecified.
    LOAD_BALANCING_ALGORITHM_UNSPECIFIED = 0

    # Balance traffic across all backends across the world proportionally based
    # on capacity.
    SPRAY_TO_WORLD = 3

    # Direct traffic to the nearest region with endpoints and capacity before
    # spilling over to other regions and spread the traffic from each client to
    # all the MIGs/NEGs in a region.
    SPRAY_TO_REGION = 4

    # Direct traffic to the nearest region with endpoints and capacity before
    # spilling over to other regions. All MIGs/NEGs within a region are evenly
    # loaded but each client might not spread the traffic to all the MIGs/NEGs
    # in the region.
    WATERFALL_BY_REGION = 5

    # Attempt to keep traffic in a single zone closest to the client, before
    # spilling over to other zones.
    WATERFALL_BY_ZONE = 6
  end

  # The granularity of this isolation restriction.
  module IsolationGranularity
    # No isolation is configured for the backend service. Traffic can overflow
    # based on the load balancing algorithm.
    ISOLATION_GRANULARITY_UNSPECIFIED = 0

    # Traffic for this service will be isolated at the cloud region level.
    REGION = 1
  end

  # The mode of this isolation restriction, defining whether clients in a given
  # region are allowed to reach out to another region.
  module IsolationMode
    # No isolation mode is configured for the backend service.
    ISOLATION_MODE_UNSPECIFIED = 0

    # Traffic will be sent to the nearest region.
    NEAREST = 1

    # Traffic will fail if no serving backends are available in the same region
    # as the load balancer.
    STRICT = 2
  end
end

#labels::Google::Protobuf::Map{::String => ::String}

Returns Optional. Set of label tags associated with the ServiceLbPolicy resource.

Returns:

  • (::Google::Protobuf::Map{::String => ::String})

    Optional. Set of label tags associated with the ServiceLbPolicy resource.



58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
# File 'proto_docs/google/cloud/networkservices/v1/service_lb_policy.rb', line 58

class ServiceLbPolicy
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Option to specify if an unhealthy IG/NEG should be considered for global
  # load balancing and traffic routing.
  # @!attribute [rw] enable
  #   @return [::Boolean]
  #     Optional. If set to 'True', an unhealthy IG/NEG will be set as drained.
  #     - An IG/NEG is considered unhealthy if less than 25% of the
  #     instances/endpoints in the IG/NEG are healthy.
  #     - This option will never result in draining more than 50% of the
  #     configured IGs/NEGs for the Backend Service.
  class AutoCapacityDrain
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Option to specify health based failover behavior.
  # This is not related to Network load balancer FailoverPolicy.
  # @!attribute [rw] failover_health_threshold
  #   @return [::Integer]
  #     Optional. The percentage threshold that a load balancer will begin to
  #     send traffic to failover backends. If the percentage of endpoints in a
  #     MIG/NEG is smaller than this value, traffic would be sent to failover
  #     backends if possible. This field should be set to a value between 1
  #     and 99. The default value is 50 for Global external HTTP(S) load balancer
  #     (classic) and Proxyless service mesh, and 70 for others.
  class FailoverConfig
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Configuration to provide isolation support for the associated Backend
  # Service.
  # @!attribute [rw] isolation_granularity
  #   @return [::Google::Cloud::NetworkServices::V1::ServiceLbPolicy::IsolationGranularity]
  #     Optional. The isolation granularity of the load balancer.
  # @!attribute [rw] isolation_mode
  #   @return [::Google::Cloud::NetworkServices::V1::ServiceLbPolicy::IsolationMode]
  #     Optional. The isolation mode of the load balancer.
  class IsolationConfig
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::String]
  class LabelsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # The global load balancing algorithm to be used.
  module LoadBalancingAlgorithm
    # The type of the loadbalancing algorithm is unspecified.
    LOAD_BALANCING_ALGORITHM_UNSPECIFIED = 0

    # Balance traffic across all backends across the world proportionally based
    # on capacity.
    SPRAY_TO_WORLD = 3

    # Direct traffic to the nearest region with endpoints and capacity before
    # spilling over to other regions and spread the traffic from each client to
    # all the MIGs/NEGs in a region.
    SPRAY_TO_REGION = 4

    # Direct traffic to the nearest region with endpoints and capacity before
    # spilling over to other regions. All MIGs/NEGs within a region are evenly
    # loaded but each client might not spread the traffic to all the MIGs/NEGs
    # in the region.
    WATERFALL_BY_REGION = 5

    # Attempt to keep traffic in a single zone closest to the client, before
    # spilling over to other zones.
    WATERFALL_BY_ZONE = 6
  end

  # The granularity of this isolation restriction.
  module IsolationGranularity
    # No isolation is configured for the backend service. Traffic can overflow
    # based on the load balancing algorithm.
    ISOLATION_GRANULARITY_UNSPECIFIED = 0

    # Traffic for this service will be isolated at the cloud region level.
    REGION = 1
  end

  # The mode of this isolation restriction, defining whether clients in a given
  # region are allowed to reach out to another region.
  module IsolationMode
    # No isolation mode is configured for the backend service.
    ISOLATION_MODE_UNSPECIFIED = 0

    # Traffic will be sent to the nearest region.
    NEAREST = 1

    # Traffic will fail if no serving backends are available in the same region
    # as the load balancer.
    STRICT = 2
  end
end

#load_balancing_algorithm::Google::Cloud::NetworkServices::V1::ServiceLbPolicy::LoadBalancingAlgorithm

Returns Optional. The type of load balancing algorithm to be used. The default behavior is WATERFALL_BY_REGION.

Returns:



58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
# File 'proto_docs/google/cloud/networkservices/v1/service_lb_policy.rb', line 58

class ServiceLbPolicy
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Option to specify if an unhealthy IG/NEG should be considered for global
  # load balancing and traffic routing.
  # @!attribute [rw] enable
  #   @return [::Boolean]
  #     Optional. If set to 'True', an unhealthy IG/NEG will be set as drained.
  #     - An IG/NEG is considered unhealthy if less than 25% of the
  #     instances/endpoints in the IG/NEG are healthy.
  #     - This option will never result in draining more than 50% of the
  #     configured IGs/NEGs for the Backend Service.
  class AutoCapacityDrain
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Option to specify health based failover behavior.
  # This is not related to Network load balancer FailoverPolicy.
  # @!attribute [rw] failover_health_threshold
  #   @return [::Integer]
  #     Optional. The percentage threshold that a load balancer will begin to
  #     send traffic to failover backends. If the percentage of endpoints in a
  #     MIG/NEG is smaller than this value, traffic would be sent to failover
  #     backends if possible. This field should be set to a value between 1
  #     and 99. The default value is 50 for Global external HTTP(S) load balancer
  #     (classic) and Proxyless service mesh, and 70 for others.
  class FailoverConfig
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Configuration to provide isolation support for the associated Backend
  # Service.
  # @!attribute [rw] isolation_granularity
  #   @return [::Google::Cloud::NetworkServices::V1::ServiceLbPolicy::IsolationGranularity]
  #     Optional. The isolation granularity of the load balancer.
  # @!attribute [rw] isolation_mode
  #   @return [::Google::Cloud::NetworkServices::V1::ServiceLbPolicy::IsolationMode]
  #     Optional. The isolation mode of the load balancer.
  class IsolationConfig
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::String]
  class LabelsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # The global load balancing algorithm to be used.
  module LoadBalancingAlgorithm
    # The type of the loadbalancing algorithm is unspecified.
    LOAD_BALANCING_ALGORITHM_UNSPECIFIED = 0

    # Balance traffic across all backends across the world proportionally based
    # on capacity.
    SPRAY_TO_WORLD = 3

    # Direct traffic to the nearest region with endpoints and capacity before
    # spilling over to other regions and spread the traffic from each client to
    # all the MIGs/NEGs in a region.
    SPRAY_TO_REGION = 4

    # Direct traffic to the nearest region with endpoints and capacity before
    # spilling over to other regions. All MIGs/NEGs within a region are evenly
    # loaded but each client might not spread the traffic to all the MIGs/NEGs
    # in the region.
    WATERFALL_BY_REGION = 5

    # Attempt to keep traffic in a single zone closest to the client, before
    # spilling over to other zones.
    WATERFALL_BY_ZONE = 6
  end

  # The granularity of this isolation restriction.
  module IsolationGranularity
    # No isolation is configured for the backend service. Traffic can overflow
    # based on the load balancing algorithm.
    ISOLATION_GRANULARITY_UNSPECIFIED = 0

    # Traffic for this service will be isolated at the cloud region level.
    REGION = 1
  end

  # The mode of this isolation restriction, defining whether clients in a given
  # region are allowed to reach out to another region.
  module IsolationMode
    # No isolation mode is configured for the backend service.
    ISOLATION_MODE_UNSPECIFIED = 0

    # Traffic will be sent to the nearest region.
    NEAREST = 1

    # Traffic will fail if no serving backends are available in the same region
    # as the load balancer.
    STRICT = 2
  end
end

#name::String

Returns Identifier. Name of the ServiceLbPolicy resource. It matches pattern projects/{project}/locations/{location}/serviceLbPolicies/{service_lb_policy_name}.

Returns:

  • (::String)

    Identifier. Name of the ServiceLbPolicy resource. It matches pattern projects/{project}/locations/{location}/serviceLbPolicies/{service_lb_policy_name}.



58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
# File 'proto_docs/google/cloud/networkservices/v1/service_lb_policy.rb', line 58

class ServiceLbPolicy
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Option to specify if an unhealthy IG/NEG should be considered for global
  # load balancing and traffic routing.
  # @!attribute [rw] enable
  #   @return [::Boolean]
  #     Optional. If set to 'True', an unhealthy IG/NEG will be set as drained.
  #     - An IG/NEG is considered unhealthy if less than 25% of the
  #     instances/endpoints in the IG/NEG are healthy.
  #     - This option will never result in draining more than 50% of the
  #     configured IGs/NEGs for the Backend Service.
  class AutoCapacityDrain
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Option to specify health based failover behavior.
  # This is not related to Network load balancer FailoverPolicy.
  # @!attribute [rw] failover_health_threshold
  #   @return [::Integer]
  #     Optional. The percentage threshold that a load balancer will begin to
  #     send traffic to failover backends. If the percentage of endpoints in a
  #     MIG/NEG is smaller than this value, traffic would be sent to failover
  #     backends if possible. This field should be set to a value between 1
  #     and 99. The default value is 50 for Global external HTTP(S) load balancer
  #     (classic) and Proxyless service mesh, and 70 for others.
  class FailoverConfig
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Configuration to provide isolation support for the associated Backend
  # Service.
  # @!attribute [rw] isolation_granularity
  #   @return [::Google::Cloud::NetworkServices::V1::ServiceLbPolicy::IsolationGranularity]
  #     Optional. The isolation granularity of the load balancer.
  # @!attribute [rw] isolation_mode
  #   @return [::Google::Cloud::NetworkServices::V1::ServiceLbPolicy::IsolationMode]
  #     Optional. The isolation mode of the load balancer.
  class IsolationConfig
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::String]
  class LabelsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # The global load balancing algorithm to be used.
  module LoadBalancingAlgorithm
    # The type of the loadbalancing algorithm is unspecified.
    LOAD_BALANCING_ALGORITHM_UNSPECIFIED = 0

    # Balance traffic across all backends across the world proportionally based
    # on capacity.
    SPRAY_TO_WORLD = 3

    # Direct traffic to the nearest region with endpoints and capacity before
    # spilling over to other regions and spread the traffic from each client to
    # all the MIGs/NEGs in a region.
    SPRAY_TO_REGION = 4

    # Direct traffic to the nearest region with endpoints and capacity before
    # spilling over to other regions. All MIGs/NEGs within a region are evenly
    # loaded but each client might not spread the traffic to all the MIGs/NEGs
    # in the region.
    WATERFALL_BY_REGION = 5

    # Attempt to keep traffic in a single zone closest to the client, before
    # spilling over to other zones.
    WATERFALL_BY_ZONE = 6
  end

  # The granularity of this isolation restriction.
  module IsolationGranularity
    # No isolation is configured for the backend service. Traffic can overflow
    # based on the load balancing algorithm.
    ISOLATION_GRANULARITY_UNSPECIFIED = 0

    # Traffic for this service will be isolated at the cloud region level.
    REGION = 1
  end

  # The mode of this isolation restriction, defining whether clients in a given
  # region are allowed to reach out to another region.
  module IsolationMode
    # No isolation mode is configured for the backend service.
    ISOLATION_MODE_UNSPECIFIED = 0

    # Traffic will be sent to the nearest region.
    NEAREST = 1

    # Traffic will fail if no serving backends are available in the same region
    # as the load balancer.
    STRICT = 2
  end
end

#update_time::Google::Protobuf::Timestamp (readonly)

Returns Output only. The timestamp when this resource was last updated.

Returns:



58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
# File 'proto_docs/google/cloud/networkservices/v1/service_lb_policy.rb', line 58

class ServiceLbPolicy
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Option to specify if an unhealthy IG/NEG should be considered for global
  # load balancing and traffic routing.
  # @!attribute [rw] enable
  #   @return [::Boolean]
  #     Optional. If set to 'True', an unhealthy IG/NEG will be set as drained.
  #     - An IG/NEG is considered unhealthy if less than 25% of the
  #     instances/endpoints in the IG/NEG are healthy.
  #     - This option will never result in draining more than 50% of the
  #     configured IGs/NEGs for the Backend Service.
  class AutoCapacityDrain
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Option to specify health based failover behavior.
  # This is not related to Network load balancer FailoverPolicy.
  # @!attribute [rw] failover_health_threshold
  #   @return [::Integer]
  #     Optional. The percentage threshold that a load balancer will begin to
  #     send traffic to failover backends. If the percentage of endpoints in a
  #     MIG/NEG is smaller than this value, traffic would be sent to failover
  #     backends if possible. This field should be set to a value between 1
  #     and 99. The default value is 50 for Global external HTTP(S) load balancer
  #     (classic) and Proxyless service mesh, and 70 for others.
  class FailoverConfig
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Configuration to provide isolation support for the associated Backend
  # Service.
  # @!attribute [rw] isolation_granularity
  #   @return [::Google::Cloud::NetworkServices::V1::ServiceLbPolicy::IsolationGranularity]
  #     Optional. The isolation granularity of the load balancer.
  # @!attribute [rw] isolation_mode
  #   @return [::Google::Cloud::NetworkServices::V1::ServiceLbPolicy::IsolationMode]
  #     Optional. The isolation mode of the load balancer.
  class IsolationConfig
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::String]
  class LabelsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # The global load balancing algorithm to be used.
  module LoadBalancingAlgorithm
    # The type of the loadbalancing algorithm is unspecified.
    LOAD_BALANCING_ALGORITHM_UNSPECIFIED = 0

    # Balance traffic across all backends across the world proportionally based
    # on capacity.
    SPRAY_TO_WORLD = 3

    # Direct traffic to the nearest region with endpoints and capacity before
    # spilling over to other regions and spread the traffic from each client to
    # all the MIGs/NEGs in a region.
    SPRAY_TO_REGION = 4

    # Direct traffic to the nearest region with endpoints and capacity before
    # spilling over to other regions. All MIGs/NEGs within a region are evenly
    # loaded but each client might not spread the traffic to all the MIGs/NEGs
    # in the region.
    WATERFALL_BY_REGION = 5

    # Attempt to keep traffic in a single zone closest to the client, before
    # spilling over to other zones.
    WATERFALL_BY_ZONE = 6
  end

  # The granularity of this isolation restriction.
  module IsolationGranularity
    # No isolation is configured for the backend service. Traffic can overflow
    # based on the load balancing algorithm.
    ISOLATION_GRANULARITY_UNSPECIFIED = 0

    # Traffic for this service will be isolated at the cloud region level.
    REGION = 1
  end

  # The mode of this isolation restriction, defining whether clients in a given
  # region are allowed to reach out to another region.
  module IsolationMode
    # No isolation mode is configured for the backend service.
    ISOLATION_MODE_UNSPECIFIED = 0

    # Traffic will be sent to the nearest region.
    NEAREST = 1

    # Traffic will fail if no serving backends are available in the same region
    # as the load balancer.
    STRICT = 2
  end
end