Assembly version conflict with 3rd party vendor - namespace conflict

5 posts, 1 answers
  1. Reini
    Reini avatar
    16 posts
    Member since:
    Apr 2007

    Posted 24 Nov 2009 Link to this post

    hi!

    i have opened a support ticket already but did not get a solution - so i try to ask the community if someone has come across a similar problem:

    we are using sitecore cms and in their new version (which we are upgrading to at the moment) they are using telerik controls as well - but the version they are using is 2008.2 - we are using 2009.1.
    now their admin site is inside the webroot (as most cms probably have) and their telerik.web.ui.dll is of course in the \bin folder.

    this of course generates a version conflict.

    we can't use the old version as we are using some stuff from the newer version.

    now we got some suggestions to solve this issue:
    • using global assebly cache
    • registering the different assemblies in web.config
    • using aliases

    all works to certain points - as even registering the specific assembly for the controls on a page with the strong name generates namspace conflicts for some properties (e.g. 'expandanimation' of rad.menu).

    does anyone out there came across similar issues?
    how did you solve these problems?

    any help is very appreciated!
    thank you!
  2. Answer
    T. Tsonev
    Admin
    T. Tsonev avatar
    2772 posts

    Posted 24 Nov 2009 Link to this post

    Hello Reini,

    I've replied to your support ticket and I'm posting the response here as well for reference:

    Using two versions of Telerik.Web.UI in the same application is not possible at all. I'm not familiar with Sitecore as a product, but their instructions seem to suggest that this can be done.

    This is a limitation of the .NET framework in general - you can have as many versions as you like in the GAC, but only one can be loaded by an Application Domain and consequently by an IIS Application Pool.

    The only solution is to use binding redirect to load the new assembly. This has the potential to create problems especially when you're skipping a lot of intermediate versions. As much as we try not to introduce breaking changes between versions this is not always possible.

    The redirect itself should look like this:

    <runtime>
      <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
        <dependentAssembly>
          <assemblyIdentity name="Telerik.Web.UI" publicKeyToken="121fae78165ba3d4" />
          <bindingRedirect oldVersion="2008.1.619.35" newVersion="2009.1.527.35" />
        </dependentAssembly>
      </assemblyBinding>
    </runtime>

    You should give it a try, but keep in mind that some things can break and test your scenario accordingly.

    Best wishes,
    Tsvetomir Tsonev
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Hessel
    Hessel avatar
    3 posts
    Member since:
    Aug 2012

    Posted 15 Mar 2012 Link to this post

    solution also/still works with Sitecore 6.4
  5. Hessel
    Hessel avatar
    3 posts
    Member since:
    Aug 2012

    Posted 15 Mar 2012 Link to this post

    solution also/still works with Sitecore 6.4
  6. Reini
    Reini avatar
    16 posts
    Member since:
    Apr 2007

    Posted 15 Mar 2012 Link to this post

    Yes, this is true.

    We are using this scenario in our solution for over a year now and are currently using Sitecore 6.4.1 rev. 110720 and it is still working :-) hopefully Telerik will stay downwards compatible also in future versions...

    I have marked the solution provided by Tsvetomir as the correct answer now (even it is still a workaround) but this is at least the only working and honest solution I got in a very long time :-)

    Thanks Telerik!
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017