Solved

Need a way to force application start

Posted on 2011-02-17
8
537 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 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
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
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

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

One of the pain points with developing AJAX, JavaScript, JQuery, and other client-side behaviors is that JavaScript doesn’t allow for cross domain request for pulling content. For example, JavaScript code on www.johnchapman.name could not pull conte…
Today is the age of broadband.  More and more people are going this route determined to experience the web and it’s multitude of services as quickly and painlessly as possible. Coupled with the move to broadband, people are experiencing the web via …
How to Install VMware Tools in Red Hat Enterprise Linux 6.4 (RHEL 6.4) Step-by-Step Tutorial

735 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