You are viewing a plain text version of this content. The canonical link for it is here.
Posted to phoenix-dev@avalon.apache.org by Ulrich Mayring <ul...@denic.de> on 2002/10/21 12:10:20 UTC

MXINFO question

Hello,

I've just created my first MXINFO file, but the descriptions I put in 
don't appear in the management console of MX4J. Apparently the file 
wasn't evaluated, but I don't see any error message in phoenix.log. Here 
are the files I have:

MyApp - an empty interface class (no methods or constructors)
MyAppMBean - contains some interface definitions for JMX
MyAppImpl - contains the implementations of the MyAppMBean interfaces 
and implements MyApp
MyAppMBean.mxinfo - my MXINFO file

Here's my MyAppMBean file:

public interface MyAppMBean {
     public String deleteObject(String id);
     public String getStatus();
     public void resume();
     public void pause();
     }

Here's what I have in the MXINFO file:

<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE mxinfo PUBLIC "-//PHOENIX/Mx Info DTD Version 1.0//EN"
 
"http://jakarta.apache.org/avalon/dtds/phoenix/mxinfo_1_0.dtd">

<mxinfo>

     <topic name="MyApp">

       <!-- attributes -->
       <attribute
         name="status"
         description="Status of MyApp"
         isWriteable="no"
         type="java.lang.String"
       />

       <!-- operations -->
       <operation
         name="deleteObject"
         description="Deletes an Object"
         type="java.lang.String"
       >
         <param
           name="instance"
           description="ID of Object to be deleted"
           type="java.lang.String"
         />
       </operation>

     </topic>

</mxinfo>

I was expecting that the descriptions I put in should appear in the 
MX4J-generated MBean web page, but they don't. I can think of two 
possible mistakes I made (although the docs don't forbid them):

1. I didn't define all the methods from the interfaces in MyAppMBean in 
the MXINFO file, because I only need descriptions for a few.

2. I should have called the MXINFO file MyAppImpl.mxinfo

Any ideas on how to debug this?

Ulrich

-- 
Ulrich Mayring
DENIC eG, Systementwicklung


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: MXINFO question

Posted by Peter Donald <pe...@apache.org>.
Can you try with the CVS version of phoenix. I just applied a patch that may 
fix your problem (and then again may not).

On Mon, 21 Oct 2002 20:10, Ulrich Mayring wrote:
> Hello,
>
> I've just created my first MXINFO file, but the descriptions I put in
> don't appear in the management console of MX4J. Apparently the file
> wasn't evaluated, but I don't see any error message in phoenix.log. Here
> are the files I have:
>
> MyApp - an empty interface class (no methods or constructors)
> MyAppMBean - contains some interface definitions for JMX
> MyAppImpl - contains the implementations of the MyAppMBean interfaces
> and implements MyApp
> MyAppMBean.mxinfo - my MXINFO file
>
> Here's my MyAppMBean file:
>
> public interface MyAppMBean {
>      public String deleteObject(String id);
>      public String getStatus();
>      public void resume();
>      public void pause();
>      }
>
> Here's what I have in the MXINFO file:
>
> <?xml version="1.0" encoding="ISO-8859-1"?>
> <!DOCTYPE mxinfo PUBLIC "-//PHOENIX/Mx Info DTD Version 1.0//EN"
>
> "http://jakarta.apache.org/avalon/dtds/phoenix/mxinfo_1_0.dtd">
>
> <mxinfo>
>
>      <topic name="MyApp">
>
>        <!-- attributes -->
>        <attribute
>          name="status"
>          description="Status of MyApp"
>          isWriteable="no"
>          type="java.lang.String"
>        />
>
>        <!-- operations -->
>        <operation
>          name="deleteObject"
>          description="Deletes an Object"
>          type="java.lang.String"
>
>          <param
>            name="instance"
>            description="ID of Object to be deleted"
>            type="java.lang.String"
>          />
>        </operation>
>
>      </topic>
>
> </mxinfo>
>
> I was expecting that the descriptions I put in should appear in the
> MX4J-generated MBean web page, but they don't. I can think of two
> possible mistakes I made (although the docs don't forbid them):
>
> 1. I didn't define all the methods from the interfaces in MyAppMBean in
> the MXINFO file, because I only need descriptions for a few.
>
> 2. I should have called the MXINFO file MyAppImpl.mxinfo
>
> Any ideas on how to debug this?
>
> Ulrich

-- 
Cheers,

Peter Donald
Einstein argued that there must be simplified explanations of nature, because
God is not capricious or arbitrary.  No such faith comforts the software
engineer.
- Fred Brooks, Jr.


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: MXINFO question

Posted by Ulrich Mayring <ul...@denic.de>.
Paul Hammant wrote:
> Ulrich,
> 
> Check in Phoenix.log.  There is a fail-silent bug that manifests itself 
> for weird return types on attributes. Try commenting all out then adding 
> them one by one.

As I said, there's nothing in phoenix.log. Also, what's weird about a 
java.lang.String return type? I'm not sure what I should comment out, as 
I only have one attribute anyway :)

Ulrich

-- 
Ulrich Mayring
DENIC eG, Systementwicklung


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: MXINFO question

Posted by Paul Hammant <Pa...@yahoo.com>.
Ulrich,

Check in Phoenix.log.  There is a fail-silent bug that manifests itself 
for weird return types on attributes. Try commenting all out then adding 
them one by one.

- Paul

> Hello,
>
> I've just created my first MXINFO file, but the descriptions I put in 
> don't appear in the management console of MX4J. Apparently the file 
> wasn't evaluated, but I don't see any error message in phoenix.log. 
> Here are the files I have:
>
> MyApp - an empty interface class (no methods or constructors)
> MyAppMBean - contains some interface definitions for JMX
> MyAppImpl - contains the implementations of the MyAppMBean interfaces 
> and implements MyApp
> MyAppMBean.mxinfo - my MXINFO file
>
> Here's my MyAppMBean file:
>
> public interface MyAppMBean {
>     public String deleteObject(String id);
>     public String getStatus();
>     public void resume();
>     public void pause();
>     }
>
> Here's what I have in the MXINFO file:
>
> <?xml version="1.0" encoding="ISO-8859-1"?>
> <!DOCTYPE mxinfo PUBLIC "-//PHOENIX/Mx Info DTD Version 1.0//EN"
>
> "http://jakarta.apache.org/avalon/dtds/phoenix/mxinfo_1_0.dtd">
>
> <mxinfo>
>
>     <topic name="MyApp">
>
>       <!-- attributes -->
>       <attribute
>         name="status"
>         description="Status of MyApp"
>         isWriteable="no"
>         type="java.lang.String"
>       />
>
>       <!-- operations -->
>       <operation
>         name="deleteObject"
>         description="Deletes an Object"
>         type="java.lang.String"
>       >
>         <param
>           name="instance"
>           description="ID of Object to be deleted"
>           type="java.lang.String"
>         />
>       </operation>
>
>     </topic>
>
> </mxinfo>
>
> I was expecting that the descriptions I put in should appear in the 
> MX4J-generated MBean web page, but they don't. I can think of two 
> possible mistakes I made (although the docs don't forbid them):
>
> 1. I didn't define all the methods from the interfaces in MyAppMBean 
> in the MXINFO file, because I only need descriptions for a few.
>
> 2. I should have called the MXINFO file MyAppImpl.mxinfo
>
> Any ideas on how to debug this?
>
> Ulrich
>



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>