コード例 #1
0
    def __init__(self, slottable, resourcepool, deployment_enact):
        PreparationScheduler.__init__(self, slottable, resourcepool,
                                      deployment_enact)

        self.imagenode = self.deployment_enact.get_imagenode()

        self.transfers = []
        self.completed_transfers = []

        self.imagenode_bandwidth = self.deployment_enact.get_bandwidth()

        self.handlers = {}
        self.handlers[
            FileTransferResourceReservation] = ReservationEventHandler(
                sched=self,
                on_start=ImageTransferPreparationScheduler.
                _handle_start_filetransfer,
                on_end=ImageTransferPreparationScheduler.
                _handle_end_filetransfer)

        self.handlers[
            DiskImageMigrationResourceReservation] = ReservationEventHandler(
                sched=self,
                on_start=ImageTransferPreparationScheduler.
                _handle_start_migrate,
                on_end=ImageTransferPreparationScheduler._handle_end_migrate)
コード例 #2
0
ファイル: imagetransfer.py プロジェクト: queba/haizea
    def __init__(self, slottable, resourcepool, deployment_enact):
        PreparationScheduler.__init__(self, slottable, resourcepool, deployment_enact)
        
        self.imagenode = self.deployment_enact.get_imagenode()
        
        self.transfers = []
        self.completed_transfers = []
        
        self.imagenode_bandwidth = self.deployment_enact.get_bandwidth()
        
        self.handlers ={}
        self.handlers[FileTransferResourceReservation] = ReservationEventHandler(
                                sched    = self,
                                on_start = ImageTransferPreparationScheduler._handle_start_filetransfer,
                                on_end   = ImageTransferPreparationScheduler._handle_end_filetransfer)

        self.handlers[DiskImageMigrationResourceReservation] = ReservationEventHandler(
                                sched    = self,
                                on_start = ImageTransferPreparationScheduler._handle_start_migrate,
                                on_end   = ImageTransferPreparationScheduler._handle_end_migrate)
コード例 #3
0
 def __init__(self, slottable, resourcepool, deployment_enact):
     PreparationScheduler.__init__(self, slottable, resourcepool,
                                   deployment_enact)
     self.handlers = {}
コード例 #4
0
 def __init__(self, slottable, resourcepool, deployment_enact):
     PreparationScheduler.__init__(self, slottable, resourcepool, deployment_enact)
     self.handlers = {}