APIMbeanServer: Show column family in jconsole

The nodetool looks for column family with by their name. When using
JConsole, it search for all MBeans.

This patch adds a check for column family and stream with null query
(wild card).

This way the column family will appear in the JConsole.

Fixes #35

Signed-off-by: Amnon Heiman <amnon@scylladb.com>
Message-Id: <1479227289-15031-1-git-send-email-amnon@scylladb.com>
This commit is contained in:
Amnon Heiman 2016-11-15 18:28:09 +02:00 committed by Pekka Enberg
parent 8e5d649048
commit b9986396bb
1 changed files with 2 additions and 0 deletions

View File

@ -78,6 +78,8 @@ public class APIMBeanServer extends ChainedMBeanServer {
@Override
public Set<ObjectName> queryNames(ObjectName name, QueryExp query) {
if (name == null) {
ColumnFamilyStore.checkRegistration();
StreamingMetrics.checkRegistration();
return super.queryNames(name, query);
}
if (name.getCanonicalKeyPropertyListString()