Joshua Grant
01/25/2023, 4:33 PMbotocore.errorfactory.ClientException: An error occurred (ClientException) when calling the RegisterTaskDefinition operation: Too many concurrent attempts to create a new revision of the specified family.
Our workflow is that we are using an ECSTask
block with github storage.
prefect-aws==0.1.8
prefect==2.6.8
This is mainly caused when a mother flow fires off a subflow via run_deployment
, but can occur when trying to invoke a standalone flowBen Muller
01/25/2023, 10:07 PMprefect-aws
Joshua Grant
01/31/2023, 2:17 PMprefect==2.7.10
prefect-aws==0.2.4
Ben Muller
01/31/2023, 6:09 PMJoshua Grant
02/01/2023, 2:18 PMprefecthq/prefect:2.7.10-python3.9
, logic used within the Dockerfile:
FROM prefecthq/prefect:2.7.10-python3.9
RUN pip install prefect-aws==0.2.4
RUN prefect block register -m prefect_aws.ecs
Ben Muller
02/01/2023, 7:16 PMJoshua Grant
02/01/2023, 7:17 PMecs_task_fg = ECSTask(
aws_credentials=aws_credentials_block,
image=docker_image,
cpu=4096,
memory=8192,
stream_output=True,
configure_cloudwatch_logs=False,
cluster=os.getenv('ECS_CLUSTER'),
execution_role_arn=os.getenv('FLOW_EXECUTION_ROLE'),
task_role_arn=os.getenv('FLOW_TASK_ROLE'),
vpc_id=os.getenv('VPC_ID'),
env=flow_environment,
task_definition=task_def,
)
task_def
is read with `pyaml-env`'s parse_config
function and is a dictionary that describes sidcars loaded with the task, it also contains logging configuration for the task container as well (we use DataDog to handle logging). flow_environment
is a dict of envars. docker_image
is a string of the ECR-stored imageBen Muller
02/02/2023, 8:07 AMAnna Geller
02/02/2023, 1:54 PMJoshua Grant
02/02/2023, 2:59 PMtask_definition=
argument was the issue. With that completely removed (not just the sidecars), we are not seeing this issue.Anna Geller
02/03/2023, 2:48 PMJoshua Grant
02/13/2023, 6:06 PMtask_definition=
argument), then went on vacation. When I returned, the too-many-revisions error (which we have been calling this) resurfaced while I was gone. Would love to get some insight into why this is happening.ECSTask
infrastructure block. This method also allows for the loading of sidecars.