I doubt the code you show compiles, since the class doesn't implement the createScheduler method in the interface it allegedly implements.
david jencks On 2002.09.20 00:37:20 -0400 G.L. Grobe wrote: > I'm still having problems getting a simple MBean to deploy. Below is the > errors I'm getting and the MBean code itself. > > Any help much appreciated. > > --- jboss 3.0.2 error output > > 01:08:39,319 INFO [MainDeployer] Starting deployment of package: > file:/u/public/jboss/jboss-3.0.2/server/default/deploy/acaiis-scheduler-service.xml > 01:08:39,529 ERROR [URLDeploymentScanner] Failed to deploy: > org.jboss.deployment.scanner.URLDeploymentScanner$DeployedURL@23d7cabd{ > >url=file:/u/public/jboss/jboss-3.0.2/server/default/deploy/acaiis-scheduler-service.xml, > deployedLastModified=0 } > org.jboss.deployment.DeploymentException: DefaultDomain:service=Scheduler > is not registered.; - nested throwable: > (javax.management.InstanceNotFoundException: > DefaultDomain:service=Scheduler is not registered.) > at org.jboss.deployment.SARDeployer.create(SARDeployer.java:227) > at org.jboss.deployment.MainDeployer.create(MainDeployer.java:755) > at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:615) > at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:580) > at java.lang.reflect.Method.invoke(Native Method) > at >org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284) > > --- > > public class Scheduler extends org.jboss.system.ServiceMBeanSupport > implements SchedulerMBean > { > private String name; > > public boolean createService() { > > System.out.println("Creating MBean ..........."); > log.info(Scheduler.class, "Creating MBean ..........."); > > SchedulerFactory schedFact = new StdSchedulerFactory(); > Scheduler sched = schedFact.getScheduler(); > > sched.start(); > > return true; > } > > public String getName() { > return "Scheduler name = " + name; > } > > public void startService()() throws Exception { > log.info(Scheduler.class, "Starting Scheduler Service MBean > ..........."); > System.out.println("starting MBean ..........."); > } > > public void stopService() throws Exception { > log.info(Scheduler.class, "Stopping Scheduler Service MBean > ..........."); > System.out.println("stoping MBean ..........."); > } > } > > ---------- > > public interface SchedulerMBean extends org.jboss.system.ServiceMBean > { > public void start() throws Exception; > public void stop() throws Exception; > public boolean createScheduler() throws Exception; > } > > > <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> > <HTML><HEAD> > <META http-equiv=Content-Type content="text/html; charset=iso-8859-1"> > <META content="MSHTML 6.00.2719.2200" name=GENERATOR> > <STYLE></STYLE> > </HEAD> > <BODY bgColor=#ffffff> > <DIV><FONT face=Arial size=2>I'm still having problems getting a simple > MBean to > deploy. Below is the errors I'm getting and the MBean code > itself.<BR><BR>Any > help much appreciated.<BR></FONT></DIV> > <DIV><FONT face=Arial size=2>--- jboss 3.0.2 error output</FONT></DIV> > <DIV><FONT face=Arial size=2></FONT> </DIV> > <DIV><FONT face=Arial size=2> 01:08:39,319 INFO [MainDeployer] > > Starting deployment of package: > >file:/u/public/jboss/jboss-3.0.2/server/default/deploy/acaiis-scheduler-service.xml<BR>01:08:39,529 > > ERROR [URLDeploymentScanner] Failed to deploy: <A > >href="mailto:org.jboss.deployment.scanner.URLDeploymentScanner$DeployedURL@23d7cabd">org.jboss.deployment.scanner.URLDeploymentScanner$DeployedURL@23d7cabd</A>{ > > >url=file:/u/public/jboss/jboss-3.0.2/server/default/deploy/acaiis-scheduler-service.xml, > > deployedLastModified=0 }<BR>org.jboss.deployment.DeploymentException: > DefaultDomain:service=Scheduler is not registered.; - nested throwable: > (javax.management.InstanceNotFoundException: > DefaultDomain:service=Scheduler is > not registered.)<BR> at > >org.jboss.deployment.SARDeployer.create(SARDeployer.java:227)<BR> > > at > >org.jboss.deployment.MainDeployer.create(MainDeployer.java:755)<BR> > > at > >org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:615)<BR> > > at > >org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:580)<BR> > > at java.lang.reflect.Method.invoke(Native > Method)<BR> at > >org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)<BR></FONT></DIV> > <DIV><FONT face=Arial size=2>---</DIV></FONT> > <DIV><FONT face=Arial size=2></FONT> </DIV> > <DIV><FONT face=Arial size=2>public class Scheduler extends > org.jboss.system.ServiceMBeanSupport<BR> > implements SchedulerMBean<BR>{<BR> private String > name;</FONT></DIV> > <DIV> </DIV> > <DIV><FONT face=Arial size=2> public boolean createService() > {</FONT></DIV> > <DIV> </DIV> > <DIV><FONT face=Arial size=2> > System.out.println("Creating MBean > ...........");<BR> > log.info(Scheduler.class, > "Creating MBean ...........");</FONT></DIV> > <DIV> </DIV> > <DIV><FONT face=Arial size=2> > SchedulerFactory > schedFact = new StdSchedulerFactory();<BR> > Scheduler sched = schedFact.getScheduler();</FONT></DIV> > <DIV> </DIV> > <DIV><FONT face=Arial size=2> > sched.start();</FONT></DIV> > <DIV> </DIV> > <DIV><FONT face=Arial size=2> return > true;<BR> }</FONT></DIV> > <DIV><FONT face=Arial size=2></FONT> </DIV> > <DIV><FONT face=Arial size=2> public String getName() > {<BR> return "Scheduler name = " + > name;<BR> }</FONT></DIV> > <DIV> </DIV> > <DIV><FONT face=Arial size=2> public void startService()() > throws > Exception {<BR> log.info(Scheduler.class, > "Starting Scheduler Service MBean > ...........");<BR> > System.out.println("starting > MBean ...........");<BR> }</FONT></DIV> > <DIV> </DIV> > <DIV><FONT face=Arial size=2> public void stopService() > throws > Exception {<BR> log.info(Scheduler.class, > "Stopping Scheduler Service MBean > ...........");<BR> > System.out.println("stoping > MBean ...........");<BR> }<BR>}<BR></FONT></DIV> > <DIV><FONT face=Arial size=2>----------</DIV></FONT> > <DIV><FONT face=Arial size=2></FONT> </DIV> > <DIV><FONT face=Arial size=2>public interface SchedulerMBean extends > org.jboss.system.ServiceMBean<BR>{<BR> public void start() > throws > Exception;<BR> public void stop() throws > Exception;<BR> > public boolean createScheduler() throws > Exception;<BR>}<BR></DIV></FONT></BODY></HTML> > ------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf _______________________________________________ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user