pub struct UnityCatalogBuilder { /* private fields */ }
Expand description
Builder for crateing a UnityCatalogClient
Implementations§
Source§impl UnityCatalogBuilder
impl UnityCatalogBuilder
Sourcepub fn new() -> Self
pub fn new() -> Self
Create a new UnityCatalogBuilder
with default values.
Sourcepub fn try_with_option(
self,
key: impl AsRef<str>,
value: impl Into<String>,
) -> DataCatalogResult<Self>
pub fn try_with_option( self, key: impl AsRef<str>, value: impl Into<String>, ) -> DataCatalogResult<Self>
Set an option on the builder via a key - value pair.
Sourcepub fn try_with_options<I: IntoIterator<Item = (impl AsRef<str>, impl Into<String>)>>(
self,
options: I,
) -> DataCatalogResult<Self>
pub fn try_with_options<I: IntoIterator<Item = (impl AsRef<str>, impl Into<String>)>>( self, options: I, ) -> DataCatalogResult<Self>
Hydrate builder from key value pairs
Sourcepub fn from_env() -> Self
pub fn from_env() -> Self
Parse configuration from the environment.
Environment keys prefixed with “UNITY_” or “DATABRICKS_” will be considered
Sourcepub fn with_workspace_url(self, url: impl Into<String>) -> Self
pub fn with_workspace_url(self, url: impl Into<String>) -> Self
Set the URL of a Databricks workspace.
Sourcepub fn with_client_id(self, client_id: impl Into<String>) -> Self
pub fn with_client_id(self, client_id: impl Into<String>) -> Self
Sets the client id for use in client secret or k8s federated credential flow
Sourcepub fn with_client_secret(self, client_secret: impl Into<String>) -> Self
pub fn with_client_secret(self, client_secret: impl Into<String>) -> Self
Sets the client secret for use in client secret flow
Sets the authority id for use service principal credential based authentication
Sourcepub fn with_bearer_token(self, bearer_token: impl Into<String>) -> Self
pub fn with_bearer_token(self, bearer_token: impl Into<String>) -> Self
Set a static bearer token to be used for authorizing requests
Sourcepub fn with_access_token(self, access_token: impl Into<String>) -> Self
pub fn with_access_token(self, access_token: impl Into<String>) -> Self
Set a personal access token (PAT) to be used for authorizing requests
Sourcepub fn with_client_options(self, options: ClientOptions) -> Self
pub fn with_client_options(self, options: ClientOptions) -> Self
Sets the client options, overriding any already set
Sourcepub fn with_retry_config(self, config: RetryConfig) -> Self
pub fn with_retry_config(self, config: RetryConfig) -> Self
Sets the retry config, overriding any already set
Sourcepub fn build(self) -> DataCatalogResult<UnityCatalog>
pub fn build(self) -> DataCatalogResult<UnityCatalog>
Build an instance of UnityCatalog
Trait Implementations§
Source§impl Default for UnityCatalogBuilder
impl Default for UnityCatalogBuilder
Source§fn default() -> UnityCatalogBuilder
fn default() -> UnityCatalogBuilder
Auto Trait Implementations§
impl !Freeze for UnityCatalogBuilder
impl RefUnwindSafe for UnityCatalogBuilder
impl Send for UnityCatalogBuilder
impl Sync for UnityCatalogBuilder
impl Unpin for UnityCatalogBuilder
impl UnwindSafe for UnityCatalogBuilder
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
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> 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>
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>
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