beautypg.com

Starting up multiple monitor instances – Apple WebObjects 3.5: Serving User Manual

Page 37

background image

Serving WebObjects

38

2. Set up your site so that the proper URL for the ISAPI adaptor is submitted

when users click buttons, images, or hyperlinks that have as targets
WebObjects applications. This URL has the form:

http://host/Scripts/WebObjects-ISAPI.dll/ApplicationPath

For HTTP requests that use the CGI adaptor, make sure that the URLs
conform to this format:

http://host/Scripts/WebObjects.exe/ApplicationPath

Starting Up Multiple Monitor Instances

As a fail-safe measure, you can start up multiple instances of the same Monitor
application. When you start an instance of Monitor, the instance searches to see
if another instance is running. If so, it puts itself to sleep. If the first Monitor
instance crashes, the second instance will wake itself. Monitor stores its
configuration information and its current state in the file system. Thus, in the
event of a crash, the backup instance can take over, read the configuration file,
restore the state from the file system, and continue as if nothing had happened.

You can have as many instances of Monitor running as you like. They will order
themselves to take over in the event that the controlling instance fails.

The same holds true for

MonitorProxy

daemon. You can have as many of these

running as you like.

Remember that Monitor is a WebObjects application. To start multiple
instances, you must provide unique instances numbers and port numbers to the
adaptor on the command line, as well as the application path argument, like this:

> Monitor.exe -a WODefaultAdaptor -n 1 -p 1067 Monitor

> Monitor.exe -a WODefaultAdaptor -n 2 -p 1068 Monitor

In this example, the first instance becomes the controlling instance of Monitor.
The second instance becomes active only if the first instance crashes.