Mr. DiFrango has over 15 years experience specializing in architecture, design, and construction of distributed, integrated systems in the enterprise and web environments. This experience includes expertise in Enterprise Systems Integration, Application Development, Service Oriented Architecture, Content Management Integration and Portal Solutions. Mr. DiFrango specializes in the JBoss Portal, Alfresco, Weblogic and Tibco product suites. Product expertise pertains primarily to Application Servers, Service Enablement Products, Content Management Integration, and Portal frameworks. Mr. DiFrango is experienced in architecting, designing and developing J2EE standardized Applications. This experience includes full lifecycle development from creating OO designs through to product testing. Mr. DiFrango also has experience leading teams of analysts, developers, and testers through troubleshooting complex development, mentoring staff, managing development schedules and work assignments, and providing architectural guidance. He is experienced in software development methodologies including procedural or waterfall, and Agile projects. He also has extensive experience with modeling systems during analysis, design, and construction using UML.
Exposing JMX Beans in Weblogic using Spring
Feb 04 2010
Eric Miles and I were working on different clients that were both utilizing the Weblogic application and the Spring framework. Each of needed a way to expose some of the configuration items as JMX beans so that production support folks could change the values of these items at runtime without requiring server re-boots. Because both of us were using Spring, exposing the beans was fairly straight forward, we just followed the Spring documentation for exporting JMX beans.
Once we did this, we wanted to know how these beans were exposed within the Weblogic management console. Much to both of our dismay’s Weblogic does not have anything that exposes these directly in the console. After some research and collaborating with Mike Argie, we came up with following set of options:
- WebLogic console extensions. The WebLogic console is not a simple Mbean navigator like JBoss’s JMX Console, so there is a bit of custom view development involved but if you need an admin-proof interface, this may be worth the effort.
- WebLogic Scripting Tool (WLST)/Jython. WLST is a command-line interface that provides (among many other things) access to any Mbean registered with the WLS Mbean server.
- JConsole in development. The consensus was that in most organizations, the production support environment needs something a bit more constrained.
After some analysis of our respective environments we both decided to choose the WLST approach. For both of us this represented the best combination of time to market along with ease of use. One thing we did find out is that in order for the beans to be exposed to WLST, the following option needed to be enabled:
- -Dcom.sun.management.jmxremote=true
After enabling this option, we followed this link that describes interacting with JMX via WLST. The commands we issued were
- custom();
- ls();
Conclusion
While Weblogic does not directly expose JMX beans to the standard administration console, it does provide enough alternative options that should meet most organizations needs.
Look for an upcoming article from Eric Miles discussing how to purge EHCache using WLST.