pub struct BatchingSettingsProto {
pub element_count_threshold: i32,
pub request_byte_threshold: i64,
pub delay_threshold: Option<Duration>,
pub element_count_limit: i32,
pub request_byte_limit: i32,
pub flow_control_element_limit: i32,
pub flow_control_byte_limit: i32,
pub flow_control_limit_exceeded_behavior: i32,
}Expand description
BatchingSettingsProto specifies a set of batching thresholds, each of
which acts as a trigger to send a batch of messages as a request. At least
one threshold must be positive nonzero.
Fields§
§element_count_threshold: i32The number of elements of a field collected into a batch which, if exceeded, causes the batch to be sent.
request_byte_threshold: i64The aggregated size of the batched field which, if exceeded, causes the batch to be sent. This size is computed by aggregating the sizes of the request field to be batched, not of the entire request message.
delay_threshold: Option<Duration>The duration after which a batch should be sent, starting from the addition of the first message to that batch.
element_count_limit: i32The maximum number of elements collected in a batch that could be accepted by server.
request_byte_limit: i32The maximum size of the request that could be accepted by server.
flow_control_element_limit: i32The maximum number of elements allowed by flow control.
flow_control_byte_limit: i32The maximum size of data allowed by flow control.
flow_control_limit_exceeded_behavior: i32The behavior to take when the flow control limit is exceeded.
Implementations§
Source§impl BatchingSettingsProto
impl BatchingSettingsProto
Sourcepub fn flow_control_limit_exceeded_behavior(
&self,
) -> FlowControlLimitExceededBehaviorProto
pub fn flow_control_limit_exceeded_behavior( &self, ) -> FlowControlLimitExceededBehaviorProto
Returns the enum value of flow_control_limit_exceeded_behavior, or the default if the field is set to an invalid enum value.
Sourcepub fn set_flow_control_limit_exceeded_behavior(
&mut self,
value: FlowControlLimitExceededBehaviorProto,
)
pub fn set_flow_control_limit_exceeded_behavior( &mut self, value: FlowControlLimitExceededBehaviorProto, )
Sets flow_control_limit_exceeded_behavior to the provided enum value.
Trait Implementations§
Source§impl Clone for BatchingSettingsProto
impl Clone for BatchingSettingsProto
Source§fn clone(&self) -> BatchingSettingsProto
fn clone(&self) -> BatchingSettingsProto
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for BatchingSettingsProto
impl Debug for BatchingSettingsProto
Source§impl Default for BatchingSettingsProto
impl Default for BatchingSettingsProto
Source§impl Message for BatchingSettingsProto
impl Message for BatchingSettingsProto
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Source§fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>
fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>
Source§fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>
fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>
Source§fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn decode<B>(buf: B) -> Result<Self, DecodeError>
fn decode<B>(buf: B) -> Result<Self, DecodeError>
Source§fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>
fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>
Source§fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>
fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>
self. Read moreSource§fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>
fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>
self.Source§impl PartialEq for BatchingSettingsProto
impl PartialEq for BatchingSettingsProto
Source§fn eq(&self, other: &BatchingSettingsProto) -> bool
fn eq(&self, other: &BatchingSettingsProto) -> bool
self and other values to be equal, and is used by ==.impl StructuralPartialEq for BatchingSettingsProto
Auto Trait Implementations§
impl Freeze for BatchingSettingsProto
impl RefUnwindSafe for BatchingSettingsProto
impl Send for BatchingSettingsProto
impl Sync for BatchingSettingsProto
impl Unpin for BatchingSettingsProto
impl UnsafeUnpin for BatchingSettingsProto
impl UnwindSafe for BatchingSettingsProto
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Requestimpl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
impl<T> Scalar for T
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.