Struct massa_node::settings::GrpcSettings
source · pub struct GrpcSettings {Show 42 fields
pub enabled: bool,
pub accept_http1: bool,
pub enable_cors: bool,
pub enable_health: bool,
pub enable_reflection: bool,
pub enable_tls: bool,
pub enable_mtls: bool,
pub generate_self_signed_certificates: bool,
pub subject_alt_names: Vec<String>,
pub bind: SocketAddr,
pub accept_compressed: Option<String>,
pub send_compressed: Option<String>,
pub max_decoding_message_size: usize,
pub max_encoding_message_size: usize,
pub max_channel_size: usize,
pub concurrency_limit_per_connection: usize,
pub timeout: MassaTime,
pub initial_stream_window_size: Option<u32>,
pub initial_connection_window_size: Option<u32>,
pub max_concurrent_streams: Option<u32>,
pub max_arguments: u64,
pub tcp_keepalive: Option<MassaTime>,
pub tcp_nodelay: bool,
pub http2_keepalive_interval: Option<MassaTime>,
pub http2_keepalive_timeout: Option<MassaTime>,
pub http2_adaptive_window: Option<bool>,
pub max_frame_size: Option<u32>,
pub draw_lookahead_period_count: u64,
pub max_block_ids_per_request: u32,
pub max_addresses_per_request: u32,
pub max_slot_ranges_per_request: u32,
pub max_endorsement_ids_per_request: u32,
pub max_operation_ids_per_request: u32,
pub max_datastore_entries_per_request: u64,
pub max_filters_per_request: u32,
pub max_query_items_per_request: u32,
pub certificate_authority_root_path: PathBuf,
pub server_certificate_path: PathBuf,
pub server_private_key_path: PathBuf,
pub client_certificate_authority_root_path: PathBuf,
pub client_certificate_path: PathBuf,
pub client_private_key_path: PathBuf,
}
Expand description
gRPC settings the gRPC settings
Fields§
§enabled: bool
whether to enable gRPC
accept_http1: bool
whether to accept HTTP/1.1 requests
enable_cors: bool
whether to enable CORS. Works only if accept_http1
is true
enable_health: bool
whether to enable gRPC health service
enable_reflection: bool
whether to enable gRPC reflection
enable_tls: bool
whether to enable TLS
enable_mtls: bool
whether to enable mTLS (requires enable_tls
to be true)
generate_self_signed_certificates: bool
whether to generate a self-signed certificate if none is provided
subject_alt_names: Vec<String>
Subject Alternative Names is an extension in X.509 certificates that allows a certificate to specify additional subject identifiers. It is used to support alternative names for a subject, other than its primary Common Name (CN), which is typically used to represent the primary domain name.
bind: SocketAddr
bind for the Massa gRPC API
accept_compressed: Option<String>
which compression encodings does the server accept for requests
send_compressed: Option<String>
which compression encodings might the server use for responses
max_decoding_message_size: usize
limits the maximum size of a decoded message. Defaults to 4MB
max_encoding_message_size: usize
limits the maximum size of an encoded message. Defaults to 4MB
max_channel_size: usize
limits the maximum size of streaming channel
concurrency_limit_per_connection: usize
set the concurrency limit applied to on requests inbound per connection. Defaults to 32
timeout: MassaTime
set a timeout on for all request handlers
initial_stream_window_size: Option<u32>
sets the SETTINGS_INITIAL_WINDOW_SIZE spec option for HTTP2 stream-level flow control. Default is 65,535
initial_connection_window_size: Option<u32>
sets the max connection-level flow control for HTTP2. Default is 65,535
max_concurrent_streams: Option<u32>
sets the SETTINGS_MAX_CONCURRENT_STREAMS spec option for HTTP2 connections. Default is no limit (None
)
max_arguments: u64
max number of arguments per gRPC request
tcp_keepalive: Option<MassaTime>
set whether TCP keepalive messages are enabled on accepted connections
tcp_nodelay: bool
set the value of TCP_NODELAY
option for accepted connections. Enabled by default
http2_keepalive_interval: Option<MassaTime>
set whether HTTP2 Ping frames are enabled on accepted connections. Default is no HTTP2 keepalive (None
)
http2_keepalive_timeout: Option<MassaTime>
sets a timeout for receiving an acknowledgement of the keepalive ping. Default is 20 seconds
http2_adaptive_window: Option<bool>
sets whether to use an adaptive flow control. Defaults to false
max_frame_size: Option<u32>
sets the maximum frame size to use for HTTP2(must be within 16,384 and 16,777,215). If not set, will default from underlying transport
draw_lookahead_period_count: u64
when looking for next draw we want to look at max draw_lookahead_period_count
max_block_ids_per_request: u32
max number of block ids that can be included in a single request
max_addresses_per_request: u32
max number of addresses that can be included in a single request
max_slot_ranges_per_request: u32
max number of slot ranges that can be included in a single request
max_endorsement_ids_per_request: u32
max number of endorsement ids that can be included in a single request
max_operation_ids_per_request: u32
max number of operation ids that can be included in a single request
max_datastore_entries_per_request: u64
max op datastore entries per request
max_filters_per_request: u32
max number of filters that can be included in a single request
max_query_items_per_request: u32
max number of query items that can be included in a single request
certificate authority root path
server_certificate_path: PathBuf
server certificate path
server_private_key_path: PathBuf
server private key path
client certificate authority root path
client_certificate_path: PathBuf
client certificate path
client_private_key_path: PathBuf
client private key path
Trait Implementations§
source§impl Clone for GrpcSettings
impl Clone for GrpcSettings
source§fn clone(&self) -> GrpcSettings
fn clone(&self) -> GrpcSettings
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for GrpcSettings
impl Debug for GrpcSettings
source§impl<'de> Deserialize<'de> for GrpcSettings
impl<'de> Deserialize<'de> for GrpcSettings
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Auto Trait Implementations§
impl Freeze for GrpcSettings
impl RefUnwindSafe for GrpcSettings
impl Send for GrpcSettings
impl Sync for GrpcSettings
impl Unpin for GrpcSettings
impl UnwindSafe for GrpcSettings
Blanket Implementations§
§impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
§type ArchivedMetadata = ()
type ArchivedMetadata = ()
§fn pointer_metadata(
_: &<T as ArchivePointee>::ArchivedMetadata,
) -> <T as Pointee>::Metadata
fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata, ) -> <T as Pointee>::Metadata
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)§impl<T> Conv for T
impl<T> Conv for T
§impl<F, W, T, D> Deserialize<With<T, W>, D> for F
impl<F, W, T, D> Deserialize<With<T, W>, D> for F
§fn deserialize(
&self,
deserializer: &mut D,
) -> Result<With<T, W>, <D as Fallible>::Error>
fn deserialize( &self, deserializer: &mut D, ) -> Result<With<T, W>, <D as Fallible>::Error>
§impl<T> FmtForward for T
impl<T> FmtForward for T
§fn fmt_binary(self) -> FmtBinary<Self>where
Self: Binary,
fn fmt_binary(self) -> FmtBinary<Self>where
Self: Binary,
self
to use its Binary
implementation when Debug
-formatted.§fn fmt_display(self) -> FmtDisplay<Self>where
Self: Display,
fn fmt_display(self) -> FmtDisplay<Self>where
Self: Display,
self
to use its Display
implementation when
Debug
-formatted.§fn fmt_lower_exp(self) -> FmtLowerExp<Self>where
Self: LowerExp,
fn fmt_lower_exp(self) -> FmtLowerExp<Self>where
Self: LowerExp,
self
to use its LowerExp
implementation when
Debug
-formatted.§fn fmt_lower_hex(self) -> FmtLowerHex<Self>where
Self: LowerHex,
fn fmt_lower_hex(self) -> FmtLowerHex<Self>where
Self: LowerHex,
self
to use its LowerHex
implementation when
Debug
-formatted.§fn fmt_octal(self) -> FmtOctal<Self>where
Self: Octal,
fn fmt_octal(self) -> FmtOctal<Self>where
Self: Octal,
self
to use its Octal
implementation when Debug
-formatted.§fn fmt_pointer(self) -> FmtPointer<Self>where
Self: Pointer,
fn fmt_pointer(self) -> FmtPointer<Self>where
Self: Pointer,
self
to use its Pointer
implementation when
Debug
-formatted.§fn fmt_upper_exp(self) -> FmtUpperExp<Self>where
Self: UpperExp,
fn fmt_upper_exp(self) -> FmtUpperExp<Self>where
Self: UpperExp,
self
to use its UpperExp
implementation when
Debug
-formatted.§fn fmt_upper_hex(self) -> FmtUpperHex<Self>where
Self: UpperHex,
fn fmt_upper_hex(self) -> FmtUpperHex<Self>where
Self: UpperHex,
self
to use its UpperHex
implementation when
Debug
-formatted.§fn fmt_list(self) -> FmtList<Self>where
&'a Self: for<'a> IntoIterator,
fn fmt_list(self) -> FmtList<Self>where
&'a Self: for<'a> IntoIterator,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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::Request
§impl<T> LayoutRaw for T
impl<T> LayoutRaw for T
§fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
§impl<T> Pipe for Twhere
T: ?Sized,
impl<T> Pipe for Twhere
T: ?Sized,
§fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> Rwhere
Self: Sized,
fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> Rwhere
Self: Sized,
§fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> Rwhere
R: 'a,
fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> Rwhere
R: 'a,
self
and passes that borrow into the pipe function. Read more§fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> Rwhere
R: 'a,
fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> Rwhere
R: 'a,
self
and passes that borrow into the pipe function. Read more§fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> R
fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> R
§fn pipe_borrow_mut<'a, B, R>(
&'a mut self,
func: impl FnOnce(&'a mut B) -> R,
) -> R
fn pipe_borrow_mut<'a, B, R>( &'a mut self, func: impl FnOnce(&'a mut B) -> R, ) -> R
§fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> R
fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> R
self
, then passes self.as_ref()
into the pipe function.§fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
self
, then passes self.as_mut()
into the pipe
function.§fn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
fn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
self
, then passes self.deref()
into the pipe function.§impl<T> Pointable for T
impl<T> Pointable for T
§impl<T> Tap for T
impl<T> Tap for T
§fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
Borrow<B>
of a value. Read more§fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
BorrowMut<B>
of a value. Read more§fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
AsRef<R>
view of a value. Read more§fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
AsMut<R>
view of a value. Read more§fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
Deref::Target
of a value. Read more§fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
Deref::Target
of a value. Read more§fn tap_dbg(self, func: impl FnOnce(&Self)) -> Self
fn tap_dbg(self, func: impl FnOnce(&Self)) -> Self
.tap()
only in debug builds, and is erased in release builds.§fn tap_mut_dbg(self, func: impl FnOnce(&mut Self)) -> Self
fn tap_mut_dbg(self, func: impl FnOnce(&mut Self)) -> Self
.tap_mut()
only in debug builds, and is erased in release
builds.§fn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
fn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
.tap_borrow()
only in debug builds, and is erased in release
builds.§fn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
fn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
.tap_borrow_mut()
only in debug builds, and is erased in release
builds.§fn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
fn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
.tap_ref()
only in debug builds, and is erased in release
builds.§fn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
fn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
.tap_ref_mut()
only in debug builds, and is erased in release
builds.§fn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
fn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
.tap_deref()
only in debug builds, and is erased in release
builds.