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.

dotnet: cdk takes long time to execute

See original GitHub issue

How long is ‘long’/how slow is ‘slow’?

PS E:\tmp> cdk init --language dotnet
PS E:\tmp> dotnet build src
...
Time Elapsed 00:00:02.05

PS E:\tmp> $sw = [Diagnostics.Stopwatch]::StartNew()
PS E:\tmp> cdk ls
PS E:\tmp> $sw.Stop();
PS E:\tmp> $sw.Elapsed.Seconds
43

In my case it takes around 40 seconds for cdk to execute the ls command in Windows. In comparison, dotnet build takes about 2 seconds.

In a docker container cdk ls takes about 30 seconds (Dockerfile)

root@1840d1c48712:/tmp/cdk# time cdk ls
hello-cdk-1
hello-cdk-2

real    0m27.063s
user    0m12.470s
sys     0m6.060s

Is there any work in the backlog to improve cdk execution time?

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:1
  • Comments:17 (9 by maintainers)

github_iconTop GitHub Comments

1reaction
unicomp21commented, May 4, 2019

I was running within the “linux on windows” subsystem. Just realized it’s the antimalware service on windows. Disabling it helps a “lot”.

1reaction
eladbcommented, Oct 11, 2018

We need to do some profiling for .net to understand what’s going on. The next release should improve things slightly (x2) as we have changed the protocol between the toolkit and the app to only require a single invocation of the app once in the regular case, but it still feels like there is room for improvement.

Read more comments on GitHub >

github_iconTop Results From Across the Web

dotnet: cdk takes long time to execute · Issue #793 - GitHub
In my case it takes around 40 seconds for cdk to execute the ls command in Windows. In comparison, dotnet build takes about...
Read more >
Increasing development speed with CDK Watch - Amazon AWS
cdk watch makes development faster by monitoring your code and assets for changes and automatically performing the optimal form of deployment ...
Read more >
The AWS CDK, Or Why I Stopped Being a CDK Skeptic
One-at-the-time stacks deployment. CDK runs on top of CloudFormation, which is famously slow. In a multi-stack application, you need to deploy ...
Read more >
AWS Lambda Cold Starts: Solving the Problem - Lumigo
This can mean a request takes much longer to execute, and only when the container ... Cold starts reflect the AWS Lambda startup...
Read more >
cdk deploy - AWS CDK Workshop
Bootstrapping an environment # The first time you deploy an AWS CDK app ... of security-related changes that the CDK is going to...
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