code: def cancel(self):
      if self._consumer_conn is not None:
          try:
              self._consumer_receive.close()
              self._consumer_conn.close()
          except Exception as e:
              LOGGER.debug(
                  "meet {} when trying to close consumer".format(e)
              )
  
          self._consumer_receive = None
          self._consumer_conn = None
  
      if self._producer_conn is not None:
          try:
              self._producer_send.close()
              self._producer_conn.close()
          except Exception as e:
              LOGGER.debug(
                  "meet {} when trying to close producer".format(e)
              )
  
          self._producer_send = None
          self._producer_conn = None
  
file_path: FATE/python/fate/arch/federation/backends/pulsar/_mq_channel.py
imports: import logging
  import pulsar
  from fate.arch.federation.message_queue import nretry
label_desc: Use image node_id 6 for calling the MQChannel obj's underlying member method code with example usage: obj.cancel() without return types