def METHOD_NAME(self, event, topic_id):
    # The False argument is for a non blocking call
    locking = self.topics[topic_id]['lock'].acquire_lock(False)
    if not(locking):
        current_t = currentThread()
        rospy.logdebug(str(current_t.getName()) + ': cannot lock topic '
                      + topic_id)
        return
    publisher = self.topics[topic_id]['publisher']
    subscriber = self.topics[topic_id]['subscriber']
    # Check if pub and sub already exist, if not try to create them after
    # checking the ros topic
    if None in(publisher, subscriber):
        topic_info = rostopic.get_topic_class(topic_id)
        if topic_info[0] is None:
            rospy.logwarn('Cannot find topic ' + topic_id)
            self.topics[topic_id]['lock'].release_lock()
            return
        else:
            # Create a (latched if needed) publisher
            self.topics[topic_id]['publisher'] = \
                rospy.Publisher(topic_id + '_throttled', topic_info[0],
                                queue_size = 1,
                                latch = self.topics[topic_id]['latched'])
            rospy.loginfo('Created publisher for ' + topic_id)
            # Create subscriber
            subscriber_partial = partial(self.subscriber_callback,
                                         topic_id=topic_id)
            self.topics[topic_id]['subscriber'] = \
                rospy.Subscriber(topic_id, topic_info[0],
                                 subscriber_partial)
            rospy.loginfo('Created subscriber for ' + topic_id)
            self.topics[topic_id]['lock'].release_lock()
            return
    last_message = self.topics[topic_id]['last_message']
    if last_message is not None:
        lazy_behavior = \
            self.topics[topic_id]['publisher'].get_num_connections() == 0 \
            and self.topics[topic_id]['lazy']
        if not lazy_behavior:
            # if requested and possible, apply the resolution change
            try:
                resolution = self.topics[topic_id]['resolution_factor']
            except KeyError:
                resolution = None
            if resolution is not None:
                last_message = self._resize_image(last_message, resolution)
            # publish the throttled message
            self.topics[topic_id]['publisher'].publish(last_message)
        self.topics[topic_id]['last_message'] = None
        self.topics[topic_id]['lock'].release_lock()
        return
    self.topics[topic_id]['lock'].release_lock()
    return