Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue 130 | Cloudformation template parameters for Batch job memory and CPU #134

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

akshayar
Copy link
Contributor

Issue #, if available:
130

Description of changes:
Added a parameter for Batch job memory and CPU, so that when job fails with memory error , memory/CPU could be added. Also added JobDefinition ARN to custom resource definition to ensure that , when the job definition is updated , the startup Lambda is called to re-generate system-config.json.

During the test - update is called followed by delete ( which is ignored in Lambda code).
{
'RequestType': 'Update',
'ServiceToken': 'arn:aws:lambda:ap-south-1:ACCOUNT_ID:function:config-test-StartUpLambda-fM2kTJ2U9gEr',
'ResponseURL': 'RESPONSE_URL',
'StackId': 'STACK_ID',
'RequestId': 'REQUEST_ID',
'LogicalResourceId': 'StartUp',
'PhysicalResourceId': 'PHYSICAL_RESOURCE_ID',
'ResourceType': 'Custom::StartUpLambda',
'ResourceProperties': {
'ServiceToken': 'arn:aws:lambda:ap-south-1:ACCOUNT_ID:function:config-test-StartUpLambda-fM2kTJ2U9gEr',
'RedshiftPerformanceTestingJobDefinition': 'arn:aws:batch:ap-south-1:ACCOUNT_ID:job-definition/RedshiftPerformanceTest-0130518c4493769:3',
'RedshiftSubnetList': [
'SUBNET_1'
]
},
'OldResourceProperties': {
'ServiceToken': 'arn:aws:lambda:ap-south-1:ACCOUNT_ID:function:config-test-StartUpLambda-fM2kTJ2U9gEr',
'RedshiftPerformanceTestingJobDefinition': 'JOB_DEF_ARN',
'RedshiftSubnetList': [
'SUBNET_1'
]
}
}

{
'RequestType': 'Delete',
'ServiceToken': 'arn:aws:lambda:ap-south-1:ACCOUNT_ID:function:config-test-StartUpLambda-fM2kTJ2U9gEr',
'ResponseURL': 'RESPONSE_URL',
'StackId': 'STACK',
'RequestId': 'REQUEST_ID',
'LogicalResourceId': 'StartUp',
'PhysicalResourceId': 'PHYSICAL_RESOURCE_ID',
'ResourceType': 'Custom::StartUpLambda',
'ResourceProperties': {
'ServiceToken': 'arn:aws:lambda:ap-south-1:ACCOUNT_ID:function:config-test-StartUpLambda-fM2kTJ2U9gEr',
'RedshiftPerformanceTestingJobDefinition': 'JOB_DEF_ARN',
'RedshiftSubnetList': [
'SUBNET_1'
]
}
}
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

aws#125

 The config/extract.yaml template from S3 is not used.
Pull code from trunk.
 Cloudformation parameter for memory and CPU of batch job.
 Cloudformation parameter for memory and CPU of batch job.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant