Skip to content

EMRClient#

Index > EMR > EMRClient

Auto-generated documentation for EMR type annotations stubs module types-boto3-emr.

EMRClient#

Type annotations and code completion for boto3.client("emr"). boto3 documentation

# EMRClient usage example

from boto3.session import Session
from types_boto3_emr.client import EMRClient

def get_emr_client() -> EMRClient:
    return Session().client("emr")

Exceptions#

boto3 client exceptions are generated in runtime. This class provides code completion for boto3.client("emr").exceptions structure.

# Exceptions.exceptions usage example

client = boto3.client("emr")

try:
    do_something(client)
except (
    client.exceptions.ClientError,
    client.exceptions.InternalServerError,
    client.exceptions.InternalServerException,
    client.exceptions.InvalidRequestException,
) as e:
    print(e)
# Exceptions.exceptions type checking example

from types_boto3_emr.client import Exceptions

def handle_error(exc: Exceptions.ClientError) -> None:
    ...

Methods#

can_paginate#

Type annotations and code completion for boto3.client("emr").can_paginate method. boto3 documentation

# can_paginate method definition

def can_paginate(
    self,
    operation_name: str,
) -> bool:
    ...

generate_presigned_url#

Type annotations and code completion for boto3.client("emr").generate_presigned_url method. boto3 documentation

# generate_presigned_url method definition

def generate_presigned_url(
    self,
    ClientMethod: str,
    Params: Mapping[str, Any] = ...,
    ExpiresIn: int = 3600,
    HttpMethod: str = ...,
) -> str:
    ...

add_instance_fleet#

Adds an instance fleet to a running cluster.

Type annotations and code completion for boto3.client("emr").add_instance_fleet method. boto3 documentation

# add_instance_fleet method definition

def add_instance_fleet(
    self,
    *,
    ClusterId: str,
    InstanceFleet: InstanceFleetConfigTypeDef,  # (1)
) -> AddInstanceFleetOutputTypeDef:  # (2)
    ...
  1. See InstanceFleetConfigTypeDef
  2. See AddInstanceFleetOutputTypeDef
# add_instance_fleet method usage example with argument unpacking

kwargs: AddInstanceFleetInputRequestTypeDef = {  # (1)
    "ClusterId": ...,
    "InstanceFleet": ...,
}

parent.add_instance_fleet(**kwargs)
  1. See AddInstanceFleetInputRequestTypeDef

add_instance_groups#

Adds one or more instance groups to a running cluster.

Type annotations and code completion for boto3.client("emr").add_instance_groups method. boto3 documentation

# add_instance_groups method definition

def add_instance_groups(
    self,
    *,
    InstanceGroups: Sequence[InstanceGroupConfigTypeDef],  # (1)
    JobFlowId: str,
) -> AddInstanceGroupsOutputTypeDef:  # (2)
    ...
  1. See InstanceGroupConfigTypeDef
  2. See AddInstanceGroupsOutputTypeDef
# add_instance_groups method usage example with argument unpacking

kwargs: AddInstanceGroupsInputRequestTypeDef = {  # (1)
    "InstanceGroups": ...,
    "JobFlowId": ...,
}

parent.add_instance_groups(**kwargs)
  1. See AddInstanceGroupsInputRequestTypeDef

add_job_flow_steps#

AddJobFlowSteps adds new steps to a running cluster.

Type annotations and code completion for boto3.client("emr").add_job_flow_steps method. boto3 documentation

# add_job_flow_steps method definition

def add_job_flow_steps(
    self,
    *,
    JobFlowId: str,
    Steps: Sequence[StepConfigUnionTypeDef],  # (1)
    ExecutionRoleArn: str = ...,
) -> AddJobFlowStepsOutputTypeDef:  # (2)
    ...
  1. See StepConfigTypeDef StepConfigOutputTypeDef
  2. See AddJobFlowStepsOutputTypeDef
# add_job_flow_steps method usage example with argument unpacking

kwargs: AddJobFlowStepsInputRequestTypeDef = {  # (1)
    "JobFlowId": ...,
    "Steps": ...,
}

parent.add_job_flow_steps(**kwargs)
  1. See AddJobFlowStepsInputRequestTypeDef

add_tags#

Adds tags to an Amazon EMR resource, such as a cluster or an Amazon EMR Studio.

Type annotations and code completion for boto3.client("emr").add_tags method. boto3 documentation

# add_tags method definition

def add_tags(
    self,
    *,
    ResourceId: str,
    Tags: Sequence[TagTypeDef],  # (1)
) -> dict[str, Any]:
    ...
  1. See TagTypeDef
# add_tags method usage example with argument unpacking

kwargs: AddTagsInputRequestTypeDef = {  # (1)
    "ResourceId": ...,
    "Tags": ...,
}

parent.add_tags(**kwargs)
  1. See AddTagsInputRequestTypeDef

cancel_steps#

Cancels a pending step or steps in a running cluster.

Type annotations and code completion for boto3.client("emr").cancel_steps method. boto3 documentation

# cancel_steps method definition

def cancel_steps(
    self,
    *,
    ClusterId: str,
    StepIds: Sequence[str],
    StepCancellationOption: StepCancellationOptionType = ...,  # (1)
) -> CancelStepsOutputTypeDef:  # (2)
    ...
  1. See StepCancellationOptionType
  2. See CancelStepsOutputTypeDef
# cancel_steps method usage example with argument unpacking

kwargs: CancelStepsInputRequestTypeDef = {  # (1)
    "ClusterId": ...,
    "StepIds": ...,
}

parent.cancel_steps(**kwargs)
  1. See CancelStepsInputRequestTypeDef

create_security_configuration#

Creates a security configuration, which is stored in the service and can be specified when a cluster is created.

Type annotations and code completion for boto3.client("emr").create_security_configuration method. boto3 documentation

# create_security_configuration method definition

def create_security_configuration(
    self,
    *,
    Name: str,
    SecurityConfiguration: str,
) -> CreateSecurityConfigurationOutputTypeDef:  # (1)
    ...
  1. See CreateSecurityConfigurationOutputTypeDef
# create_security_configuration method usage example with argument unpacking

kwargs: CreateSecurityConfigurationInputRequestTypeDef = {  # (1)
    "Name": ...,
    "SecurityConfiguration": ...,
}

parent.create_security_configuration(**kwargs)
  1. See CreateSecurityConfigurationInputRequestTypeDef

create_studio#

Creates a new Amazon EMR Studio.

Type annotations and code completion for boto3.client("emr").create_studio method. boto3 documentation

# create_studio method definition

def create_studio(
    self,
    *,
    Name: str,
    AuthMode: AuthModeType,  # (1)
    VpcId: str,
    SubnetIds: Sequence[str],
    ServiceRole: str,
    WorkspaceSecurityGroupId: str,
    EngineSecurityGroupId: str,
    DefaultS3Location: str,
    Description: str = ...,
    UserRole: str = ...,
    IdpAuthUrl: str = ...,
    IdpRelayStateParameterName: str = ...,
    Tags: Sequence[TagTypeDef] = ...,  # (2)
    TrustedIdentityPropagationEnabled: bool = ...,
    IdcUserAssignment: IdcUserAssignmentType = ...,  # (3)
    IdcInstanceArn: str = ...,
    EncryptionKeyArn: str = ...,
) -> CreateStudioOutputTypeDef:  # (4)
    ...
  1. See AuthModeType
  2. See TagTypeDef
  3. See IdcUserAssignmentType
  4. See CreateStudioOutputTypeDef
# create_studio method usage example with argument unpacking

kwargs: CreateStudioInputRequestTypeDef = {  # (1)
    "Name": ...,
    "AuthMode": ...,
    "VpcId": ...,
    "SubnetIds": ...,
    "ServiceRole": ...,
    "WorkspaceSecurityGroupId": ...,
    "EngineSecurityGroupId": ...,
    "DefaultS3Location": ...,
}

parent.create_studio(**kwargs)
  1. See CreateStudioInputRequestTypeDef

create_studio_session_mapping#

Maps a user or group to the Amazon EMR Studio specified by StudioId, and applies a session policy to refine Studio permissions for that user or group.

Type annotations and code completion for boto3.client("emr").create_studio_session_mapping method. boto3 documentation

# create_studio_session_mapping method definition

def create_studio_session_mapping(
    self,
    *,
    StudioId: str,
    IdentityType: IdentityTypeType,  # (1)
    SessionPolicyArn: str,
    IdentityId: str = ...,
    IdentityName: str = ...,
) -> EmptyResponseMetadataTypeDef:  # (2)
    ...
  1. See IdentityTypeType
  2. See EmptyResponseMetadataTypeDef
# create_studio_session_mapping method usage example with argument unpacking

kwargs: CreateStudioSessionMappingInputRequestTypeDef = {  # (1)
    "StudioId": ...,
    "IdentityType": ...,
    "SessionPolicyArn": ...,
}

parent.create_studio_session_mapping(**kwargs)
  1. See CreateStudioSessionMappingInputRequestTypeDef

delete_security_configuration#

Deletes a security configuration.

Type annotations and code completion for boto3.client("emr").delete_security_configuration method. boto3 documentation

# delete_security_configuration method definition

def delete_security_configuration(
    self,
    *,
    Name: str,
) -> dict[str, Any]:
    ...
# delete_security_configuration method usage example with argument unpacking

kwargs: DeleteSecurityConfigurationInputRequestTypeDef = {  # (1)
    "Name": ...,
}

parent.delete_security_configuration(**kwargs)
  1. See DeleteSecurityConfigurationInputRequestTypeDef

delete_studio#

Removes an Amazon EMR Studio from the Studio metadata store.

Type annotations and code completion for boto3.client("emr").delete_studio method. boto3 documentation

# delete_studio method definition

def delete_studio(
    self,
    *,
    StudioId: str,
) -> EmptyResponseMetadataTypeDef:  # (1)
    ...
  1. See EmptyResponseMetadataTypeDef
# delete_studio method usage example with argument unpacking

kwargs: DeleteStudioInputRequestTypeDef = {  # (1)
    "StudioId": ...,
}

parent.delete_studio(**kwargs)
  1. See DeleteStudioInputRequestTypeDef

delete_studio_session_mapping#

Removes a user or group from an Amazon EMR Studio.

Type annotations and code completion for boto3.client("emr").delete_studio_session_mapping method. boto3 documentation

# delete_studio_session_mapping method definition

def delete_studio_session_mapping(
    self,
    *,
    StudioId: str,
    IdentityType: IdentityTypeType,  # (1)
    IdentityId: str = ...,
    IdentityName: str = ...,
) -> EmptyResponseMetadataTypeDef:  # (2)
    ...
  1. See IdentityTypeType
  2. See EmptyResponseMetadataTypeDef
# delete_studio_session_mapping method usage example with argument unpacking

kwargs: DeleteStudioSessionMappingInputRequestTypeDef = {  # (1)
    "StudioId": ...,
    "IdentityType": ...,
}

parent.delete_studio_session_mapping(**kwargs)
  1. See DeleteStudioSessionMappingInputRequestTypeDef

describe_cluster#

Provides cluster-level details including status, hardware and software configuration, VPC settings, and so on.

Type annotations and code completion for boto3.client("emr").describe_cluster method. boto3 documentation

# describe_cluster method definition

def describe_cluster(
    self,
    *,
    ClusterId: str,
) -> DescribeClusterOutputTypeDef:  # (1)
    ...
  1. See DescribeClusterOutputTypeDef
# describe_cluster method usage example with argument unpacking

kwargs: DescribeClusterInputRequestTypeDef = {  # (1)
    "ClusterId": ...,
}

parent.describe_cluster(**kwargs)
  1. See DescribeClusterInputRequestTypeDef

describe_job_flows#

This API is no longer supported and will eventually be removed.

Type annotations and code completion for boto3.client("emr").describe_job_flows method. boto3 documentation

# describe_job_flows method definition

def describe_job_flows(
    self,
    *,
    CreatedAfter: TimestampTypeDef = ...,
    CreatedBefore: TimestampTypeDef = ...,
    JobFlowIds: Sequence[str] = ...,
    JobFlowStates: Sequence[JobFlowExecutionStateType] = ...,  # (1)
) -> DescribeJobFlowsOutputTypeDef:  # (2)
    ...
  1. See JobFlowExecutionStateType
  2. See DescribeJobFlowsOutputTypeDef
# describe_job_flows method usage example with argument unpacking

kwargs: DescribeJobFlowsInputRequestTypeDef = {  # (1)
    "CreatedAfter": ...,
}

parent.describe_job_flows(**kwargs)
  1. See DescribeJobFlowsInputRequestTypeDef

describe_notebook_execution#

Provides details of a notebook execution.

Type annotations and code completion for boto3.client("emr").describe_notebook_execution method. boto3 documentation

# describe_notebook_execution method definition

def describe_notebook_execution(
    self,
    *,
    NotebookExecutionId: str,
) -> DescribeNotebookExecutionOutputTypeDef:  # (1)
    ...
  1. See DescribeNotebookExecutionOutputTypeDef
# describe_notebook_execution method usage example with argument unpacking

kwargs: DescribeNotebookExecutionInputRequestTypeDef = {  # (1)
    "NotebookExecutionId": ...,
}

parent.describe_notebook_execution(**kwargs)
  1. See DescribeNotebookExecutionInputRequestTypeDef

describe_release_label#

Provides Amazon EMR release label details, such as the releases available the Region where the API request is run, and the available applications for a specific Amazon EMR release label.

Type annotations and code completion for boto3.client("emr").describe_release_label method. boto3 documentation

# describe_release_label method definition

def describe_release_label(
    self,
    *,
    ReleaseLabel: str = ...,
    NextToken: str = ...,
    MaxResults: int = ...,
) -> DescribeReleaseLabelOutputTypeDef:  # (1)
    ...
  1. See DescribeReleaseLabelOutputTypeDef
# describe_release_label method usage example with argument unpacking

kwargs: DescribeReleaseLabelInputRequestTypeDef = {  # (1)
    "ReleaseLabel": ...,
}

parent.describe_release_label(**kwargs)
  1. See DescribeReleaseLabelInputRequestTypeDef

describe_security_configuration#

Provides the details of a security configuration by returning the configuration JSON.

Type annotations and code completion for boto3.client("emr").describe_security_configuration method. boto3 documentation

# describe_security_configuration method definition

def describe_security_configuration(
    self,
    *,
    Name: str,
) -> DescribeSecurityConfigurationOutputTypeDef:  # (1)
    ...
  1. See DescribeSecurityConfigurationOutputTypeDef
# describe_security_configuration method usage example with argument unpacking

kwargs: DescribeSecurityConfigurationInputRequestTypeDef = {  # (1)
    "Name": ...,
}

parent.describe_security_configuration(**kwargs)
  1. See DescribeSecurityConfigurationInputRequestTypeDef

describe_step#

Provides more detail about the cluster step.

Type annotations and code completion for boto3.client("emr").describe_step method. boto3 documentation

# describe_step method definition

def describe_step(
    self,
    *,
    ClusterId: str,
    StepId: str,
) -> DescribeStepOutputTypeDef:  # (1)
    ...
  1. See DescribeStepOutputTypeDef
# describe_step method usage example with argument unpacking

kwargs: DescribeStepInputRequestTypeDef = {  # (1)
    "ClusterId": ...,
    "StepId": ...,
}

parent.describe_step(**kwargs)
  1. See DescribeStepInputRequestTypeDef

describe_studio#

Returns details for the specified Amazon EMR Studio including ID, Name, VPC, Studio access URL, and so on.

Type annotations and code completion for boto3.client("emr").describe_studio method. boto3 documentation

# describe_studio method definition

def describe_studio(
    self,
    *,
    StudioId: str,
) -> DescribeStudioOutputTypeDef:  # (1)
    ...
  1. See DescribeStudioOutputTypeDef
# describe_studio method usage example with argument unpacking

kwargs: DescribeStudioInputRequestTypeDef = {  # (1)
    "StudioId": ...,
}

parent.describe_studio(**kwargs)
  1. See DescribeStudioInputRequestTypeDef

get_auto_termination_policy#

Returns the auto-termination policy for an Amazon EMR cluster.

Type annotations and code completion for boto3.client("emr").get_auto_termination_policy method. boto3 documentation

# get_auto_termination_policy method definition

def get_auto_termination_policy(
    self,
    *,
    ClusterId: str,
) -> GetAutoTerminationPolicyOutputTypeDef:  # (1)
    ...
  1. See GetAutoTerminationPolicyOutputTypeDef
# get_auto_termination_policy method usage example with argument unpacking

kwargs: GetAutoTerminationPolicyInputRequestTypeDef = {  # (1)
    "ClusterId": ...,
}

parent.get_auto_termination_policy(**kwargs)
  1. See GetAutoTerminationPolicyInputRequestTypeDef

get_block_public_access_configuration#

Returns the Amazon EMR block public access configuration for your Amazon Web Services account in the current Region.

Type annotations and code completion for boto3.client("emr").get_block_public_access_configuration method. boto3 documentation

# get_block_public_access_configuration method definition

def get_block_public_access_configuration(
    self,
) -> GetBlockPublicAccessConfigurationOutputTypeDef:  # (1)
    ...
  1. See GetBlockPublicAccessConfigurationOutputTypeDef

get_cluster_session_credentials#

Provides temporary, HTTP basic credentials that are associated with a given runtime IAM role and used by a cluster with fine-grained access control activated.

Type annotations and code completion for boto3.client("emr").get_cluster_session_credentials method. boto3 documentation

# get_cluster_session_credentials method definition

def get_cluster_session_credentials(
    self,
    *,
    ClusterId: str,
    ExecutionRoleArn: str = ...,
) -> GetClusterSessionCredentialsOutputTypeDef:  # (1)
    ...
  1. See GetClusterSessionCredentialsOutputTypeDef
# get_cluster_session_credentials method usage example with argument unpacking

kwargs: GetClusterSessionCredentialsInputRequestTypeDef = {  # (1)
    "ClusterId": ...,
}

parent.get_cluster_session_credentials(**kwargs)
  1. See GetClusterSessionCredentialsInputRequestTypeDef

get_managed_scaling_policy#

Fetches the attached managed scaling policy for an Amazon EMR cluster.

Type annotations and code completion for boto3.client("emr").get_managed_scaling_policy method. boto3 documentation

# get_managed_scaling_policy method definition

def get_managed_scaling_policy(
    self,
    *,
    ClusterId: str,
) -> GetManagedScalingPolicyOutputTypeDef:  # (1)
    ...
  1. See GetManagedScalingPolicyOutputTypeDef
# get_managed_scaling_policy method usage example with argument unpacking

kwargs: GetManagedScalingPolicyInputRequestTypeDef = {  # (1)
    "ClusterId": ...,
}

parent.get_managed_scaling_policy(**kwargs)
  1. See GetManagedScalingPolicyInputRequestTypeDef

get_studio_session_mapping#

Fetches mapping details for the specified Amazon EMR Studio and identity (user or group).

Type annotations and code completion for boto3.client("emr").get_studio_session_mapping method. boto3 documentation

# get_studio_session_mapping method definition

def get_studio_session_mapping(
    self,
    *,
    StudioId: str,
    IdentityType: IdentityTypeType,  # (1)
    IdentityId: str = ...,
    IdentityName: str = ...,
) -> GetStudioSessionMappingOutputTypeDef:  # (2)
    ...
  1. See IdentityTypeType
  2. See GetStudioSessionMappingOutputTypeDef
# get_studio_session_mapping method usage example with argument unpacking

kwargs: GetStudioSessionMappingInputRequestTypeDef = {  # (1)
    "StudioId": ...,
    "IdentityType": ...,
}

parent.get_studio_session_mapping(**kwargs)
  1. See GetStudioSessionMappingInputRequestTypeDef

list_bootstrap_actions#

Provides information about the bootstrap actions associated with a cluster.

Type annotations and code completion for boto3.client("emr").list_bootstrap_actions method. boto3 documentation

# list_bootstrap_actions method definition

def list_bootstrap_actions(
    self,
    *,
    ClusterId: str,
    Marker: str = ...,
) -> ListBootstrapActionsOutputTypeDef:  # (1)
    ...
  1. See ListBootstrapActionsOutputTypeDef
# list_bootstrap_actions method usage example with argument unpacking

kwargs: ListBootstrapActionsInputRequestTypeDef = {  # (1)
    "ClusterId": ...,
}

parent.list_bootstrap_actions(**kwargs)
  1. See ListBootstrapActionsInputRequestTypeDef

list_clusters#

Provides the status of all clusters visible to this Amazon Web Services account.

Type annotations and code completion for boto3.client("emr").list_clusters method. boto3 documentation

# list_clusters method definition

def list_clusters(
    self,
    *,
    CreatedAfter: TimestampTypeDef = ...,
    CreatedBefore: TimestampTypeDef = ...,
    ClusterStates: Sequence[ClusterStateType] = ...,  # (1)
    Marker: str = ...,
) -> ListClustersOutputTypeDef:  # (2)
    ...
  1. See ClusterStateType
  2. See ListClustersOutputTypeDef
# list_clusters method usage example with argument unpacking

kwargs: ListClustersInputRequestTypeDef = {  # (1)
    "CreatedAfter": ...,
}

parent.list_clusters(**kwargs)
  1. See ListClustersInputRequestTypeDef

list_instance_fleets#

Lists all available details about the instance fleets in a cluster.

Type annotations and code completion for boto3.client("emr").list_instance_fleets method. boto3 documentation

# list_instance_fleets method definition

def list_instance_fleets(
    self,
    *,
    ClusterId: str,
    Marker: str = ...,
) -> ListInstanceFleetsOutputTypeDef:  # (1)
    ...
  1. See ListInstanceFleetsOutputTypeDef
# list_instance_fleets method usage example with argument unpacking

kwargs: ListInstanceFleetsInputRequestTypeDef = {  # (1)
    "ClusterId": ...,
}

parent.list_instance_fleets(**kwargs)
  1. See ListInstanceFleetsInputRequestTypeDef

list_instance_groups#

Provides all available details about the instance groups in a cluster.

Type annotations and code completion for boto3.client("emr").list_instance_groups method. boto3 documentation

# list_instance_groups method definition

def list_instance_groups(
    self,
    *,
    ClusterId: str,
    Marker: str = ...,
) -> ListInstanceGroupsOutputTypeDef:  # (1)
    ...
  1. See ListInstanceGroupsOutputTypeDef
# list_instance_groups method usage example with argument unpacking

kwargs: ListInstanceGroupsInputRequestTypeDef = {  # (1)
    "ClusterId": ...,
}

parent.list_instance_groups(**kwargs)
  1. See ListInstanceGroupsInputRequestTypeDef

list_instances#

Provides information for all active Amazon EC2 instances and Amazon EC2 instances terminated in the last 30 days, up to a maximum of 2,000.

Type annotations and code completion for boto3.client("emr").list_instances method. boto3 documentation

# list_instances method definition

def list_instances(
    self,
    *,
    ClusterId: str,
    InstanceGroupId: str = ...,
    InstanceGroupTypes: Sequence[InstanceGroupTypeType] = ...,  # (1)
    InstanceFleetId: str = ...,
    InstanceFleetType: InstanceFleetTypeType = ...,  # (2)
    InstanceStates: Sequence[InstanceStateType] = ...,  # (3)
    Marker: str = ...,
) -> ListInstancesOutputTypeDef:  # (4)
    ...
  1. See InstanceGroupTypeType
  2. See InstanceFleetTypeType
  3. See InstanceStateType
  4. See ListInstancesOutputTypeDef
# list_instances method usage example with argument unpacking

kwargs: ListInstancesInputRequestTypeDef = {  # (1)
    "ClusterId": ...,
}

parent.list_instances(**kwargs)
  1. See ListInstancesInputRequestTypeDef

list_notebook_executions#

Provides summaries of all notebook executions.

Type annotations and code completion for boto3.client("emr").list_notebook_executions method. boto3 documentation

# list_notebook_executions method definition

def list_notebook_executions(
    self,
    *,
    EditorId: str = ...,
    Status: NotebookExecutionStatusType = ...,  # (1)
    From: TimestampTypeDef = ...,
    To: TimestampTypeDef = ...,
    Marker: str = ...,
    ExecutionEngineId: str = ...,
) -> ListNotebookExecutionsOutputTypeDef:  # (2)
    ...
  1. See NotebookExecutionStatusType
  2. See ListNotebookExecutionsOutputTypeDef
# list_notebook_executions method usage example with argument unpacking

kwargs: ListNotebookExecutionsInputRequestTypeDef = {  # (1)
    "EditorId": ...,
}

parent.list_notebook_executions(**kwargs)
  1. See ListNotebookExecutionsInputRequestTypeDef

list_release_labels#

Retrieves release labels of Amazon EMR services in the Region where the API is called.

Type annotations and code completion for boto3.client("emr").list_release_labels method. boto3 documentation

# list_release_labels method definition

def list_release_labels(
    self,
    *,
    Filters: ReleaseLabelFilterTypeDef = ...,  # (1)
    NextToken: str = ...,
    MaxResults: int = ...,
) -> ListReleaseLabelsOutputTypeDef:  # (2)
    ...
  1. See ReleaseLabelFilterTypeDef
  2. See ListReleaseLabelsOutputTypeDef
# list_release_labels method usage example with argument unpacking

kwargs: ListReleaseLabelsInputRequestTypeDef = {  # (1)
    "Filters": ...,
}

parent.list_release_labels(**kwargs)
  1. See ListReleaseLabelsInputRequestTypeDef

list_security_configurations#

Lists all the security configurations visible to this account, providing their creation dates and times, and their names.

Type annotations and code completion for boto3.client("emr").list_security_configurations method. boto3 documentation

# list_security_configurations method definition

def list_security_configurations(
    self,
    *,
    Marker: str = ...,
) -> ListSecurityConfigurationsOutputTypeDef:  # (1)
    ...
  1. See ListSecurityConfigurationsOutputTypeDef
# list_security_configurations method usage example with argument unpacking

kwargs: ListSecurityConfigurationsInputRequestTypeDef = {  # (1)
    "Marker": ...,
}

parent.list_security_configurations(**kwargs)
  1. See ListSecurityConfigurationsInputRequestTypeDef

list_steps#

Provides a list of steps for the cluster in reverse order unless you specify stepIds with the request or filter by StepStates.

Type annotations and code completion for boto3.client("emr").list_steps method. boto3 documentation

# list_steps method definition

def list_steps(
    self,
    *,
    ClusterId: str,
    StepStates: Sequence[StepStateType] = ...,  # (1)
    StepIds: Sequence[str] = ...,
    Marker: str = ...,
) -> ListStepsOutputTypeDef:  # (2)
    ...
  1. See StepStateType
  2. See ListStepsOutputTypeDef
# list_steps method usage example with argument unpacking

kwargs: ListStepsInputRequestTypeDef = {  # (1)
    "ClusterId": ...,
}

parent.list_steps(**kwargs)
  1. See ListStepsInputRequestTypeDef

list_studio_session_mappings#

Returns a list of all user or group session mappings for the Amazon EMR Studio specified by StudioId.

Type annotations and code completion for boto3.client("emr").list_studio_session_mappings method. boto3 documentation

# list_studio_session_mappings method definition

def list_studio_session_mappings(
    self,
    *,
    StudioId: str = ...,
    IdentityType: IdentityTypeType = ...,  # (1)
    Marker: str = ...,
) -> ListStudioSessionMappingsOutputTypeDef:  # (2)
    ...
  1. See IdentityTypeType
  2. See ListStudioSessionMappingsOutputTypeDef
# list_studio_session_mappings method usage example with argument unpacking

kwargs: ListStudioSessionMappingsInputRequestTypeDef = {  # (1)
    "StudioId": ...,
}

parent.list_studio_session_mappings(**kwargs)
  1. See ListStudioSessionMappingsInputRequestTypeDef

list_studios#

Returns a list of all Amazon EMR Studios associated with the Amazon Web Services account.

Type annotations and code completion for boto3.client("emr").list_studios method. boto3 documentation

# list_studios method definition

def list_studios(
    self,
    *,
    Marker: str = ...,
) -> ListStudiosOutputTypeDef:  # (1)
    ...
  1. See ListStudiosOutputTypeDef
# list_studios method usage example with argument unpacking

kwargs: ListStudiosInputRequestTypeDef = {  # (1)
    "Marker": ...,
}

parent.list_studios(**kwargs)
  1. See ListStudiosInputRequestTypeDef

list_supported_instance_types#

A list of the instance types that Amazon EMR supports.

Type annotations and code completion for boto3.client("emr").list_supported_instance_types method. boto3 documentation

# list_supported_instance_types method definition

def list_supported_instance_types(
    self,
    *,
    ReleaseLabel: str,
    Marker: str = ...,
) -> ListSupportedInstanceTypesOutputTypeDef:  # (1)
    ...
  1. See ListSupportedInstanceTypesOutputTypeDef
# list_supported_instance_types method usage example with argument unpacking

kwargs: ListSupportedInstanceTypesInputRequestTypeDef = {  # (1)
    "ReleaseLabel": ...,
}

parent.list_supported_instance_types(**kwargs)
  1. See ListSupportedInstanceTypesInputRequestTypeDef

modify_cluster#

Modifies the number of steps that can be executed concurrently for the cluster specified using ClusterID.

Type annotations and code completion for boto3.client("emr").modify_cluster method. boto3 documentation

# modify_cluster method definition

def modify_cluster(
    self,
    *,
    ClusterId: str,
    StepConcurrencyLevel: int = ...,
) -> ModifyClusterOutputTypeDef:  # (1)
    ...
  1. See ModifyClusterOutputTypeDef
# modify_cluster method usage example with argument unpacking

kwargs: ModifyClusterInputRequestTypeDef = {  # (1)
    "ClusterId": ...,
}

parent.modify_cluster(**kwargs)
  1. See ModifyClusterInputRequestTypeDef

modify_instance_fleet#

Modifies the target On-Demand and target Spot capacities for the instance fleet with the specified InstanceFleetID within the cluster specified using ClusterID.

Type annotations and code completion for boto3.client("emr").modify_instance_fleet method. boto3 documentation

# modify_instance_fleet method definition

def modify_instance_fleet(
    self,
    *,
    ClusterId: str,
    InstanceFleet: InstanceFleetModifyConfigTypeDef,  # (1)
) -> EmptyResponseMetadataTypeDef:  # (2)
    ...
  1. See InstanceFleetModifyConfigTypeDef
  2. See EmptyResponseMetadataTypeDef
# modify_instance_fleet method usage example with argument unpacking

kwargs: ModifyInstanceFleetInputRequestTypeDef = {  # (1)
    "ClusterId": ...,
    "InstanceFleet": ...,
}

parent.modify_instance_fleet(**kwargs)
  1. See ModifyInstanceFleetInputRequestTypeDef

modify_instance_groups#

ModifyInstanceGroups modifies the number of nodes and configuration settings of an instance group.

Type annotations and code completion for boto3.client("emr").modify_instance_groups method. boto3 documentation

# modify_instance_groups method definition

def modify_instance_groups(
    self,
    *,
    ClusterId: str = ...,
    InstanceGroups: Sequence[InstanceGroupModifyConfigTypeDef] = ...,  # (1)
) -> EmptyResponseMetadataTypeDef:  # (2)
    ...
  1. See InstanceGroupModifyConfigTypeDef
  2. See EmptyResponseMetadataTypeDef
# modify_instance_groups method usage example with argument unpacking

kwargs: ModifyInstanceGroupsInputRequestTypeDef = {  # (1)
    "ClusterId": ...,
}

parent.modify_instance_groups(**kwargs)
  1. See ModifyInstanceGroupsInputRequestTypeDef

put_auto_scaling_policy#

Creates or updates an automatic scaling policy for a core instance group or task instance group in an Amazon EMR cluster.

Type annotations and code completion for boto3.client("emr").put_auto_scaling_policy method. boto3 documentation

# put_auto_scaling_policy method definition

def put_auto_scaling_policy(
    self,
    *,
    ClusterId: str,
    InstanceGroupId: str,
    AutoScalingPolicy: AutoScalingPolicyTypeDef,  # (1)
) -> PutAutoScalingPolicyOutputTypeDef:  # (2)
    ...
  1. See AutoScalingPolicyTypeDef
  2. See PutAutoScalingPolicyOutputTypeDef
# put_auto_scaling_policy method usage example with argument unpacking

kwargs: PutAutoScalingPolicyInputRequestTypeDef = {  # (1)
    "ClusterId": ...,
    "InstanceGroupId": ...,
    "AutoScalingPolicy": ...,
}

parent.put_auto_scaling_policy(**kwargs)
  1. See PutAutoScalingPolicyInputRequestTypeDef

put_auto_termination_policy#

Auto-termination is supported in Amazon EMR releases 5.30.0 and 6.1.0 and later.

Type annotations and code completion for boto3.client("emr").put_auto_termination_policy method. boto3 documentation

# put_auto_termination_policy method definition

def put_auto_termination_policy(
    self,
    *,
    ClusterId: str,
    AutoTerminationPolicy: AutoTerminationPolicyTypeDef = ...,  # (1)
) -> dict[str, Any]:
    ...
  1. See AutoTerminationPolicyTypeDef
# put_auto_termination_policy method usage example with argument unpacking

kwargs: PutAutoTerminationPolicyInputRequestTypeDef = {  # (1)
    "ClusterId": ...,
}

parent.put_auto_termination_policy(**kwargs)
  1. See PutAutoTerminationPolicyInputRequestTypeDef

put_block_public_access_configuration#

Creates or updates an Amazon EMR block public access configuration for your Amazon Web Services account in the current Region.

Type annotations and code completion for boto3.client("emr").put_block_public_access_configuration method. boto3 documentation

# put_block_public_access_configuration method definition

def put_block_public_access_configuration(
    self,
    *,
    BlockPublicAccessConfiguration: BlockPublicAccessConfigurationTypeDef,  # (1)
) -> dict[str, Any]:
    ...
  1. See BlockPublicAccessConfigurationTypeDef
# put_block_public_access_configuration method usage example with argument unpacking

kwargs: PutBlockPublicAccessConfigurationInputRequestTypeDef = {  # (1)
    "BlockPublicAccessConfiguration": ...,
}

parent.put_block_public_access_configuration(**kwargs)
  1. See PutBlockPublicAccessConfigurationInputRequestTypeDef

put_managed_scaling_policy#

Creates or updates a managed scaling policy for an Amazon EMR cluster.

Type annotations and code completion for boto3.client("emr").put_managed_scaling_policy method. boto3 documentation

# put_managed_scaling_policy method definition

def put_managed_scaling_policy(
    self,
    *,
    ClusterId: str,
    ManagedScalingPolicy: ManagedScalingPolicyTypeDef,  # (1)
) -> dict[str, Any]:
    ...
  1. See ManagedScalingPolicyTypeDef
# put_managed_scaling_policy method usage example with argument unpacking

kwargs: PutManagedScalingPolicyInputRequestTypeDef = {  # (1)
    "ClusterId": ...,
    "ManagedScalingPolicy": ...,
}

parent.put_managed_scaling_policy(**kwargs)
  1. See PutManagedScalingPolicyInputRequestTypeDef

remove_auto_scaling_policy#

Removes an automatic scaling policy from a specified instance group within an Amazon EMR cluster.

Type annotations and code completion for boto3.client("emr").remove_auto_scaling_policy method. boto3 documentation

# remove_auto_scaling_policy method definition

def remove_auto_scaling_policy(
    self,
    *,
    ClusterId: str,
    InstanceGroupId: str,
) -> dict[str, Any]:
    ...
# remove_auto_scaling_policy method usage example with argument unpacking

kwargs: RemoveAutoScalingPolicyInputRequestTypeDef = {  # (1)
    "ClusterId": ...,
    "InstanceGroupId": ...,
}

parent.remove_auto_scaling_policy(**kwargs)
  1. See RemoveAutoScalingPolicyInputRequestTypeDef

remove_auto_termination_policy#

Removes an auto-termination policy from an Amazon EMR cluster.

Type annotations and code completion for boto3.client("emr").remove_auto_termination_policy method. boto3 documentation

# remove_auto_termination_policy method definition

def remove_auto_termination_policy(
    self,
    *,
    ClusterId: str,
) -> dict[str, Any]:
    ...
# remove_auto_termination_policy method usage example with argument unpacking

kwargs: RemoveAutoTerminationPolicyInputRequestTypeDef = {  # (1)
    "ClusterId": ...,
}

parent.remove_auto_termination_policy(**kwargs)
  1. See RemoveAutoTerminationPolicyInputRequestTypeDef

remove_managed_scaling_policy#

Removes a managed scaling policy from a specified Amazon EMR cluster.

Type annotations and code completion for boto3.client("emr").remove_managed_scaling_policy method. boto3 documentation

# remove_managed_scaling_policy method definition

def remove_managed_scaling_policy(
    self,
    *,
    ClusterId: str,
) -> dict[str, Any]:
    ...
# remove_managed_scaling_policy method usage example with argument unpacking

kwargs: RemoveManagedScalingPolicyInputRequestTypeDef = {  # (1)
    "ClusterId": ...,
}

parent.remove_managed_scaling_policy(**kwargs)
  1. See RemoveManagedScalingPolicyInputRequestTypeDef

remove_tags#

Removes tags from an Amazon EMR resource, such as a cluster or Amazon EMR Studio.

Type annotations and code completion for boto3.client("emr").remove_tags method. boto3 documentation

# remove_tags method definition

def remove_tags(
    self,
    *,
    ResourceId: str,
    TagKeys: Sequence[str],
) -> dict[str, Any]:
    ...
# remove_tags method usage example with argument unpacking

kwargs: RemoveTagsInputRequestTypeDef = {  # (1)
    "ResourceId": ...,
    "TagKeys": ...,
}

parent.remove_tags(**kwargs)
  1. See RemoveTagsInputRequestTypeDef

run_job_flow#

RunJobFlow creates and starts running a new cluster (job flow).

Type annotations and code completion for boto3.client("emr").run_job_flow method. boto3 documentation

# run_job_flow method definition

def run_job_flow(
    self,
    *,
    Name: str,
    Instances: JobFlowInstancesConfigTypeDef,  # (1)
    LogUri: str = ...,
    LogEncryptionKmsKeyId: str = ...,
    AdditionalInfo: str = ...,
    AmiVersion: str = ...,
    ReleaseLabel: str = ...,
    Steps: Sequence[StepConfigTypeDef] = ...,  # (2)
    BootstrapActions: Sequence[BootstrapActionConfigUnionTypeDef] = ...,  # (3)
    SupportedProducts: Sequence[str] = ...,
    NewSupportedProducts: Sequence[SupportedProductConfigTypeDef] = ...,  # (4)
    Applications: Sequence[ApplicationUnionTypeDef] = ...,  # (5)
    Configurations: Sequence[ConfigurationUnionTypeDef] = ...,  # (6)
    VisibleToAllUsers: bool = ...,
    JobFlowRole: str = ...,
    ServiceRole: str = ...,
    Tags: Sequence[TagTypeDef] = ...,  # (7)
    SecurityConfiguration: str = ...,
    AutoScalingRole: str = ...,
    ScaleDownBehavior: ScaleDownBehaviorType = ...,  # (8)
    CustomAmiId: str = ...,
    EbsRootVolumeSize: int = ...,
    RepoUpgradeOnBoot: RepoUpgradeOnBootType = ...,  # (9)
    KerberosAttributes: KerberosAttributesTypeDef = ...,  # (10)
    StepConcurrencyLevel: int = ...,
    ManagedScalingPolicy: ManagedScalingPolicyTypeDef = ...,  # (11)
    PlacementGroupConfigs: Sequence[PlacementGroupConfigTypeDef] = ...,  # (12)
    AutoTerminationPolicy: AutoTerminationPolicyTypeDef = ...,  # (13)
    OSReleaseLabel: str = ...,
    EbsRootVolumeIops: int = ...,
    EbsRootVolumeThroughput: int = ...,
) -> RunJobFlowOutputTypeDef:  # (14)
    ...
  1. See JobFlowInstancesConfigTypeDef
  2. See StepConfigTypeDef
  3. See BootstrapActionConfigTypeDef BootstrapActionConfigOutputTypeDef
  4. See SupportedProductConfigTypeDef
  5. See ApplicationTypeDef ApplicationOutputTypeDef
  6. See ConfigurationTypeDef ConfigurationOutputTypeDef
  7. See TagTypeDef
  8. See ScaleDownBehaviorType
  9. See RepoUpgradeOnBootType
  10. See KerberosAttributesTypeDef
  11. See ManagedScalingPolicyTypeDef
  12. See PlacementGroupConfigTypeDef
  13. See AutoTerminationPolicyTypeDef
  14. See RunJobFlowOutputTypeDef
# run_job_flow method usage example with argument unpacking

kwargs: RunJobFlowInputRequestTypeDef = {  # (1)
    "Name": ...,
    "Instances": ...,
}

parent.run_job_flow(**kwargs)
  1. See RunJobFlowInputRequestTypeDef

set_keep_job_flow_alive_when_no_steps#

You can use the SetKeepJobFlowAliveWhenNoSteps to configure a cluster (job flow) to terminate after the step execution, i.e., all your steps are executed.

Type annotations and code completion for boto3.client("emr").set_keep_job_flow_alive_when_no_steps method. boto3 documentation

# set_keep_job_flow_alive_when_no_steps method definition

def set_keep_job_flow_alive_when_no_steps(
    self,
    *,
    JobFlowIds: Sequence[str],
    KeepJobFlowAliveWhenNoSteps: bool,
) -> EmptyResponseMetadataTypeDef:  # (1)
    ...
  1. See EmptyResponseMetadataTypeDef
# set_keep_job_flow_alive_when_no_steps method usage example with argument unpacking

kwargs: SetKeepJobFlowAliveWhenNoStepsInputRequestTypeDef = {  # (1)
    "JobFlowIds": ...,
    "KeepJobFlowAliveWhenNoSteps": ...,
}

parent.set_keep_job_flow_alive_when_no_steps(**kwargs)
  1. See SetKeepJobFlowAliveWhenNoStepsInputRequestTypeDef

set_termination_protection#

SetTerminationProtection locks a cluster (job flow) so the Amazon EC2 instances in the cluster cannot be terminated by user intervention, an API call, or in the event of a job-flow error.

Type annotations and code completion for boto3.client("emr").set_termination_protection method. boto3 documentation

# set_termination_protection method definition

def set_termination_protection(
    self,
    *,
    JobFlowIds: Sequence[str],
    TerminationProtected: bool,
) -> EmptyResponseMetadataTypeDef:  # (1)
    ...
  1. See EmptyResponseMetadataTypeDef
# set_termination_protection method usage example with argument unpacking

kwargs: SetTerminationProtectionInputRequestTypeDef = {  # (1)
    "JobFlowIds": ...,
    "TerminationProtected": ...,
}

parent.set_termination_protection(**kwargs)
  1. See SetTerminationProtectionInputRequestTypeDef

set_unhealthy_node_replacement#

Specify whether to enable unhealthy node replacement, which lets Amazon EMR gracefully replace core nodes on a cluster if any nodes become unhealthy.

Type annotations and code completion for boto3.client("emr").set_unhealthy_node_replacement method. boto3 documentation

# set_unhealthy_node_replacement method definition

def set_unhealthy_node_replacement(
    self,
    *,
    JobFlowIds: Sequence[str],
    UnhealthyNodeReplacement: bool,
) -> EmptyResponseMetadataTypeDef:  # (1)
    ...
  1. See EmptyResponseMetadataTypeDef
# set_unhealthy_node_replacement method usage example with argument unpacking

kwargs: SetUnhealthyNodeReplacementInputRequestTypeDef = {  # (1)
    "JobFlowIds": ...,
    "UnhealthyNodeReplacement": ...,
}

parent.set_unhealthy_node_replacement(**kwargs)
  1. See SetUnhealthyNodeReplacementInputRequestTypeDef

set_visible_to_all_users#

The SetVisibleToAllUsers parameter is no longer supported.

Type annotations and code completion for boto3.client("emr").set_visible_to_all_users method. boto3 documentation

# set_visible_to_all_users method definition

def set_visible_to_all_users(
    self,
    *,
    JobFlowIds: Sequence[str],
    VisibleToAllUsers: bool,
) -> EmptyResponseMetadataTypeDef:  # (1)
    ...
  1. See EmptyResponseMetadataTypeDef
# set_visible_to_all_users method usage example with argument unpacking

kwargs: SetVisibleToAllUsersInputRequestTypeDef = {  # (1)
    "JobFlowIds": ...,
    "VisibleToAllUsers": ...,
}

parent.set_visible_to_all_users(**kwargs)
  1. See SetVisibleToAllUsersInputRequestTypeDef

start_notebook_execution#

Starts a notebook execution.

Type annotations and code completion for boto3.client("emr").start_notebook_execution method. boto3 documentation

# start_notebook_execution method definition

def start_notebook_execution(
    self,
    *,
    ExecutionEngine: ExecutionEngineConfigTypeDef,  # (1)
    ServiceRole: str,
    EditorId: str = ...,
    RelativePath: str = ...,
    NotebookExecutionName: str = ...,
    NotebookParams: str = ...,
    NotebookInstanceSecurityGroupId: str = ...,
    Tags: Sequence[TagTypeDef] = ...,  # (2)
    NotebookS3Location: NotebookS3LocationFromInputTypeDef = ...,  # (3)
    OutputNotebookS3Location: OutputNotebookS3LocationFromInputTypeDef = ...,  # (4)
    OutputNotebookFormat: OutputNotebookFormatType = ...,  # (5)
    EnvironmentVariables: Mapping[str, str] = ...,
) -> StartNotebookExecutionOutputTypeDef:  # (6)
    ...
  1. See ExecutionEngineConfigTypeDef
  2. See TagTypeDef
  3. See NotebookS3LocationFromInputTypeDef
  4. See OutputNotebookS3LocationFromInputTypeDef
  5. See OutputNotebookFormatType
  6. See StartNotebookExecutionOutputTypeDef
# start_notebook_execution method usage example with argument unpacking

kwargs: StartNotebookExecutionInputRequestTypeDef = {  # (1)
    "ExecutionEngine": ...,
    "ServiceRole": ...,
}

parent.start_notebook_execution(**kwargs)
  1. See StartNotebookExecutionInputRequestTypeDef

stop_notebook_execution#

Stops a notebook execution.

Type annotations and code completion for boto3.client("emr").stop_notebook_execution method. boto3 documentation

# stop_notebook_execution method definition

def stop_notebook_execution(
    self,
    *,
    NotebookExecutionId: str,
) -> EmptyResponseMetadataTypeDef:  # (1)
    ...
  1. See EmptyResponseMetadataTypeDef
# stop_notebook_execution method usage example with argument unpacking

kwargs: StopNotebookExecutionInputRequestTypeDef = {  # (1)
    "NotebookExecutionId": ...,
}

parent.stop_notebook_execution(**kwargs)
  1. See StopNotebookExecutionInputRequestTypeDef

terminate_job_flows#

TerminateJobFlows shuts a list of clusters (job flows) down.

Type annotations and code completion for boto3.client("emr").terminate_job_flows method. boto3 documentation

# terminate_job_flows method definition

def terminate_job_flows(
    self,
    *,
    JobFlowIds: Sequence[str],
) -> EmptyResponseMetadataTypeDef:  # (1)
    ...
  1. See EmptyResponseMetadataTypeDef
# terminate_job_flows method usage example with argument unpacking

kwargs: TerminateJobFlowsInputRequestTypeDef = {  # (1)
    "JobFlowIds": ...,
}

parent.terminate_job_flows(**kwargs)
  1. See TerminateJobFlowsInputRequestTypeDef

update_studio#

Updates an Amazon EMR Studio configuration, including attributes such as name, description, and subnets.

Type annotations and code completion for boto3.client("emr").update_studio method. boto3 documentation

# update_studio method definition

def update_studio(
    self,
    *,
    StudioId: str,
    Name: str = ...,
    Description: str = ...,
    SubnetIds: Sequence[str] = ...,
    DefaultS3Location: str = ...,
    EncryptionKeyArn: str = ...,
) -> EmptyResponseMetadataTypeDef:  # (1)
    ...
  1. See EmptyResponseMetadataTypeDef
# update_studio method usage example with argument unpacking

kwargs: UpdateStudioInputRequestTypeDef = {  # (1)
    "StudioId": ...,
}

parent.update_studio(**kwargs)
  1. See UpdateStudioInputRequestTypeDef

update_studio_session_mapping#

Updates the session policy attached to the user or group for the specified Amazon EMR Studio.

Type annotations and code completion for boto3.client("emr").update_studio_session_mapping method. boto3 documentation

# update_studio_session_mapping method definition

def update_studio_session_mapping(
    self,
    *,
    StudioId: str,
    IdentityType: IdentityTypeType,  # (1)
    SessionPolicyArn: str,
    IdentityId: str = ...,
    IdentityName: str = ...,
) -> EmptyResponseMetadataTypeDef:  # (2)
    ...
  1. See IdentityTypeType
  2. See EmptyResponseMetadataTypeDef
# update_studio_session_mapping method usage example with argument unpacking

kwargs: UpdateStudioSessionMappingInputRequestTypeDef = {  # (1)
    "StudioId": ...,
    "IdentityType": ...,
    "SessionPolicyArn": ...,
}

parent.update_studio_session_mapping(**kwargs)
  1. See UpdateStudioSessionMappingInputRequestTypeDef

get_paginator#

Type annotations and code completion for boto3.client("emr").get_paginator method with overloads.

get_waiter#

Type annotations and code completion for boto3.client("emr").get_waiter method with overloads.