-
1. Re: startService use to work?
andrewboyd Jan 7, 2004 4:52 PM (in response to andrewboyd)When I removed the xmbean-dd my startService started to work!??
Can anyone see anything wrong with it?<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE mbean PUBLIC "-//JBoss//DTD JBOSS XMBEAN 1.0//EN" "http://www.jboss.org/j2ee/dtd/jboss_xmbean_1_0.dtd"> <mbean> <description>Host is the container in which agents reside</description> <descriptors> <persistence persistPolicy="Never"/> <currencyTimeLimit value="10"/> <state-action-on-update value="keep-running"/> <display-name value="KAFE Host"/> </descriptors> <class>com.digitalreasoning.kafe.host.Host</class> <!--attributes--> <attribute access="read-only" getMethod="getHostMetaData"> <description>Provides MetaData about the host that may be used to determine whether or not an agent would like to migrate there.</description> <name>HostMetaData</name> <type>com.digitalreasoning.kafe.host.HostMetaData</type> <descriptors> <persistence/> </descriptors> </attribute> <!--artificial attributes--> <!--operations --> <operation impact="ACTION"> <description>The entry port for MobileAgents.</description> <name>enter</name> <parameter> <description>A MobileAgent that wishes to enter this Host</description> <name>agent</name> <type>com.digitalreasoning.kafe.agent.MobileAgent</type> </parameter> <return-type>void</return-type> <descriptors> </descriptors> </operation> <!--artificial operations--> <!--notifications --> <notification> <description>Local Agent Registration</description> <name>javax.management.Notification</name> <notification-type>host.localagent.registered</notification-type> <descriptors> <persistence/> </descriptors> </notification> <notification> <description>Mobile Agent Registration</description> <name>javax.management.Notification</name> <notification-type>host.mobileagent.registered</notification-type> <descriptors> <persistence/> </descriptors> </notification> </mbean>
I would like to use an XMBean but write now I can't.
Thanks,
Andrew -
2. Re: startService use to work?
andrewboyd Jan 7, 2004 4:54 PM (in response to andrewboyd)Well that didn't show much. I'll try it with a quote
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mbean PUBLIC "-//JBoss//DTD JBOSS XMBEAN 1.0//EN" "http://www.jboss.org/j2ee/dtd/jboss_xmbean_1_0.dtd">
<mbean>
<description>Host is the container in which agents reside</description>
<descriptors>
<persistence persistPolicy="Never"/>
<currencyTimeLimit value="10"/>
<state-action-on-update value="keep-running"/>
<display-name value="KAFE Host"/>
</descriptors>
<class>com.digitalreasoning.kafe.host.Host</class>
<!--attributes-->
<attribute access="read-only" getMethod="getHostMetaData">
<description>Provides MetaData about the host that may be used to determine whether or not an agent would like to migrate there.</description>
<name>HostMetaData</name>
<type>com.digitalreasoning.kafe.host.HostMetaData</type>
<descriptors>
<persistence/>
</descriptors>
</attribute>
<!--artificial attributes-->
<!--operations -->
<operation impact="ACTION">
<description>The entry port for MobileAgents.</description>
<name>enter</name>
<parameter>
<description>A MobileAgent that wishes to enter this Host</description>
<name>agent</name>
<type>com.digitalreasoning.kafe.agent.MobileAgent</type>
</parameter>
<return-type>void</return-type>
<descriptors>
</descriptors>
</operation>
<!--artificial operations-->
<!--notifications -->
<notification>
<description>Local Agent Registration</description>
<name>javax.management.Notification</name>
<notification-type>host.localagent.registered</notification-type>
<descriptors>
<persistence/>
</descriptors>
</notification>
<notification>
<description>Mobile Agent Registration</description>
<name>javax.management.Notification</name>
<notification-type>host.mobileagent.registered</notification-type>
<descriptors>
<persistence/>
</descriptors>
</notification>
</mbean> -
3. Re: startService use to work?
andrewboyd Jan 7, 2004 4:56 PM (in response to andrewboyd)That did't work. How about w/out html
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mbean PUBLIC "-//JBoss//DTD JBOSS XMBEAN 1.0//EN" "http://www.jboss.org/j2ee/dtd/jboss_xmbean_1_0.dtd">
Host is the container in which agents reside
<state-action-on-update value="keep-running"/>
<display-name value="KAFE Host"/>
com.digitalreasoning.kafe.host.Host
<!--attributes-->
Provides MetaData about the host that may be used to determine whether or not an agent would like to migrate there.
HostMetaData
com.digitalreasoning.kafe.host.HostMetaData
<!--artificial attributes-->
<!--operations -->
The entry port for MobileAgents.
enter
A MobileAgent that wishes to enter this Host
agent
com.digitalreasoning.kafe.agent.MobileAgent
<return-type>void</return-type>
<!--artificial operations-->
<!--notifications -->
Local Agent Registration
javax.management.Notification
<notification-type>host.localagent.registered</notification-type>
Mobile Agent Registration
javax.management.Notification
<notification-type>host.mobileagent.registered</notification-type> -
4. Re: startService use to work?
andrewboyd Jan 7, 2004 5:26 PM (in response to andrewboyd)Ok. Found it. It is somewhat of a Dooh! but not exactly.
My XMBean descriptor (see above) did not list the startService method. (Dooh!)
However my MBean interface did extend ServiceMBean and I had even
added the startService method to my MBean interface so that is why I could not understand what was wrong.
Lesson learned. XMBean does not support interface inheritance.
Andrew