Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Need a way to force application start

Posted on 2011-02-17
8
Medium Priority
?
541 Views
Last Modified: 2012-05-11
I am coding a "wake up" system for my app.  I am using a "cache expired" event to trigger things.  I need to wake up my application after it has stopped due to inactiviy.  One recommended method is to hit the site with an http request.  This is not working for me because of router issues.  (trying to send request to myself on the public network does not work due to router configuration poblems).  Also, sending a request seems like an extreme kludge just to get the application to startup.

Is there a way to force an application start from code, without sending an http request to the site?

0
Comment
Question by:No1Coder
  • 4
  • 3
8 Comments
 
LVL 16

Expert Comment

by:BurnieP
ID: 34921682
Hi,

You can check this article titled : Forcing an ASP.NET Application to 'stay alive'  at http://www.west-wind.com/weblog/posts/67557.aspx.

0
 
LVL 2

Expert Comment

by:jondow
ID: 34924761
Assuming you are using .net 4 with IIS 7+ you can use the auto start feature...

To use the ASP.NET 4 auto-start feature, you first configure the IIS “application pool” worker process that the application runs within to automatically startup when the web-server first loads.  You can do this by opening up the IIS 7.5 applicationHost.config file (C:\Windows\System32\inetsrv\config\applicationHost.config) and by adding a startMode=”AlwaysRunning” attribute to the appropriate <applicationPools> entry:

    <applicationPools>

         <add name="MyAppWorkerProcess" managedRuntimeVersion="v4.0" startMode="AlwaysRunning" />

    </applicationPools>

Full article at:
http://weblogs.asp.net/scottgu/archive/2009/09/15/auto-start-asp-net-applications-vs-2010-and-net-4-0-series.aspx
0
 

Author Comment

by:No1Coder
ID: 34924883
jondow: I am running w2008 web server.  Unfortunately, it does not have the auto start feature.


Burniep: This solution sends a web request to wake up the server.  This is what I am trying to avoid.
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
LVL 2

Expert Comment

by:jondow
ID: 34925056
Im not sure then.

A bodge I use on one of my websites (publicly available) is to use pingdom, which hits a designated web page at regular intervals.  I know thats what you are trying to avoid but it may be a useful and easy option if you dont find another way.
0
 

Author Comment

by:No1Coder
ID: 34925130
Jondow:  I wrote one of these myself.  I was trying to make the application self sustaining though.  I guess there is no solution.
0
 
LVL 2

Expert Comment

by:jondow
ID: 34925167
Check this one out, havent tried it yet but the idea is sound:

http://weblogs.asp.net/dmarsh/archive/2003/02/21/2758.aspx

Or will you get the same routing issues with this approach?
0
 

Accepted Solution

by:
No1Coder earned 0 total points
ID: 34945929
No apparent solution exists.  Clsoing.
0
 

Author Closing Comment

by:No1Coder
ID: 34986541
No solution exists.
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Lots of people ask this question on how to extend the “MembershipProvider” to make use of custom authentication like using existing database or make use of some other way of authentication. Many blogs show you how to extend the membership provider c…
In an ASP.NET application, I faced some technical problems. In this article, I list them out and show the solutions that I found.  I hope it will be useful. Problem: After closing a pop-up window, the parent page should be refreshed automaticall…
We’ve all felt that sense of false security before—locking down external access to a database or component and feeling like we’ve done all we need to do to secure company data. But that feeling is fleeting. Attacks these days can happen in many w…
Please read the paragraph below before following the instructions in the video — there are important caveats in the paragraph that I did not mention in the video. If your PaperPort 12 or PaperPort 14 is failing to start, or crashing, or hanging, …
Suggested Courses

972 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question