This Bugzilla instance is deprecated, and most Eclipse projects now use GitHub or Eclipse GitLab. Please see the deprecation plan for details.
Bug 235168 - WebLogic 10.x JMX MBean support
Summary: WebLogic 10.x JMX MBean support
Status: RESOLVED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: Eclipselink (show other bugs)
Version: unspecified   Edit
Hardware: All All
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Michael OBrien CLA
QA Contact:
URL: http://wiki.eclipse.org/EclipseLink/D...
Whiteboard: Fixed in 1.0M11
Keywords:
: 213174 (view as bug list)
Depends on:
Blocks: 238412 252786 238246 238252 238343 238408 239075 243585 248600 248746 248747 248748 316513
  Show dependency tree
 
Reported: 2008-06-02 11:47 EDT by Michael OBrien CLA
Modified: 2022-06-09 10:09 EDT (History)
2 users (show)

See Also:


Attachments
EclipseLink proposed JMX MBeans (2) in JConsole (95.04 KB, image/pjpeg)
2008-06-20 15:13 EDT, Michael OBrien CLA
no flags Details
jconsole view of session specific post-login registered mbeans (72.41 KB, image/pjpeg)
2008-06-23 16:42 EDT, Michael OBrien CLA
no flags Details
eclipselink.core patch (pre-codereview) (72.25 KB, patch)
2008-06-25 10:13 EDT, Michael OBrien CLA
no flags Details | Diff
eclipselink.core.patch (post-codereview) (72.27 KB, patch)
2008-06-27 17:09 EDT, Michael OBrien CLA
no flags Details | Diff
eclipselink.core.manifest.patch (OSGI) (644 bytes, patch)
2008-06-28 08:56 EDT, Michael OBrien CLA
no flags Details | Diff
WebLogic 10.3 regression test for MBean registration/unregistration (3.32 KB, text/plain)
2008-06-28 09:40 EDT, Michael OBrien CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Michael OBrien CLA 2008-06-02 11:47:09 EDT
This ER will detail the design and implementation of WebLogic 10.3 JMX MBean support based on JMX 1.2 and JMX Remote API 1.0 for EclipseLink.

References:
------------
http://edocs.bea.com/wls/docs100/jmx/understandWLS.html
http://edocs.bea.com/wls/essex/wlsmbeanref/core/index.html
Comment 1 Michael OBrien CLA 2008-06-19 14:02:36 EDT
*** Bug 213174 has been marked as a duplicate of this bug. ***
Comment 2 Michael OBrien CLA 2008-06-19 14:16:36 EDT
POC using EclipseLink as JPA provider in a WLS 10.3 deployed EAR sucessfull via weblogic-application.xml ApplicationLifecyleListener on a 3.0 local stateless session bean.

EL Finest]: 2008.06.19 12:36:52.626--ServerSession(9461137)--Thread(Thread[Thread-21,5,Pooled Threads])--End predeploying Persistence Unit unifiedWebLogicEL; state Predeployed; factoryCount 1
>>>>>>>postStart: ApplicationLifecycleEvent{weblogic.application.internal.ApplicationContextImpl@50c5b0}
[EL Finest]: 2008.06.19 12:36:53.297--Thread(Thread[[STANDBY] ExecuteThread: '1' for queue: 'weblogic.kernel.Default (self-tuning)',5,Pooled Threads])--ProjectDeployment.registeringMBeans enter
>>>MBean: Configuration: org.eclipse.persistence.services.mbean.MBeanDevelopmentServices[TopLink_Domain:Name=Development_toplinkwls,Type=Configuration]
>>>MBean: reporting: org.eclipse.persistence.services.mbean.MBeanRuntimeServices[TopLink_Domain:Name=Runtime_toplinkwls,Type=Reporting]
>>>reportingMBean: getShouldProfilePerformance(): true
[EL Finest]: 2008.06.19 12:36:53.891--Thread(Thread[[STANDBY] ExecuteThread: '1' for queue: 'weblogic.kernel.Default (self-tuning)',5,Pooled Threads])--ProjectDeployment.registeringMBeans return

Pending Work:
  Working security, MBeanServer config, JConsole JMX MBean command ui, and session wrapper design.
Comment 3 Michael OBrien CLA 2008-06-20 15:12:00 EDT
	1) Got eclipselink mbeans registered in the jndi tree using generic javax (no weblogic.jar dependencies) code -it took a while to transition from [weblogic.management.home.localhome] to [java:comp/env/jmx/runtime].  With some security settings and the right jndi call client code and JConsole can see them.
	2) EJB Client gets references to the MBeans
	3) JConsole can see the MBeans and invoke operations on them - see attached jpg
 
Registration:
-------------
[EL Finest]: 2008.06.20 13:07:23.326--ServerSession(32358708)--Thread(Thread[Thread-16,5,Pooled Threads])--End predeploying Persistence Unit unifiedWebLogicEL; state Predeployed; factoryCount 1
>>>>>>>postStart: ApplicationLifecycleEvent{weblogic.application.internal.ApplicationContextImpl@114a0de}
[EL Finest]: 2008.06.20 13:07:25.704--Thread(Thread[[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)',5,Pooled Threads])--ProjectDeployment.registeringMBeans enter
ApplicationLifecycleListenerImpl JNDI:  java:comp/jmx/runtime
ApplicationLifecycleListenerImpl MBeanServerRuntime: weblogic.management.jmx.mbeanserver.WLSMBeanServer@18baa34
ApplicationLifecycleListenerImpl MBeanServerRuntime: count: 171
>>>MBeanRemote Registered: Configuration: org.eclipse.persistence.services.mbean.MBeanDevelopmentServices[EclipseLink_Domain:Name=Development_eclipselinkwls,Type=Configuration]
>>>MBeanRemote Registered: reporting: org.eclipse.persistence.services.mbean.MBeanRuntimeServices[EclipseLink_Domain:Name=Runtime_eclipselinkwls,Type=Reporting]
ApplicationLifecycleListenerImpl MBeanServerRuntime: new count: 173
[EL Finest]: 2008.06.20 13:07:25.705--Thread(Thread[[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)',5,Pooled Threads])--ProjectDeployment.registeringMBeans return

EJB Session bean Client:
-----------
ApplicationService MBeanServer: weblogic.management.jmx.mbeanserver.WLSMBeanServer@18baa34
ApplicationService MBeanServer: count: 193
ApplicationService MBeanServer: info: javax.management.MBeanInfo[description=Information on the management interface of the MBean, attributes=[javax.management.MBeanAttributeInfo[description=Attribute exposed for management, name=ShouldBindAllParameters, type=boolean, read/write, descriptor={}], javax.management.MBeanAttributeInfo[description=Attribute exposed for management, name=UsesBatchWriting, type=boolean, read/write, descriptor={}], javax.management.MBeanAttributeInfo[description=Attribute exposed for management, name=UsesJDBCBatchWriting,
Comment 5 Michael OBrien CLA 2008-06-20 15:13:36 EDT
Created attachment 105538 [details]
EclipseLink proposed JMX MBeans (2) in JConsole
Comment 6 Michael OBrien CLA 2008-06-23 16:34:02 EDT
Verified postLogin registration of MBeans in WLS 10.0 as well as 10.3
Changing title to 10.x from 10.3

serverSpecificRegisterMBean MBeanServerRuntime: count: 1053
>>>serverSpecificRegisterMBean MBeanRemote Registered: Configuration: javax.management.ObjectInstance@e64f4e2c
>>>serverSpecificRegisterMBean MBeanRemote Registered: reporting: javax.management.ObjectInstance@f17acdfc
>>>serverSpecificRegisterMBean MBeanServerRuntime: new count: 1055
Comment 7 Michael OBrien CLA 2008-06-23 16:42:24 EDT
Created attachment 105663 [details]
jconsole view of session specific post-login registered mbeans

The client ApplicationListener is no longer required, the registration happens in DatabaseSessionImpl.postConnectDatasource()
Comment 8 Michael OBrien CLA 2008-06-25 10:13:43 EDT
Created attachment 105811 [details]
eclipselink.core patch (pre-codereview)
Comment 9 Michael OBrien CLA 2008-06-25 10:59:24 EDT
In Review as soon as this mail reaches the dev list...
-----Original Message-----
From: MICHAEL.OBRIEN@ORACLE.COM 
Sent: Wednesday, June 25, 2008 10:17 AM
To: eclipselink-dev@eclipse.org
Subject: Fix/review for 235168: enhancement: Add WebLogic JMX MBean
support


Hi,
	The following patch is available for review in bug 235168, see the design doc wiki page for details on the fix and outstanding issues.

Enhancement
https://bugs.eclipse.org/bugs/show_bug.cgi?id=235168
https://bugs.eclipse.org/bugs/attachment.cgi?id=105811&action=diff
Design Doc
http://wiki.eclipse.org/EclipseLink/DesignDocs/235168

	Summary:
		The two development and runtime MBeans have been addded to the services and services.mbean packages off of core.
		These mbeans are currently enabled by platform only for WebLogic.
	Testing:
		These mbeans have been tested on WebLogic 10.3 using the <JAVA_HOME>/bin/jconsole jmx client
		Testing on WebLogic 10.0 is occurring today.
		A full J2SE JMX client test suite will be required in 238412

	thank you
	/michael

Comment 10 Michael OBrien CLA 2008-06-25 15:13:31 EDT
Backport of this change to WebLogic 10.0 as 1.5 compiled eclipselink.jar working - MBeans registered and working via JConsole

[EL Info]: 2008.06.25
13:51:11.209--ServerSession(14401377)--Thread(Thread[[ACTIVE] ExecuteThread:
'1' for queue: 'weblogic.kernel.Default (self-tuning)',5,Pooled
Threads])--EclipseLink, version: Eclipse Persistence Services - 1.0 (Build
SNAPSHOT - 20080625)
[EL Info]: 2008.06.25
13:51:11.210--ServerSession(14401377)--Thread(Thread[[ACTIVE] ExecuteThread:
'1' for queue: 'weblogic.kernel.Default (self-tuning)',5,Pooled
Threads])--Server: WebLogic Server 10.0 MP1  Thu Oct 18 20:17:44 EDT 2007
1005184
[EL Finer]: 2008.06.25
13:51:11.612--UnitOfWork(1934804)--Thread(Thread[[ACTIVE] ExecuteThread: '1'
for queue: 'weblogic.kernel.Default (self-tuning)',5,Pooled Threads])--release
unit of work

<JConsole action>

[EL Finer]: 2008.06.25 13:51:48.422--ServerSession(14401377)--Thread(Thread[RMI
TCP Connection(3)-10.156.52.98,5,RMI Runtime])--initialize identitymaps
Comment 11 Michael OBrien CLA 2008-06-26 09:02:00 EDT
Doing code review changes, regression testing.
20080625: 1500 code review by Gordon

- remove comment on wls10 platform constructor
- development mbean off
- runtime mbean on
- don't cache mbeanserver, initialcontext to be used by unregister
- don't really need null session checking but keep it in for clients using the mbean api
- defer bug on no logs during an error from eclipselink in jconsol ui
- remove stack traces – logging will handle output of these in a controllable manner


Comment 12 Michael OBrien CLA 2008-06-27 17:04:37 EDT
Manual Test lifecycle:
- start wls server (check mbean enable properties)
- deploy EAR (if not already deployed by adding to autodeploy dir)
- exercise J2EE JPA application
  (invokes lazy registration of MBeans during session login)
- launch jconsole and attach to wls jvm
- do some operations against toplink via the runtime or dev mbean
- undeploy/logout application to unregister MBeans
  (remove the EAR from the autodeploy dir)
- close and restart jconsole (notice no EclipseLink MBeans anymore
Comment 13 Michael OBrien CLA 2008-06-27 17:09:36 EDT
Created attachment 106046 [details]
eclipselink.core.patch (post-codereview)
Comment 14 Michael OBrien CLA 2008-06-28 08:56:05 EDT
Created attachment 106059 [details]
eclipselink.core.manifest.patch (OSGI)

Added services and services.mbean packages for OSGI export
Comment 15 Michael OBrien CLA 2008-06-28 09:18:12 EDT
Completed: At revision: 1770  
Some minor changes to the design doc for enabling/disabing mbeans is required before documentation bug# 238246 can be picked up
Comment 16 Michael OBrien CLA 2008-06-28 09:40:27 EDT
Created attachment 106062 [details]
WebLogic 10.3 regression test for MBean registration/unregistration
Comment 17 Michael OBrien CLA 2008-07-02 09:01:19 EDT
In 1.0M11, MBean operations verified in 239075
Comment 18 Michael OBrien CLA 2010-07-13 11:02:02 EDT
>See full refactor for JMX MBean functionality in WebLogic, WebSphere, JBoss and Glassfish in bug # 316513 for EclipseLink 2.1.1
Comment 19 Eclipse Webmaster CLA 2022-06-09 10:09:55 EDT
The Eclipselink project has moved to Github: https://github.com/eclipse-ee4j/eclipselink