creating a JDBC provider using IBM's ConfigServiceProxy (JMX)

Discussions

General J2EE: creating a JDBC provider using IBM's ConfigServiceProxy (JMX)

  1. I am trying to create a JDBC provider using IBM's ConfigServiceProxy class.

    My code runs in a standalone Java application (It does not run inside Websphere)

    My server is WebSphere Platform 5.1 [BASE 5.1.1 a0426.01] [JDK 1.4.2.1.1 pj9n142sr1a-20050218] on Windows XP.

    When I try to create a JDBC provider, an exception occurs in the server.

    How can I fix this?


    com.ibm.websphere.management.exception.ConfigServiceException
    at com.ibm.ws.management.configservice.WorkspaceHelper.getTemplate(WorkspaceHelper.java:274)
    at com.ibm.ws.management.configservice.WorkspaceHelper.getTemplate(WorkspaceHelper.java:208)
    at com.ibm.ws.management.configservice.MOFUtil.newRefObject(MOFUtil.java:78)
    at com.ibm.ws.management.configservice.MOFUtil.createRefObject(MOFUtil.java:1053)
    at com.ibm.ws.management.configservice.MOFUtil.createRefObject(MOFUtil.java:314)
    at com.ibm.ws.management.configservice.DocAccessor.createRootConfigObject(DocAccessor.java:137)
    at com.ibm.ws.management.configservice.RootObjectDelegator.createConfigObject(RootObjectDelegator.java:230)
    at com.ibm.ws.management.configservice.ConfigObjectDelegator.createConfigData(ConfigObjectDelegator.java:139)
    at com.ibm.ws.management.configservice.ConfigServiceImpl.createConfigDataByTemplate(ConfigServiceImpl.java:697)
    at com.ibm.ws.management.configservice.ConfigServiceImpl.createConfigData(ConfigServiceImpl.java:729)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:85)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:58)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:60)
    at java.lang.reflect.Method.invoke(Method.java:391)
    at com.tivoli.jmx.modelmbean.MMBInvoker.invoke(MMBInvoker.java:46)
    at com.tivoli.jmx.modelmbean.MMBInvoker.invokeOperation(MMBInvoker.java:115)
    at com.tivoli.jmx.modelmbean.DynamicModelMBeanSupport.invoke(DynamicModelMBeanSupport.java:409)
    at javax.management.modelmbean.RequiredModelMBean.invoke(RequiredModelMBean.java:323)
    at com.tivoli.jmx.GenericMBeanSupport.invoke(GenericMBeanSupport.java:178)
    at com.tivoli.jmx.MBeanAccess.invoke(MBeanAccess.java:113)
    at com.tivoli.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:290)
    at com.ibm.ws.management.AdminServiceImpl.invoke(AdminServiceImpl.java:659)
    at com.ibm.ws.management.connector.AdminServiceDelegator.invoke(AdminServiceDelegator.java:130)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:85)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:58)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:60)
    at java.lang.reflect.Method.invoke(Method.java:391)
    at com.ibm.ws.management.connector.soap.SOAPConnector.invoke(SOAPConnector.java:306)
    at com.ibm.ws.management.connector.soap.SOAPConnector.service(SOAPConnector.java:178)
    at com.ibm.ws.management.connector.soap.SOAPConnection.handleRequest(SOAPConnection.java:55)
    at com.ibm.ws.http.HttpConnection.readAndHandleRequest(HttpConnection.java:615)
    at com.ibm.ws.http.HttpConnection.run(HttpConnection.java:439)
    at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:912)
    Caused by: java.lang.NullPointerException
    at com.ibm.ws.management.configservice.WorkspaceHelper.getTemplate(WorkspaceHelper.java:239)
    ... 34 more
    ---- Begin backtrace for nested exception
    java.lang.NullPointerException
    at com.ibm.ws.management.configservice.WorkspaceHelper.getTemplate(WorkspaceHelper.java:239)
    at com.ibm.ws.management.configservice.WorkspaceHelper.getTemplate(WorkspaceHelper.java:208)
    at com.ibm.ws.management.configservice.MOFUtil.newRefObject(MOFUtil.java:78)
    at com.ibm.ws.management.configservice.MOFUtil.createRefObject(MOFUtil.java:1053)
    at com.ibm.ws.management.configservice.MOFUtil.createRefObject(MOFUtil.java:314)
    at com.ibm.ws.management.configservice.DocAccessor.createRootConfigObject(DocAccessor.java:137)
    at com.ibm.ws.management.configservice.RootObjectDelegator.createConfigObject(RootObjectDelegator.java:230)
    at com.ibm.ws.management.configservice.ConfigObjectDelegator.createConfigData(ConfigObjectDelegator.java:139)
    at com.ibm.ws.management.configservice.ConfigServiceImpl.createConfigDataByTemplate(ConfigServiceImpl.java:697)
    at com.ibm.ws.management.configservice.ConfigServiceImpl.createConfigData(ConfigServiceImpl.java:729)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:85)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:58)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:60)
    at java.lang.reflect.Method.invoke(Method.java:391)
    at com.tivoli.jmx.modelmbean.MMBInvoker.invoke(MMBInvoker.java:46)
    at com.tivoli.jmx.modelmbean.MMBInvoker.invokeOperation(MMBInvoker.java:115)
    at com.tivoli.jmx.modelmbean.DynamicModelMBeanSupport.invoke(DynamicModelMBeanSupport.java:409)
    at javax.management.modelmbean.RequiredModelMBean.invoke(RequiredModelMBean.java:323)
    at com.tivoli.jmx.GenericMBeanSupport.invoke(GenericMBeanSupport.java:178)
    at com.tivoli.jmx.MBeanAccess.invoke(MBeanAccess.java:113)
    at com.tivoli.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:290)
    at com.ibm.ws.management.AdminServiceImpl.invoke(AdminServiceImpl.java:659)
    at com.ibm.ws.management.connector.AdminServiceDelegator.invoke(AdminServiceDelegator.java:130)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:85)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:58)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:60)
    at java.lang.reflect.Method.invoke(Method.java:391)
    at com.ibm.ws.management.connector.soap.SOAPConnector.invoke(SOAPConnector.java:306)
    at com.ibm.ws.management.connector.soap.SOAPConnector.service(SOAPConnector.java:178)
    at com.ibm.ws.management.connector.soap.SOAPConnection.handleRequest(SOAPConnection.java:55)
    at com.ibm.ws.http.HttpConnection.readAndHandleRequest(HttpConnection.java:615)
    at com.ibm.ws.http.HttpConnection.run(HttpConnection.java:439)
    at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:912)
  2. Check out my blog at:
    http://www.jroller.com/page/rankorn

    There are some explainations and examples on using JMX with WAS.