Not entirely sure whether this is the right forum to post ( because we don't have a AutoCAD idea forum like Civil 3D ideas forum), but anyway I just give it a shot here.
First, I'm writing Civil 3D plugins rather than AutoCAD plugins, but since Civil 3D is built on top of AutoCAD architecture, and this is an architectural issue, I figure that it should be solved at AutoCAD level, hence here.
The issue is that we need to be able to use AssemblyLoadContext internally within AutoCAD/Civil 3D for our plugin, just like Inventor. For precisely the very same problem. This is very important because different plugins can have same dependency DLLs ( say System.Text.Json.dll), but different version, which results in DLL hell.
From what I can tell, subclassing AssemblyLoadContext and keep a reference to it in the concrete class inheriting IExtensionApplication should work... in theory. But in practice, the all important Load method is simply not being called ( I've tested it so I know). This is why I said that it's not supported at the moment
Some of the related issues that I can find on the forum:
I'm aware that we have some sort of workarounds, but I feel that they are inadequate. Let me address them one by one.
Revit seems to have a hot discussion on this internally. So AutoCAD/Civil 3D should also have this feature.
PS: I've opened up an internal feedback item on this. Hopefully those can, will go and vote on it too.
Can't find what you're looking for? Ask the community or share your knowledge.