Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Putting assemblies in GAC---which machine if load-balanced?

Status
Not open for further replies.

jsteph

Technical User
Oct 24, 2002
2,562
0
0
US
Hi all,
Sorry if this is not the correct forum, I searched for "visual studio" and found nothing here forum-wise.
Anyway, we have a C# web project that uses a server farm, each IIS server's site points to a single shared virtual folder holding the compiled app. But my question is--for global assemblies, should they be in the GAC on each IIS machine or should they be on the shared file server with some IIS setting pointing to this shared GAC? We'd been copying them to all 3 places out of ignorance...I don't think that's necessary and am looking for guidance.
Thanks,
James
 
It is not uncommon to "bin deploy" any assemblies that aren't installed on the server. I've used this when using Go Daddy with libraries they don't have, such as RIA Services for Silverlight. It also comes in handy when using a 3rd party toolset, such as Telerik. When you take an upgrade, you are simply publishing the new .dlls up in the bin folder rather than installing the new version on each server on the balancer. In my experience, the web app will look at the bin folder for the .dll... if it doesn't find it, it will look into the GAC. All you need to do in the web app project is select the references you want to bin deploy and make sure "Copy Local" is set to true.

Good luck!

-Mark
 
Mark,
Thanks very much, that eases my mind a bit.
--James
 
You have to pay close attention to bin deploy. I've had NuGet packages that didn't install into the package folder, but into the bin folder. Problem is, we don't check the bin folder into source control (not a good practice in general). This caused the build on the CI server to fail because the assembly was missing.

Craig Berntson
MCSD, Visual C# MVP,
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top