code: function broadcastMonitors(records, moduleId, msg) {
      msg = protocol.composeRequest(null, moduleId, msg);
  
      if (records instanceof Array) {
          for (let i = 0, l = records.length; i < l; i++) {
              const socket = records[i].socket;
              doSend(socket, 'monitor', msg);
          }
      } else {
          for (const id in records) {
              if (records.hasOwnProperty(id)) {
                  const socket = records[id].socket;
                  doSend(socket, 'monitor', msg);
              }
          }
      }
  }
docs: broadcast msg to monitor
  
  @param {Object} records registered modules
  @param {String} moduleId module id/name
  @param {Object} msg message
  @api private