What is a resource script?
Resource scripts are basically (extended) System V init scripts. They have to support stop, start, and status operations. In the future we will also add support for a monitor operation for monitoring services as you requested. The IPaddr script implements this new monitor operation now (but Heartbeat doesn’t use that function of it). For more info see Resource HOWTO.