Increasing Nuget Package Update ( Resolving Dependencies) speed

Recently I worked on a big project with lots of nuget packages installed and was trying to update and consolidate packages in many projects under one solution. And I noticed that the nuget update process was quite slow.

It took over a minute to resolve all dependencies. After searching on google a bit( as we all dev do), I came across this post:

https://github.com/NuGet/Home/issues/1909#issuecomment-309484744

Trying out the solution, It increased the speed tremendously. The previous task that took over a minute ran just under seconds.

You will need to modify your deven.exe.config located at “C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\Common7\IDE”.

add following lines under system.net tag:

<connectionManagement>
	<add address="*" maxconnection="256" />
</connectionManagement>

and restart visual studio.

The final version would look like this:

Connection Management

 

Note: Every time there is an update for Visual Studio, this setting gets overwritten.

 

Sandeep

a dev, an amateur photographer and a father

 

Leave a Reply

Your email address will not be published. Required fields are marked *

%d bloggers like this: