pub struct FlightSqlServerBuilder { /* private fields */ }Implementations§
Source§impl FlightSqlServerBuilder
impl FlightSqlServerBuilder
Sourcepub fn with_view_factory_fn<F, Fut>(self, f: F) -> Selfwhere
F: FnOnce(Arc<RuntimeEnv>, Arc<DataLakeConnection>) -> Fut + Send + 'static,
Fut: Future<Output = Result<ViewFactory>> + Send + 'static,
pub fn with_view_factory_fn<F, Fut>(self, f: F) -> Selfwhere
F: FnOnce(Arc<RuntimeEnv>, Arc<DataLakeConnection>) -> Fut + Send + 'static,
Fut: Future<Output = Result<ViewFactory>> + Send + 'static,
Override the default view factory with a custom closure.
The closure receives the runtime and data lake created by the builder.
Sourcepub fn with_session_configurator(
self,
cfg: Arc<dyn SessionConfigurator>,
) -> Self
pub fn with_session_configurator( self, cfg: Arc<dyn SessionConfigurator>, ) -> Self
Override the default session configurator.
By default the builder loads static tables from MICROMEGAS_STATIC_TABLES_URL.
Use this to replace that behavior entirely.
Sourcepub fn with_auth_provider(self, provider: Arc<dyn AuthProvider>) -> Self
pub fn with_auth_provider(self, provider: Arc<dyn AuthProvider>) -> Self
Set an explicit auth provider.
Sourcepub fn with_default_auth(self) -> Self
pub fn with_default_auth(self) -> Self
Use the default auth provider from env vars during build.
Errors if no auth providers are configured (fail-fast).
Sourcepub fn with_max_decoding_message_size(self, bytes: usize) -> Self
pub fn with_max_decoding_message_size(self, bytes: usize) -> Self
Set the max decoding message size (default: 100 MB).
Sourcepub fn with_listen_addr(self, addr: SocketAddr) -> Self
pub fn with_listen_addr(self, addr: SocketAddr) -> Self
Set the listen address (default: 0.0.0.0:50051).
Sourcepub async fn build_and_serve(self) -> Result<()>
pub async fn build_and_serve(self) -> Result<()>
Build and run the FlightSQL server.
Runs the full setup sequence and blocks until the server shuts down.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for FlightSqlServerBuilder
impl !RefUnwindSafe for FlightSqlServerBuilder
impl Send for FlightSqlServerBuilder
impl !Sync for FlightSqlServerBuilder
impl Unpin for FlightSqlServerBuilder
impl !UnwindSafe for FlightSqlServerBuilder
Blanket Implementations§
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
Mutably borrows from an owned value. Read more
§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> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request§impl<L> LayerExt<L> for L
impl<L> LayerExt<L> for L
§fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
Applies the layer to a service and wraps it in [
Layered].