#[non_exhaustive]pub struct JobFlowInstancesConfigBuilder { /* private fields */ }
Expand description
A builder for JobFlowInstancesConfig
.
Implementations§
Source§impl JobFlowInstancesConfigBuilder
impl JobFlowInstancesConfigBuilder
Sourcepub fn master_instance_type(self, input: impl Into<String>) -> Self
pub fn master_instance_type(self, input: impl Into<String>) -> Self
The Amazon EC2 instance type of the master node.
Sourcepub fn set_master_instance_type(self, input: Option<String>) -> Self
pub fn set_master_instance_type(self, input: Option<String>) -> Self
The Amazon EC2 instance type of the master node.
Sourcepub fn get_master_instance_type(&self) -> &Option<String>
pub fn get_master_instance_type(&self) -> &Option<String>
The Amazon EC2 instance type of the master node.
Sourcepub fn slave_instance_type(self, input: impl Into<String>) -> Self
pub fn slave_instance_type(self, input: impl Into<String>) -> Self
The Amazon EC2 instance type of the core and task nodes.
Sourcepub fn set_slave_instance_type(self, input: Option<String>) -> Self
pub fn set_slave_instance_type(self, input: Option<String>) -> Self
The Amazon EC2 instance type of the core and task nodes.
Sourcepub fn get_slave_instance_type(&self) -> &Option<String>
pub fn get_slave_instance_type(&self) -> &Option<String>
The Amazon EC2 instance type of the core and task nodes.
Sourcepub fn instance_count(self, input: i32) -> Self
pub fn instance_count(self, input: i32) -> Self
The number of Amazon EC2 instances in the cluster.
Sourcepub fn set_instance_count(self, input: Option<i32>) -> Self
pub fn set_instance_count(self, input: Option<i32>) -> Self
The number of Amazon EC2 instances in the cluster.
Sourcepub fn get_instance_count(&self) -> &Option<i32>
pub fn get_instance_count(&self) -> &Option<i32>
The number of Amazon EC2 instances in the cluster.
Sourcepub fn instance_groups(self, input: InstanceGroupConfig) -> Self
pub fn instance_groups(self, input: InstanceGroupConfig) -> Self
Appends an item to instance_groups
.
To override the contents of this collection use set_instance_groups
.
Configuration for the instance groups in a cluster.
Sourcepub fn set_instance_groups(
self,
input: Option<Vec<InstanceGroupConfig>>,
) -> Self
pub fn set_instance_groups( self, input: Option<Vec<InstanceGroupConfig>>, ) -> Self
Configuration for the instance groups in a cluster.
Sourcepub fn get_instance_groups(&self) -> &Option<Vec<InstanceGroupConfig>>
pub fn get_instance_groups(&self) -> &Option<Vec<InstanceGroupConfig>>
Configuration for the instance groups in a cluster.
Sourcepub fn instance_fleets(self, input: InstanceFleetConfig) -> Self
pub fn instance_fleets(self, input: InstanceFleetConfig) -> Self
Appends an item to instance_fleets
.
To override the contents of this collection use set_instance_fleets
.
The instance fleet configuration is available only in Amazon EMR releases 4.8.0 and later, excluding 5.0.x versions.
Describes the Amazon EC2 instances and instance configurations for clusters that use the instance fleet configuration.
Sourcepub fn set_instance_fleets(
self,
input: Option<Vec<InstanceFleetConfig>>,
) -> Self
pub fn set_instance_fleets( self, input: Option<Vec<InstanceFleetConfig>>, ) -> Self
The instance fleet configuration is available only in Amazon EMR releases 4.8.0 and later, excluding 5.0.x versions.
Describes the Amazon EC2 instances and instance configurations for clusters that use the instance fleet configuration.
Sourcepub fn get_instance_fleets(&self) -> &Option<Vec<InstanceFleetConfig>>
pub fn get_instance_fleets(&self) -> &Option<Vec<InstanceFleetConfig>>
The instance fleet configuration is available only in Amazon EMR releases 4.8.0 and later, excluding 5.0.x versions.
Describes the Amazon EC2 instances and instance configurations for clusters that use the instance fleet configuration.
Sourcepub fn ec2_key_name(self, input: impl Into<String>) -> Self
pub fn ec2_key_name(self, input: impl Into<String>) -> Self
The name of the Amazon EC2 key pair that can be used to connect to the master node using SSH as the user called "hadoop."
Sourcepub fn set_ec2_key_name(self, input: Option<String>) -> Self
pub fn set_ec2_key_name(self, input: Option<String>) -> Self
The name of the Amazon EC2 key pair that can be used to connect to the master node using SSH as the user called "hadoop."
Sourcepub fn get_ec2_key_name(&self) -> &Option<String>
pub fn get_ec2_key_name(&self) -> &Option<String>
The name of the Amazon EC2 key pair that can be used to connect to the master node using SSH as the user called "hadoop."
Sourcepub fn placement(self, input: PlacementType) -> Self
pub fn placement(self, input: PlacementType) -> Self
The Availability Zone in which the cluster runs.
Sourcepub fn set_placement(self, input: Option<PlacementType>) -> Self
pub fn set_placement(self, input: Option<PlacementType>) -> Self
The Availability Zone in which the cluster runs.
Sourcepub fn get_placement(&self) -> &Option<PlacementType>
pub fn get_placement(&self) -> &Option<PlacementType>
The Availability Zone in which the cluster runs.
Sourcepub fn keep_job_flow_alive_when_no_steps(self, input: bool) -> Self
pub fn keep_job_flow_alive_when_no_steps(self, input: bool) -> Self
Specifies whether the cluster should remain available after completing all steps. Defaults to false
. For more information about configuring cluster termination, see Control Cluster Termination in the EMR Management Guide.
Sourcepub fn set_keep_job_flow_alive_when_no_steps(self, input: Option<bool>) -> Self
pub fn set_keep_job_flow_alive_when_no_steps(self, input: Option<bool>) -> Self
Specifies whether the cluster should remain available after completing all steps. Defaults to false
. For more information about configuring cluster termination, see Control Cluster Termination in the EMR Management Guide.
Sourcepub fn get_keep_job_flow_alive_when_no_steps(&self) -> &Option<bool>
pub fn get_keep_job_flow_alive_when_no_steps(&self) -> &Option<bool>
Specifies whether the cluster should remain available after completing all steps. Defaults to false
. For more information about configuring cluster termination, see Control Cluster Termination in the EMR Management Guide.
Sourcepub fn termination_protected(self, input: bool) -> Self
pub fn termination_protected(self, input: bool) -> Self
Specifies whether to lock the cluster to prevent the Amazon EC2 instances from being terminated by API call, user intervention, or in the event of a job-flow error.
Sourcepub fn set_termination_protected(self, input: Option<bool>) -> Self
pub fn set_termination_protected(self, input: Option<bool>) -> Self
Specifies whether to lock the cluster to prevent the Amazon EC2 instances from being terminated by API call, user intervention, or in the event of a job-flow error.
Sourcepub fn get_termination_protected(&self) -> &Option<bool>
pub fn get_termination_protected(&self) -> &Option<bool>
Specifies whether to lock the cluster to prevent the Amazon EC2 instances from being terminated by API call, user intervention, or in the event of a job-flow error.
Sourcepub fn unhealthy_node_replacement(self, input: bool) -> Self
pub fn unhealthy_node_replacement(self, input: bool) -> Self
Indicates whether Amazon EMR should gracefully replace core nodes that have degraded within the cluster.
Sourcepub fn set_unhealthy_node_replacement(self, input: Option<bool>) -> Self
pub fn set_unhealthy_node_replacement(self, input: Option<bool>) -> Self
Indicates whether Amazon EMR should gracefully replace core nodes that have degraded within the cluster.
Sourcepub fn get_unhealthy_node_replacement(&self) -> &Option<bool>
pub fn get_unhealthy_node_replacement(&self) -> &Option<bool>
Indicates whether Amazon EMR should gracefully replace core nodes that have degraded within the cluster.
Sourcepub fn hadoop_version(self, input: impl Into<String>) -> Self
pub fn hadoop_version(self, input: impl Into<String>) -> Self
Applies only to Amazon EMR release versions earlier than 4.0. The Hadoop version for the cluster. Valid inputs are "0.18" (no longer maintained), "0.20" (no longer maintained), "0.20.205" (no longer maintained), "1.0.3", "2.2.0", or "2.4.0". If you do not set this value, the default of 0.18 is used, unless the AmiVersion
parameter is set in the RunJobFlow call, in which case the default version of Hadoop for that AMI version is used.
Sourcepub fn set_hadoop_version(self, input: Option<String>) -> Self
pub fn set_hadoop_version(self, input: Option<String>) -> Self
Applies only to Amazon EMR release versions earlier than 4.0. The Hadoop version for the cluster. Valid inputs are "0.18" (no longer maintained), "0.20" (no longer maintained), "0.20.205" (no longer maintained), "1.0.3", "2.2.0", or "2.4.0". If you do not set this value, the default of 0.18 is used, unless the AmiVersion
parameter is set in the RunJobFlow call, in which case the default version of Hadoop for that AMI version is used.
Sourcepub fn get_hadoop_version(&self) -> &Option<String>
pub fn get_hadoop_version(&self) -> &Option<String>
Applies only to Amazon EMR release versions earlier than 4.0. The Hadoop version for the cluster. Valid inputs are "0.18" (no longer maintained), "0.20" (no longer maintained), "0.20.205" (no longer maintained), "1.0.3", "2.2.0", or "2.4.0". If you do not set this value, the default of 0.18 is used, unless the AmiVersion
parameter is set in the RunJobFlow call, in which case the default version of Hadoop for that AMI version is used.
Sourcepub fn ec2_subnet_id(self, input: impl Into<String>) -> Self
pub fn ec2_subnet_id(self, input: impl Into<String>) -> Self
Applies to clusters that use the uniform instance group configuration. To launch the cluster in Amazon Virtual Private Cloud (Amazon VPC), set this parameter to the identifier of the Amazon VPC subnet where you want the cluster to launch. If you do not specify this value and your account supports EC2-Classic, the cluster launches in EC2-Classic.
Sourcepub fn set_ec2_subnet_id(self, input: Option<String>) -> Self
pub fn set_ec2_subnet_id(self, input: Option<String>) -> Self
Applies to clusters that use the uniform instance group configuration. To launch the cluster in Amazon Virtual Private Cloud (Amazon VPC), set this parameter to the identifier of the Amazon VPC subnet where you want the cluster to launch. If you do not specify this value and your account supports EC2-Classic, the cluster launches in EC2-Classic.
Sourcepub fn get_ec2_subnet_id(&self) -> &Option<String>
pub fn get_ec2_subnet_id(&self) -> &Option<String>
Applies to clusters that use the uniform instance group configuration. To launch the cluster in Amazon Virtual Private Cloud (Amazon VPC), set this parameter to the identifier of the Amazon VPC subnet where you want the cluster to launch. If you do not specify this value and your account supports EC2-Classic, the cluster launches in EC2-Classic.
Sourcepub fn ec2_subnet_ids(self, input: impl Into<String>) -> Self
pub fn ec2_subnet_ids(self, input: impl Into<String>) -> Self
Appends an item to ec2_subnet_ids
.
To override the contents of this collection use set_ec2_subnet_ids
.
Applies to clusters that use the instance fleet configuration. When multiple Amazon EC2 subnet IDs are specified, Amazon EMR evaluates them and launches instances in the optimal subnet.
The instance fleet configuration is available only in Amazon EMR releases 4.8.0 and later, excluding 5.0.x versions.
Sourcepub fn set_ec2_subnet_ids(self, input: Option<Vec<String>>) -> Self
pub fn set_ec2_subnet_ids(self, input: Option<Vec<String>>) -> Self
Applies to clusters that use the instance fleet configuration. When multiple Amazon EC2 subnet IDs are specified, Amazon EMR evaluates them and launches instances in the optimal subnet.
The instance fleet configuration is available only in Amazon EMR releases 4.8.0 and later, excluding 5.0.x versions.
Sourcepub fn get_ec2_subnet_ids(&self) -> &Option<Vec<String>>
pub fn get_ec2_subnet_ids(&self) -> &Option<Vec<String>>
Applies to clusters that use the instance fleet configuration. When multiple Amazon EC2 subnet IDs are specified, Amazon EMR evaluates them and launches instances in the optimal subnet.
The instance fleet configuration is available only in Amazon EMR releases 4.8.0 and later, excluding 5.0.x versions.
Sourcepub fn emr_managed_master_security_group(self, input: impl Into<String>) -> Self
pub fn emr_managed_master_security_group(self, input: impl Into<String>) -> Self
The identifier of the Amazon EC2 security group for the master node. If you specify EmrManagedMasterSecurityGroup
, you must also specify EmrManagedSlaveSecurityGroup
.
Sourcepub fn set_emr_managed_master_security_group(
self,
input: Option<String>,
) -> Self
pub fn set_emr_managed_master_security_group( self, input: Option<String>, ) -> Self
The identifier of the Amazon EC2 security group for the master node. If you specify EmrManagedMasterSecurityGroup
, you must also specify EmrManagedSlaveSecurityGroup
.
Sourcepub fn get_emr_managed_master_security_group(&self) -> &Option<String>
pub fn get_emr_managed_master_security_group(&self) -> &Option<String>
The identifier of the Amazon EC2 security group for the master node. If you specify EmrManagedMasterSecurityGroup
, you must also specify EmrManagedSlaveSecurityGroup
.
Sourcepub fn emr_managed_slave_security_group(self, input: impl Into<String>) -> Self
pub fn emr_managed_slave_security_group(self, input: impl Into<String>) -> Self
The identifier of the Amazon EC2 security group for the core and task nodes. If you specify EmrManagedSlaveSecurityGroup
, you must also specify EmrManagedMasterSecurityGroup
.
Sourcepub fn set_emr_managed_slave_security_group(self, input: Option<String>) -> Self
pub fn set_emr_managed_slave_security_group(self, input: Option<String>) -> Self
The identifier of the Amazon EC2 security group for the core and task nodes. If you specify EmrManagedSlaveSecurityGroup
, you must also specify EmrManagedMasterSecurityGroup
.
Sourcepub fn get_emr_managed_slave_security_group(&self) -> &Option<String>
pub fn get_emr_managed_slave_security_group(&self) -> &Option<String>
The identifier of the Amazon EC2 security group for the core and task nodes. If you specify EmrManagedSlaveSecurityGroup
, you must also specify EmrManagedMasterSecurityGroup
.
Sourcepub fn service_access_security_group(self, input: impl Into<String>) -> Self
pub fn service_access_security_group(self, input: impl Into<String>) -> Self
The identifier of the Amazon EC2 security group for the Amazon EMR service to access clusters in VPC private subnets.
Sourcepub fn set_service_access_security_group(self, input: Option<String>) -> Self
pub fn set_service_access_security_group(self, input: Option<String>) -> Self
The identifier of the Amazon EC2 security group for the Amazon EMR service to access clusters in VPC private subnets.
Sourcepub fn get_service_access_security_group(&self) -> &Option<String>
pub fn get_service_access_security_group(&self) -> &Option<String>
The identifier of the Amazon EC2 security group for the Amazon EMR service to access clusters in VPC private subnets.
Sourcepub fn additional_master_security_groups(self, input: impl Into<String>) -> Self
pub fn additional_master_security_groups(self, input: impl Into<String>) -> Self
Appends an item to additional_master_security_groups
.
To override the contents of this collection use set_additional_master_security_groups
.
A list of additional Amazon EC2 security group IDs for the master node.
Sourcepub fn set_additional_master_security_groups(
self,
input: Option<Vec<String>>,
) -> Self
pub fn set_additional_master_security_groups( self, input: Option<Vec<String>>, ) -> Self
A list of additional Amazon EC2 security group IDs for the master node.
Sourcepub fn get_additional_master_security_groups(&self) -> &Option<Vec<String>>
pub fn get_additional_master_security_groups(&self) -> &Option<Vec<String>>
A list of additional Amazon EC2 security group IDs for the master node.
Sourcepub fn additional_slave_security_groups(self, input: impl Into<String>) -> Self
pub fn additional_slave_security_groups(self, input: impl Into<String>) -> Self
Appends an item to additional_slave_security_groups
.
To override the contents of this collection use set_additional_slave_security_groups
.
A list of additional Amazon EC2 security group IDs for the core and task nodes.
Sourcepub fn set_additional_slave_security_groups(
self,
input: Option<Vec<String>>,
) -> Self
pub fn set_additional_slave_security_groups( self, input: Option<Vec<String>>, ) -> Self
A list of additional Amazon EC2 security group IDs for the core and task nodes.
Sourcepub fn get_additional_slave_security_groups(&self) -> &Option<Vec<String>>
pub fn get_additional_slave_security_groups(&self) -> &Option<Vec<String>>
A list of additional Amazon EC2 security group IDs for the core and task nodes.
Sourcepub fn build(self) -> JobFlowInstancesConfig
pub fn build(self) -> JobFlowInstancesConfig
Consumes the builder and constructs a JobFlowInstancesConfig
.
Trait Implementations§
Source§impl Clone for JobFlowInstancesConfigBuilder
impl Clone for JobFlowInstancesConfigBuilder
Source§fn clone(&self) -> JobFlowInstancesConfigBuilder
fn clone(&self) -> JobFlowInstancesConfigBuilder
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Default for JobFlowInstancesConfigBuilder
impl Default for JobFlowInstancesConfigBuilder
Source§fn default() -> JobFlowInstancesConfigBuilder
fn default() -> JobFlowInstancesConfigBuilder
Source§impl PartialEq for JobFlowInstancesConfigBuilder
impl PartialEq for JobFlowInstancesConfigBuilder
Source§fn eq(&self, other: &JobFlowInstancesConfigBuilder) -> bool
fn eq(&self, other: &JobFlowInstancesConfigBuilder) -> bool
self
and other
values to be equal, and is used by ==
.impl StructuralPartialEq for JobFlowInstancesConfigBuilder
Auto Trait Implementations§
impl Freeze for JobFlowInstancesConfigBuilder
impl RefUnwindSafe for JobFlowInstancesConfigBuilder
impl Send for JobFlowInstancesConfigBuilder
impl Sync for JobFlowInstancesConfigBuilder
impl Unpin for JobFlowInstancesConfigBuilder
impl UnwindSafe for JobFlowInstancesConfigBuilder
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);