listGroups = async () => {
    await cluster.refreshMetadata()
    let groups = []
    for (var nodeId in cluster.brokerPool.brokers) {
      const broker = await cluster.findBroker({ nodeId })
      const response = await broker.listGroups()
      groups = groups.concat(response.groups)
    }

    return { groups }
  }
List groups in a broker

@return {Promise<ListGroups>}

@typedef {Object} ListGroups
@property {Array<ListGroup>} groups

@typedef {Object} ListGroup
@property {string} groupId
@property {string} protocolType