• 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 ...
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Jeanne Boyarsky
  • Tim Cooke
  • Liutauras Vilda
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Frits Walraven
  • Piet Souris
  • Himai Minh


Ranch Hand
Posts: 40
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

I have a question concerning the way I can get javax.management.ObjectName for WebSphere ApplicationManager and AppManagement objects. With WebSphere 6.00 I would do something like this:

String queryExp = "WebSphere latform= dynamicproxy,cell=CELLNAME,version=,name=ApplicationManager||AppManagement,mbeanIdentifier= ApplicationManager||AppManagement ,type= ApplicationManager||AppManagement,node=NODENAME,process=SERVERNAME�;
ObjectName objectName = new ObjectName(queryExp);

Everything worked perfectly and I would be able to get both objects, provided that I ran the previous query two times, one for the ApplicationManager, another for the AppManagement.
Now I�m using WebSphere 6.02 and I�m observing a strange behavior. As version I have to use instead of But that makes all sense. The problem is that the value for the platform property depends on the object I�m trying to get. If I want to get the ApplicationManager I keep specifying platform=dynamicproxy. But if I want to get the AppManagement object, I have to set platform=proxy while in 6.00 it would be dynamic proxy. This seems to be a problem�
I tried to make my code more generic so I could ignore both the version and platform properties. After reading some WebSphere documentation my conclusion was that the following code would do it:

String queryExp = "WebSphere:cell=CELLNAME, name=ApplicationManager||AppManagement,mbeanIdentifier= ApplicationManager||AppManagement , type= ApplicationManager||AppManagement, node=NODENAME,process=SERVERNAME,*�;
ObjectName objectName = new ObjectName(queryExp);

I do not specify the version and platform properties anymore, and in the end I added a ,*. But it seems that this does not work. But if I try to the following query using wsadmin then everything goes ok:

$AdminControl queryNames cell=CELLNAME, name=ApplicationManager||AppManagement,mbeanIdentifier= ApplicationManager||AppManagement , type= ApplicationManager||AppManagement, node=NODENAME,process=SERVERNAME,*

Anyone know what I might be doing wrong in my code?

Many thanks!!!

Today's lesson is that you can't wear a jetpack AND a cape. I should have read this tiny ad:
Free, earth friendly heat - from the CodeRanch trailboss
    Bookmark Topic Watch Topic
  • New Topic