db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "John H. Embretsen (JIRA)" <j...@apache.org>
Subject [jira] Commented: (DERBY-1387) Add JMX extensions to Derby
Date Wed, 23 Jan 2008 13:58:34 GMT

    [ https://issues.apache.org/jira/browse/DERBY-1387?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12561683#action_12561683

John H. Embretsen commented on DERBY-1387:

I finally got this patch to build without requiring extra jar files. I have tested that the
Network Server runs fine with jdk1.4 if jmx is not enabled, and that basic JMX management
works fine when using JDK 6, but I have not run other tests so far. (Trying to run using jdk1.4
with jmx enabled currently results in a fatal error, which is something I hope to improve
eventually by providing a more helpful error message)

I would however appreciate some input on whether my solution so far is something we can live
with or if it needs refinements. This is what I did to make it build:

- Made org.apache.derby.iapi.services.mbeans.ManagementService independent
   of JMX / jdk1.5:

     This was necessary because ManagementService is an interface
     representing the (JMX) module that is referenced elsewhere in
     the Derby code, regardless of the availability of JMX support.
     The implementation(s) of this interface may (must) refer to the JMX 
     API, but the interface itself may not. Otherwise, all code referencing
     this interface must also be compiled with JMX support in the 
     classpath, which is not the default on jdk1.4. Care should be taken not 
     to call methods of this interface if JMX support is not available. 

     Changes were:

     - Removed getMBeanServer() method (was not used), which returned a
       JMX object (MBeanServer). Callers (e.g. NetworkServerControlImpl) can
       access (create, destroy, register) MBeans through this interface, but may
       no longer get direct access to the MBean server unless they call the
       implementing class (BasicManagementService) directly.
     - Changed second parameter of registerMBean() method to take a String
       representing a JMX ObjectName instead of the ObjectName itself. It
       is then up to the implementing class to create the actual ObjectName
       object based on that String.

 - NetworkServerControlImpl now calls the ManagementService interface
   without having to refer to the JMX API (e.g. ObjectName), which means it
   may be compiled with jdk1.4 and be runnable without JMX support. 

 - Changed build scripts so that org.apache.derby.iapi.services.mbeans is
   compiled with ${compile.classpath} (jdk1.4 / jsr169). 

 - Added missing class o.a.d.impl.services.MDatabase.java.

My JMX experience may be limited, but not more so than my knowledge of Derby code internals
;) I'll continue to work on an updated patch, but any comments or advice will be appreciated
in the mean time.

> Add JMX extensions to Derby
> ---------------------------
>                 Key: DERBY-1387
>                 URL: https://issues.apache.org/jira/browse/DERBY-1387
>             Project: Derby
>          Issue Type: New Feature
>          Components: Services
>            Reporter: Sanket Sharma
>            Assignee: John H. Embretsen
>         Attachments: DERBY-1387-1.diff, DERBY-1387-1.stat, DERBY-1387-2.diff, DERBY-1387-2.stat,
DERBY-1387-3.diff, DERBY-1387-3.stat, DERBY-1387-4.diff, DERBY-1387-4.stat, DERBY-1387-5.diff,
DERBY-1387-5.stat, DERBY-1387-6.zip, DERBY-1387-7.zip, DERBY-1387-8.zip, derbyjmx.patch, jmx.diff,
jmx.stat, jmxFuncspec.html, Requirements for JMX Updated.html, Requirements for JMX.html,
Requirements for JMX.zip
> This is a draft requirement specification for adding monitoring and management extensions
to Apache Derby using JMX. The requirements document has been uploaded on JIRA as well as
the Derby Wiki page at http://wiki.apache.org/db-derby/_Requirement_Specifications_for_Monitoring_%26_Management_Extensions_using_JMX
> Developers and Users are requested to please look at the document (feature list in particular)
and add their own rating to features by adding a coloumn to the table.
> Comments are welcome.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message