pub struct CreateSessionFluentBuilder { /* private fields */ }
Expand description
Fluent builder constructing a request to CreateSession
.
Creates a new session.
Implementations§
Source§impl CreateSessionFluentBuilder
impl CreateSessionFluentBuilder
Sourcepub fn as_input(&self) -> &CreateSessionInputBuilder
pub fn as_input(&self) -> &CreateSessionInputBuilder
Access the CreateSession as a reference.
Sourcepub async fn send(
self,
) -> Result<CreateSessionOutput, SdkError<CreateSessionError, HttpResponse>>
pub async fn send( self, ) -> Result<CreateSessionOutput, SdkError<CreateSessionError, HttpResponse>>
Sends the request and returns the response.
If an error occurs, an SdkError
will be returned with additional details that
can be matched against.
By default, any retryable failures will be retried twice. Retry behavior is configurable with the RetryConfig, which can be set when configuring the client.
Sourcepub fn customize(
self,
) -> CustomizableOperation<CreateSessionOutput, CreateSessionError, Self>
pub fn customize( self, ) -> CustomizableOperation<CreateSessionOutput, CreateSessionError, Self>
Consumes this builder, creating a customizable operation that can be modified before being sent.
Sourcepub fn description(self, input: impl Into<String>) -> Self
pub fn description(self, input: impl Into<String>) -> Self
The description of the session.
Sourcepub fn set_description(self, input: Option<String>) -> Self
pub fn set_description(self, input: Option<String>) -> Self
The description of the session.
Sourcepub fn get_description(&self) -> &Option<String>
pub fn get_description(&self) -> &Option<String>
The description of the session.
Sourcepub fn command(self, input: SessionCommand) -> Self
pub fn command(self, input: SessionCommand) -> Self
The SessionCommand
that runs the job.
Sourcepub fn set_command(self, input: Option<SessionCommand>) -> Self
pub fn set_command(self, input: Option<SessionCommand>) -> Self
The SessionCommand
that runs the job.
Sourcepub fn get_command(&self) -> &Option<SessionCommand>
pub fn get_command(&self) -> &Option<SessionCommand>
The SessionCommand
that runs the job.
Sourcepub fn timeout(self, input: i32) -> Self
pub fn timeout(self, input: i32) -> Self
The number of minutes before session times out. Default for Spark ETL jobs is 48 hours (2880 minutes). Consult the documentation for other job types.
Sourcepub fn set_timeout(self, input: Option<i32>) -> Self
pub fn set_timeout(self, input: Option<i32>) -> Self
The number of minutes before session times out. Default for Spark ETL jobs is 48 hours (2880 minutes). Consult the documentation for other job types.
Sourcepub fn get_timeout(&self) -> &Option<i32>
pub fn get_timeout(&self) -> &Option<i32>
The number of minutes before session times out. Default for Spark ETL jobs is 48 hours (2880 minutes). Consult the documentation for other job types.
Sourcepub fn idle_timeout(self, input: i32) -> Self
pub fn idle_timeout(self, input: i32) -> Self
The number of minutes when idle before session times out. Default for Spark ETL jobs is value of Timeout. Consult the documentation for other job types.
Sourcepub fn set_idle_timeout(self, input: Option<i32>) -> Self
pub fn set_idle_timeout(self, input: Option<i32>) -> Self
The number of minutes when idle before session times out. Default for Spark ETL jobs is value of Timeout. Consult the documentation for other job types.
Sourcepub fn get_idle_timeout(&self) -> &Option<i32>
pub fn get_idle_timeout(&self) -> &Option<i32>
The number of minutes when idle before session times out. Default for Spark ETL jobs is value of Timeout. Consult the documentation for other job types.
Sourcepub fn default_arguments(
self,
k: impl Into<String>,
v: impl Into<String>,
) -> Self
pub fn default_arguments( self, k: impl Into<String>, v: impl Into<String>, ) -> Self
Adds a key-value pair to DefaultArguments
.
To override the contents of this collection use set_default_arguments
.
A map array of key-value pairs. Max is 75 pairs.
Sourcepub fn set_default_arguments(
self,
input: Option<HashMap<String, String>>,
) -> Self
pub fn set_default_arguments( self, input: Option<HashMap<String, String>>, ) -> Self
A map array of key-value pairs. Max is 75 pairs.
Sourcepub fn get_default_arguments(&self) -> &Option<HashMap<String, String>>
pub fn get_default_arguments(&self) -> &Option<HashMap<String, String>>
A map array of key-value pairs. Max is 75 pairs.
Sourcepub fn connections(self, input: ConnectionsList) -> Self
pub fn connections(self, input: ConnectionsList) -> Self
The number of connections to use for the session.
Sourcepub fn set_connections(self, input: Option<ConnectionsList>) -> Self
pub fn set_connections(self, input: Option<ConnectionsList>) -> Self
The number of connections to use for the session.
Sourcepub fn get_connections(&self) -> &Option<ConnectionsList>
pub fn get_connections(&self) -> &Option<ConnectionsList>
The number of connections to use for the session.
Sourcepub fn max_capacity(self, input: f64) -> Self
pub fn max_capacity(self, input: f64) -> Self
The number of Glue data processing units (DPUs) that can be allocated when the job runs. A DPU is a relative measure of processing power that consists of 4 vCPUs of compute capacity and 16 GB memory.
Sourcepub fn set_max_capacity(self, input: Option<f64>) -> Self
pub fn set_max_capacity(self, input: Option<f64>) -> Self
The number of Glue data processing units (DPUs) that can be allocated when the job runs. A DPU is a relative measure of processing power that consists of 4 vCPUs of compute capacity and 16 GB memory.
Sourcepub fn get_max_capacity(&self) -> &Option<f64>
pub fn get_max_capacity(&self) -> &Option<f64>
The number of Glue data processing units (DPUs) that can be allocated when the job runs. A DPU is a relative measure of processing power that consists of 4 vCPUs of compute capacity and 16 GB memory.
Sourcepub fn number_of_workers(self, input: i32) -> Self
pub fn number_of_workers(self, input: i32) -> Self
The number of workers of a defined WorkerType
to use for the session.
Sourcepub fn set_number_of_workers(self, input: Option<i32>) -> Self
pub fn set_number_of_workers(self, input: Option<i32>) -> Self
The number of workers of a defined WorkerType
to use for the session.
Sourcepub fn get_number_of_workers(&self) -> &Option<i32>
pub fn get_number_of_workers(&self) -> &Option<i32>
The number of workers of a defined WorkerType
to use for the session.
Sourcepub fn worker_type(self, input: WorkerType) -> Self
pub fn worker_type(self, input: WorkerType) -> Self
The type of predefined worker that is allocated when a job runs. Accepts a value of G.1X, G.2X, G.4X, or G.8X for Spark jobs. Accepts the value Z.2X for Ray notebooks.
-
For the
G.1X
worker type, each worker maps to 1 DPU (4 vCPUs, 16 GB of memory) with 94GB disk, and provides 1 executor per worker. We recommend this worker type for workloads such as data transforms, joins, and queries, to offers a scalable and cost effective way to run most jobs. -
For the
G.2X
worker type, each worker maps to 2 DPU (8 vCPUs, 32 GB of memory) with 138GB disk, and provides 1 executor per worker. We recommend this worker type for workloads such as data transforms, joins, and queries, to offers a scalable and cost effective way to run most jobs. -
For the
G.4X
worker type, each worker maps to 4 DPU (16 vCPUs, 64 GB of memory) with 256GB disk, and provides 1 executor per worker. We recommend this worker type for jobs whose workloads contain your most demanding transforms, aggregations, joins, and queries. This worker type is available only for Glue version 3.0 or later Spark ETL jobs in the following Amazon Web Services Regions: US East (Ohio), US East (N. Virginia), US West (Oregon), Asia Pacific (Singapore), Asia Pacific (Sydney), Asia Pacific (Tokyo), Canada (Central), Europe (Frankfurt), Europe (Ireland), and Europe (Stockholm). -
For the
G.8X
worker type, each worker maps to 8 DPU (32 vCPUs, 128 GB of memory) with 512GB disk, and provides 1 executor per worker. We recommend this worker type for jobs whose workloads contain your most demanding transforms, aggregations, joins, and queries. This worker type is available only for Glue version 3.0 or later Spark ETL jobs, in the same Amazon Web Services Regions as supported for theG.4X
worker type. -
For the
Z.2X
worker type, each worker maps to 2 M-DPU (8vCPUs, 64 GB of memory) with 128 GB disk, and provides up to 8 Ray workers based on the autoscaler.
Sourcepub fn set_worker_type(self, input: Option<WorkerType>) -> Self
pub fn set_worker_type(self, input: Option<WorkerType>) -> Self
The type of predefined worker that is allocated when a job runs. Accepts a value of G.1X, G.2X, G.4X, or G.8X for Spark jobs. Accepts the value Z.2X for Ray notebooks.
-
For the
G.1X
worker type, each worker maps to 1 DPU (4 vCPUs, 16 GB of memory) with 94GB disk, and provides 1 executor per worker. We recommend this worker type for workloads such as data transforms, joins, and queries, to offers a scalable and cost effective way to run most jobs. -
For the
G.2X
worker type, each worker maps to 2 DPU (8 vCPUs, 32 GB of memory) with 138GB disk, and provides 1 executor per worker. We recommend this worker type for workloads such as data transforms, joins, and queries, to offers a scalable and cost effective way to run most jobs. -
For the
G.4X
worker type, each worker maps to 4 DPU (16 vCPUs, 64 GB of memory) with 256GB disk, and provides 1 executor per worker. We recommend this worker type for jobs whose workloads contain your most demanding transforms, aggregations, joins, and queries. This worker type is available only for Glue version 3.0 or later Spark ETL jobs in the following Amazon Web Services Regions: US East (Ohio), US East (N. Virginia), US West (Oregon), Asia Pacific (Singapore), Asia Pacific (Sydney), Asia Pacific (Tokyo), Canada (Central), Europe (Frankfurt), Europe (Ireland), and Europe (Stockholm). -
For the
G.8X
worker type, each worker maps to 8 DPU (32 vCPUs, 128 GB of memory) with 512GB disk, and provides 1 executor per worker. We recommend this worker type for jobs whose workloads contain your most demanding transforms, aggregations, joins, and queries. This worker type is available only for Glue version 3.0 or later Spark ETL jobs, in the same Amazon Web Services Regions as supported for theG.4X
worker type. -
For the
Z.2X
worker type, each worker maps to 2 M-DPU (8vCPUs, 64 GB of memory) with 128 GB disk, and provides up to 8 Ray workers based on the autoscaler.
Sourcepub fn get_worker_type(&self) -> &Option<WorkerType>
pub fn get_worker_type(&self) -> &Option<WorkerType>
The type of predefined worker that is allocated when a job runs. Accepts a value of G.1X, G.2X, G.4X, or G.8X for Spark jobs. Accepts the value Z.2X for Ray notebooks.
-
For the
G.1X
worker type, each worker maps to 1 DPU (4 vCPUs, 16 GB of memory) with 94GB disk, and provides 1 executor per worker. We recommend this worker type for workloads such as data transforms, joins, and queries, to offers a scalable and cost effective way to run most jobs. -
For the
G.2X
worker type, each worker maps to 2 DPU (8 vCPUs, 32 GB of memory) with 138GB disk, and provides 1 executor per worker. We recommend this worker type for workloads such as data transforms, joins, and queries, to offers a scalable and cost effective way to run most jobs. -
For the
G.4X
worker type, each worker maps to 4 DPU (16 vCPUs, 64 GB of memory) with 256GB disk, and provides 1 executor per worker. We recommend this worker type for jobs whose workloads contain your most demanding transforms, aggregations, joins, and queries. This worker type is available only for Glue version 3.0 or later Spark ETL jobs in the following Amazon Web Services Regions: US East (Ohio), US East (N. Virginia), US West (Oregon), Asia Pacific (Singapore), Asia Pacific (Sydney), Asia Pacific (Tokyo), Canada (Central), Europe (Frankfurt), Europe (Ireland), and Europe (Stockholm). -
For the
G.8X
worker type, each worker maps to 8 DPU (32 vCPUs, 128 GB of memory) with 512GB disk, and provides 1 executor per worker. We recommend this worker type for jobs whose workloads contain your most demanding transforms, aggregations, joins, and queries. This worker type is available only for Glue version 3.0 or later Spark ETL jobs, in the same Amazon Web Services Regions as supported for theG.4X
worker type. -
For the
Z.2X
worker type, each worker maps to 2 M-DPU (8vCPUs, 64 GB of memory) with 128 GB disk, and provides up to 8 Ray workers based on the autoscaler.
Sourcepub fn security_configuration(self, input: impl Into<String>) -> Self
pub fn security_configuration(self, input: impl Into<String>) -> Self
The name of the SecurityConfiguration structure to be used with the session
Sourcepub fn set_security_configuration(self, input: Option<String>) -> Self
pub fn set_security_configuration(self, input: Option<String>) -> Self
The name of the SecurityConfiguration structure to be used with the session
Sourcepub fn get_security_configuration(&self) -> &Option<String>
pub fn get_security_configuration(&self) -> &Option<String>
The name of the SecurityConfiguration structure to be used with the session
Sourcepub fn glue_version(self, input: impl Into<String>) -> Self
pub fn glue_version(self, input: impl Into<String>) -> Self
The Glue version determines the versions of Apache Spark and Python that Glue supports. The GlueVersion must be greater than 2.0.
Sourcepub fn set_glue_version(self, input: Option<String>) -> Self
pub fn set_glue_version(self, input: Option<String>) -> Self
The Glue version determines the versions of Apache Spark and Python that Glue supports. The GlueVersion must be greater than 2.0.
Sourcepub fn get_glue_version(&self) -> &Option<String>
pub fn get_glue_version(&self) -> &Option<String>
The Glue version determines the versions of Apache Spark and Python that Glue supports. The GlueVersion must be greater than 2.0.
Adds a key-value pair to Tags
.
To override the contents of this collection use set_tags
.
The map of key value pairs (tags) belonging to the session.
The map of key value pairs (tags) belonging to the session.
The map of key value pairs (tags) belonging to the session.
Sourcepub fn request_origin(self, input: impl Into<String>) -> Self
pub fn request_origin(self, input: impl Into<String>) -> Self
The origin of the request.
Sourcepub fn set_request_origin(self, input: Option<String>) -> Self
pub fn set_request_origin(self, input: Option<String>) -> Self
The origin of the request.
Sourcepub fn get_request_origin(&self) -> &Option<String>
pub fn get_request_origin(&self) -> &Option<String>
The origin of the request.
Trait Implementations§
Source§impl Clone for CreateSessionFluentBuilder
impl Clone for CreateSessionFluentBuilder
Source§fn clone(&self) -> CreateSessionFluentBuilder
fn clone(&self) -> CreateSessionFluentBuilder
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreAuto Trait Implementations§
impl Freeze for CreateSessionFluentBuilder
impl !RefUnwindSafe for CreateSessionFluentBuilder
impl Send for CreateSessionFluentBuilder
impl Sync for CreateSessionFluentBuilder
impl Unpin for CreateSessionFluentBuilder
impl !UnwindSafe for CreateSessionFluentBuilder
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);