-
1. Re: How to not run a gateway instance if the target server is down
BKBK Feb 5, 2009 12:27 PM (in response to BrianO)The DirectoryWatcher gateway is designed to check a directory on the same server, not on another server.
-
2. Re: How to not run a gateway instance if the target server is down
BrianO Feb 5, 2009 12:31 PM (in response to BrianO)It works fine on other servers as long as permissions are set correctly. -
3. Re: How to not run a gateway instance if the target server is down
BKBK Feb 9, 2009 7:58 PM (in response to BrianO)How do I tell the gateway instance to not run if the server it is looking at is down or the directory in this case is unavailable?
I missed that one. Coldfusion's gateways are perpetual listeners, threads that are designed to run continuously.
-
4. Re: How to not run a gateway instance if the target server is down
Theravive Mar 10, 2010 8:31 PM (in response to BKBK)listeners have a timeout period. if the target computer is going through a reboot cycle, the downtime should be short enough that you can setup a timeout. Set one that is long enough so that you do not trigger a failure event, and the timepsan allows for the target server to come back online before the timeout expiration.
Another way that is more robust is to create a seperate application, perhaps one built on Visual Studio or even a scripthost that does a simple ping of the destination server every 10 seconds or so. When the server is not found, you can do a shutdown of your CF. (you can shutdown any application from another application). Once you can re-ping the server, relaunch your gateway listener. If the listener cannot support what you want to do, just write another program that will perform your logic for you.
People have it within them to change
Proud user of Adobe products, and webmaster of the Theravive counselor network , built on Dreamweaver, and Photoshop. Toss in a little Visual Studio, but who's keeping score!


