Results 1 to 7 of 7

Thread: JMX attributes do not appear on Tomcat

Hybrid View

  1. #1
    Join Date
    Nov 2004
    Posts
    18

    Default JMX attributes do not appear on Tomcat

    I'm using Spring 1.2.2 with Tomcat 5.0.

    I have the following JMX/MBean configuration in my application context file.

    <bean id="exporter" class="org.springframework.jmx.export.MBeanExporte r">
    <property name="beans">
    <map>
    <entry key="bean:name=presenceService">
    <ref local="presenceService"/>
    </entry>
    </map>
    </property>
    <property name="assembler">
    <bean class="org.springframework.jmx.export.assembler.Me thodNameBasedMBeanInfoAssembler">
    <property name="methodMappings">
    <map>
    <entry key="bean:name=presenceService"><value>getJabberSe rver,getJabberServerPort,getEnable</value></entry>
    </map>
    </property>
    </bean>
    </property>
    </bean>

    When I deploy my app on JBoss 4.0.2 and point my browser to http://localhost:8080/web-console, I can see three attributes - getJabberServer, getJabberServerPort, getEnable - on the JMX console and the values of the attributes displayed there are correct.

    However, when I deploy the same app/configuration on Tomcat 5.0, and point my browser to http://localhost:8080/manager/jmxproxy/?qry=*:*, I can only see the name of my JMX bean but not its attributes. The following two lines are all I got.

    Name: bean:name=presenceService
    modelerType: com.sitescape.ef.presence.impl.PresenceServiceImpl

    All Tomcat JMX components themlselves are displayed correctly with their attribute values included.

    Does anyone know why this discrepency? Any help would be appreciated.

  2. #2
    Join Date
    Nov 2004
    Posts
    18

    Default Standard MBeans work

    To further investigate the problem, I added another bean that actually implements MBean interface (i.e., standard MBeans) and Tomcat displays the attributes of the bean without problem. So it appears that only the dynamic/model MBeans setup is not working. Does anyone know if this is a problem with Tomcat's JMX support?

  3. #3
    Join Date
    Jan 2005
    Location
    Bucharest, Romania
    Posts
    5,403

    Default

    What about Spring 1.2.6?
    Costin Leau
    SpringSource - http://www.SpringSource.com- Spring Training, Consulting, and Support - "From the Source"
    http://twitter.com/costinl
    Please use [ c o d e ] [ / c o d e ] tags

  4. #4
    Join Date
    Nov 2004
    Posts
    18

    Default no difference

    I just tried Spring 1.2.6, but still the same.

  5. #5
    Join Date
    Jan 2005
    Location
    Bucharest, Romania
    Posts
    5,403

    Default

    Can you please raise an issue on JIRA? It would help if you could provide a simple test/example that demonstrates the problem. Thanks.
    Costin Leau
    SpringSource - http://www.SpringSource.com- Spring Training, Consulting, and Support - "From the Source"
    http://twitter.com/costinl
    Please use [ c o d e ] [ / c o d e ] tags

  6. #6
    Join Date
    Aug 2006
    Posts
    130

    Default jdk

    I encountered the same behaviour when i had to change the
    JAVA_HOME for JBoss from 1.5 to 1.42 for production,
    i've tried interface mappings,commons-attributes and method-based export
    interface = attributes are all null
    common-attributes = only the first attribute was shown with null value
    method-based = the last method was exposed as an operation the rest as attributes with null value

    with jdk 1.5 it worked fine.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •