def _pick_attach_data(self, attach_type):
        if attach_type == self.A.MISSING_ATTACH_DATA:
            return None
        elif attach_type == self.A.MISSING_INSTANCE_ID:
            attach_data = dict()
            attach_data['Device'] = u'/dev/sdf'
            attach_data['InstanceId'] = ''
            return attach_data
        elif attach_type == self.A.MISSING_DEVICE:
            attach_data = dict()
            attach_data['Device'] = ''
            attach_data['InstanceId'] = u'i-xyz'
            return attach_data
        elif attach_type == self.A.ATTACH_SUCCESS:
            attach_data = dict()
            attach_data['Device'] = u'/dev/sdf'
            attach_data['InstanceId'] = u'i-xyz'
            return attach_data
        elif attach_type == self.A.DETACH_SUCCESS:
            return None
Checks to see if our internal package DB should be rebuilt.
dataset/ETHPy150Open ClusterHQ/flocker/flocker/node/agents/functional/test_ebs.py/VolumeStateTransitionTests._pick_attach_data--crossover with--dataset/ETHPy150Open munki/munki/code/client/munkilib/removepackages.py/shouldRebuildDB