Question

I would like to do some logging at the end of the lifetime of my nancy web app. In an MVC/Webforms ASP.NET application I would use Application_End. I thought there might be a suitable overridable method in DefaultNancyBootstrapper but can't see one - Is there something equivalent to this in Nancy?

Was it helpful?

Solution

I'm not sure what you would gain from this at all. But we are sort of lacking some information.

When you're working with IIS / System.Web hosting then you can still use the Application_End event.

If you're self-hosting in a console then you can just include code that happens after the Console's ReadKey event is raised (or similar)

If you're using OWIN then I'm not sure what you could hook into.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top