locked
CRM 2011 Plugin Registration Issue RRS feed

  • Question

  • In CRM 2011, when trying to register a large plugin and workflow file the import or the plugin registration tool is constantly failing with the message "Plug-in assembly does not contain the required types or assembly content cannot be updated." The problem is the assembly does contain the types and the error doesn't make any sense. This is a large assembly (around 6 MB) and this issue has just started happening. The strange thing is this error is somewhat inconsistent. It's like we have either reached a class limit in our Entities file or an assembly size limit because if I remove some random classes in the Entities.cs file that are not being used the process will complete. The only pattern that I can tell is the process fails at the very end of the plugin\workflow registrations. There are about 65-70 plugins and workflows and it fails towards the very end each time. I'm beginning to think CRM can't handle the number of types in the assembly and is truncating the types that I need for the registration to complete.
    • Edited by John123124 Tuesday, November 15, 2011 4:20 PM
    Tuesday, November 15, 2011 4:18 PM

Answers

All replies

  • Try splitting the file at the last successful plugin or in the middle or something, and then try it again.  also try debugging the plugin registration tool during this process.
    Jamie Miley
    Check out my about.me profile!
    http://mileyja.blogspot.com
    Linked-In Profile
    Follow Me on Twitter!
    Tuesday, November 15, 2011 4:35 PM
    Moderator
  • Jamie, thanks for the reply. I already have the plugins split into their own files. The code generated file (Entities.cs) is the one big file I was talking about. I tried to split that one up with no impact. However, if I remove unused classes from the Entities.cs file I can make more progress. I'm beginning to think CRM has a limit on the number of classes it can handle for plugin registration or something along those lines. Anyone from Microsoft know of such a limit or a limit with the assembly size?
    Wednesday, November 16, 2011 3:38 PM
  • I am definitely leaning more towards assembly size limit here vs limit on the number of classes.
    Jamie Miley
    Check out my about.me profile!
    http://mileyja.blogspot.com
    Linked-In Profile
    Follow Me on Twitter!
    Wednesday, November 16, 2011 4:01 PM
    Moderator
  • I think you are right. If I start removing namespaces and thus shrinking the size of the assembly I get further along in the plugin\workflow registration. The one strange thing is a Release build has no impact from a Debug build even though the assembly is several 100 KB smaller. This is really strange and not a very informative error from Microsoft. Any idea on how to increase the allowed size?
    Wednesday, November 16, 2011 4:21 PM