code: def clear_messages(self, queue_name, timeout=None):
          '''
          Deletes all messages from the specified queue.
  
          :param str queue_name:
              The name of the queue whose messages to clear.
          :param int timeout:
              The server timeout, expressed in seconds.
          '''
          _validate_not_none('queue_name', queue_name)
          request = HTTPRequest()
          request.method = 'DELETE'
          request.host_locations = self._get_host_locations()
          request.path = _get_path(queue_name, True)
          request.query = {'timeout': _int_to_str(timeout)}
          self._perform_request(requestf clear_messages(self, queue_name, timeout=None):
          '''
          Deletes all messages from the specified queue.
  
          :param str queue_name:
              The name of the queue whose messages to clear.
          :param int timeout:
              The server timeout, expressed in seconds.
          '''
          _validate_not_none('queue_name', queue_name)
          request = HTTPRequest()
          request.method = 'DELETE'
          request.host_locations = self._get_host_locations()
          request.path = _get_path(queue_name, True)
          request.query = {'timeout': _int_to_str(timeout)}
          self._perform_request(request)
docs: Deletes all messages from the specified queue.
  
          :param str queue_name:
              The name of the queue whose messages to clear.
          :param int timeout:
              The server timeout, expressed in seconds.