users@glassfish.java.net

developing lifecycle module

From: Saloustros Georgios <gesalous_at_gmail.com>
Date: Wed, 19 Dec 2007 19:52:10 +0200

Hello.
I am trying to develop a test lifecycle module for glassfish.
As I read the documentation every time an LifeCycle Event arrives the
application server calls the handleEvent method for every lifecycle
module(right?)
In glassfish's domain.xml file the lifecycle module is configured as

*<lifecycle-module* class-name="Loader"
classpath="/root/NetBeansProjects/loader/build/classes/LifecycleModule"
enabled="true" is-failure-fatal="true" name="loader"
object-type="user"*/>*

...and the module

package LifecycleModule;

import com.sun.appserv.server.*;



/**
 *
 * @author root
 */
public class Loader implements com.sun.appserv.server.LifecycleListener
    {

     public void handleEvent(com.sun.appserv.server.LifecycleEvent event)
     {

          if (event.getEventType()==event.INIT_EVENT)
            {


              System.out.println("got init event");
            }

            else if(event.getEventType()==event.READY_EVENT)
            {
                System.out.println("got ready event");
            }

             else if(event.getEventType()==event.STARTUP_EVENT)
            {
                System.out.println("got startup event");
            }
             else if(event.getEventType()==event.SHUTDOWN_EVENT)
            {
                System.out.println("got shutdown event");
            }
             else if(event.getEventType()==event.TERMINATION_EVENT)
            {
               System.out.println("got termination event");
            }

             else{ }
           }




     }


}/*end of class Loader*/

but in the server log I get a Loader class not found exception .
What am I doing wrong?
Thanks,
GS