MS Dynamics CRM - Differences between Plugin Deployments (Database, GAC, Disk)
The CRM SDK gives some information about the storage options when registering a plugin,
GAC Deployment
- Plugin assebly registered in GAC
- Plugins do not backed up with database
- Plugins cannot be added to the solution
- Plugins needs IISRESET to refresh
- Does not support Dynamics CRM online
- You can refer external DLL assemblies used in Plugin only if they are registered in GAC
DB Deployment
- Plugin uploaded into the database
- Plugins backed up with database
- Plugins can be added to the solution
- Plugins do not need IISRESET to refresh
- Supports Dynamics CRM online deployment
- You can refer external DLL assemblies used in Plugin only if they are registered in GAC
Disk deployments
- Plugin assembly saved on CRM server hard disk
- Plugins do not backed up with database
- Plugins cannot be added to the solution
- Plugins needs IISRESET to refresh
- Does not support Dynamics CRM online
- You can refer external DLL assemblies from the disk and from GAC
But, there are a few more considerations, below is the bullets you need to know:
- Database: The assembly dll is stored in the database, rather than the file system. The major advantages are that the assembly need only be deployed once if you have multiple CRM servers, and that no additional action is required to restore / redeploy the assembly either during disaster recovery, or if redeploying to an alternate server. **This is the preferred option in a production environment **
- Disk: The assembly dll is placed in the \server\bin\assembly directory on each server. You have to ensure the dll is placed in the correct place on all CRM servers, so the deployment overhead is a little greater. I normally use this option in development environments as you can redeploy newer versions solely by file transfer, rather than reregistering. Also, if debugging, the assembly .pdb file needs to be placed in the same location; with this option it's easy to ensure the dll and pdb are from the same build.
- GAC: The assembly is placed in the Global Assembly Cache on each CRM server, and again you will have to do this. The GAC does allow multiple versions of an assembly, but CRM doesn't, so you don't really gain anything by using the GAC. I don't think I've ever used this option.
NOTE: There is one further consideration. If your plugin assembly has other dependent assemblies, then you can place this dependent assembly in the GAC whichever of the above options you take. However, if you use the Disk option, then the dependent assemblies can also be deployed into the \server\bin\assembly directory.
for more information you can refer to Register and Deploy Plug-Ins, David Jennaway - Plugin Deployment Options.
Thank You.
Comments
Post a Comment