pub struct RemoteConfig {
pub name: String,
pub remote_type: RemoteType,
pub uri: String,
pub mode: RemoteMode,
pub credential_provider: Option<String>,
pub auto_attach: bool,
}Expand description
Configuration for a remote storage location.
Fields§
§name: StringRemote name (used as schema name: remote_{name})
remote_type: RemoteTypeType of remote storage
uri: StringURI for the remote (e.g., s3://bucket/path/bird.duckdb, md:database_name)
mode: RemoteModeAccess mode (read_write or read_only)
credential_provider: Option<String>Credential provider for S3 (e.g., “credential_chain”, “config”)
auto_attach: boolWhether to auto-attach on connection open
Implementations§
Source§impl RemoteConfig
impl RemoteConfig
Sourcepub fn new(
name: impl Into<String>,
remote_type: RemoteType,
uri: impl Into<String>,
) -> Self
pub fn new( name: impl Into<String>, remote_type: RemoteType, uri: impl Into<String>, ) -> Self
Create a new remote config.
Sourcepub fn schema_name(&self) -> String
pub fn schema_name(&self) -> String
Get the DuckDB schema name for this remote.
Sourcepub fn quoted_schema_name(&self) -> String
pub fn quoted_schema_name(&self) -> String
Get the quoted DuckDB schema name for this remote (for use in SQL).
Sourcepub fn attach_sql(&self) -> String
pub fn attach_sql(&self) -> String
Generate the ATTACH SQL statement for this remote.
Sourcepub fn blob_base_url(&self) -> Option<String>
pub fn blob_base_url(&self) -> Option<String>
Get the base URL for blob storage (for S3/GCS remotes).
Trait Implementations§
Source§impl Clone for RemoteConfig
impl Clone for RemoteConfig
Source§fn clone(&self) -> RemoteConfig
fn clone(&self) -> RemoteConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for RemoteConfig
impl Debug for RemoteConfig
Source§impl<'de> Deserialize<'de> for RemoteConfig
impl<'de> Deserialize<'de> for RemoteConfig
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>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for RemoteConfig
impl RefUnwindSafe for RemoteConfig
impl Send for RemoteConfig
impl Sync for RemoteConfig
impl Unpin for RemoteConfig
impl UnwindSafe for RemoteConfig
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