• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Liutauras Vilda
  • Jeanne Boyarsky
  • paul wheaton
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Henry Wong
Saloon Keepers:
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Tim Moores
  • Mikalai Zaikin
Bartenders:
  • Frits Walraven

what are JMX Configuration required in WebSphere5.0 with JDK1.4/Sample Pmirm.xml

 
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi All
I am using JMX mBeans in WebSphere5.0 with JDK1.4.
am getting runtime exception, when I am trying to
access mBeans through 2 approaches
My Requirement is restart the MQListener in WAS5.0 Programmatically using JMX without restarting the Server
1)If you have any sample configured Pmirm.xml that will help me to get rid of my PmiClient Creation Exception at runtime
2)What are the configuration setting required in WAS5.0 in order to get AdminClient?
--------------------------------------------------------
I put 1)admin.jar
2)wsexception.jar
3)jmxc.jar
4)pmi.jar
5)pmiclient.jar 6)JMX1.2Zip in classpath
-------------------------------------------
I followed 2 approaches
1)First Approach

com.ibm.websphere.pmi.client.PmiClient pmiClnt=new
PmiClient(NodeName,
PortNumber,"WAS50",false,"CONNECTOR_TYPE_SOAP");>>>
getting Exception in Runtime for Pmi
Client CreationPerfDescriptor[]
allservers=pmiClnt.listServers(NodeName);
javax.management.ObjectName[]
onames=pmiClnt.listMBeans(NodeName,ServerName);

Here have added all the Jar files in classpath of
WAS5.0, compiled fine , when I ran am getting
exception in Runtime for PmiClient Creation.
-----------------------------------------------
2)Second Approach
Properties props = new Properties();
props.setProperty(AdminClient.CONNECTOR_TYPE,
AdminClient.CONNECTOR_TYPE_SOAP);
props.setProperty(AdminClient.CONNECTOR_HOST,
HostName);
props.setProperty(AdminClient.CONNECTOR_PORT,
PortNumber);
props.setProperty(AdminClient.CONNECTOR_SECURITY_ENABLED, "false");

//props.setProperty(AdminClient.USERNAME, usrname); >>>>
We don't have username for SRSDev Appserver

//props.setProperty(AdminClient.PASSWORD, usrpwd);
>>>>>>We don't have password for SRSDev
Appserver(WAS5.0)

AdminClient adminClient =
AdminClientFactory.createAdminClient(props);----I am
getting exception in Runtime for adminClient Creation

// create a config service proxy object.ConfigService configService = new
ConfigServiceProxy(adminClient);

// create a session.
Session session = new Session();
whereAmI=54;
// query to get the node where we want to create the
new server.
ObjectName node = configService.resolve(session,
"Node=" + NodeName)[0];
whereAmI=55;
// Locate the application object.
ObjectName rootID = configService.resolve(session,
"Deployment="+ApplicationName)[0];
//System.out.println ("rootID is: " + rootID);
ObjectName
listenerMBean=ConfigServiceHelper.createObjectName
(nwie.net:type=Custom,name=ListenerManagement,
id=uniqueid);
where nwie.net ----is domain name) if I follow this
syntax am getting compilation error)
------------------------------------------------

Basically my requirement is to get ListenerManaged
MBean / and use that bean to restart my MQListener
prorammatically in Websphere5.0
Advance Thanks
Do you have any file called Pmirm or Pmi.xml in you
server ? I need to know configuration
if you have any sample Pmirm.xml
Advance Thanks/Appreciated
regards
bala
 
Bala Dakshin
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am getting InvocationTargetException, Please help me
13:02:41,248 [gine.Transports : 35] (enerated.nwieglobal_nwiecommon) ERROR shplas150|10.200.145.3 - java.rmi.RemoteException: [CollectorJMX] Failed to initialize CollectorJMX. Error creating AdminClient; nested exception is:
java.lang.reflect.InvocationTargetException
at com.ibm.ws.pmi.perfServer.CollectorJMX.init(CollectorJMX.java:128)
at com.ibm.ws.pmi.perfServer.DataCache.createCollector(DataCache.java:106)
at com.ibm.websphere.pmi.client.PmiClient.init(PmiClient.java:399)
at com.ibm.websphere.pmi.client.PmiClient.init(PmiClient.java:359)
at com.ibm.websphere.pmi.client.PmiClient.<init>(PmiClient.java:259)
at com.pegarules.generated.nwieglobal_nwiecommon.RestartListener02_30_02(nwieglobal_nwiecommon.java:16587)
at com.pegarules.generated.nwieglobal_nwiecommon.RestartListener(nwieglobal_nwiecommon.java:16699)
at com.pegarules.generated.activity.ra_activity_nwie_ni_prod_gsuw_rules_runservicerestartlistener_58daf02786bd2938780fbced3baeb308.step1_circum0(ra_activity_nwie_ni_prod_gsuw_rules_runservicerestartlistener_58daf02786bd2938780fbced3baeb308.java:208)
at com.pegarules.generated.activity.ra_activity_nwie_ni_prod_gsuw_rules_runservicerestartlistener_58daf02786bd2938780fbced3baeb308.perform(ra_activity_nwie_ni_prod_gsuw_rules_runservicerestartlistener_58daf02786bd2938780fbced3baeb308.java:66)
at com.pega.pegarules.engine.runtime.Executable.doActivity(Executable.java(Compiled Code))
at com.pega.pegarules.engine.context.PRThreadImpl.runActivitiesAlt(PRThreadImpl.java(Compiled Code))
at com.pega.pegarules.web.util.HTTPRulesWrapper.processInputData(HTTPRulesWrapper.java(Compiled Code))
at com.pega.pegarules.web.PRServlet.doPost(PRServlet.java(Compiled Code))
at com.pega.pegarules.web.PRServlet.doGet(PRServlet.java(Compiled Code))
at javax.servlet.http.HttpServlet.service(HttpServlet.java(Compiled Code))
at javax.servlet.http.HttpServlet.service(HttpServlet.java(Compiled Code))
at com.ibm.ws.webcontainer.servlet.StrictServletInstance.doService(StrictServletInstance.java(Compiled Code))
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet._service(StrictLifecycleServlet.java(Compiled Code))
at com.ibm.ws.webcontainer.servlet.IdleServletState.service(StrictLifecycleServlet.java(Compiled Code))
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet.service(StrictLifecycleServlet.java(Inlined Compiled Code))
at com.ibm.ws.webcontainer.servlet.ServletInstance.service(ServletInstance.java(Compiled Code))
at com.ibm.ws.webcontainer.servlet.ValidServletReferenceState.dispatch(ValidServletReferenceState.java(Compiled Code))
at com.ibm.ws.webcontainer.servlet.ServletInstanceReference.dispatch(ServletInstanceReference.java(Inlined Compiled Code))
at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java(Compiled Code))
at com.pega.pegarules.web.StaticContentFilter.doFilter(StaticContentFilter.java(Compiled Code))
at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java(Compiled Code))
at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java(Compiled Code))
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.handleWebAppDispatch(WebAppRequestDispatcher.java(Compiled Code))
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.dispatch(WebAppRequestDispatcher.java(Compiled Code))
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.forward(WebAppRequestDispatcher.java(Compiled Code))
at com.ibm.ws.webcontainer.srt.WebAppInvoker.doForward(WebAppInvoker.java(Compiled Code))
at com.ibm.ws.webcontainer.srt.WebAppInvoker.handleInvocationHook(WebAppInvoker.java(Compiled Code))
at com.ibm.ws.webcontainer.cache.invocation.CachedInvocation.handleInvocation(CachedInvocation.java(Compiled Code))
at com.ibm.ws.webcontainer.cache.invocation.CacheableInvocationContext.invoke(CacheableInvocationContext.java(Compiled Code))
at com.ibm.ws.webcontainer.srp.ServletRequestProcessor.dispatchByURI(ServletRequestProcessor.java(Compiled Code))
at com.ibm.ws.webcontainer.oselistener.OSEListenerDispatcher.service(OSEListener.java(Compiled Code))
at com.ibm.ws.webcontainer.http.HttpConnection.handleRequest(HttpConnection.java(Compiled Code))
at com.ibm.ws.http.HttpConnection.readAndHandleRequest(HttpConnection.java(Compiled Code))
at com.ibm.ws.http.HttpConnection.run(HttpConnection.java(Compiled Code))
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java(Compiled Code))
Caused by: java.lang.reflect.InvocationTargetException
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java(Compiled Code))
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java(Compiled Code))
at java.lang.reflect.Constructor.newInstance(Constructor.java(Compiled Code))
at com.ibm.websphere.pmi.PmiJmxMapper.<init>(PmiJmxMapper.java:73)
at com.ibm.ws.pmi.perfServer.CollectorJMX.init(CollectorJMX.java:123)
... 39 more
Caused by: com.ibm.websphere.management.exception.InvalidAdminClientTypeException
at com.ibm.websphere.management.AdminClientFactory.createAdminClient(AdminClientFactory.java:489)
at com.ibm.websphere.pmi.extutils.AdminUtilClntImpl.<init>(AdminUtilClntImpl.java:76)
 
What? What, what, what? What what tiny ad:
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
reply
    Bookmark Topic Watch Topic
  • New Topic