Hi All,

It seems that o.a.Catalina.Core MBeans descriptor has got operations
containing POJO objects instead of primitive types which make them
inaccessible via JConsole.
I suggest the following to avoid this situation. Any comments and
suggestions are appreciated.


*Class: StandardContext *
'
Method         : addValve (org.apache.catalina.Valve)
Suggestion : Modify the signature to addValve(String className) where
className is that of the Valve to be instantiated. This is acceptable since
all the Valve classes have no arg constructors AFA I noticed.

Method         : removeValve(org.apache.catalina.Valve)
Suggestion :   Modify the signature to removeValve(String oname)

Methods       :
add/removeLifecycleListener(org.apache.catalina.LifecycleListener)
Suggestion  :  Remove the methods since the method can be provided in a
generic way with only involving primitives. Any ideas on this?


These methods can be included in a seperate MBean class
(e.g:StandardContextMBean) so that original class interface is left intact.

*Class: StandardEngine*

Method           :    addChild(org.apache.catalina.Container)
Suggestion   :    addHost(String name, String appBase, boolean
autoDeploy,boolean deployOnStartup,boolean deployXML, boolean unpackWARs)

This method can be included in a seperate MBean class so that original class
interface is left intact. Since only a host can be added as a child mbean
method name can be named as addHost to remove any ambiguity.

*Class: StandardHost*

Method            :  addChild(org.apache.catalina.Container)
Suggestion    :  addContext(String path, String docBase, boolean
xmlValidation, boolean xmlNamespaceAware, boolean tldValidation, boolean
tldNamespaceAware)


*Class: StandardService*

Method            :  addConnector(org.apache.catalina.connector.Connector)
Suggestion    :   addConnector(String address, int port, boolean isAjp,
boolean isSSL)


*Class: StandardWrapper*

Method             :
add/removeLifeCycleListener(org.apache.catalina.LifecycleListener)
Suggestion     : Remove the methods since the method can be provided in a
generic way with only involving primitives.


Regards,
Chamith

Reply via email to