예제 #1
0
파일: manager.py 프로젝트: ugvddm/cinder
    def create_volume(
        self, context, topic, volume_id, snapshot_id=None, image_id=None, request_spec=None, filter_properties=None
    ):

        try:
            flow_engine = create_volume.get_scheduler_flow(
                context, db, self.driver, request_spec, filter_properties, volume_id, snapshot_id, image_id
            )
        except Exception:
            LOG.exception(_("Failed to create scheduler manager volume flow"))
            raise exception.CinderException(_("Failed to create scheduler manager volume flow"))
        flow_engine.run()
예제 #2
0
파일: manager.py 프로젝트: CloudVPS/cinder
    def create_volume(self, context, topic, volume_id, snapshot_id=None,
                      image_id=None, request_spec=None,
                      filter_properties=None):

        flow = create_volume.get_scheduler_flow(db, self.driver,
                                                request_spec,
                                                filter_properties,
                                                volume_id, snapshot_id,
                                                image_id)
        assert flow, _('Schedule volume flow not retrieved')

        flow.run(context)
        if flow.state != states.SUCCESS:
            LOG.warn(_("Failed to successfully complete"
                       " schedule volume using flow: %s"), flow)
예제 #3
0
파일: manager.py 프로젝트: blakelai/cinder
    def create_volume(self, context, topic, volume_id, snapshot_id=None,
                      image_id=None, request_spec=None,
                      filter_properties=None):

        try:
            flow_engine = create_volume.get_scheduler_flow(context,
                                                           db, self.driver,
                                                           request_spec,
                                                           filter_properties,
                                                           volume_id,
                                                           snapshot_id,
                                                           image_id)
        except Exception:
            LOG.exception(_("Failed to create scheduler manager volume flow"))
            raise exception.CinderException(
                _("Failed to create scheduler manager volume flow"))
        flow_engine.run()
예제 #4
0
    def create_volume(self,
                      context,
                      topic,
                      volume_id,
                      snapshot_id=None,
                      image_id=None,
                      request_spec=None,
                      filter_properties=None):

        flow = create_volume.get_scheduler_flow(db, self.driver, request_spec,
                                                filter_properties, volume_id,
                                                snapshot_id, image_id)
        assert flow, _('Schedule volume flow not retrieved')

        flow.run(context)
        if flow.state != states.SUCCESS:
            LOG.warn(
                _("Failed to successfully complete"
                  " schedule volume using flow: %s"), flow)