code: def updateMetadata(self, new):
          
          if self.node_id != new.node_id:
              raise ValueError("Broker metadata {!r} doesn't match node_id={}".format(new, self.node_id))
  
          self.node_id = new.node_id
          self.host = new.host
          self.port = new.port
docs: Update the metadata stored for this broker.
  
          Future connections made to the broker will use the host and port
          defined in the new metadata. Any existing connection is not dropped,
          however.
  
          :param new:
              :clas:`afkak.common.BrokerMetadata` with the same node ID as the
              current metadata.