2

I don't know when this started working, but my deployments are horifically slow now and I'm not sure why...

I change a single apex class, right-click the file and pick SFDX:Deploy Source to Org, and it's taking well over 5 minutes for the "Running..." scrollbar to vanish.

The weird thing is, if I look in the Org under "Deployment Status", it completed ages ago, taking under a minute (start/finish time are the same).

Any ideas what VSCode is doing after the deployment completes that's taking so long? The CLI is on version 7.201.6

James
  • 999
  • 2
  • 11
  • 22

2 Answers2

1

A new setting 'Enable Source Tracking For Deploy and Retrieve' was introduced recently, in response to this issue. It is checked by default. https://github.com/forcedotcom/salesforcedx-vscode/issues/4865

I was experiencing the issue described here, but after unchecking that setting my deploys have returned to taking several seconds.

(sfdx-cli/7.205.6 win32-x64 node-v18.15.0)

Another similar issue that I had was that 'Push-or-deploy-on-save' stopped working for me. It was trying to push but not responding. Whilst looking at the above issue, I discovered another setting 'Prefer Deploy On Save'. With this checked I am now back to speedy deploys on save.

enter image description here

This content was originally posted at https://stackoverflow.com. Do not reward video streams of this content on YouTube.

MikeA
  • 189
  • 9
0

I was facing the same issue today. I faced the issue with v57.15.0. I installed an earlier version of Salesforce CLI which was v57.13.1 and my deployment time is not slow anymore.

Venkat
  • 29
  • 2
  • Hey there! Could you edit your answer to show which version of the CLI you originally installed when you experienced the problem and which version you have installed now? – TheKvist May 26 '23 at 14:11
  • This seemed to work for me - I just did a quick test deploy using the version suggested, and it was performing correctly. Thanks! – James May 30 '23 at 13:56