Revision 26fef2b9

b/db/models.py
188 188
        ('OP_INSTANCE_REMOVE', 'Remove Instance'),
189 189
        ('OP_INSTANCE_STARTUP', 'Startup Instance'),
190 190
        ('OP_INSTANCE_SHUTDOWN', 'Shutdown Instance'),
191
        ('OP_INSTANCE_REBOOT', 'Reboot Instance')
191
        ('OP_INSTANCE_REBOOT', 'Reboot Instance'),
192

  
193
        # These are listed here for completeness,
194
        # and are ignored for the time being
195
        ('OP_INSTANCE_SET_PARAMS', 'Set Instance Parameters'),
196
        ('OP_INSTANCE_QUERY_DATA', 'Query Instance Data'),
192 197
    )
193 198
    # A backend job may be in one of the following possible states
194 199
    BACKEND_STATUSES = (
......
208 213
        'OP_INSTANCE_REMOVE': 'DESTROYED',
209 214
        'OP_INSTANCE_STARTUP': 'STARTED',
210 215
        'OP_INSTANCE_SHUTDOWN': 'STOPPED',
211
        'OP_INSTANCE_REBOOT': 'STARTED'
216
        'OP_INSTANCE_REBOOT': 'STARTED',
217
        'OP_INSTANCE_SET_PARAMS': None,
218
        'OP_INSTANCE_QUERY_DATA': None
212 219
    }
213 220

  
214 221
    # This dictionary contains the correspondence between
b/logic/backend.py
31 31
    vm.backendlogmsg = logmsg
32 32

  
33 33
    # Notifications of success change the operating state
34
    if status == 'success':
34
    if status == 'success' and VirtualMachine.OPER_STATE_FROM_OPCODE is not None:
35 35
        utils.update_state(vm, VirtualMachine.OPER_STATE_FROM_OPCODE[opcode])
36 36
        # Set the deleted flag explicitly, to cater for admin-initiated removals
37 37
        if opcode == 'OP_INSTANCE_REMOVE':

Also available in: Unified diff