So I've got these iParts, see? They have references to several ASI dlls, typically Asi, Asi.Business.ContentManagement, Asi.iBO, Asi.Web, Secure and Telerik.Web.UI. I have those files in my project folder, it builds my dlls just fine and works great...until the client upgrades. At that point, my code refuses to run because it can't find the file it was compiled against. Telerik is the most common offender. Moving from 15.1.1 to 15.1.2 required a new dll even though I was using only features available in both flavors.
I'm trying to avoid compiling and distributing new copies of each of my iParts for every release and patch of iMIS. That's a lot of installers to maintain. Keeping another copy of the same file, perhaps in the GAC, seems messy and probably not the right approach.
I've done a bit of research on MSDN and StackOverflow about manifests, especially the dependentAssembly > bindingRedirect attributes. From what I've learned so far, I think I could distribute a new manifest whenever non-breaking changes are made to my dependencies. Has anyone tried this and got it to work? (This also looks like something ASI may be able to fix more globally by incorporating such changes into web.config for everyone's benefit.)
I realize that if the dependency has important changes in behavior, then bindingRedirect is going to move the problem instead of solve it. At that point, a new version of my iPart makes sense, as I probably have to modify my code as well.
Does anybody have any other suggestions for how to solve this?
Is there something ASI could do differently with their DLLs to make sure I'd only have to build an installer for each _major_ version of iMIS instead of each patch?
Hi I found nice article
Hi
I found nice article related version dependecies,
http://blog.fredrikhaglund.se/blog/2008/02/23/get-control-over-your-assembly-dependencies/
basically by editing csproj file and remove version number other details and compile so your dll is not related to any version numbers
For example by default your reference created like this
<Reference Include="Asi, Version=15.1.2.5901, Culture=neutral, processorArchitecture=MSIL" />
<Reference Include="Asi.Business.ContentManagement, Version=15.1.2.5901, Culture=neutral, processorArchitecture=MSIL" />
<Reference Include="Asi.ContentManagerNet, Version=15.1.2.5901, Culture=neutral, processorArchitecture=MSIL" />
<Reference Include="Asi.iBO, Version=15.1.2.5901, Culture=neutral, processorArchitecture=MSIL" />
<Reference Include="Secure, Version=15.1.2.4260, Culture=neutral, processorArchitecture=MSIL" />
<Reference Include="System" />
<Reference Include="System.Data" />
<Reference Include="System.Core">
now you can change this section to something like this would solve the problem.
<Reference Include="Asi" />
<Reference Include="Asi.Business.ContentManagement" />
<Reference Include="Asi.ContentManagerNet" />
<Reference Include="Asi.iBO" />
I have not tested this but this should work.
Thanks