Пример #1
0
 def __init__(self, instance):
     self._instance_reference = weakref.ref(instance)
     task_work_list = list()
     task_work_list.append(GuestServicesEnableTaskWork(self, instance,
                                                       force_pass=True))
     super(GuestServicesEnableTask, self).__init__(
         'guest-services-enable_%s' % instance.name, task_work_list)
Пример #2
0
    def __init__(self, instance):
        from nfv_vim import objects

        self._instance_reference = weakref.ref(instance)
        self._action_type = objects.INSTANCE_ACTION_TYPE.LIVE_MIGRATE
        task_work_list = list()
        task_work_list.append(GuestServicesEnableTaskWork(self, instance,
                                                          force_pass=True))
        task_work_list.append(GuestServicesPostNotifyTaskWork(self, instance,
                                                              self._action_type,
                                                              force_pass=True))
        super(LiveMigrateFinishTask, self).__init__(
            'live-migrate-finish-instance_%s' % instance.name, task_work_list)
Пример #3
0
    def __init__(self, instance):
        from nfv_vim import objects

        self._instance_reference = weakref.ref(instance)
        self._action_type = objects.INSTANCE_ACTION_TYPE.RESUME
        task_work_list = list()
        task_work_list.append(ResumeTaskWork(self, instance))
        task_work_list.append(GuestServicesEnableTaskWork(self, instance,
                                                          force_pass=True))
        task_work_list.append(GuestServicesPostNotifyTaskWork(self, instance,
                                                              self._action_type,
                                                              force_pass=True))
        super(ResumeTask, self).__init__(
            'resume-instance_%s' % instance.name, task_work_list)