Skip to content
This repository has been archived by the owner on Nov 1, 2018. It is now read-only.

[AspNetCoreModule] consider an 'auto-start' option #161

Closed
tuespetre opened this issue May 2, 2016 · 6 comments
Closed

[AspNetCoreModule] consider an 'auto-start' option #161

tuespetre opened this issue May 2, 2016 · 6 comments

Comments

@tuespetre
Copy link

With a 'traditional' ASP.NET application, IIS could be configured to have the app pool "Always Running", which would trigger Application_Start or a Startup class, giving developers a chance to schedule recurring background tasks and trust that they ran as long as IIS and the app pool were running. This was great for simple, small-scale deployment scenarios.

HttpPlatformHandler was not as friendly and enabling for such scenarios. Now that HttpPlatformHandler has been forked to AspNetCoreModule, could an option be added that causes the module to start the application immediately instead of waiting for a request?

@muratg muratg added this to the 1.0.0 milestone May 9, 2016
@mikes-gh
Copy link

Shouldn't the application lifetime be controlled at the IIS app pool level as it is now?

@guardrex
Copy link
Contributor

@mikes-gh It is, @tuespetre is calling attention to the startup nature of the app. Take a Windows Service, for example. When you start that service and set it to automatically start, you know that your service is going to fire right up and always run when the server restarts. We don't have that for IIS apps, and I think this is a great idea.

@mikes-gh
Copy link

@guardrex Being devils advocate 😄 I'm not sure web.config could control the app pool process lifetime variables such as "Always Running" ? The app pool might have more than one app in which case you might have 2 settings fighting each other. Unless we change the model to one app pol per app.
If @tuespetre is saying lets replace Application Initialization with a new mechanism in AspnetcoreModule I whole heartily agree. Its a real pain at the mo and pretty much every app I write I want always running and warmed up by default.

@guardrex
Copy link
Contributor

@mikes-gh AFAIK that's a non-starter b/c they issued earlier guidance: one app for one AppPool ... but that may have changed. I don't recall a more recent discussion on it.

I wasn't really too concerned about web.config setting it up; although, I believe you can set Idle Time-out with the <processModel> and the Always Running with applicationInitialization in web.config, but I've never done it. If I could just set things up manually, I'd be happy.

I want always running and warmed up by default.

👍

@Tratcher
Copy link
Member

We plan to use this feature to replace the DEBUG request (#102) VS currently sends to start the process. When that happens remove the DEBUG filter from IISMiddleware.

@Tratcher
Copy link
Member

This issue was moved to aspnet/AspNetCoreModule#29

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

6 participants