Target full framework in core project with ServiceStack?

Is it possible to use an AspNet Core project targeting the full framework and using ServiceStack? We want to migrate from our old AspNet project type to an AspNet Core one.

Using the template here I am setting up a new project in a large enterprise system that runs off net471.


However in the Startup.cs file I cannot seem to get things to work. It is not possible to target netcore2+ due to other dependencies.

Note that we have an AspNet Core website that targets net471 (as above) in the same enterprise project and everything works perfectly - we get the benefits of using latest tools and methodologies while still working alongside ServiceStack and other non-net core deps. Is this not possible with ServiceStack?

I have tried:


As well as:


Neither work as expected.

Please read docs on Run ASP.NET Core Apps on the .NET Framework, i.e. you can only reference .Core packages, of which the easiest way is to start with one of the -corefx templates in the above docs.

I understand now. So everywhere we are referencing OrmLite or ServiceStack, when migrating to ASP.NET Core App Hosts targeting the full framework we need to change all these references to ServiceStack.Core and OrmLite.Core, etc?

Yes, you cannot Reference any packages containing .NET Framework builds because they will be referenced over .NET Standard .dlls which is what contains support for ASP.NET Core Apps.