-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Making Nancy run on .NET Core #1959
Comments
|
I ran Nancy.dll through the portability analyzer, I've uploaded the spreadsheet here: Lists all the references that are not supported in aspnet5 and an alternative in some cases. Most of the System.Type ones are for TinyIOC which we can ignore as there is already a coreclr version of that available. |
One other thing to consider would be to sit on top of the new routing system rather having a custom one. For example, MVC 6 today hooks into this routing system. |
@tugberkugurlu you mean pass the routes from a module back to the middleware? Or move the routes out of the modules all together and use the middleware to point to routes? |
We won't be replacing our routing, if people want to use the ASPNet stuff to do mapping that's fine, but that's no different to how we currently use OWIN (and without any of the IApplicationBuilder nonsense - bleh :)) |
I gave a go at cutting down some of the build errors but messed git up a bit in the process: https://github.com/EliotJones/NancyTest/tree/feature/core50 . For me this is building against DNXCore50 with only 200 errors but it might just be my environment, sorry if it's still broken for everyone else |
@awec where's that coreclr version of tinyioc you mention? |
So... does this mean I can use this branch in my DNX 451 project? |
You can try but it's not complete On Wednesday, 12 August 2015, janus007 [email protected] wrote:
|
@janus007 I've been using the latest
|
@masaeedu You know that we provide an extension method for the // Either
app.UseOwin(owin => owin.UseNancy(NancyConfiguration));
// Or
app.UseOwin().UseNancy(NancyConfiguration); And you don't even need |
@khellang Ah, I didn't realize there was a |
Hi. I've just created a bare-bone Nancy app in DNX 4.5.1 with a module in a separate class library. It turns out that Nancy cannot discover modules from that library, because the reference is actually not added until some code referenced. The typical way Nancy discovers stuff by inspecting all assemblies in Is there any way other than actually referencing some code explicitly? This breaks the feature I liked about Nancy, that I could just drop a dll in bin and it just works. |
@tpluscode This is the same for all Nancy projects - DNX or not. Nancy won't scan assemblies not referencing Nancy.dll by default. Also, there's no hardcoded path that Nancy scans. It looks at |
@khellang AFAICT In my case the Nancy hosted with OWIN in a ASP.NET 5 app doesn't discover my module. Also, here's a repro. |
Hmm. When I think about it, I doubt anyone's actually tested this scenario. It's probably just been tested with modules in the same assembly as the host. |
Some context; aspnet/dnx#1253 |
@khellang getting it to run with |
Absolutely. But there are some yaks that needs some shaving before we get to that point; |
One part of the problem is that Nancy's assembly scanning is static today, while |
Hey guys, how is the work on this feature? |
@danfma We're working on some stuff to unblock .NET core. |
Can I help with anything? I don't have much time but I can try to help with something. |
The problem is that there's not enough work to do it concurrently. We'll just have to let @thecodejunkie finish #1846 after #2000 is done 😄 Thanks for offering your help! 👍 |
Ok! |
UPDATE : I ditched my branch as it got too big and we plan to move to dnx in smaller stages. At time of writing we already have a couple of PRs to change the repo structure and have csproj and project.json side by side in the short term |
Hi guys, Is someone still working on this? Can we help somehow? http://www.ageofascent.com/asp-net-core-exeeds-1-15-million-requests-12-6-gbps/ Looking forward to see Nancy doing it! ;) |
This is kind of a duplicate of #2220 so closing but if anyone is following check these out: https://twitter.com/NancyFx/status/702825092418543616 |
Wow, that is great!! Nice timing! Are you planing to release a version anytime soon? |
Not at the moment. We plan to do a 2.0-alpha soon from master branch, then On 25 February 2016 at 14:45, Renato Quinhoneiro Todorov <
|
@jchannon |
dotnet core is compiling on the master branch, we have no nuget package out On 26 June 2016 at 09:48, Peter Blazejewicz [email protected]
|
Thanks! |
Hi guys! Thx |
@a23o already done :) checkout the latest barneyrubble release |
Awesome!! Thank you. |
Thank you very much for the great work you. Package Nancy.Hosting.Self 2.0.0-barneyrubble is not compatible with netcoreapp1.0 (.NETCoreApp,Version=v1.0). Package Nancy.Hosting.Self 2.0.0-barneyrubble supports: net452 (.NETFramework,Version=v4.5.2) As I can see from sources you already updated this package. I am running .NET Core on Linux Ubuntu 14.04 LTS |
@mrgrifon You should use Kesteral hosting, please refer to https://github.com/NancyFx/Nancy/tree/master/samples/Nancy.Demo.Hosting.Kestrel |
Will self hosting be implemented for .NET core, or is the plan to just use Kestral? |
Kestrel is self-hosting. It's the default model for ASP.NET Core apps. Either using Kestrel, or WebListener. |
UseOwin seems to be missing from Kestrel in .NET Core... |
|
khellang, it's installed and is no longer present with .NET Core 2.0 preview 1. EDIT: uhm, okay. I have a project we've been working actively on for the last five months and I upgraded to .NET Core 2.0 preview today and UseOwin was gone... apparently the package was removed in the process. Re-added it back in and all is well. Thanks, sometimes just takes another set of eyes I suppose ;) |
Thoroughly confused right now. So, is the netcore 2.0 port happening? |
The thing I (probably we) love about Nancy.Hosting.Self is the MINIMAL boilerplate... That kestrel demo project is a nightmare for anyone getting started with dotnet core and Nancy IMHO. I don't mind switching to kestrel, just give us a minimalist example PLEASE!? Right now, OWIN looks like the way to go. There is official documentation for hosting Nancy with OWIN (although no mention of dontenet core). And someone posted usable code snippets on this thread. |
Nancy on Dotnet Core (OWIN + Kestrel)Alright! Here is a little gift to anyone who wants to do this but couldn't find a good example. HelloWorld.csproj
Program.cs
Startup.cs
DefaultModule.cs
|
Obviously we want to make Nancy run on .NET Core so we'll use this issue as the parent issue.
dotnet5.3
(netstandard1.2
) targets to run on .NET core (and beyond!)Please add items to this list or ask @NancyFx/most-valued-minions @NancyFx/owners to append it
The text was updated successfully, but these errors were encountered: