docs: static void collectStats(final StatsCollector collector) {
      final RpcManager manager = INSTANCE.get();
      if (manager != null) {
        if (manager.rpc_plugins != null) {
          try {
            collector.addExtraTag("plugin", "rpc");
            for (final RpcPlugin rpc : manager.rpc_plugins) {
              rpc.collectStats(collector);
            }
          } finally {
            collector.clearExtraTag("plugin");
          }
        }
  
        if (manager.http_plugin_commands != null) {
          try {
            collector.addExtraTag("plugin", "httprpc");
            for (final Map.Entry<String, HttpRpcPlugin> entry
                : manager.http_plugin_commands.entrySet()) {
              entry.getValue().collectStats(collector);
            }
          } finally {
            collector.clearExtraTag("plugin");
          }
        }
      }
    }