I'm developing .net core 2.2 web API, I'm using a separate custom assemblyLoadContext to load my controllers at run time. Each controller(or service)loaded in separate Context but I get below error in resolving SDK assembly!
System.IO.FileLoadException: 'Could not load file or assembly 'System.Data.Common, Version=4.2.1.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'. An operation is not legal in the current state. (Exception from HRESULT: 0x80131509)'
when I use the Default context to load all assemblies everything works well.
in the design document of AssemblyLoadContext microsoft mentioned that if resolving assembly failed in the costume context core will fallback to default context which is not happened in my case.
User contributions licensed under CC BY-SA 3.0