question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

(core): app.synth 1.75.0 performance degradation

See original GitHub issue

The bug appears in the slow down of the cdk commands ‘cdk ls, cdk diff, cdk deploy’. When killing the process the traceback would include the app.synth() function in the code.

Reproduction Steps

Replicating the environment with the latest cdk library 1.75.0 our existing cdk python code base performance goes from several minutes to deploy to 10s of minutes to deploy. It appears that any command that runs the app.synth() (app = core.App()) function in the codebase degrades the performance. There is no error thrown, eventually the function completes.

Environment

  • CDK CLI Version : 1.75.0
  • Framework Version: Python
  • Node.js Version:
  • OS : Locally mac, but also duplicated on build machines ubuntu-20.04 and ubuntu-18.04
  • Language (Version): Python 3.7.9

pip freeze

attrs==20.3.0 aws-adfs==1.24.4 aws-cdk.assets==1.75.0 aws-cdk.aws-apigateway==1.75.0 aws-cdk.aws-apigatewayv2==1.75.0 aws-cdk.aws-applicationautoscaling==1.75.0 aws-cdk.aws-autoscaling==1.75.0 aws-cdk.aws-autoscaling-common==1.75.0 aws-cdk.aws-autoscaling-hooktargets==1.75.0 aws-cdk.aws-batch==1.75.0 aws-cdk.aws-certificatemanager==1.75.0 aws-cdk.aws-cloudformation==1.75.0 aws-cdk.aws-cloudfront==1.75.0 aws-cdk.aws-cloudwatch==1.75.0 aws-cdk.aws-codebuild==1.75.0 aws-cdk.aws-codecommit==1.75.0 aws-cdk.aws-codeguruprofiler==1.75.0 aws-cdk.aws-codepipeline==1.75.0 aws-cdk.aws-cognito==1.75.0 aws-cdk.aws-ec2==1.75.0 aws-cdk.aws-ecr==1.75.0 aws-cdk.aws-ecr-assets==1.75.0 aws-cdk.aws-ecs==1.75.0 aws-cdk.aws-ecs-patterns==1.75.0 aws-cdk.aws-efs==1.75.0 aws-cdk.aws-elasticloadbalancing==1.75.0 aws-cdk.aws-elasticloadbalancingv2==1.75.0 aws-cdk.aws-events==1.75.0 aws-cdk.aws-events-targets==1.75.0 aws-cdk.aws-iam==1.75.0 aws-cdk.aws-kinesis==1.75.0 aws-cdk.aws-kinesisfirehose==1.75.0 aws-cdk.aws-kms==1.75.0 aws-cdk.aws-lambda==1.75.0 aws-cdk.aws-logs==1.75.0 aws-cdk.aws-route53==1.75.0 aws-cdk.aws-route53-targets==1.75.0 aws-cdk.aws-s3==1.75.0 aws-cdk.aws-s3-assets==1.75.0 aws-cdk.aws-sam==1.75.0 aws-cdk.aws-secretsmanager==1.75.0 aws-cdk.aws-servicediscovery==1.75.0 aws-cdk.aws-sns==1.75.0 aws-cdk.aws-sns-subscriptions==1.75.0 aws-cdk.aws-sqs==1.75.0 aws-cdk.aws-ssm==1.75.0 aws-cdk.aws-stepfunctions==1.75.0 aws-cdk.cloud-assembly-schema==1.75.0 aws-cdk.core==1.75.0 aws-cdk.custom-resources==1.75.0 aws-cdk.cx-api==1.75.0 aws-cdk.region-info==1.75.0 awscli==1.18.185 boto3==1.14.37 botocore==1.19.25 cattrs==1.1.1 Cerberus==1.3.1 certifi==2020.6.20 cffi==1.14.0 chardet==3.0.4 click==7.1.2 colorama==0.4.3 configparser==5.0.0 constructs==3.2.44 cryptography==2.9.2 docutils==0.15.2 fido2==0.8.1 idna==2.10 jmespath==0.10.0 jsii==1.15.0 lxml==4.5.1 publication==0.0.3 pyasn1==0.4.8 pycparser==2.20 pykerberos==1.2.1 pyOpenSSL==19.1.0 python-dateutil==2.8.1 PyYAML==5.1.2 requests==2.24.0 requests-kerberos==0.12.0 rsa==3.4.2 s3transfer==0.3.3 six==1.15.0 typing-extensions==3.7.4.2 urllib3==1.25.9


Other

The previous version that worked fine cdk version 1.74.0 pip freeze


attrs==19.3.0 aws-adfs==1.24.4 aws-cdk.assets==1.74.0 aws-cdk.aws-apigateway==1.74.0 aws-cdk.aws-apigatewayv2==1.74.0 aws-cdk.aws-applicationautoscaling==1.74.0 aws-cdk.aws-autoscaling==1.74.0 aws-cdk.aws-autoscaling-common==1.74.0 aws-cdk.aws-autoscaling-hooktargets==1.74.0 aws-cdk.aws-batch==1.74.0 aws-cdk.aws-certificatemanager==1.74.0 aws-cdk.aws-cloudformation==1.74.0 aws-cdk.aws-cloudfront==1.74.0 aws-cdk.aws-cloudwatch==1.74.0 aws-cdk.aws-codebuild==1.74.0 aws-cdk.aws-codecommit==1.74.0 aws-cdk.aws-codeguruprofiler==1.74.0 aws-cdk.aws-codepipeline==1.74.0 aws-cdk.aws-cognito==1.74.0 aws-cdk.aws-ec2==1.74.0 aws-cdk.aws-ecr==1.74.0 aws-cdk.aws-ecr-assets==1.74.0 aws-cdk.aws-ecs==1.74.0 aws-cdk.aws-ecs-patterns==1.74.0 aws-cdk.aws-efs==1.74.0 aws-cdk.aws-elasticloadbalancing==1.74.0 aws-cdk.aws-elasticloadbalancingv2==1.74.0 aws-cdk.aws-events==1.74.0 aws-cdk.aws-events-targets==1.74.0 aws-cdk.aws-iam==1.74.0 aws-cdk.aws-kinesis==1.74.0 aws-cdk.aws-kinesisfirehose==1.74.0 aws-cdk.aws-kms==1.74.0 aws-cdk.aws-lambda==1.74.0 aws-cdk.aws-logs==1.74.0 aws-cdk.aws-route53==1.74.0 aws-cdk.aws-route53-targets==1.74.0 aws-cdk.aws-s3==1.74.0 aws-cdk.aws-s3-assets==1.74.0 aws-cdk.aws-sam==1.74.0 aws-cdk.aws-secretsmanager==1.74.0 aws-cdk.aws-servicediscovery==1.74.0 aws-cdk.aws-sns==1.74.0 aws-cdk.aws-sns-subscriptions==1.74.0 aws-cdk.aws-sqs==1.74.0 aws-cdk.aws-ssm==1.74.0 aws-cdk.aws-stepfunctions==1.74.0 aws-cdk.cloud-assembly-schema==1.74.0 aws-cdk.core==1.74.0 aws-cdk.custom-resources==1.74.0 aws-cdk.cx-api==1.74.0 aws-cdk.region-info==1.74.0 awscli==1.18.185 boto3==1.16.25 botocore==1.19.25 cattrs==1.0.0 Cerberus==1.3.1 certifi==2020.6.20 cffi==1.14.0 chardet==3.0.4 click==7.1.2 colorama==0.4.3 configparser==5.0.0 constructs==3.0.28 cryptography==2.9.2 docutils==0.15.2 fido2==0.8.1 idna==2.10 jmespath==0.10.0 jsii==1.8.0 lxml==4.5.1 publication==0.0.3 pyasn1==0.4.8 pycparser==2.20 pykerberos==1.2.1 pyOpenSSL==19.1.0 python-dateutil==2.8.1 PyYAML==5.1.2 requests==2.24.0 requests-kerberos==0.12.0 rsa==3.4.2 s3transfer==0.3.3 six==1.15.0 typing-extensions==3.7.4.2 urllib3==1.26.2



This is 🐛 Bug Report

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:1
  • Comments:7 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
RomainMullercommented, Dec 3, 2020

In fact, this can likely be fixed without having to have a CDK release. Once the fix has been verified, we can release a new version of the jsii runtime libraries, which should fix all clients (they’d simply need to make sure their dependencies are re-resolved so the latest runtime is downloaded)

1reaction
NetaNircommented, Dec 2, 2020

Probably related https://github.com/aws/jsii/pull/2298. The next release of the cdk will include the jsii patch

Read more comments on GitHub >

github_iconTop Results From Across the Web

cdk synth (v1.75.0) throws error with aws-lambda-step-function
When synthesizing a construct that uses aws-lambda-step-function, an error is thrown and synthesis fails. When looking at the stack trace, ...
Read more >
App — AWS Cloud Development Kit 1.184.0 documentation
synth () which will emit a “cloud assembly” from this app into the directory specified by outdir . Cloud assemblies includes artifacts such...
Read more >
Caustic Core :: Caustic 3 finally! - Single Cell Software
The "synth maker" app would use the core to read the modular preset, show available controls and give you live preview, then dump...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found