UpdateApplication - Amazon EMR Serverless

UpdateApplication

Updates a specified application. An application has to be in a stopped or created state in order to be updated.

Request Syntax

PATCH /applications/applicationId HTTP/1.1 Content-type: application/json { "architecture": "string", "autoStartConfiguration": { "enabled": boolean }, "autoStopConfiguration": { "enabled": boolean, "idleTimeoutMinutes": number }, "clientToken": "string", "imageConfiguration": { "imageUri": "string" }, "initialCapacity": { "string" : { "workerConfiguration": { "cpu": "string", "disk": "string", "memory": "string" }, "workerCount": number } }, "maximumCapacity": { "cpu": "string", "disk": "string", "memory": "string" }, "monitoringConfiguration": { "cloudWatchLoggingConfiguration": { "enabled": boolean, "encryptionKeyArn": "string", "logGroupName": "string", "logStreamNamePrefix": "string", "logTypes": { "string" : [ "string" ] } }, "managedPersistenceMonitoringConfiguration": { "enabled": boolean, "encryptionKeyArn": "string" }, "s3MonitoringConfiguration": { "encryptionKeyArn": "string", "logUri": "string" } }, "networkConfiguration": { "securityGroupIds": [ "string" ], "subnetIds": [ "string" ] }, "releaseLabel": "string", "runtimeConfiguration": [ { "classification": "string", "configurations": [ "Configuration" ], "properties": { "string" : "string" } } ], "workerTypeSpecifications": { "string" : { "imageConfiguration": { "imageUri": "string" } } } }

URI Request Parameters

The request uses the following URI parameters.

applicationId

The ID of the application to update.

Length Constraints: Minimum length of 1. Maximum length of 64.

Pattern: ^[0-9a-z]+$

Required: Yes

Request Body

The request accepts the following data in JSON format.

architecture

The CPU architecture of an application.

Type: String

Valid Values: ARM64 | X86_64

Required: No

autoStartConfiguration

The configuration for an application to automatically start on job submission.

Type: AutoStartConfig object

Required: No

autoStopConfiguration

The configuration for an application to automatically stop after a certain amount of time being idle.

Type: AutoStopConfig object

Required: No

clientToken

The client idempotency token of the application to update. Its value must be unique for each request.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 64.

Pattern: ^[A-Za-z0-9._-]+$

Required: Yes

imageConfiguration

The image configuration to be used for all worker types. You can either set this parameter or imageConfiguration for each worker type in WorkerTypeSpecificationInput.

Type: ImageConfigurationInput object

Required: No

initialCapacity

The capacity to initialize when the application is updated.

Type: String to InitialCapacityConfig object map

Map Entries: Minimum number of 0 items. Maximum number of 10 items.

Key Length Constraints: Minimum length of 1. Maximum length of 50.

Key Pattern: ^[a-zA-Z]+[-_]*[a-zA-Z]+$

Required: No

maximumCapacity

The maximum capacity to allocate when the application is updated. This is cumulative across all workers at any given point in time during the lifespan of the application. No new resources will be created once any one of the defined limits is hit.

Type: MaximumAllowedResources object

Required: No

monitoringConfiguration

The configuration setting for monitoring.

Type: MonitoringConfiguration object

Required: No

networkConfiguration

The network configuration for customer VPC connectivity.

Type: NetworkConfiguration object

Required: No

releaseLabel

The Amazon EMR release label for the application. You can change the release label to use a different release of Amazon EMR.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 64.

Pattern: ^[A-Za-z0-9._/-]+$

Required: No

runtimeConfiguration

The Configuration specifications to use when updating an application. Each configuration consists of a classification and properties. This configuration is applied across all the job runs submitted under the application.

Type: Array of Configuration objects

Array Members: Minimum number of 0 items. Maximum number of 100 items.

Required: No

workerTypeSpecifications

The key-value pairs that specify worker type to WorkerTypeSpecificationInput. This parameter must contain all valid worker types for a Spark or Hive application. Valid worker types include Driver and Executor for Spark applications and HiveDriver and TezTask for Hive applications. You can either set image details in this parameter for each worker type, or in imageConfiguration for all worker types.

Type: String to WorkerTypeSpecificationInput object map

Key Length Constraints: Minimum length of 1. Maximum length of 50.

Key Pattern: ^[a-zA-Z]+[-_]*[a-zA-Z]+$

Required: No

Response Syntax

HTTP/1.1 200 Content-type: application/json { "application": { "applicationId": "string", "architecture": "string", "arn": "string", "autoStartConfiguration": { "enabled": boolean }, "autoStopConfiguration": { "enabled": boolean, "idleTimeoutMinutes": number }, "createdAt": number, "imageConfiguration": { "imageUri": "string", "resolvedImageDigest": "string" }, "initialCapacity": { "string" : { "workerConfiguration": { "cpu": "string", "disk": "string", "memory": "string" }, "workerCount": number } }, "maximumCapacity": { "cpu": "string", "disk": "string", "memory": "string" }, "monitoringConfiguration": { "cloudWatchLoggingConfiguration": { "enabled": boolean, "encryptionKeyArn": "string", "logGroupName": "string", "logStreamNamePrefix": "string", "logTypes": { "string" : [ "string" ] } }, "managedPersistenceMonitoringConfiguration": { "enabled": boolean, "encryptionKeyArn": "string" }, "s3MonitoringConfiguration": { "encryptionKeyArn": "string", "logUri": "string" } }, "name": "string", "networkConfiguration": { "securityGroupIds": [ "string" ], "subnetIds": [ "string" ] }, "releaseLabel": "string", "runtimeConfiguration": [ { "classification": "string", "configurations": [ "Configuration" ], "properties": { "string" : "string" } } ], "state": "string", "stateDetails": "string", "tags": { "string" : "string" }, "type": "string", "updatedAt": number, "workerTypeSpecifications": { "string" : { "imageConfiguration": { "imageUri": "string", "resolvedImageDigest": "string" } } } } }

Response Elements

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in JSON format by the service.

application

Information about the updated application.

Type: Application object

Errors

For information about the errors that are common to all actions, see Common Errors.

InternalServerException

Request processing failed because of an error or failure with the service.

HTTP Status Code: 500

ResourceNotFoundException

The specified resource was not found.

HTTP Status Code: 404

ValidationException

The input fails to satisfy the constraints specified by an AWS service.

HTTP Status Code: 400

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following: