Developer forum

Forum » Development » Handling external dependencies

Handling external dependencies

Imar Spaanjaars Dynamicweb Employee
Imar Spaanjaars
Reply

Hi there,

I have a custom Dynamicweb application that uses an external component. That component relies on Newtonsoft.Json version 7.x while Dynamicweb ships with version 6. This causes some issues when recompiling and/or upgrading the application as the version of that assembly is downgraded.

Would it be possible to upgrade Dynamicweb's external references like this one from time to time so it ships with recent versions? I can see some potential issues with that, so it may not be feasible. If it's not, then what is the recommend way around this? How do others  deal with these dependencies?

Thanks,

Imar


Replies

 
Imar Spaanjaars Dynamicweb Employee
Imar Spaanjaars
Reply

Bump. Any ideas on this?

As an alternative, would it be possible somehow to skip overwriting some assemblies? Maybe add some kind of subscriber that I can use to skip stuff like Newtonsoft through code?

Imar

 
Nicolai Pedersen
Reply

Hi Imar

I have no ideas - its a classic problem I guess. You can update your local solution to 7 and add the redirect in web.config - it should work...

We have updated Newtonsoft on 9. Upgrading on the 8-series will give us issues with all those compiling against 6.

 
Imar Spaanjaars Dynamicweb Employee
Imar Spaanjaars
Reply

Hi Nicolai,

Yes, a redirect in web.config works and that's what we use today. The issue, however, is not in getting the site to run, but to get it updated. Whenever we deploy a hotfix of the core application, Dynamicweb copies all assemblies from the application's bin to the bin of the site and overwrites any DLL it finds. This means that our DLLs get downgraded and then the binding redirect fails to find the proper version. I am trying to find a way to prevent these DLLs that are external to Dynamicweb from being overwritten on an upgrade.

 

You must be logged in to post in the forum