Struct google_api_proto::google::cloud::compute::v1::Backend

source ·
pub struct Backend {
Show 13 fields pub balancing_mode: Option<String>, pub capacity_scaler: Option<f32>, pub description: Option<String>, pub failover: Option<bool>, pub group: Option<String>, pub max_connections: Option<i32>, pub max_connections_per_endpoint: Option<i32>, pub max_connections_per_instance: Option<i32>, pub max_rate: Option<i32>, pub max_rate_per_endpoint: Option<f32>, pub max_rate_per_instance: Option<f32>, pub max_utilization: Option<f32>, pub preference: Option<String>,
}
Expand description

Message containing information of one individual backend.

Fields§

§balancing_mode: Option<String>

Specifies how to determine whether the backend of a load balancer can handle additional traffic or is fully loaded. For usage guidelines, see Connection balancing mode. Backends must use compatible balancing modes. For more information, see Supported balancing modes and target capacity settings and Restrictions and guidance for instance groups. Note: Currently, if you use the API to configure incompatible balancing modes, the configuration might be accepted even though it has no impact and is ignored. Specifically, Backend.maxUtilization is ignored when Backend.balancingMode is RATE. In the future, this incompatible combination will be rejected. Check the BalancingMode enum for the list of possible values.

§capacity_scaler: Option<f32>

A multiplier applied to the backend’s target capacity of its balancing mode. The default value is 1, which means the group serves up to 100% of its configured capacity (depending on balancingMode). A setting of 0 means the group is completely drained, offering 0% of its available capacity. The valid ranges are 0.0 and [0.1,1.0]. You cannot configure a setting larger than 0 and smaller than 0.1. You cannot configure a setting of 0 when there is only one backend attached to the backend service. Not available with backends that don’t support using a balancingMode. This includes backends such as global internet NEGs, regional serverless NEGs, and PSC NEGs.

§description: Option<String>

An optional description of this resource. Provide this property when you create the resource.

§failover: Option<bool>

This field designates whether this is a failover backend. More than one failover backend can be configured for a given BackendService.

§group: Option<String>

The fully-qualified URL of an instance group or network endpoint group (NEG) resource. To determine what types of backends a load balancer supports, see the Backend services overview. You must use the fully-qualified URL (starting with https://www.googleapis.com/) to specify the instance group or NEG. Partial URLs are not supported.

§max_connections: Option<i32>

Defines a target maximum number of simultaneous connections. For usage guidelines, see Connection balancing mode and Utilization balancing mode. Not available if the backend’s balancingMode is RATE.

§max_connections_per_endpoint: Option<i32>

Defines a target maximum number of simultaneous connections. For usage guidelines, see Connection balancing mode and Utilization balancing mode. Not available if the backend’s balancingMode is RATE.

§max_connections_per_instance: Option<i32>

Defines a target maximum number of simultaneous connections. For usage guidelines, see Connection balancing mode and Utilization balancing mode. Not available if the backend’s balancingMode is RATE.

§max_rate: Option<i32>

Defines a maximum number of HTTP requests per second (RPS). For usage guidelines, see Rate balancing mode and Utilization balancing mode. Not available if the backend’s balancingMode is CONNECTION.

§max_rate_per_endpoint: Option<f32>

Defines a maximum target for requests per second (RPS). For usage guidelines, see Rate balancing mode and Utilization balancing mode. Not available if the backend’s balancingMode is CONNECTION.

§max_rate_per_instance: Option<f32>

Defines a maximum target for requests per second (RPS). For usage guidelines, see Rate balancing mode and Utilization balancing mode. Not available if the backend’s balancingMode is CONNECTION.

§max_utilization: Option<f32>

Optional parameter to define a target capacity for the UTILIZATION balancing mode. The valid range is [0.0, 1.0]. For usage guidelines, see Utilization balancing mode.

§preference: Option<String>

This field indicates whether this backend should be fully utilized before sending traffic to backends with default preference. The possible values are: - PREFERRED: Backends with this preference level will be filled up to their capacity limits first, based on RTT. - DEFAULT: If preferred backends don’t have enough capacity, backends in this layer would be used and traffic would be assigned based on the load balancing algorithm you use. This is the default Check the Preference enum for the list of possible values.

Implementations§

source§

impl Backend

source

pub fn max_rate_per_instance(&self) -> f32

Returns the value of max_rate_per_instance, or the default value if max_rate_per_instance is unset.

source

pub fn group(&self) -> &str

Returns the value of group, or the default value if group is unset.

source

pub fn max_connections_per_instance(&self) -> i32

Returns the value of max_connections_per_instance, or the default value if max_connections_per_instance is unset.

source

pub fn max_connections(&self) -> i32

Returns the value of max_connections, or the default value if max_connections is unset.

source

pub fn max_rate_per_endpoint(&self) -> f32

Returns the value of max_rate_per_endpoint, or the default value if max_rate_per_endpoint is unset.

source

pub fn failover(&self) -> bool

Returns the value of failover, or the default value if failover is unset.

source

pub fn max_utilization(&self) -> f32

Returns the value of max_utilization, or the default value if max_utilization is unset.

source

pub fn preference(&self) -> &str

Returns the value of preference, or the default value if preference is unset.

source

pub fn max_connections_per_endpoint(&self) -> i32

Returns the value of max_connections_per_endpoint, or the default value if max_connections_per_endpoint is unset.

source

pub fn capacity_scaler(&self) -> f32

Returns the value of capacity_scaler, or the default value if capacity_scaler is unset.

source

pub fn max_rate(&self) -> i32

Returns the value of max_rate, or the default value if max_rate is unset.

source

pub fn description(&self) -> &str

Returns the value of description, or the default value if description is unset.

source

pub fn balancing_mode(&self) -> &str

Returns the value of balancing_mode, or the default value if balancing_mode is unset.

Trait Implementations§

source§

impl Clone for Backend

source§

fn clone(&self) -> Backend

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Backend

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Default for Backend

source§

fn default() -> Self

Returns the “default value” for a type. Read more
source§

impl Message for Backend

source§

fn encoded_len(&self) -> usize

Returns the encoded length of the message without a length delimiter.
source§

fn clear(&mut self)

Clears the message, resetting all fields to their default.
source§

fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>
where Self: Sized,

Encodes the message to a buffer. Read more
source§

fn encode_to_vec(&self) -> Vec<u8>
where Self: Sized,

Encodes the message to a newly allocated buffer.
source§

fn encode_length_delimited( &self, buf: &mut impl BufMut, ) -> Result<(), EncodeError>
where Self: Sized,

Encodes the message with a length-delimiter to a buffer. Read more
source§

fn encode_length_delimited_to_vec(&self) -> Vec<u8>
where Self: Sized,

Encodes the message with a length-delimiter to a newly allocated buffer.
source§

fn decode(buf: impl Buf) -> Result<Self, DecodeError>
where Self: Default,

Decodes an instance of the message from a buffer. Read more
source§

fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>
where Self: Default,

Decodes a length-delimited instance of the message from the buffer.
source§

fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>
where Self: Sized,

Decodes an instance of the message from a buffer, and merges it into self. Read more
source§

fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>
where Self: Sized,

Decodes a length-delimited instance of the message from buffer, and merges it into self.
source§

impl PartialEq for Backend

source§

fn eq(&self, other: &Backend) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl StructuralPartialEq for Backend

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T> FromRef<T> for T
where T: Clone,

§

fn from_ref(input: &T) -> T

Converts to this type from a reference to the input type.
§

impl<T> Instrument for T

§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided [Span], returning an Instrumented wrapper. Read more
§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> IntoRequest<T> for T

source§

fn into_request(self) -> Request<T>

Wrap the input message T in a tonic::Request
source§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

§

fn vzip(self) -> V

§

impl<T> WithSubscriber for T

§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a [WithDispatch] wrapper. Read more
§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a [WithDispatch] wrapper. Read more