Results 1 to 4 of 4

Thread: websphere 6.0 and spring jmx

  1. #1
    Join Date
    Apr 2006
    Posts
    2

    Default websphere 6.0 and spring jmx

    I'm trying to access a remote websphere 6.0 JMX Server.

    I'm Using the MBeanServerConnectionFactoryBean but the default serviceUrl is not working (I'm using service:jmx:rmi://localhost:2809) I'm getting back a null object.

    I didnt find anyware in the Internet any example of using Client-side Connectors with spring and websphere (I have to say that I succeded to connect to the jmx server from a stand alone client with the websphere jmx api but I still want to use Spring to do it and to also use proxy object)

    Does Spring-jmx Client-side Connectors support websphere ?
    Anyone tried it and can send me the xml configuration?

    Thnx, asaf.

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

    Default

    Can you post your configuration and turn on logging and see what is going on? Spring uses jmx so as long as ws 6.0 supports jmx 1.2 (I assume it does especially since you managed to connect with a client), your scenario should work.
    there is probably some small configuration error that is causing the problem.
    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

  3. #3
    Join Date
    Apr 2006
    Posts
    2

    Default

    this is the application-context.xml:
    <beans>
    <bean id="clientConnector" class="org.springframework.jmx.support.MBeanServer ConnectionFactoryBean">
    <property name="serviceUrl" value="service:jmx:rmi://localhost:2809"/>
    </bean>


    from my code i'm just calling to this bean.

    the error i get:
    Exception in thread "P=396219:O=0:CT" org.springframework.beans.factory.FactoryBeanNotIn itializedException: Error creating bean with name 'clientConnector': FactoryBean returned null object: probably not fully initialized (maybe due to circular bean reference)
    at org.springframework.beans.factory.support.Abstract BeanFactory.getObjectForSharedInstance(AbstractBea nFactory.java:833)
    at org.springframework.beans.factory.support.Abstract BeanFactory.getBean(AbstractBeanFactory.java:248)
    at org.springframework.beans.factory.support.Abstract BeanFactory.getBean(AbstractBeanFactory.java:145)
    at a.JmxMain.main(JmxMain.java:61)


    I think that the serviceUrl is not OK.

    maybe someone has a source code for a working example on websphere?

  4. #4

    Default Websphere 6.0 RAd

    Hi,
    I am having my server running onconsole based application. I am trying to connect it to through Webshpere 6.0 and i am using standard mbean

    JMXServiceURL url = new JMXServiceURL(
    "service:jmx:rmi://localhost:9999/jndi/rmi://localhost:9999/server");

    JMXConnector jmxc = JMXConnectorFactory.connect(url, null);
    MBeanServerConnection mbsc = jmxc.getMBeanServerConnection();

    But jmxc.getMBeanServerConnection() is returning a null value.

    I am not finding any reason for thsi.

    But if i am running on console based, It is running perfectly.

    if url is "service:jmx:rmi:///jndi/rmi://localhost:9999/server",
    it is unable to parse url.

    i am expecting a solution friom you bcoz u have faced this problem

Posting Permissions

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