WorkerTypeV2 Class
The type of predefined worker that is allocated when a job runs.
If you need to use a WorkerTypeV2 that doesn't exist as a static member, you can instantiate a WorkerTypeV2 object, e.g: WorkerTypeV2.of('other type').
Example
ts
new tasks.GlueStartJobRun(this, 'Task', {
glueJobName: 'my-glue-job',
workerConfiguration: {
workerTypeV2: tasks.WorkerTypeV2.G_1X, // Worker type
numberOfWorkers: 2, // Number of Workers
},
});
python
tasks.GlueStartJobRun(self, "Task",
glue_job_name="my-glue-job",
worker_configuration=tasks.WorkerConfigurationProperty(
worker_type_v2=tasks.WorkerTypeV2.G_1X, # Worker type
number_of_workers=2
)
)
java
GlueStartJobRun.Builder.create(this, "Task")
.glueJobName("my-glue-job")
.workerConfiguration(WorkerConfigurationProperty.builder()
.workerTypeV2(WorkerTypeV2.G_1X) // Worker type
.numberOfWorkers(2)
.build())
.build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
new GlueStartJobRun(this, "Task", new GlueStartJobRunProps {
GlueJobName = "my-glue-job",
WorkerConfiguration = new WorkerConfigurationProperty {
WorkerTypeV2 = WorkerTypeV2.G_1X, // Worker type
NumberOfWorkers = 2
}
});
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
tasks.NewGlueStartJobRun(this, jsii.String("Task"), &GlueStartJobRunProps{
GlueJobName: jsii.String("my-glue-job"),
WorkerConfiguration: &WorkerConfigurationProperty{
WorkerTypeV2: tasks.WorkerTypeV2_G_1X(),
// Worker type
NumberOfWorkers: jsii.Number(2),
},
})
Properties
Each worker maps to 0.25 DPU (2 vCPU, 4 GB of memory, 64 GB disk), and provides 1 executor per worker. Suitable for low volume streaming jobs.
Each worker maps to 1 DPU (4 vCPU, 16 GB of memory, 64 GB disk), and provides 1 executor per worker.
Suitable for memory-intensive jobs.
Each worker maps to 2 DPU (8 vCPU, 32 GB of memory, 128 GB disk), and provides 1 executor per worker.
Suitable for memory-intensive jobs.
Each worker maps to 4 DPU (16 vCPU, 64 GB of memory, 256 GB 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 AWS Glue version 3.0 or later jobs.
Each worker maps to 8 DPU (32 vCPU, 128 GB of memory, 512 GB 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 AWS Glue version 3.0 or later jobs.
The name of this WorkerType, as expected by Job resource.
STANDARDWorkerTypeV2standardWorkerTypeV2STANDARDWorkerTypeV2STANDARDWorkerTypeV2STANDARDWorkerTypeV2static#Each worker provides 4 vCPU, 16 GB of memory and a 50GB disk, and 2 executors per worker.
Each worker maps to 2 high-memory DPU [M-DPU] (8 vCPU, 64 GB of memory, 128 GB disk).
Supported in Ray jobs.
Methods
of(workerType: string): WorkerTypeV2 // chainable@staticmethod def of(worker_type: str) -> WorkerTypeV2public static WorkerTypeV2 of(String workerType)public static WorkerTypeV2 Of(string workerType)func Of(WorkerType *string) WorkerTypeV2static#Custom worker type.
1 parameter
Parameters
workerTypeworker_typeworkerTypeworkerTypeWorkerType— custom worker type.