Search code examples
asp.netmemorygac

Does DLL deployment into GAC reduce memory usage when shared by 100+ web apps?


I have an ASP.NET app hosted for many domains and all are mapped to the same root folder, i.e., code-base. Will it take less memeory if I load the DLLs currently located in bin folder into GAC? Any special code considerations to take to load DLLs into GAC for sharing (other than security aspect)?

Is there any way of making DLLs sharable in .NET environment?

Thank you

Kris


Solution

  • Putting the DLLs in the GAC will not help with memory usage. The DLLs still need to be loaded into each app domain, and they will not be in shared memory.

    The point of using the GAC is to centralize distribution of assemblies - so changes can be managed in one place. Sounds like this is something that you could still benefit from.