views:

352

answers:

3

I've been building .NET web applications for many years now, and I never use the GAC?

What am I missing? Or am I better off staying away from it?

+2  A: 

The GAC is only useful if you register libraries which you're going to reuse. It is in no way obligatory to use to run a WebApp without shared libraries .

Vincent Van Den Berghe
+2  A: 

The GAC is mainly for storing shared libraries, especially when your application requires a specific version. This way, I could install FooLib 1.0 and FooLib 2.0 on the same machine, and applications that require either one could find the ones they want. Web applications don't seem to use a whole lot of external libraries anyways.

In another example, SSIS requires that your custom tools are in the GAC. Major pain.

Stefan Mai
+1  A: 

Like Vincent says, the GAC is important mostly for third-party library vendors who want to support servicing independent of client applications. In other words, if there's a bug in the library, you could upgrade the library and fix all applications that use the library, without having to know which applications they are, etc.

In practice, most .NET applications (so far) are web applications, so it turns out that it's mostly useful for Microsoft, as few other people have routine ability to push updates to end-user machines.

Barry Kelly