Browse Source

Merge "Change how we retrieve host wwpns from block_device_mapping"

Zuul 1 year ago
parent
commit
6a69a7b22d

+ 0
- 3
nova_dpm/tests/unit/virt/dpm/test_block_device.py View File

@@ -22,9 +22,6 @@ LUN = 0
22 22
 BLOCK_DEVICE = {
23 23
     'connection_info': {
24 24
         'driver_volume_type': 'fibre_channel',
25
-        'connector': {
26
-            'wwpns': [PARTITION_WWPN],
27
-            'host': '3cfb165c-0df3-4d80-87b2-4c353e61318f'},
28 25
         'data': {
29 26
             'initiator_target_map': {
30 27
                 PARTITION_WWPN: [

+ 3
- 1
nova_dpm/virt/dpm/block_device.py View File

@@ -31,7 +31,9 @@ class BlockDevice(object):
31 31
 
32 32
     @property
33 33
     def host_wwpns(self):
34
-        return self.bd['connection_info']['connector']['wwpns']
34
+        return (
35
+            self.bd['connection_info']['data']['initiator_target_map'].keys()
36
+        )
35 37
 
36 38
     def get_target_wwpn(self, partition_wwpn):
37 39
         if partition_wwpn not in self.host_wwpns:

Loading…
Cancel
Save