Example #1
0
        def COMMITTED(self):
            self.taskIns = assetUpdate(self.taskIns, "State", "COMMITTED")

            if self.arch2ins.taskCoordinator == self.parent.device_uuid:
                #add subtask asset to the device
                self.parent.adapter.addAsset('Task', self.task_uuid,
                                             self.taskIns)
Example #2
0
        def PREPARING(self):
            self.parent.adapter.begin_gather()
            self.interface.set_value("PREPARING")
            self.parent.adapter.complete_gather()

            self.taskIns = assetUpdate(self.taskIns, "State", "PREPARING")
            self.parent.adapter.addAsset('Task', self.master_task_uuid,
                                         self.taskIns)
Example #3
0
        def COMMITTING(self):
            self.taskIns = assetUpdate(self.taskIns, "State", "COMMITTING")

            if self.arch2ins.taskCoordinator == self.parent.device_uuid:
                self.parent.adapter.addAsset('Task', self.task_uuid,
                                             self.taskIns)

            self.all_commit()
Example #4
0
        def FAIL(self):
            self.taskIns = assetUpdate(self.taskIns, "State", "FAIL")
            if self.arch2ins.taskCoordinator == self.parent.device_uuid:
                self.parent.adapter.addAsset('Task', self.task_uuid,
                                             self.taskIns)

            if self.arch2ins.taskCoordinator == self.parent.device_uuid:
                self.parent.adapter.removeAsset(self.task_uuid)

            self.default()
Example #5
0
        def COMPLETE(self):
            #update states and remove asset once subtask is complete
            self.taskIns = assetUpdate(self.taskIns, "State", "COMPLETE")
            if self.arch2ins.taskCoordinator == self.parent.device_uuid:
                self.parent.adapter.addAsset('Task', self.task_uuid,
                                             self.taskIns)

            if self.arch2ins.taskCoordinator == self.parent.device_uuid:
                self.parent.adapter.removeAsset(self.task_uuid)

            self.default()
Example #6
0
        def COMMITTING(self):

            self.parent.adapter.begin_gather()
            self.interface.set_value("COMMITTING")
            self.parent.adapter.complete_gather()

            self.taskIns = assetUpdate(self.taskIns, "State", "COMMITTING")
            self.parent.adapter.addAsset('Task', self.master_task_uuid,
                                         self.taskIns)

            self.timer_commit()
Example #7
0
        def FAIL(self):
            self.taskIns = assetUpdate(self.taskIns, "State", "FAIL")
            self.parent.adapter.addAsset('Task', self.master_task_uuid,
                                         self.taskIns)
            self.parent.adapter.removeAsset(self.master_task_uuid)

            self.parent.adapter.begin_gather()
            self.interface.set_value("INACTIVE")
            self.parent.adapter.complete_gather()

            self.default()
Example #8
0
        def COMPLETE(self):
            #update states and remove task asset once completed
            self.taskIns = assetUpdate(self.taskIns, "State", "COMPLETE")
            self.parent.adapter.addAsset('Task', self.master_task_uuid,
                                         self.taskIns)

            self.parent.adapter.begin_gather()
            self.interface.set_value("INACTIVE")
            self.parent.adapter.complete_gather()

            self.parent.adapter.removeAsset(self.master_task_uuid)

            self.default()
Example #9
0
        def COMMITTED(self):

            self.parent.adapter.begin_gather()
            self.interface.set_value("COMMITTED")
            self.parent.adapter.complete_gather()

            self.parent.priority.commit_check()

            self.taskIns = assetUpdate(self.taskIns, "State", "COMMITTED")
            self.parent.adapter.addAsset('Task', self.master_task_uuid,
                                         self.taskIns)

            self.committed()