Hi Everyone.... I was wondering if anyone might be able to offer any assistance with a problem I'm experiencing when trying to use and implement Extcore in a .NET Core 3.1 MVC based solution. My setup is as follows, I have a main .NET Core 3.1 Project called AAGOne which will act as the overall holder for all of the different modules which will be used as part of the website. To test the compiled DLL modular functionality of ExtCore I have added a test module called "CBAS" which is a .NET Core 3.1 class library. I have listed the references I have set up for the two different projects below.
AAGOne - Holder Project
references - ExtCore.Mvc 5.1.0, ExtCore.Mvc.Infrastructure 5.1.0, ExtCore.WebApplication 5.1.0
CBAS - Module/Extension
references - ExtCore.Mvc.Infrastructure 5.1.0
In the holder project I am setting up ExtCore as shown below in the start up class, the "extensionsPath" variable is populated correctly as I can see the path generated and navigate there. I have attached screen shot labelled "Startup.cs - ConfigureServices" and highlighted the extcore call.
Then in the "Configure" method in Startup.cs I am then requesting that the "ApplicationBuilder" make use of extcore as showin the screen labelled "Startup.cs - Configure".
On the module "CBAS" side of things I thought I would start with setting up a really simple controller and view to test it out, so I the project structure in the screen shot labelled "CBAS Project Structure".
In Actions/UseEndPointsAction.cs I have implemented "IUseEndpointsAction" as show in screen shot labelled "UseEndpointsAction.cs". On the CBAS project file side I have added the "EmbeddedResource" directive as shown in the screen shot labelled "CBAS.csproj".
I am then building the solution and copying the built CBAS dll and placing this in the "Modules" folder within the holder solution as shown in screenshot labelled "Modules Location", which matches up with the appsettings.json of the holder project as shown in screenshot labelled with "AppSettings".
When I run the project I navigate to the correct route "https://localhost:44372/default/cbasindex" and this then triggers the view error screen as shown in screen shot labelled "View Error".
After googling around this issue I think that this may be related to this previously reported issue - ExtCore/ExtCore#22. I've tried various things but I've been unable to make progress with this....does anyone have any ideas how I can fix this problem or debug this further?
Any help much appreciated,
Thanks Ian
Hi all, probably I'm doing something wrong, but if I adds addExtCore, i get an error
warn: ExtCore.WebApplication[0]
System.IO.FileNotFoundException: Could not load file or assembly 'runtime.debian.8-x64.runtime.native.System.Security.Cryptography.OpenSsl, Culture=neutral, PublicKeyToken=null'. The system cannot find the file specified.
File name: 'runtime.debian.8-x64.runtime.native.System.Security.Cryptography.OpenSsl, Culture=neutral, PublicKeyToken=null'
at System.Reflection.RuntimeAssembly.nLoad(AssemblyName fileName, String codeBase, RuntimeAssembly assemblyContext, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, AssemblyLoadContext assemblyLoadContext)
at System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(AssemblyName assemblyRef, StackCrawlMark& stackMark, AssemblyLoadContext assemblyLoadContext)
at System.Reflection.Assembly.Load(AssemblyName assemblyRef, StackCrawlMark& stackMark, AssemblyLoadContext assemblyLoadContext)
at System.Runtime.Loader.AssemblyLoadContext.LoadFromAssemblyName(AssemblyName assemblyName)
at ExtCore.WebApplication.DefaultAssemblyProvider.GetAssembliesFromDependencyContext(List`1 assemblies)
warn: ExtCore.WebApplication[0]
Error loading assembly 'runtime.fedora.23-x64.runtime.native.System.Security.Cryptography.OpenSsl'
warn: ExtCore.WebApplication[0]
System.IO.FileNotFoundException: Could not load file or assembly 'runtime.fedora.23-x64.runtime.native.System.Security.Cryptography.OpenSsl, Culture=neutral, PublicKeyToken=null'. The system cannot find the file specified.
File name: 'runtime.fedora.23-x64.runtime.native.System.Security.Cryptography.OpenSsl, Culture=neutral, PublicKeyToken=null'
at System.Reflection.RuntimeAssembly.nLoad(AssemblyName fileName, String codeBase, RuntimeAssembly assemblyContext, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, AssemblyLoadContext assemblyLoadContext)
at System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(AssemblyName assemblyRef, StackCrawlMark& stackMark, AssemblyLoadContext assemblyLoadContext)
at System.Reflection.Assembly.Load(AssemblyName assemblyRef, StackCrawlMark& stackMark, AssemblyLoadContext assemblyLoadContext)
at System.Runtime.Loader.AssemblyLoadContext.LoadFromAssemblyName(AssemblyName assemblyName)
at ExtCore.WebApplication.DefaultAssemblyProvider.GetAssembliesFromDependencyContext(List`1 assemblies)
warn: ExtCore.WebApplication[0]
Error loading assembly 'runtime.fedora.24-x64.runtime.native.System.Security.Cryptography.OpenSsl'
warn: ExtCore.WebApplication[0]
System.IO.FileNotFoundException: Could not load file or assembly 'runtime.fedora.24-x64.runtime.native.System.Security.Cryptography.OpenSsl, Culture=neutral, PublicKeyToken=null'. The system cannot find the file specified.
File name: 'runtime.fedora.24-x64.runtime.native.System.Security.Cryptography.OpenSsl, Culture=neutral, PublicKeyToken=null'
at System.Reflection.RuntimeAssembly.nLoad(AssemblyName fileName, String codeBase, RuntimeAssembly assemblyContext, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, AssemblyLoadContext assemblyLoadContext)
at System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(AssemblyName assemblyRef, StackCrawlMark& stackMark, AssemblyLoadContext assemblyLoadContext)
at System.Reflection.Assembly.Load(AssemblyName assemblyRef, StackCrawlMark& stackMark, AssemblyLoadContext assemblyLoadContext)
at System.Runtime.Loader.AssemblyLoadContext.LoadFromAssemblyName(AssemblyName assemblyName)
at ExtCore.WebApplication.DefaultAssemblyProvider.GetAssembliesFromDependencyContext(List`1 assemblies)
Anyone who know how to solve this? I don't add extension currently, so I don't know what the reason of this error is.
Hello Dmitry. Recently working with ExtCore 5 and having a trouble switching to Extensions.
The Startup.cs of my inner project is not recognized by the Project. So Dependency Injection not working