#[non_exhaustive]pub struct SnowflakeNodeData {Show 21 fields
pub source_type: Option<String>,
pub connection: Option<Option>,
pub schema: Option<String>,
pub table: Option<String>,
pub database: Option<String>,
pub temp_dir: Option<String>,
pub iam_role: Option<Option>,
pub additional_options: Option<HashMap<String, String>>,
pub sample_query: Option<String>,
pub pre_action: Option<String>,
pub post_action: Option<String>,
pub action: Option<String>,
pub upsert: bool,
pub merge_action: Option<String>,
pub merge_when_matched: Option<String>,
pub merge_when_not_matched: Option<String>,
pub merge_clause: Option<String>,
pub staging_table: Option<String>,
pub selected_columns: Option<Vec<Option>>,
pub auto_pushdown: bool,
pub table_schema: Option<Vec<Option>>,
}
Expand description
Specifies configuration for Snowflake nodes in Glue Studio.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. }
syntax; cannot be matched against without a wildcard ..
; and struct update syntax will not work.source_type: Option<String>
Specifies how retrieved data is specified. Valid values: "table"
, "query"
.
connection: Option<Option>
Specifies a Glue Data Catalog Connection to a Snowflake endpoint.
schema: Option<String>
Specifies a Snowflake database schema for your node to use.
table: Option<String>
Specifies a Snowflake table for your node to use.
database: Option<String>
Specifies a Snowflake database for your node to use.
temp_dir: Option<String>
Not currently used.
iam_role: Option<Option>
Not currently used.
additional_options: Option<HashMap<String, String>>
Specifies additional options passed to the Snowflake connector. If options are specified elsewhere in this node, this will take precedence.
sample_query: Option<String>
A SQL string used to retrieve data with the query
sourcetype.
pre_action: Option<String>
A SQL string run before the Snowflake connector performs its standard actions.
post_action: Option<String>
A SQL string run after the Snowflake connector performs its standard actions.
action: Option<String>
Specifies what action to take when writing to a table with preexisting data. Valid values: append
, merge
, truncate
, drop
.
upsert: bool
Used when Action is append
. Specifies the resolution behavior when a row already exists. If true, preexisting rows will be updated. If false, those rows will be inserted.
merge_action: Option<String>
Specifies a merge action. Valid values: simple
, custom
. If simple, merge behavior is defined by MergeWhenMatched
and MergeWhenNotMatched
. If custom, defined by MergeClause
.
merge_when_matched: Option<String>
Specifies how to resolve records that match preexisting data when merging. Valid values: update
, delete
.
merge_when_not_matched: Option<String>
Specifies how to process records that do not match preexisting data when merging. Valid values: insert
, none
.
merge_clause: Option<String>
A SQL statement that specifies a custom merge behavior.
staging_table: Option<String>
The name of a staging table used when performing merge
or upsert append
actions. Data is written to this table, then moved to table
by a generated postaction.
selected_columns: Option<Vec<Option>>
Specifies the columns combined to identify a record when detecting matches for merges and upserts. A list of structures with value
, label
and description
keys. Each structure describes a column.
auto_pushdown: bool
Specifies whether automatic query pushdown is enabled. If pushdown is enabled, then when a query is run on Spark, if part of the query can be "pushed down" to the Snowflake server, it is pushed down. This improves performance of some queries.
table_schema: Option<Vec<Option>>
Manually defines the target schema for the node. A list of structures with value
, label
and description
keys. Each structure defines a column.
Implementations§
Source§impl SnowflakeNodeData
impl SnowflakeNodeData
Sourcepub fn source_type(&self) -> Option<&str>
pub fn source_type(&self) -> Option<&str>
Specifies how retrieved data is specified. Valid values: "table"
, "query"
.
Sourcepub fn connection(&self) -> Option<&Option>
pub fn connection(&self) -> Option<&Option>
Specifies a Glue Data Catalog Connection to a Snowflake endpoint.
Sourcepub fn schema(&self) -> Option<&str>
pub fn schema(&self) -> Option<&str>
Specifies a Snowflake database schema for your node to use.
Sourcepub fn additional_options(&self) -> Option<&HashMap<String, String>>
pub fn additional_options(&self) -> Option<&HashMap<String, String>>
Specifies additional options passed to the Snowflake connector. If options are specified elsewhere in this node, this will take precedence.
Sourcepub fn sample_query(&self) -> Option<&str>
pub fn sample_query(&self) -> Option<&str>
A SQL string used to retrieve data with the query
sourcetype.
Sourcepub fn pre_action(&self) -> Option<&str>
pub fn pre_action(&self) -> Option<&str>
A SQL string run before the Snowflake connector performs its standard actions.
Sourcepub fn post_action(&self) -> Option<&str>
pub fn post_action(&self) -> Option<&str>
A SQL string run after the Snowflake connector performs its standard actions.
Sourcepub fn action(&self) -> Option<&str>
pub fn action(&self) -> Option<&str>
Specifies what action to take when writing to a table with preexisting data. Valid values: append
, merge
, truncate
, drop
.
Sourcepub fn upsert(&self) -> bool
pub fn upsert(&self) -> bool
Used when Action is append
. Specifies the resolution behavior when a row already exists. If true, preexisting rows will be updated. If false, those rows will be inserted.
Sourcepub fn merge_action(&self) -> Option<&str>
pub fn merge_action(&self) -> Option<&str>
Specifies a merge action. Valid values: simple
, custom
. If simple, merge behavior is defined by MergeWhenMatched
and MergeWhenNotMatched
. If custom, defined by MergeClause
.
Sourcepub fn merge_when_matched(&self) -> Option<&str>
pub fn merge_when_matched(&self) -> Option<&str>
Specifies how to resolve records that match preexisting data when merging. Valid values: update
, delete
.
Sourcepub fn merge_when_not_matched(&self) -> Option<&str>
pub fn merge_when_not_matched(&self) -> Option<&str>
Specifies how to process records that do not match preexisting data when merging. Valid values: insert
, none
.
Sourcepub fn merge_clause(&self) -> Option<&str>
pub fn merge_clause(&self) -> Option<&str>
A SQL statement that specifies a custom merge behavior.
Sourcepub fn staging_table(&self) -> Option<&str>
pub fn staging_table(&self) -> Option<&str>
The name of a staging table used when performing merge
or upsert append
actions. Data is written to this table, then moved to table
by a generated postaction.
Sourcepub fn selected_columns(&self) -> &[Option]
pub fn selected_columns(&self) -> &[Option]
Specifies the columns combined to identify a record when detecting matches for merges and upserts. A list of structures with value
, label
and description
keys. Each structure describes a column.
If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use .selected_columns.is_none()
.
Sourcepub fn auto_pushdown(&self) -> bool
pub fn auto_pushdown(&self) -> bool
Specifies whether automatic query pushdown is enabled. If pushdown is enabled, then when a query is run on Spark, if part of the query can be "pushed down" to the Snowflake server, it is pushed down. This improves performance of some queries.
Sourcepub fn table_schema(&self) -> &[Option]
pub fn table_schema(&self) -> &[Option]
Manually defines the target schema for the node. A list of structures with value
, label
and description
keys. Each structure defines a column.
If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use .table_schema.is_none()
.
Source§impl SnowflakeNodeData
impl SnowflakeNodeData
Sourcepub fn builder() -> SnowflakeNodeDataBuilder
pub fn builder() -> SnowflakeNodeDataBuilder
Creates a new builder-style object to manufacture SnowflakeNodeData
.
Trait Implementations§
Source§impl Clone for SnowflakeNodeData
impl Clone for SnowflakeNodeData
Source§fn clone(&self) -> SnowflakeNodeData
fn clone(&self) -> SnowflakeNodeData
1.0.0 · Source§const fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for SnowflakeNodeData
impl Debug for SnowflakeNodeData
Source§impl PartialEq for SnowflakeNodeData
impl PartialEq for SnowflakeNodeData
impl StructuralPartialEq for SnowflakeNodeData
Auto Trait Implementations§
impl Freeze for SnowflakeNodeData
impl RefUnwindSafe for SnowflakeNodeData
impl Send for SnowflakeNodeData
impl Sync for SnowflakeNodeData
impl Unpin for SnowflakeNodeData
impl UnwindSafe for SnowflakeNodeData
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> 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> 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 moreSource§impl<T> Paint for Twhere
T: ?Sized,
impl<T> Paint for Twhere
T: ?Sized,
Source§fn fg(&self, value: Color) -> Painted<&T>
fn fg(&self, value: Color) -> Painted<&T>
Returns a styled value derived from self
with the foreground set to
value
.
This method should be used rarely. Instead, prefer to use color-specific
builder methods like red()
and
green()
, which have the same functionality but are
pithier.
§Example
Set foreground color to white using fg()
:
use yansi::{Paint, Color};
painted.fg(Color::White);
Set foreground color to white using white()
.
use yansi::Paint;
painted.white();
Source§fn bright_black(&self) -> Painted<&T>
fn bright_black(&self) -> Painted<&T>
Source§fn bright_red(&self) -> Painted<&T>
fn bright_red(&self) -> Painted<&T>
Source§fn bright_green(&self) -> Painted<&T>
fn bright_green(&self) -> Painted<&T>
Source§fn bright_yellow(&self) -> Painted<&T>
fn bright_yellow(&self) -> Painted<&T>
Source§fn bright_blue(&self) -> Painted<&T>
fn bright_blue(&self) -> Painted<&T>
Source§fn bright_magenta(&self) -> Painted<&T>
fn bright_magenta(&self) -> Painted<&T>
Source§fn bright_cyan(&self) -> Painted<&T>
fn bright_cyan(&self) -> Painted<&T>
Source§fn bright_white(&self) -> Painted<&T>
fn bright_white(&self) -> Painted<&T>
Source§fn bg(&self, value: Color) -> Painted<&T>
fn bg(&self, value: Color) -> Painted<&T>
Returns a styled value derived from self
with the background set to
value
.
This method should be used rarely. Instead, prefer to use color-specific
builder methods like on_red()
and
on_green()
, which have the same functionality but
are pithier.
§Example
Set background color to red using fg()
:
use yansi::{Paint, Color};
painted.bg(Color::Red);
Set background color to red using on_red()
.
use yansi::Paint;
painted.on_red();
Source§fn on_primary(&self) -> Painted<&T>
fn on_primary(&self) -> Painted<&T>
Source§fn on_magenta(&self) -> Painted<&T>
fn on_magenta(&self) -> Painted<&T>
Source§fn on_bright_black(&self) -> Painted<&T>
fn on_bright_black(&self) -> Painted<&T>
Source§fn on_bright_red(&self) -> Painted<&T>
fn on_bright_red(&self) -> Painted<&T>
Source§fn on_bright_green(&self) -> Painted<&T>
fn on_bright_green(&self) -> Painted<&T>
Source§fn on_bright_yellow(&self) -> Painted<&T>
fn on_bright_yellow(&self) -> Painted<&T>
Source§fn on_bright_blue(&self) -> Painted<&T>
fn on_bright_blue(&self) -> Painted<&T>
Source§fn on_bright_magenta(&self) -> Painted<&T>
fn on_bright_magenta(&self) -> Painted<&T>
Source§fn on_bright_cyan(&self) -> Painted<&T>
fn on_bright_cyan(&self) -> Painted<&T>
Source§fn on_bright_white(&self) -> Painted<&T>
fn on_bright_white(&self) -> Painted<&T>
Source§fn attr(&self, value: Attribute) -> Painted<&T>
fn attr(&self, value: Attribute) -> Painted<&T>
Enables the styling Attribute
value
.
This method should be used rarely. Instead, prefer to use
attribute-specific builder methods like bold()
and
underline()
, which have the same functionality
but are pithier.
§Example
Make text bold using attr()
:
use yansi::{Paint, Attribute};
painted.attr(Attribute::Bold);
Make text bold using using bold()
.
use yansi::Paint;
painted.bold();
Source§fn rapid_blink(&self) -> Painted<&T>
fn rapid_blink(&self) -> Painted<&T>
Source§fn quirk(&self, value: Quirk) -> Painted<&T>
fn quirk(&self, value: Quirk) -> Painted<&T>
Enables the yansi
Quirk
value
.
This method should be used rarely. Instead, prefer to use quirk-specific
builder methods like mask()
and
wrap()
, which have the same functionality but are
pithier.
§Example
Enable wrapping using .quirk()
:
use yansi::{Paint, Quirk};
painted.quirk(Quirk::Wrap);
Enable wrapping using wrap()
.
use yansi::Paint;
painted.wrap();
Source§fn clear(&self) -> Painted<&T>
👎Deprecated since 1.0.1: renamed to resetting()
due to conflicts with Vec::clear()
.
The clear()
method will be removed in a future release.
fn clear(&self) -> Painted<&T>
resetting()
due to conflicts with Vec::clear()
.
The clear()
method will be removed in a future release.Source§fn whenever(&self, value: Condition) -> Painted<&T>
fn whenever(&self, value: Condition) -> Painted<&T>
Conditionally enable styling based on whether the Condition
value
applies. Replaces any previous condition.
See the crate level docs for more details.
§Example
Enable styling painted
only when both stdout
and stderr
are TTYs:
use yansi::{Paint, Condition};
painted.red().on_yellow().whenever(Condition::STDOUTERR_ARE_TTY);