On Thu, Apr 23, 2015 at 1:14 PM, Robert Munteanu romb...@apache.org wrote:
Hi Chetan,
On Thu, 2015-04-23 at 10:03 +0530, Chetan Mehrotra wrote:
I assume that this happens because there is no OSGi environment
available
Thats not the case. MBean would be registered only if a MBeanServer
is
provided while constructing Oak instance (in non OSGi env). So in
oak-run where Oak instance is created if you also set MBeanServer
Something like
Oak oak = ..
oak.with(ManagementFactory.getPlatformMBeanServer());
This would lead to registration of MBean
Thanks for the pointer. Filed
https://issues.apache.org/jira/browse/OAK-2805
with a trivial patch to enable JMX MBean registration for oak-run.
Note however that this does not register all available MBeans for the
DocumentNodeStore. Some of the specific MBeans do not appear and only
seem to be registered by the DocumentNodeStoreService ( see [2] ).
That was what lead me to believe that JMX MBean registration is tied
to OSGi. Is this available for registration in another way in oak-run?
Thanks,
Robert
[2]:
https://github.com/apache/jackrabbit-oak/blob/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/document/DocumentNodeStoreService.java#L503-L508
Robert
Chetan Mehrotra
On Wed, Apr 22, 2015 at 6:37 PM, Robert Munteanu romb...@apache.org
wrote:
Hi,
I've built Oak from trunk and want to access the
DocumentNodeStoreMBean. I see that the mbeans are not registered
when
using oak-run ( I assume that this happens because there is no OSGi
environment available ).
I can always install a custom version of Oak in Sling, but I was
wondering whether there's a faster way of running a locally-built
Oak
in an OSGi environment.
Thanks,
Robert