ternya/ternya.py
def init_cinder_consumer(self, mq):
        """
        Init openstack cinder mq

        1. Check if enable listening cinder notification
        2. Create consumer

        :param mq: class ternya.mq.MQ
        """
        if not self.enable_component_notification(Openstack.Cinder):
            log.debug("disable listening cinder notification")
            return

        for i in range(self.config.cinder_mq_consumer_count):
            mq.create_consumer(self.config.cinder_mq_exchange,
                               self.config.cinder_mq_queue,
                               ProcessFactory.process(Openstack.Cinder))

        log.debug("enable listening openstack cinder notification.")
def init_cinder_consumer(self, mq):
        if not self.enable_component_notification(Openstack.Cinder):
            log.debug("disable listening cinder notification")
            return

        for i in range(self.config.cinder_mq_consumer_count):
            mq.create_consumer(self.config.cinder_mq_exchange,
                               self.config.cinder_mq_queue,
                               ProcessFactory.process(Openstack.Cinder))

        log.debug("enable listening openstack cinder notification.")
def init_cinder_consumer ( self , mq ) : if not self . enable_component_notification ( Openstack . Cinder ) : log . debug ( "disable listening cinder notification" ) return for i in range ( self . config . cinder_mq_consumer_count ) : mq . create_consumer ( self . config . cinder_mq_exchange , self . config . cinder_mq_queue , ProcessFactory . process ( Openstack . Cinder ) ) log . debug ( "enable listening openstack cinder notification." )
Init openstack cinder mq

        1. Check if enable listening cinder notification
        2. Create consumer

        :param mq: class ternya.mq.MQ
Init openstack cinder mq