)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"80c4e6699d27d06e0ce0c96c976647a3eab6537b","unresolved":false,"context_lines":[{"line_number":7,"context_line":"New cinder driver to support INFINIDAT InfiniBox"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Add a cinder volume driver for the INFINIDAT InfiniBox storage array."},{"line_number":10,"context_line":"It will include the minimum set of features required by OpenStack."},{"line_number":11,"context_line":"This driver supports FC connectivity only."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"DocImpact"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"3ac371cc_9a11f954","line":10,"range":{"start_line":10,"start_character":56,"end_line":10,"end_character":65},"updated":"2016-08-18 12:23:49.000000000","message":"Cinder","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"85de9c674f8998dc9b3c3e9ec2075f36ebaf752c","unresolved":false,"context_lines":[{"line_number":7,"context_line":"New cinder driver to support INFINIDAT InfiniBox"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Add a cinder volume driver for the INFINIDAT InfiniBox storage array."},{"line_number":10,"context_line":"It will include the minimum set of features required by OpenStack."},{"line_number":11,"context_line":"This driver supports FC connectivity only."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"DocImpact"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"1ac06dbe_dab951cd","line":10,"range":{"start_line":10,"start_character":56,"end_line":10,"end_character":65},"in_reply_to":"3ac371cc_9a11f954","updated":"2016-08-21 07:59:58.000000000","message":"Done","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"}],"cinder/tests/unit/volume/drivers/test_infinidat.py":[{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"b6ac4c2921c964b380890c6950a3400352318e38","unresolved":false,"context_lines":[{"line_number":14,"context_line":"#    under the License."},{"line_number":15,"context_line":"\"\"\"Unit tests for INFINIDAT InfiniBox volume driver.\"\"\""},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"from cinder import exception"},{"line_number":18,"context_line":"from cinder import test"},{"line_number":19,"context_line":"from cinder.volume import configuration"},{"line_number":20,"context_line":"from cinder.volume.drivers.infinidat import InfiniboxVolumeDriver"}],"source_content_type":"text/x-python","patch_set":2,"id":"3ac371cc_88bd1e04","line":17,"updated":"2016-08-18 17:13:01.000000000","message":"Please reorder imports. They should be separated into three groups of standard python modules, third party modules, then local (cinder) imports.","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"3d0ee331c243a3cfa59f3d5ec6cc94c52876315c","unresolved":false,"context_lines":[{"line_number":14,"context_line":"#    under the License."},{"line_number":15,"context_line":"\"\"\"Unit tests for INFINIDAT InfiniBox volume driver.\"\"\""},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"from cinder import exception"},{"line_number":18,"context_line":"from cinder import test"},{"line_number":19,"context_line":"from cinder.volume import configuration"},{"line_number":20,"context_line":"from cinder.volume.drivers.infinidat import InfiniboxVolumeDriver"}],"source_content_type":"text/x-python","patch_set":2,"id":"1ac06dbe_5acd615c","line":17,"in_reply_to":"3ac371cc_88bd1e04","updated":"2016-11-09 09:45:43.000000000","message":"Done","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":16708,"name":"Kendall Nelson","display_name":"Kendall (diablo_rojo)","email":"kennelson11@gmail.com","username":"kjnelson"},"change_message_id":"67806777062545ad8b4c209e2929987f6ded6af3","unresolved":false,"context_lines":[{"line_number":18,"context_line":"from cinder import test"},{"line_number":19,"context_line":"from cinder.volume import configuration"},{"line_number":20,"context_line":"from cinder.volume.drivers.infinidat import InfiniboxVolumeDriver"},{"line_number":21,"context_line":"import copy"},{"line_number":22,"context_line":"import json"},{"line_number":23,"context_line":"import mock"},{"line_number":24,"context_line":"import requests"},{"line_number":25,"context_line":"import six"},{"line_number":26,"context_line":""},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"BASE_URL \u003d \u0027http://mockbox/api/rest/\u0027"}],"source_content_type":"text/x-python","patch_set":2,"id":"5a8bc5a2_baee78b2","line":25,"range":{"start_line":21,"start_character":0,"end_line":25,"end_character":10},"updated":"2016-09-27 22:15:04.000000000","message":"These should come first separated by a line and then the cinder imports in alphabetical order.","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"b6ac4c2921c964b380890c6950a3400352318e38","unresolved":false,"context_lines":[{"line_number":125,"context_line":"        self._responses[\"GET\"][GET_POOL_URL][0][\"free_physical_space\"] \u003d 0"},{"line_number":126,"context_line":"        # no refresh - free capacity should stay the same"},{"line_number":127,"context_line":"        result \u003d self.driver.get_volume_stats(refresh\u003dFalse)"},{"line_number":128,"context_line":"        self.assertEqual(result[\"free_capacity_gb\"], 1)"},{"line_number":129,"context_line":"        # refresh - free capacity should change to 0"},{"line_number":130,"context_line":"        result \u003d self.driver.get_volume_stats(refresh\u003dTrue)"},{"line_number":131,"context_line":"        self.assertEqual(result[\"free_capacity_gb\"], 0)"}],"source_content_type":"text/x-python","patch_set":2,"id":"3ac371cc_e85932fe","line":128,"range":{"start_line":128,"start_character":25,"end_line":128,"end_character":54},"updated":"2016-08-18 17:13:01.000000000","message":"Throughout, change assertEqual arguments to be (EXPECTED, ACTUAL)","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"3d0ee331c243a3cfa59f3d5ec6cc94c52876315c","unresolved":false,"context_lines":[{"line_number":125,"context_line":"        self._responses[\"GET\"][GET_POOL_URL][0][\"free_physical_space\"] \u003d 0"},{"line_number":126,"context_line":"        # no refresh - free capacity should stay the same"},{"line_number":127,"context_line":"        result \u003d self.driver.get_volume_stats(refresh\u003dFalse)"},{"line_number":128,"context_line":"        self.assertEqual(result[\"free_capacity_gb\"], 1)"},{"line_number":129,"context_line":"        # refresh - free capacity should change to 0"},{"line_number":130,"context_line":"        result \u003d self.driver.get_volume_stats(refresh\u003dTrue)"},{"line_number":131,"context_line":"        self.assertEqual(result[\"free_capacity_gb\"], 0)"}],"source_content_type":"text/x-python","patch_set":2,"id":"1ac06dbe_7ad2dd01","line":128,"range":{"start_line":128,"start_character":25,"end_line":128,"end_character":54},"in_reply_to":"3ac371cc_e85932fe","updated":"2016-11-09 09:45:43.000000000","message":"Done","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"5d2be3a224969c7b8cbc3602cc60ed73606dae3a","unresolved":false,"context_lines":[{"line_number":24,"context_line":"from cinder import exception"},{"line_number":25,"context_line":"from cinder import test"},{"line_number":26,"context_line":"from cinder.volume import configuration"},{"line_number":27,"context_line":"from cinder.volume.drivers.infinidat import InfiniboxVolumeDriver"},{"line_number":28,"context_line":""},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"BASE_URL \u003d \u0027http://mockbox/api/rest/\u0027"}],"source_content_type":"text/x-python","patch_set":4,"id":"9a629dbe_eadc3c14","line":27,"range":{"start_line":27,"start_character":44,"end_line":27,"end_character":64},"updated":"2016-11-09 14:26:32.000000000","message":"Import modules, not classes.","commit_id":"6c20718e2da330d3321c064c6bba4794d0cd5049"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"1afab0b0f18f794dd360105c1a82118414d17ee5","unresolved":false,"context_lines":[{"line_number":24,"context_line":"from cinder import exception"},{"line_number":25,"context_line":"from cinder import test"},{"line_number":26,"context_line":"from cinder.volume import configuration"},{"line_number":27,"context_line":"from cinder.volume.drivers.infinidat import InfiniboxVolumeDriver"},{"line_number":28,"context_line":""},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"BASE_URL \u003d \u0027http://mockbox/api/rest/\u0027"}],"source_content_type":"text/x-python","patch_set":4,"id":"7a77a97e_406e1497","line":27,"range":{"start_line":27,"start_character":44,"end_line":27,"end_character":64},"in_reply_to":"9a629dbe_eadc3c14","updated":"2016-11-21 08:24:24.000000000","message":"Done","commit_id":"6c20718e2da330d3321c064c6bba4794d0cd5049"},{"author":{"_account_id":16708,"name":"Kendall Nelson","display_name":"Kendall (diablo_rojo)","email":"kennelson11@gmail.com","username":"kjnelson"},"change_message_id":"a8a2d399aa89efd1a448a641eb1034d9bea88c3a","unresolved":false,"context_lines":[{"line_number":171,"context_line":"        self.assertEqual(1, result[\"data\"][\"target_lun\"])"},{"line_number":172,"context_line":"        self.assertEqual(\"rw\", result[\"data\"][\"access_mode\"])"},{"line_number":173,"context_line":""},{"line_number":174,"context_line":"    def test_initialize_connection_map_write_protecetd_vol(self):"},{"line_number":175,"context_line":"        self._responses[\"GET\"][GET_VOLUME_URL] \u003d [VOLUME_RESULT_WP]"},{"line_number":176,"context_line":"        result \u003d self.driver.initialize_connection(test_volume, test_connector)"},{"line_number":177,"context_line":"        self.assertEqual(1, result[\"data\"][\"target_lun\"])"}],"source_content_type":"text/x-python","patch_set":4,"id":"7a77a97e_7d2f88a1","line":174,"range":{"start_line":174,"start_character":45,"end_line":174,"end_character":54},"updated":"2016-11-14 22:21:33.000000000","message":"s/proteceted/protected ?","commit_id":"6c20718e2da330d3321c064c6bba4794d0cd5049"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"1afab0b0f18f794dd360105c1a82118414d17ee5","unresolved":false,"context_lines":[{"line_number":171,"context_line":"        self.assertEqual(1, result[\"data\"][\"target_lun\"])"},{"line_number":172,"context_line":"        self.assertEqual(\"rw\", result[\"data\"][\"access_mode\"])"},{"line_number":173,"context_line":""},{"line_number":174,"context_line":"    def test_initialize_connection_map_write_protecetd_vol(self):"},{"line_number":175,"context_line":"        self._responses[\"GET\"][GET_VOLUME_URL] \u003d [VOLUME_RESULT_WP]"},{"line_number":176,"context_line":"        result \u003d self.driver.initialize_connection(test_volume, test_connector)"},{"line_number":177,"context_line":"        self.assertEqual(1, result[\"data\"][\"target_lun\"])"}],"source_content_type":"text/x-python","patch_set":4,"id":"7a77a97e_606dd097","line":174,"range":{"start_line":174,"start_character":45,"end_line":174,"end_character":54},"in_reply_to":"7a77a97e_7d2f88a1","updated":"2016-11-21 08:24:24.000000000","message":"Done","commit_id":"6c20718e2da330d3321c064c6bba4794d0cd5049"},{"author":{"_account_id":16708,"name":"Kendall Nelson","display_name":"Kendall (diablo_rojo)","email":"kennelson11@gmail.com","username":"kjnelson"},"change_message_id":"a8a2d399aa89efd1a448a641eb1034d9bea88c3a","unresolved":false,"context_lines":[{"line_number":272,"context_line":"                          self.driver.create_snapshot, test_snapshot)"},{"line_number":273,"context_line":""},{"line_number":274,"context_line":"    def test_create_volume_from_snapshot(self):"},{"line_number":275,"context_line":"        with mock.patch(\"cinder.volume.utils.copy_volume\"), \\"},{"line_number":276,"context_line":"            mock.patch(\"cinder.utils.brick_get_connector\"), \\"},{"line_number":277,"context_line":"            mock.patch(\"cinder.utils.brick_get_connector_properties\","},{"line_number":278,"context_line":"                       return_value\u003dtest_connector):"},{"line_number":279,"context_line":"            self.driver.create_volume_from_snapshot(test_clone, test_snapshot)"},{"line_number":280,"context_line":""},{"line_number":281,"context_line":"    def test_create_volume_from_snapshot_doesnt_exist(self):"}],"source_content_type":"text/x-python","patch_set":4,"id":"7a77a97e_e003eb0b","line":278,"range":{"start_line":275,"start_character":8,"end_line":278,"end_character":51},"updated":"2016-11-14 22:21:33.000000000","message":"Any reason why you are setting the mocks up inside the method rather than outside? Also, please try to avoid \u0027\\\u0027 and use \u0027()\u0027 instead.","commit_id":"6c20718e2da330d3321c064c6bba4794d0cd5049"},{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"33f27e0532d44b6ecce1c1bb9472d2f884f2879f","unresolved":false,"context_lines":[{"line_number":272,"context_line":"                          self.driver.create_snapshot, test_snapshot)"},{"line_number":273,"context_line":""},{"line_number":274,"context_line":"    def test_create_volume_from_snapshot(self):"},{"line_number":275,"context_line":"        with mock.patch(\"cinder.volume.utils.copy_volume\"), \\"},{"line_number":276,"context_line":"            mock.patch(\"cinder.utils.brick_get_connector\"), \\"},{"line_number":277,"context_line":"            mock.patch(\"cinder.utils.brick_get_connector_properties\","},{"line_number":278,"context_line":"                       return_value\u003dtest_connector):"},{"line_number":279,"context_line":"            self.driver.create_volume_from_snapshot(test_clone, test_snapshot)"},{"line_number":280,"context_line":""},{"line_number":281,"context_line":"    def test_create_volume_from_snapshot_doesnt_exist(self):"}],"source_content_type":"text/x-python","patch_set":4,"id":"7a77a97e_4e2e0544","line":278,"range":{"start_line":275,"start_character":8,"end_line":278,"end_character":51},"in_reply_to":"7a77a97e_3895badd","updated":"2016-11-17 12:14:45.000000000","message":"I still don\u0027t understand the reason why \u0027\\\u0027 is not wanted. +1 to using decorators -\u003e http://bit.ly/2fYOXU9","commit_id":"6c20718e2da330d3321c064c6bba4794d0cd5049"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"1afab0b0f18f794dd360105c1a82118414d17ee5","unresolved":false,"context_lines":[{"line_number":272,"context_line":"                          self.driver.create_snapshot, test_snapshot)"},{"line_number":273,"context_line":""},{"line_number":274,"context_line":"    def test_create_volume_from_snapshot(self):"},{"line_number":275,"context_line":"        with mock.patch(\"cinder.volume.utils.copy_volume\"), \\"},{"line_number":276,"context_line":"            mock.patch(\"cinder.utils.brick_get_connector\"), \\"},{"line_number":277,"context_line":"            mock.patch(\"cinder.utils.brick_get_connector_properties\","},{"line_number":278,"context_line":"                       return_value\u003dtest_connector):"},{"line_number":279,"context_line":"            self.driver.create_volume_from_snapshot(test_clone, test_snapshot)"},{"line_number":280,"context_line":""},{"line_number":281,"context_line":"    def test_create_volume_from_snapshot_doesnt_exist(self):"}],"source_content_type":"text/x-python","patch_set":4,"id":"7a77a97e_9e6a0ced","line":278,"range":{"start_line":275,"start_character":8,"end_line":278,"end_character":51},"in_reply_to":"7a77a97e_4e2e0544","updated":"2016-11-21 08:24:24.000000000","message":"Done for all mock.patch-es","commit_id":"6c20718e2da330d3321c064c6bba4794d0cd5049"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"b8a0f66a757d713c38b1f5a6780232498e978a7c","unresolved":false,"context_lines":[{"line_number":272,"context_line":"                          self.driver.create_snapshot, test_snapshot)"},{"line_number":273,"context_line":""},{"line_number":274,"context_line":"    def test_create_volume_from_snapshot(self):"},{"line_number":275,"context_line":"        with mock.patch(\"cinder.volume.utils.copy_volume\"), \\"},{"line_number":276,"context_line":"            mock.patch(\"cinder.utils.brick_get_connector\"), \\"},{"line_number":277,"context_line":"            mock.patch(\"cinder.utils.brick_get_connector_properties\","},{"line_number":278,"context_line":"                       return_value\u003dtest_connector):"},{"line_number":279,"context_line":"            self.driver.create_volume_from_snapshot(test_clone, test_snapshot)"},{"line_number":280,"context_line":""},{"line_number":281,"context_line":"    def test_create_volume_from_snapshot_doesnt_exist(self):"}],"source_content_type":"text/x-python","patch_set":4,"id":"7a77a97e_3895badd","line":278,"range":{"start_line":275,"start_character":8,"end_line":278,"end_character":51},"in_reply_to":"7a77a97e_e003eb0b","updated":"2016-11-16 17:01:09.000000000","message":"I believe nested mock.patch\u0027s need the \\. When I switched over code that was using contextlib.nested to using nested mock.patch I tried to get rid of the \\ but there\u0027s something about it that mock just does not like.","commit_id":"6c20718e2da330d3321c064c6bba4794d0cd5049"},{"author":{"_account_id":16708,"name":"Kendall Nelson","display_name":"Kendall (diablo_rojo)","email":"kennelson11@gmail.com","username":"kjnelson"},"change_message_id":"a8a2d399aa89efd1a448a641eb1034d9bea88c3a","unresolved":false,"context_lines":[{"line_number":299,"context_line":"                              test_clone, test_snapshot)"},{"line_number":300,"context_line":""},{"line_number":301,"context_line":"    def test_create_volume_from_snapshot_delete_clone_fails(self):"},{"line_number":302,"context_line":"        with mock.patch(\"cinder.volume.utils.copy_volume\"), \\"},{"line_number":303,"context_line":"            mock.patch(\"cinder.utils.brick_get_connector\"), \\"},{"line_number":304,"context_line":"            mock.patch(\"cinder.utils.brick_get_connector_properties\","},{"line_number":305,"context_line":"                       return_value\u003dtest_connector):"},{"line_number":306,"context_line":"            self._responses[\"DELETE\"][VOLUME_URL + APPROVAL] \u003d 500"},{"line_number":307,"context_line":"            self.assertRaises(exception.VolumeBackendAPIException,"},{"line_number":308,"context_line":"                              self.driver.create_volume_from_snapshot,"}],"source_content_type":"text/x-python","patch_set":4,"id":"7a77a97e_e02a0b7e","line":305,"range":{"start_line":302,"start_character":8,"end_line":305,"end_character":11},"updated":"2016-11-14 22:21:33.000000000","message":"Ditto above comment.","commit_id":"6c20718e2da330d3321c064c6bba4794d0cd5049"},{"author":{"_account_id":16708,"name":"Kendall Nelson","display_name":"Kendall (diablo_rojo)","email":"kennelson11@gmail.com","username":"kjnelson"},"change_message_id":"a8a2d399aa89efd1a448a641eb1034d9bea88c3a","unresolved":false,"context_lines":[{"line_number":330,"context_line":"                          self.driver.delete_snapshot, test_snapshot)"},{"line_number":331,"context_line":""},{"line_number":332,"context_line":"    def test_create_cloned_volume(self):"},{"line_number":333,"context_line":"        with mock.patch(\"cinder.volume.utils.copy_volume\"), \\"},{"line_number":334,"context_line":"            mock.patch(\"cinder.utils.brick_get_connector\"), \\"},{"line_number":335,"context_line":"            mock.patch(\"cinder.utils.brick_get_connector_properties\","},{"line_number":336,"context_line":"                       return_value\u003dtest_connector):"},{"line_number":337,"context_line":"            self.driver.create_cloned_volume(test_clone, test_volume)"},{"line_number":338,"context_line":""},{"line_number":339,"context_line":"    def test_create_cloned_volume_volume_already_mapped(self):"}],"source_content_type":"text/x-python","patch_set":4,"id":"7a77a97e_8034f7de","line":336,"range":{"start_line":333,"start_character":7,"end_line":336,"end_character":52},"updated":"2016-11-14 22:21:33.000000000","message":"Ditto above comment.","commit_id":"6c20718e2da330d3321c064c6bba4794d0cd5049"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"13d17499479878e4981632cfcdcfee784538e550","unresolved":false,"context_lines":[{"line_number":65,"context_line":"HOST2_RESULT \u003d dict(id\u003d11)"},{"line_number":66,"context_line":"POOL_RESULT \u003d dict(id\u003d100,"},{"line_number":67,"context_line":"                   free_physical_space\u003d1024 ** 3,"},{"line_number":68,"context_line":"                   physical_capacity\u003d1024 ** 3)"},{"line_number":69,"context_line":""},{"line_number":70,"context_line":"GOOD_PATH_RESPONSES \u003d dict(GET\u003d{GET_VOLUME_URL: [VOLUME_RESULT],"},{"line_number":71,"context_line":"                                GET_HOST_URL: [HOST_RESULT],"}],"source_content_type":"text/x-python","patch_set":5,"id":"5a74a57a_58355844","line":68,"updated":"2016-11-23 17:35:11.000000000","message":"Please use units in oslo_utils.","commit_id":"f96e4812de7550660fc3b3abfeb3cd55df560f93"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"b657ff1a9d22219016514beb338728589ca13f28","unresolved":false,"context_lines":[{"line_number":65,"context_line":"HOST2_RESULT \u003d dict(id\u003d11)"},{"line_number":66,"context_line":"POOL_RESULT \u003d dict(id\u003d100,"},{"line_number":67,"context_line":"                   free_physical_space\u003d1024 ** 3,"},{"line_number":68,"context_line":"                   physical_capacity\u003d1024 ** 3)"},{"line_number":69,"context_line":""},{"line_number":70,"context_line":"GOOD_PATH_RESPONSES \u003d dict(GET\u003d{GET_VOLUME_URL: [VOLUME_RESULT],"},{"line_number":71,"context_line":"                                GET_HOST_URL: [HOST_RESULT],"}],"source_content_type":"text/x-python","patch_set":5,"id":"5a74a57a_266ba986","line":68,"in_reply_to":"5a74a57a_58355844","updated":"2016-11-27 16:13:36.000000000","message":"Done","commit_id":"f96e4812de7550660fc3b3abfeb3cd55df560f93"}],"cinder/volume/drivers/infinidat.py":[{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"80c4e6699d27d06e0ce0c96c976647a3eab6537b","unresolved":false,"context_lines":[{"line_number":13,"context_line":"#    License for the specific language governing permissions and limitations"},{"line_number":14,"context_line":"#    under the License."},{"line_number":15,"context_line":"#"},{"line_number":16,"context_line":"#"},{"line_number":17,"context_line":"# INFINIDAT InfiniBox Volume Driver"},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"from cinder.i18n import _"},{"line_number":20,"context_line":"from oslo_config import cfg"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_9adbb97b","line":17,"range":{"start_line":16,"start_character":0,"end_line":17,"end_character":35},"updated":"2016-08-18 12:23:49.000000000","message":"Here you should leave the copyright header with \u0027#\u0027 and use \"\"\"INFINIDAT InfiniBox Volume Driver\"\"\"","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"85de9c674f8998dc9b3c3e9ec2075f36ebaf752c","unresolved":false,"context_lines":[{"line_number":13,"context_line":"#    License for the specific language governing permissions and limitations"},{"line_number":14,"context_line":"#    under the License."},{"line_number":15,"context_line":"#"},{"line_number":16,"context_line":"#"},{"line_number":17,"context_line":"# INFINIDAT InfiniBox Volume Driver"},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"from cinder.i18n import _"},{"line_number":20,"context_line":"from oslo_config import cfg"}],"source_content_type":"text/x-python","patch_set":1,"id":"1ac06dbe_9a9b5972","line":17,"range":{"start_line":16,"start_character":0,"end_line":17,"end_character":35},"in_reply_to":"3ac371cc_9adbb97b","updated":"2016-08-21 07:59:58.000000000","message":"Done","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"80c4e6699d27d06e0ce0c96c976647a3eab6537b","unresolved":false,"context_lines":[{"line_number":34,"context_line":"VENDOR_NAME \u003d \u0027INFINIDAT\u0027"},{"line_number":35,"context_line":"DRIVER_VERSION \u003d \u00271.0\u0027"},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"infinidat_opts \u003d ["},{"line_number":38,"context_line":"    cfg.StrOpt(\u0027infinidat_pool_name\u0027,"},{"line_number":39,"context_line":"               help\u003d\u0027name of the pool from which volumes are allocated\u0027),"},{"line_number":40,"context_line":"    cfg.StrOpt(\u0027infinidat_provision_type\u0027,"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_1a7fc9e0","line":37,"range":{"start_line":37,"start_character":0,"end_line":37,"end_character":14},"updated":"2016-08-18 12:23:49.000000000","message":"The help strings from this options will be imported to openstack-manuals config-reference, so, its important that they are properly formatted with \u0027.\u0027, capitals, etc. Also, when possible give a better explanation of how to use then.","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"85de9c674f8998dc9b3c3e9ec2075f36ebaf752c","unresolved":false,"context_lines":[{"line_number":34,"context_line":"VENDOR_NAME \u003d \u0027INFINIDAT\u0027"},{"line_number":35,"context_line":"DRIVER_VERSION \u003d \u00271.0\u0027"},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"infinidat_opts \u003d ["},{"line_number":38,"context_line":"    cfg.StrOpt(\u0027infinidat_pool_name\u0027,"},{"line_number":39,"context_line":"               help\u003d\u0027name of the pool from which volumes are allocated\u0027),"},{"line_number":40,"context_line":"    cfg.StrOpt(\u0027infinidat_provision_type\u0027,"}],"source_content_type":"text/x-python","patch_set":1,"id":"1ac06dbe_fa888d24","line":37,"range":{"start_line":37,"start_character":0,"end_line":37,"end_character":14},"in_reply_to":"3ac371cc_1a7fc9e0","updated":"2016-08-21 07:59:58.000000000","message":"Done","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"80c4e6699d27d06e0ce0c96c976647a3eab6537b","unresolved":false,"context_lines":[{"line_number":36,"context_line":""},{"line_number":37,"context_line":"infinidat_opts \u003d ["},{"line_number":38,"context_line":"    cfg.StrOpt(\u0027infinidat_pool_name\u0027,"},{"line_number":39,"context_line":"               help\u003d\u0027name of the pool from which volumes are allocated\u0027),"},{"line_number":40,"context_line":"    cfg.StrOpt(\u0027infinidat_provision_type\u0027,"},{"line_number":41,"context_line":"               choices\u003d[\u0027thick\u0027, \u0027thin\u0027],"},{"line_number":42,"context_line":"               default\u003d\u0027thick\u0027,"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_3a92854c","line":39,"range":{"start_line":39,"start_character":21,"end_line":39,"end_character":25},"updated":"2016-08-18 12:23:49.000000000","message":"Name","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"85de9c674f8998dc9b3c3e9ec2075f36ebaf752c","unresolved":false,"context_lines":[{"line_number":36,"context_line":""},{"line_number":37,"context_line":"infinidat_opts \u003d ["},{"line_number":38,"context_line":"    cfg.StrOpt(\u0027infinidat_pool_name\u0027,"},{"line_number":39,"context_line":"               help\u003d\u0027name of the pool from which volumes are allocated\u0027),"},{"line_number":40,"context_line":"    cfg.StrOpt(\u0027infinidat_provision_type\u0027,"},{"line_number":41,"context_line":"               choices\u003d[\u0027thick\u0027, \u0027thin\u0027],"},{"line_number":42,"context_line":"               default\u003d\u0027thick\u0027,"}],"source_content_type":"text/x-python","patch_set":1,"id":"1ac06dbe_da8b111d","line":39,"range":{"start_line":39,"start_character":21,"end_line":39,"end_character":25},"in_reply_to":"3ac371cc_3a92854c","updated":"2016-08-21 07:59:58.000000000","message":"Done","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"80c4e6699d27d06e0ce0c96c976647a3eab6537b","unresolved":false,"context_lines":[{"line_number":37,"context_line":"infinidat_opts \u003d ["},{"line_number":38,"context_line":"    cfg.StrOpt(\u0027infinidat_pool_name\u0027,"},{"line_number":39,"context_line":"               help\u003d\u0027name of the pool from which volumes are allocated\u0027),"},{"line_number":40,"context_line":"    cfg.StrOpt(\u0027infinidat_provision_type\u0027,"},{"line_number":41,"context_line":"               choices\u003d[\u0027thick\u0027, \u0027thin\u0027],"},{"line_number":42,"context_line":"               default\u003d\u0027thick\u0027,"},{"line_number":43,"context_line":"               help\u003d\u0027Provisioning type\u0027),"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_1a66a950","line":40,"range":{"start_line":40,"start_character":26,"end_line":40,"end_character":35},"updated":"2016-08-18 12:23:49.000000000","message":"_provisioning_?","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"85de9c674f8998dc9b3c3e9ec2075f36ebaf752c","unresolved":false,"context_lines":[{"line_number":37,"context_line":"infinidat_opts \u003d ["},{"line_number":38,"context_line":"    cfg.StrOpt(\u0027infinidat_pool_name\u0027,"},{"line_number":39,"context_line":"               help\u003d\u0027name of the pool from which volumes are allocated\u0027),"},{"line_number":40,"context_line":"    cfg.StrOpt(\u0027infinidat_provision_type\u0027,"},{"line_number":41,"context_line":"               choices\u003d[\u0027thick\u0027, \u0027thin\u0027],"},{"line_number":42,"context_line":"               default\u003d\u0027thick\u0027,"},{"line_number":43,"context_line":"               help\u003d\u0027Provisioning type\u0027),"}],"source_content_type":"text/x-python","patch_set":1,"id":"1ac06dbe_3a834506","line":40,"range":{"start_line":40,"start_character":26,"end_line":40,"end_character":35},"in_reply_to":"3ac371cc_1a66a950","updated":"2016-08-21 07:59:58.000000000","message":"Done","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"80c4e6699d27d06e0ce0c96c976647a3eab6537b","unresolved":false,"context_lines":[{"line_number":55,"context_line":""},{"line_number":56,"context_line":""},{"line_number":57,"context_line":"@interface.volumedriver"},{"line_number":58,"context_line":"class InfiniboxVolumeDriver(driver.VolumeDriver):"},{"line_number":59,"context_line":"    def __init__(self, *args, **kwargs):"},{"line_number":60,"context_line":"        super(InfiniboxVolumeDriver, self).__init__(*args, **kwargs)"},{"line_number":61,"context_line":"        self.configuration.append_config_values(infinidat_opts)"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_ba7f9513","line":58,"range":{"start_line":58,"start_character":0,"end_line":58,"end_character":49},"updated":"2016-08-18 12:23:49.000000000","message":"The driver also needs 2 fields defined:\nVERSION \u003d DRIVER_VERSION\nCI_WIKI_NAME \u003d \u0027YourCI\u0027\n\nFor the CI wiki, you can create one here[1], and fill the page later when you have the CI account details.\n\n[1] https://wiki.openstack.org/wiki/ThirdPartySystems","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"85de9c674f8998dc9b3c3e9ec2075f36ebaf752c","unresolved":false,"context_lines":[{"line_number":55,"context_line":""},{"line_number":56,"context_line":""},{"line_number":57,"context_line":"@interface.volumedriver"},{"line_number":58,"context_line":"class InfiniboxVolumeDriver(driver.VolumeDriver):"},{"line_number":59,"context_line":"    def __init__(self, *args, **kwargs):"},{"line_number":60,"context_line":"        super(InfiniboxVolumeDriver, self).__init__(*args, **kwargs)"},{"line_number":61,"context_line":"        self.configuration.append_config_values(infinidat_opts)"}],"source_content_type":"text/x-python","patch_set":1,"id":"1ac06dbe_1a864913","line":58,"range":{"start_line":58,"start_character":0,"end_line":58,"end_character":49},"in_reply_to":"3ac371cc_ba7f9513","updated":"2016-08-21 07:59:58.000000000","message":"Done","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"80c4e6699d27d06e0ce0c96c976647a3eab6537b","unresolved":false,"context_lines":[{"line_number":63,"context_line":"    def do_setup(self, context):"},{"line_number":64,"context_line":"        \"\"\"Driver initialization\"\"\""},{"line_number":65,"context_line":"        self._session \u003d requests.Session()"},{"line_number":66,"context_line":"        self._session.auth \u003d (self.configuration.infinidat_username,"},{"line_number":67,"context_line":"                              self.configuration.infinidat_password)"},{"line_number":68,"context_line":"        management_address \u003d self.configuration.infinidat_management_address"},{"line_number":69,"context_line":"        self._base_url \u003d \u0027http://{0}/api/rest/\u0027.format(management_address)"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_3a3445fa","line":66,"range":{"start_line":66,"start_character":29,"end_line":66,"end_character":68},"updated":"2016-08-18 12:23:49.000000000","message":"A suggestion here is that you first check if the admin provided all the correct parameters and if no, fail with a proper message.","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"044535331db2360edd1f224e0cbf065ec4e2b4ca","unresolved":false,"context_lines":[{"line_number":63,"context_line":"    def do_setup(self, context):"},{"line_number":64,"context_line":"        \"\"\"Driver initialization\"\"\""},{"line_number":65,"context_line":"        self._session \u003d requests.Session()"},{"line_number":66,"context_line":"        self._session.auth \u003d (self.configuration.infinidat_username,"},{"line_number":67,"context_line":"                              self.configuration.infinidat_password)"},{"line_number":68,"context_line":"        management_address \u003d self.configuration.infinidat_management_address"},{"line_number":69,"context_line":"        self._base_url \u003d \u0027http://{0}/api/rest/\u0027.format(management_address)"}],"source_content_type":"text/x-python","patch_set":1,"id":"1ac06dbe_0024bb5d","line":66,"range":{"start_line":66,"start_character":29,"end_line":66,"end_character":68},"in_reply_to":"3ac371cc_3a3445fa","updated":"2016-11-09 09:46:36.000000000","message":"Done, by inheriting from SanDriver","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"80c4e6699d27d06e0ce0c96c976647a3eab6537b","unresolved":false,"context_lines":[{"line_number":70,"context_line":"        backend_name \u003d self.configuration.safe_get(\u0027volume_backend_name\u0027)"},{"line_number":71,"context_line":"        self._backend_name \u003d backend_name or self.__class__.__name__"},{"line_number":72,"context_line":"        self._volume_stats \u003d None"},{"line_number":73,"context_line":"        LOG.debug(\u0027setup complete. base url: {0}\u0027.format(self._base_url))"},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"    def check_for_setup_error(self):"},{"line_number":76,"context_line":"        \"\"\"Validate setup\"\"\""}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_f54abe53","line":73,"range":{"start_line":73,"start_character":19,"end_line":73,"end_character":33},"updated":"2016-08-18 12:23:49.000000000","message":"Also, do some checking to see if the storage is reachable before telling setup is complete.","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"80c4e6699d27d06e0ce0c96c976647a3eab6537b","unresolved":false,"context_lines":[{"line_number":73,"context_line":"        LOG.debug(\u0027setup complete. base url: {0}\u0027.format(self._base_url))"},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"    def check_for_setup_error(self):"},{"line_number":76,"context_line":"        \"\"\"Validate setup\"\"\""},{"line_number":77,"context_line":"        pass"},{"line_number":78,"context_line":""},{"line_number":79,"context_line":"    def _request(self, action, uri, data\u003dNone):"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_55a7520a","line":76,"range":{"start_line":76,"start_character":11,"end_line":76,"end_character":25},"updated":"2016-08-18 12:23:49.000000000","message":"You can do those checks here if you prefer.","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"80c4e6699d27d06e0ce0c96c976647a3eab6537b","unresolved":false,"context_lines":[{"line_number":77,"context_line":"        pass"},{"line_number":78,"context_line":""},{"line_number":79,"context_line":"    def _request(self, action, uri, data\u003dNone):"},{"line_number":80,"context_line":"        LOG.debug(\u0027--\u003e {0} {1} {2!r}\u0027.format(action, uri, data))"},{"line_number":81,"context_line":"        response \u003d self._session.request(action,"},{"line_number":82,"context_line":"                                         self._base_url + uri,"},{"line_number":83,"context_line":"                                         json\u003ddata)"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_15d95a57","line":80,"range":{"start_line":80,"start_character":8,"end_line":80,"end_character":64},"updated":"2016-08-18 12:23:49.000000000","message":"I don\u0027t know if this is a rule for debug (is for warning and others), but for logging things, the usual way in Openstack[1] is LOG.debug(\u0027%(var1)s %(var2)s\u0027,{\u0027var1\u0027:var1, \u0027var2\u0027:var2}).\n\n[1] http://bit.ly/2bkOZ6Y","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"85de9c674f8998dc9b3c3e9ec2075f36ebaf752c","unresolved":false,"context_lines":[{"line_number":77,"context_line":"        pass"},{"line_number":78,"context_line":""},{"line_number":79,"context_line":"    def _request(self, action, uri, data\u003dNone):"},{"line_number":80,"context_line":"        LOG.debug(\u0027--\u003e {0} {1} {2!r}\u0027.format(action, uri, data))"},{"line_number":81,"context_line":"        response \u003d self._session.request(action,"},{"line_number":82,"context_line":"                                         self._base_url + uri,"},{"line_number":83,"context_line":"                                         json\u003ddata)"}],"source_content_type":"text/x-python","patch_set":1,"id":"1ac06dbe_7a7dbd1b","line":80,"range":{"start_line":80,"start_character":8,"end_line":80,"end_character":64},"in_reply_to":"3ac371cc_15d95a57","updated":"2016-08-21 07:59:58.000000000","message":"Done","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"80c4e6699d27d06e0ce0c96c976647a3eab6537b","unresolved":false,"context_lines":[{"line_number":112,"context_line":"        return str(wwpn).replace(\u0027:\u0027, \u0027\u0027)"},{"line_number":113,"context_line":""},{"line_number":114,"context_line":"    def _make_volume_name(self, cinder_volume):"},{"line_number":115,"context_line":"        return \u0027openstack-vol-{0}\u0027.format(cinder_volume[\u0027id\u0027])"},{"line_number":116,"context_line":""},{"line_number":117,"context_line":"    def _make_snapshot_name(self, cinder_snapshot):"},{"line_number":118,"context_line":"        return \u0027openstack-snap-{0}\u0027.format(cinder_snapshot[\u0027id\u0027])"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_75e6cee8","line":115,"range":{"start_line":115,"start_character":42,"end_line":115,"end_character":61},"updated":"2016-08-18 12:23:49.000000000","message":"cinder_volume.id","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"044535331db2360edd1f224e0cbf065ec4e2b4ca","unresolved":false,"context_lines":[{"line_number":112,"context_line":"        return str(wwpn).replace(\u0027:\u0027, \u0027\u0027)"},{"line_number":113,"context_line":""},{"line_number":114,"context_line":"    def _make_volume_name(self, cinder_volume):"},{"line_number":115,"context_line":"        return \u0027openstack-vol-{0}\u0027.format(cinder_volume[\u0027id\u0027])"},{"line_number":116,"context_line":""},{"line_number":117,"context_line":"    def _make_snapshot_name(self, cinder_snapshot):"},{"line_number":118,"context_line":"        return \u0027openstack-snap-{0}\u0027.format(cinder_snapshot[\u0027id\u0027])"}],"source_content_type":"text/x-python","patch_set":1,"id":"1ac06dbe_25b84ae5","line":115,"range":{"start_line":115,"start_character":42,"end_line":115,"end_character":61},"in_reply_to":"3ac371cc_75e6cee8","updated":"2016-11-09 09:46:36.000000000","message":"Done","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"80c4e6699d27d06e0ce0c96c976647a3eab6537b","unresolved":false,"context_lines":[{"line_number":115,"context_line":"        return \u0027openstack-vol-{0}\u0027.format(cinder_volume[\u0027id\u0027])"},{"line_number":116,"context_line":""},{"line_number":117,"context_line":"    def _make_snapshot_name(self, cinder_snapshot):"},{"line_number":118,"context_line":"        return \u0027openstack-snap-{0}\u0027.format(cinder_snapshot[\u0027id\u0027])"},{"line_number":119,"context_line":""},{"line_number":120,"context_line":"    def _make_host_name(self, wwpn):"},{"line_number":121,"context_line":"        wwn_for_name \u003d self._cleanup_wwpn(wwpn)"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_55e912b6","line":118,"range":{"start_line":118,"start_character":43,"end_line":118,"end_character":64},"updated":"2016-08-18 12:23:49.000000000","message":"cinder_snapshot.id","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"044535331db2360edd1f224e0cbf065ec4e2b4ca","unresolved":false,"context_lines":[{"line_number":115,"context_line":"        return \u0027openstack-vol-{0}\u0027.format(cinder_volume[\u0027id\u0027])"},{"line_number":116,"context_line":""},{"line_number":117,"context_line":"    def _make_snapshot_name(self, cinder_snapshot):"},{"line_number":118,"context_line":"        return \u0027openstack-snap-{0}\u0027.format(cinder_snapshot[\u0027id\u0027])"},{"line_number":119,"context_line":""},{"line_number":120,"context_line":"    def _make_host_name(self, wwpn):"},{"line_number":121,"context_line":"        wwn_for_name \u003d self._cleanup_wwpn(wwpn)"}],"source_content_type":"text/x-python","patch_set":1,"id":"1ac06dbe_85cf7e7e","line":118,"range":{"start_line":118,"start_character":43,"end_line":118,"end_character":64},"in_reply_to":"3ac371cc_55e912b6","updated":"2016-11-09 09:46:36.000000000","message":"Done","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"80c4e6699d27d06e0ce0c96c976647a3eab6537b","unresolved":false,"context_lines":[{"line_number":180,"context_line":"        nodes \u003d self._get(\u0027components/nodes?fields\u003dfc_ports\u0027)"},{"line_number":181,"context_line":"        for node in nodes:"},{"line_number":182,"context_line":"            for port in node[\u0027fc_ports\u0027]:"},{"line_number":183,"context_line":"                if port[\u0027link_state\u0027].lower() \u003d\u003d \u0027up\u0027 \\"},{"line_number":184,"context_line":"                   and port[\u0027state\u0027] \u003d\u003d \u0027OK\u0027:"},{"line_number":185,"context_line":"                    yield self._cleanup_wwpn(port[\u0027wwpn\u0027])"},{"line_number":186,"context_line":""},{"line_number":187,"context_line":"    def initialize_connection(self, volume, connector):"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_d5a4e24b","line":184,"range":{"start_line":183,"start_character":16,"end_line":184,"end_character":45},"updated":"2016-08-18 12:23:49.000000000","message":"Please use () to break lines.","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"85de9c674f8998dc9b3c3e9ec2075f36ebaf752c","unresolved":false,"context_lines":[{"line_number":180,"context_line":"        nodes \u003d self._get(\u0027components/nodes?fields\u003dfc_ports\u0027)"},{"line_number":181,"context_line":"        for node in nodes:"},{"line_number":182,"context_line":"            for port in node[\u0027fc_ports\u0027]:"},{"line_number":183,"context_line":"                if port[\u0027link_state\u0027].lower() \u003d\u003d \u0027up\u0027 \\"},{"line_number":184,"context_line":"                   and port[\u0027state\u0027] \u003d\u003d \u0027OK\u0027:"},{"line_number":185,"context_line":"                    yield self._cleanup_wwpn(port[\u0027wwpn\u0027])"},{"line_number":186,"context_line":""},{"line_number":187,"context_line":"    def initialize_connection(self, volume, connector):"}],"source_content_type":"text/x-python","patch_set":1,"id":"1ac06dbe_5a78c12b","line":184,"range":{"start_line":183,"start_character":16,"end_line":184,"end_character":45},"in_reply_to":"3ac371cc_d5a4e24b","updated":"2016-08-21 07:59:58.000000000","message":"Done","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"80c4e6699d27d06e0ce0c96c976647a3eab6537b","unresolved":false,"context_lines":[{"line_number":184,"context_line":"                   and port[\u0027state\u0027] \u003d\u003d \u0027OK\u0027:"},{"line_number":185,"context_line":"                    yield self._cleanup_wwpn(port[\u0027wwpn\u0027])"},{"line_number":186,"context_line":""},{"line_number":187,"context_line":"    def initialize_connection(self, volume, connector):"},{"line_number":188,"context_line":"        \"\"\"Map an InfiniBox volume to the host\"\"\""},{"line_number":189,"context_line":"        volume_name \u003d self._make_volume_name(volume)"},{"line_number":190,"context_line":"        infinidat_volume \u003d self._get_infinidat_volume_by_name(volume_name)"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_a7b3fd4b","line":187,"range":{"start_line":187,"start_character":4,"end_line":187,"end_character":55},"updated":"2016-08-18 12:23:49.000000000","message":"Please LOG.debug() all driver interface methods inputs and returns.","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"044535331db2360edd1f224e0cbf065ec4e2b4ca","unresolved":false,"context_lines":[{"line_number":184,"context_line":"                   and port[\u0027state\u0027] \u003d\u003d \u0027OK\u0027:"},{"line_number":185,"context_line":"                    yield self._cleanup_wwpn(port[\u0027wwpn\u0027])"},{"line_number":186,"context_line":""},{"line_number":187,"context_line":"    def initialize_connection(self, volume, connector):"},{"line_number":188,"context_line":"        \"\"\"Map an InfiniBox volume to the host\"\"\""},{"line_number":189,"context_line":"        volume_name \u003d self._make_volume_name(volume)"},{"line_number":190,"context_line":"        infinidat_volume \u003d self._get_infinidat_volume_by_name(volume_name)"}],"source_content_type":"text/x-python","patch_set":1,"id":"1ac06dbe_9a02390a","line":187,"range":{"start_line":187,"start_character":4,"end_line":187,"end_character":55},"in_reply_to":"1ac06dbe_1a9da959","updated":"2016-11-09 09:46:36.000000000","message":"Using this decorator causes an exception which looks unrelated to my code: \nhttps://gist.github.com/wiggin15/8847f05d40a4a4e889caee9637356b70\nthis long traceback also makes me think the decorator is overkill so I prefer not to use it.\nI only see two vendors have these, anyway (HPE and NetApp), and few others have their own enter/leave logging","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"f8b789ab94f926a0a7108e41f638d14c5248ddbe","unresolved":false,"context_lines":[{"line_number":184,"context_line":"                   and port[\u0027state\u0027] \u003d\u003d \u0027OK\u0027:"},{"line_number":185,"context_line":"                    yield self._cleanup_wwpn(port[\u0027wwpn\u0027])"},{"line_number":186,"context_line":""},{"line_number":187,"context_line":"    def initialize_connection(self, volume, connector):"},{"line_number":188,"context_line":"        \"\"\"Map an InfiniBox volume to the host\"\"\""},{"line_number":189,"context_line":"        volume_name \u003d self._make_volume_name(volume)"},{"line_number":190,"context_line":"        infinidat_volume \u003d self._get_infinidat_volume_by_name(volume_name)"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_59e3ef33","line":187,"range":{"start_line":187,"start_character":4,"end_line":187,"end_character":55},"in_reply_to":"3ac371cc_3da43c06","updated":"2016-08-18 18:58:07.000000000","message":"All drivers should have that. This is crucial for detecting failures and resolving issues. This is not mandatory, but will save you a lot of time in the future.\n\nPS. There\u0027s a decorator: @utils.trace[1] that should make things easier, though I think way better to use the debug messages I place in the code.\n\n[1] http://bit.ly/2b2cIOw","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"85de9c674f8998dc9b3c3e9ec2075f36ebaf752c","unresolved":false,"context_lines":[{"line_number":184,"context_line":"                   and port[\u0027state\u0027] \u003d\u003d \u0027OK\u0027:"},{"line_number":185,"context_line":"                    yield self._cleanup_wwpn(port[\u0027wwpn\u0027])"},{"line_number":186,"context_line":""},{"line_number":187,"context_line":"    def initialize_connection(self, volume, connector):"},{"line_number":188,"context_line":"        \"\"\"Map an InfiniBox volume to the host\"\"\""},{"line_number":189,"context_line":"        volume_name \u003d self._make_volume_name(volume)"},{"line_number":190,"context_line":"        infinidat_volume \u003d self._get_infinidat_volume_by_name(volume_name)"}],"source_content_type":"text/x-python","patch_set":1,"id":"1ac06dbe_1a9da959","line":187,"range":{"start_line":187,"start_character":4,"end_line":187,"end_character":55},"in_reply_to":"3ac371cc_59e3ef33","updated":"2016-08-21 07:59:58.000000000","message":"Ok, thanks for the explanation, I will add this. Mentioning the decorator in the original comment would have been helpful - from what you wrote it sounded like you wanted us to add actual LOG.debug calls inline.","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"2c07db3eb324247945690ec85221d81936044c96","unresolved":false,"context_lines":[{"line_number":184,"context_line":"                   and port[\u0027state\u0027] \u003d\u003d \u0027OK\u0027:"},{"line_number":185,"context_line":"                    yield self._cleanup_wwpn(port[\u0027wwpn\u0027])"},{"line_number":186,"context_line":""},{"line_number":187,"context_line":"    def initialize_connection(self, volume, connector):"},{"line_number":188,"context_line":"        \"\"\"Map an InfiniBox volume to the host\"\"\""},{"line_number":189,"context_line":"        volume_name \u003d self._make_volume_name(volume)"},{"line_number":190,"context_line":"        infinidat_volume \u003d self._get_infinidat_volume_by_name(volume_name)"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_3da43c06","line":187,"range":{"start_line":187,"start_character":4,"end_line":187,"end_character":55},"in_reply_to":"3ac371cc_a7b3fd4b","updated":"2016-08-18 14:37:31.000000000","message":"Almost none of the other drivers have debug logs for every enter/return of the interface functions.","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"80c4e6699d27d06e0ce0c96c976647a3eab6537b","unresolved":false,"context_lines":[{"line_number":194,"context_line":"                                                  infinidat_volume[\u0027id\u0027])"},{"line_number":195,"context_line":"            lun \u003d mapping[\u0027lun\u0027]"},{"line_number":196,"context_line":""},{"line_number":197,"context_line":"        access_mode \u003d \u0027ro\u0027 if infinidat_volume[\u0027write_protected\u0027] else \u0027rw\u0027"},{"line_number":198,"context_line":"        target_wwn \u003d list(self._get_online_fc_ports())"},{"line_number":199,"context_line":"        return dict(driver_volume_type\u003d\u0027fibre_channel\u0027,"},{"line_number":200,"context_line":"                    data\u003ddict(target_discovered\u003dFalse,"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_a7177d43","line":197,"range":{"start_line":197,"start_character":7,"end_line":197,"end_character":75},"updated":"2016-08-18 12:23:49.000000000","message":"I didn\u0027t see how you set this option for volume. How does this work?","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"f8b789ab94f926a0a7108e41f638d14c5248ddbe","unresolved":false,"context_lines":[{"line_number":194,"context_line":"                                                  infinidat_volume[\u0027id\u0027])"},{"line_number":195,"context_line":"            lun \u003d mapping[\u0027lun\u0027]"},{"line_number":196,"context_line":""},{"line_number":197,"context_line":"        access_mode \u003d \u0027ro\u0027 if infinidat_volume[\u0027write_protected\u0027] else \u0027rw\u0027"},{"line_number":198,"context_line":"        target_wwn \u003d list(self._get_online_fc_ports())"},{"line_number":199,"context_line":"        return dict(driver_volume_type\u003d\u0027fibre_channel\u0027,"},{"line_number":200,"context_line":"                    data\u003ddict(target_discovered\u003dFalse,"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_79022bb6","line":197,"range":{"start_line":197,"start_character":7,"end_line":197,"end_character":75},"in_reply_to":"3ac371cc_6a0a6c27","updated":"2016-08-18 18:58:07.000000000","message":"Thanks for the explanation.","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"85de9c674f8998dc9b3c3e9ec2075f36ebaf752c","unresolved":false,"context_lines":[{"line_number":194,"context_line":"                                                  infinidat_volume[\u0027id\u0027])"},{"line_number":195,"context_line":"            lun \u003d mapping[\u0027lun\u0027]"},{"line_number":196,"context_line":""},{"line_number":197,"context_line":"        access_mode \u003d \u0027ro\u0027 if infinidat_volume[\u0027write_protected\u0027] else \u0027rw\u0027"},{"line_number":198,"context_line":"        target_wwn \u003d list(self._get_online_fc_ports())"},{"line_number":199,"context_line":"        return dict(driver_volume_type\u003d\u0027fibre_channel\u0027,"},{"line_number":200,"context_line":"                    data\u003ddict(target_discovered\u003dFalse,"}],"source_content_type":"text/x-python","patch_set":1,"id":"1ac06dbe_9a723948","line":197,"range":{"start_line":197,"start_character":7,"end_line":197,"end_character":75},"in_reply_to":"3ac371cc_79022bb6","updated":"2016-08-21 07:59:58.000000000","message":"Done","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"2c07db3eb324247945690ec85221d81936044c96","unresolved":false,"context_lines":[{"line_number":194,"context_line":"                                                  infinidat_volume[\u0027id\u0027])"},{"line_number":195,"context_line":"            lun \u003d mapping[\u0027lun\u0027]"},{"line_number":196,"context_line":""},{"line_number":197,"context_line":"        access_mode \u003d \u0027ro\u0027 if infinidat_volume[\u0027write_protected\u0027] else \u0027rw\u0027"},{"line_number":198,"context_line":"        target_wwn \u003d list(self._get_online_fc_ports())"},{"line_number":199,"context_line":"        return dict(driver_volume_type\u003d\u0027fibre_channel\u0027,"},{"line_number":200,"context_line":"                    data\u003ddict(target_discovered\u003dFalse,"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_6a0a6c27","line":197,"range":{"start_line":197,"start_character":7,"end_line":197,"end_character":75},"in_reply_to":"3ac371cc_a7177d43","updated":"2016-08-18 14:37:31.000000000","message":"All INFINIDAT volumes are not \"write_protected\", while all snapshots and clones (children of snapshots) are write_protected, unless updated otherwise. See the \"_put\" in \"create_volume_from_snapshot\"","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"80c4e6699d27d06e0ce0c96c976647a3eab6537b","unresolved":false,"context_lines":[{"line_number":196,"context_line":""},{"line_number":197,"context_line":"        access_mode \u003d \u0027ro\u0027 if infinidat_volume[\u0027write_protected\u0027] else \u0027rw\u0027"},{"line_number":198,"context_line":"        target_wwn \u003d list(self._get_online_fc_ports())"},{"line_number":199,"context_line":"        return dict(driver_volume_type\u003d\u0027fibre_channel\u0027,"},{"line_number":200,"context_line":"                    data\u003ddict(target_discovered\u003dFalse,"},{"line_number":201,"context_line":"                              target_wwn\u003dtarget_wwn,"},{"line_number":202,"context_line":"                              target_lun\u003dlun,"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_c78f1973","line":199,"range":{"start_line":199,"start_character":8,"end_line":199,"end_character":55},"updated":"2016-08-18 12:23:49.000000000","message":"Please LOG.debug() all driver interface methods inputs and returns.","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"80c4e6699d27d06e0ce0c96c976647a3eab6537b","unresolved":false,"context_lines":[{"line_number":241,"context_line":"        data \u003d dict(pool_id\u003dpool[\u0027id\u0027],"},{"line_number":242,"context_line":"                    provtype\u003dprovtype,"},{"line_number":243,"context_line":"                    name\u003dvolume_name,"},{"line_number":244,"context_line":"                    size\u003dvolume[\u0027size\u0027] * units.Gi)"},{"line_number":245,"context_line":"        self._post(\u0027volumes\u0027, data)"},{"line_number":246,"context_line":""},{"line_number":247,"context_line":"    def _delete_parent_snapshot_if_needed(self, volume):"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_c76b9983","line":244,"range":{"start_line":244,"start_character":25,"end_line":244,"end_character":39},"updated":"2016-08-18 12:23:49.000000000","message":"volume.size, here and all access to the volume/snapshot objects","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"f8b789ab94f926a0a7108e41f638d14c5248ddbe","unresolved":false,"context_lines":[{"line_number":241,"context_line":"        data \u003d dict(pool_id\u003dpool[\u0027id\u0027],"},{"line_number":242,"context_line":"                    provtype\u003dprovtype,"},{"line_number":243,"context_line":"                    name\u003dvolume_name,"},{"line_number":244,"context_line":"                    size\u003dvolume[\u0027size\u0027] * units.Gi)"},{"line_number":245,"context_line":"        self._post(\u0027volumes\u0027, data)"},{"line_number":246,"context_line":""},{"line_number":247,"context_line":"    def _delete_parent_snapshot_if_needed(self, volume):"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_e4e67aaf","line":244,"range":{"start_line":244,"start_character":25,"end_line":244,"end_character":39},"in_reply_to":"3ac371cc_168b1d20","updated":"2016-08-18 18:58:07.000000000","message":"Yes, there\u0027s has been an effort from Cinder community to move to this new access.\nhttps://review.openstack.org/#/q/message:OVO+project:openstack/cinder","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"2c07db3eb324247945690ec85221d81936044c96","unresolved":false,"context_lines":[{"line_number":241,"context_line":"        data \u003d dict(pool_id\u003dpool[\u0027id\u0027],"},{"line_number":242,"context_line":"                    provtype\u003dprovtype,"},{"line_number":243,"context_line":"                    name\u003dvolume_name,"},{"line_number":244,"context_line":"                    size\u003dvolume[\u0027size\u0027] * units.Gi)"},{"line_number":245,"context_line":"        self._post(\u0027volumes\u0027, data)"},{"line_number":246,"context_line":""},{"line_number":247,"context_line":"    def _delete_parent_snapshot_if_needed(self, volume):"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_168b1d20","line":244,"range":{"start_line":244,"start_character":25,"end_line":244,"end_character":39},"in_reply_to":"3ac371cc_c76b9983","updated":"2016-08-18 14:37:31.000000000","message":"Is this a requirement? Many other drivers use the string key access, and changing this will require a non-trivial change to the tests.","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"044535331db2360edd1f224e0cbf065ec4e2b4ca","unresolved":false,"context_lines":[{"line_number":241,"context_line":"        data \u003d dict(pool_id\u003dpool[\u0027id\u0027],"},{"line_number":242,"context_line":"                    provtype\u003dprovtype,"},{"line_number":243,"context_line":"                    name\u003dvolume_name,"},{"line_number":244,"context_line":"                    size\u003dvolume[\u0027size\u0027] * units.Gi)"},{"line_number":245,"context_line":"        self._post(\u0027volumes\u0027, data)"},{"line_number":246,"context_line":""},{"line_number":247,"context_line":"    def _delete_parent_snapshot_if_needed(self, volume):"}],"source_content_type":"text/x-python","patch_set":1,"id":"1ac06dbe_65ca4270","line":244,"range":{"start_line":244,"start_character":25,"end_line":244,"end_character":39},"in_reply_to":"3ac371cc_e4e67aaf","updated":"2016-11-09 09:46:36.000000000","message":"Done","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"80c4e6699d27d06e0ce0c96c976647a3eab6537b","unresolved":false,"context_lines":[{"line_number":261,"context_line":"        try:"},{"line_number":262,"context_line":"            volume_name \u003d self._make_volume_name(volume)"},{"line_number":263,"context_line":"            volume \u003d self._get_infinidat_volume_by_name(volume_name)"},{"line_number":264,"context_line":"            if volume[\u0027has_children\u0027]:"},{"line_number":265,"context_line":"                # can\u0027t delete a volume that has a live snapshot/clone"},{"line_number":266,"context_line":"                raise exception.VolumeIsBusy(volume_name\u003dvolume_name)"},{"line_number":267,"context_line":"            self._delete(\u0027volumes/{0}?approved\u003dtrue\u0027.format(volume[\u0027id\u0027]))"},{"line_number":268,"context_line":"            self._delete_parent_snapshot_if_needed(volume)"},{"line_number":269,"context_line":"        except (exception.InvalidVolume, exception.NotFound):"},{"line_number":270,"context_line":"            return      # volume not found"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_270eed8b","line":267,"range":{"start_line":264,"start_character":11,"end_line":267,"end_character":74},"updated":"2016-08-18 12:23:49.000000000","message":"This is not compliant with the Cinder architecture of volume/clones. If you create a volume and then a clone of that volume, you must be able to delete the source volume! You need to de-couple the clone -\u003e parent after cloning if you need to delete the parent.","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"2c07db3eb324247945690ec85221d81936044c96","unresolved":false,"context_lines":[{"line_number":261,"context_line":"        try:"},{"line_number":262,"context_line":"            volume_name \u003d self._make_volume_name(volume)"},{"line_number":263,"context_line":"            volume \u003d self._get_infinidat_volume_by_name(volume_name)"},{"line_number":264,"context_line":"            if volume[\u0027has_children\u0027]:"},{"line_number":265,"context_line":"                # can\u0027t delete a volume that has a live snapshot/clone"},{"line_number":266,"context_line":"                raise exception.VolumeIsBusy(volume_name\u003dvolume_name)"},{"line_number":267,"context_line":"            self._delete(\u0027volumes/{0}?approved\u003dtrue\u0027.format(volume[\u0027id\u0027]))"},{"line_number":268,"context_line":"            self._delete_parent_snapshot_if_needed(volume)"},{"line_number":269,"context_line":"        except (exception.InvalidVolume, exception.NotFound):"},{"line_number":270,"context_line":"            return      # volume not found"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_fd062484","line":267,"range":{"start_line":264,"start_character":11,"end_line":267,"end_character":74},"in_reply_to":"3ac371cc_270eed8b","updated":"2016-08-18 14:37:31.000000000","message":"This is impossible in our architecture and in many other SAN systems. Please see the implementation of many other drivers that also raise VolumeIsBusy/SnapshotIsBusy for this case. The HPE and LVM drivers are two examples.","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"f8b789ab94f926a0a7108e41f638d14c5248ddbe","unresolved":false,"context_lines":[{"line_number":261,"context_line":"        try:"},{"line_number":262,"context_line":"            volume_name \u003d self._make_volume_name(volume)"},{"line_number":263,"context_line":"            volume \u003d self._get_infinidat_volume_by_name(volume_name)"},{"line_number":264,"context_line":"            if volume[\u0027has_children\u0027]:"},{"line_number":265,"context_line":"                # can\u0027t delete a volume that has a live snapshot/clone"},{"line_number":266,"context_line":"                raise exception.VolumeIsBusy(volume_name\u003dvolume_name)"},{"line_number":267,"context_line":"            self._delete(\u0027volumes/{0}?approved\u003dtrue\u0027.format(volume[\u0027id\u0027]))"},{"line_number":268,"context_line":"            self._delete_parent_snapshot_if_needed(volume)"},{"line_number":269,"context_line":"        except (exception.InvalidVolume, exception.NotFound):"},{"line_number":270,"context_line":"            return      # volume not found"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_39f7138e","line":267,"range":{"start_line":264,"start_character":11,"end_line":267,"end_character":74},"in_reply_to":"3ac371cc_332452c5","updated":"2016-08-18 18:58:07.000000000","message":"I think its very unlikely that a vendor does not support splitting volumes after cloning, but if that is the case, you should use some kind of local copy with \u0027dd\u0027.","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"044535331db2360edd1f224e0cbf065ec4e2b4ca","unresolved":false,"context_lines":[{"line_number":261,"context_line":"        try:"},{"line_number":262,"context_line":"            volume_name \u003d self._make_volume_name(volume)"},{"line_number":263,"context_line":"            volume \u003d self._get_infinidat_volume_by_name(volume_name)"},{"line_number":264,"context_line":"            if volume[\u0027has_children\u0027]:"},{"line_number":265,"context_line":"                # can\u0027t delete a volume that has a live snapshot/clone"},{"line_number":266,"context_line":"                raise exception.VolumeIsBusy(volume_name\u003dvolume_name)"},{"line_number":267,"context_line":"            self._delete(\u0027volumes/{0}?approved\u003dtrue\u0027.format(volume[\u0027id\u0027]))"},{"line_number":268,"context_line":"            self._delete_parent_snapshot_if_needed(volume)"},{"line_number":269,"context_line":"        except (exception.InvalidVolume, exception.NotFound):"},{"line_number":270,"context_line":"            return      # volume not found"}],"source_content_type":"text/x-python","patch_set":1,"id":"1ac06dbe_c0d46321","line":267,"range":{"start_line":264,"start_character":11,"end_line":267,"end_character":74},"in_reply_to":"3ac371cc_39f7138e","updated":"2016-11-09 09:46:36.000000000","message":"Done. The check and raise are still there for the snapshots, but clones will be detached now (using \u0027dd\u0027 like Kaminario)","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"20467236b3c8182e0f94cc3f0b7c0286a4dfa50a","unresolved":false,"context_lines":[{"line_number":261,"context_line":"        try:"},{"line_number":262,"context_line":"            volume_name \u003d self._make_volume_name(volume)"},{"line_number":263,"context_line":"            volume \u003d self._get_infinidat_volume_by_name(volume_name)"},{"line_number":264,"context_line":"            if volume[\u0027has_children\u0027]:"},{"line_number":265,"context_line":"                # can\u0027t delete a volume that has a live snapshot/clone"},{"line_number":266,"context_line":"                raise exception.VolumeIsBusy(volume_name\u003dvolume_name)"},{"line_number":267,"context_line":"            self._delete(\u0027volumes/{0}?approved\u003dtrue\u0027.format(volume[\u0027id\u0027]))"},{"line_number":268,"context_line":"            self._delete_parent_snapshot_if_needed(volume)"},{"line_number":269,"context_line":"        except (exception.InvalidVolume, exception.NotFound):"},{"line_number":270,"context_line":"            return      # volume not found"}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_332452c5","line":267,"range":{"start_line":264,"start_character":11,"end_line":267,"end_character":74},"in_reply_to":"3ac371cc_fd062484","updated":"2016-08-18 18:35:06.000000000","message":"This should be true for snapshots, but clones should be separate independent entities. Source volumes should be able to be deletes after they\u0027ve been used to create clones.\n\nErlon verified LVM works correctly with thin and thick provisioning, and HPE has also reported that this is not a restriction for them either.","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"80c4e6699d27d06e0ce0c96c976647a3eab6537b","unresolved":false,"context_lines":[{"line_number":298,"context_line":"        try:"},{"line_number":299,"context_line":"            snapshot_name \u003d self._make_snapshot_name(snapshot)"},{"line_number":300,"context_line":"            snapshot \u003d self._get_infinidat_snapshot_by_name(snapshot_name)"},{"line_number":301,"context_line":"            if snapshot[\u0027has_children\u0027]:"},{"line_number":302,"context_line":"                # can\u0027t delete a snapshot that has a live clone"},{"line_number":303,"context_line":"                raise exception.SnapshotIsBusy(snapshot_name\u003dsnapshot_name)"},{"line_number":304,"context_line":"            self._delete(\u0027volumes/{0}?approved\u003dtrue\u0027.format(snapshot[\u0027id\u0027]))"},{"line_number":305,"context_line":"        except (exception.InvalidSnapshot, exception.NotFound):"},{"line_number":306,"context_line":"            return      # snapshot not found"},{"line_number":307,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"3ac371cc_a71addc3","line":304,"range":{"start_line":301,"start_character":0,"end_line":304,"end_character":76},"updated":"2016-08-18 12:23:49.000000000","message":"Same here.","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"044535331db2360edd1f224e0cbf065ec4e2b4ca","unresolved":false,"context_lines":[{"line_number":298,"context_line":"        try:"},{"line_number":299,"context_line":"            snapshot_name \u003d self._make_snapshot_name(snapshot)"},{"line_number":300,"context_line":"            snapshot \u003d self._get_infinidat_snapshot_by_name(snapshot_name)"},{"line_number":301,"context_line":"            if snapshot[\u0027has_children\u0027]:"},{"line_number":302,"context_line":"                # can\u0027t delete a snapshot that has a live clone"},{"line_number":303,"context_line":"                raise exception.SnapshotIsBusy(snapshot_name\u003dsnapshot_name)"},{"line_number":304,"context_line":"            self._delete(\u0027volumes/{0}?approved\u003dtrue\u0027.format(snapshot[\u0027id\u0027]))"},{"line_number":305,"context_line":"        except (exception.InvalidSnapshot, exception.NotFound):"},{"line_number":306,"context_line":"            return      # snapshot not found"},{"line_number":307,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"1ac06dbe_e0ad1f9c","line":304,"range":{"start_line":301,"start_character":0,"end_line":304,"end_character":76},"in_reply_to":"3ac371cc_a71addc3","updated":"2016-11-09 09:46:36.000000000","message":"Done","commit_id":"e7d675430eb293720ee0d7de2cc24b65b4317550"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"b6ac4c2921c964b380890c6950a3400352318e38","unresolved":false,"context_lines":[{"line_number":16,"context_line":"INFINIDAT InfiniBox Volume Driver"},{"line_number":17,"context_line":"\"\"\""},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"from cinder.i18n import _"},{"line_number":20,"context_line":"from oslo_config import cfg"},{"line_number":21,"context_line":"from oslo_log import log as logging"},{"line_number":22,"context_line":"from oslo_utils import units"}],"source_content_type":"text/x-python","patch_set":2,"id":"3ac371cc_e8b5b2ec","line":19,"updated":"2016-08-18 17:13:01.000000000","message":"Same comment about regrouping imports.","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"3d0ee331c243a3cfa59f3d5ec6cc94c52876315c","unresolved":false,"context_lines":[{"line_number":16,"context_line":"INFINIDAT InfiniBox Volume Driver"},{"line_number":17,"context_line":"\"\"\""},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"from cinder.i18n import _"},{"line_number":20,"context_line":"from oslo_config import cfg"},{"line_number":21,"context_line":"from oslo_log import log as logging"},{"line_number":22,"context_line":"from oslo_utils import units"}],"source_content_type":"text/x-python","patch_set":2,"id":"1ac06dbe_fa040d7f","line":19,"in_reply_to":"1ac06dbe_9aa9997e","updated":"2016-11-09 09:45:43.000000000","message":"Done","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"8143bf8e204fadeb9a598857d7ec5c1be9fdefd1","unresolved":false,"context_lines":[{"line_number":16,"context_line":"INFINIDAT InfiniBox Volume Driver"},{"line_number":17,"context_line":"\"\"\""},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"from cinder.i18n import _"},{"line_number":20,"context_line":"from oslo_config import cfg"},{"line_number":21,"context_line":"from oslo_log import log as logging"},{"line_number":22,"context_line":"from oslo_utils import units"}],"source_content_type":"text/x-python","patch_set":2,"id":"1ac06dbe_9aa9997e","line":19,"in_reply_to":"3ac371cc_3901d33a","updated":"2016-08-21 08:00:21.000000000","message":"pep8 checker passes, so apparently it doesn\u0027t check this.","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"5ae562be108313c50a1713a70be3eee627f82291","unresolved":false,"context_lines":[{"line_number":16,"context_line":"INFINIDAT InfiniBox Volume Driver"},{"line_number":17,"context_line":"\"\"\""},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"from cinder.i18n import _"},{"line_number":20,"context_line":"from oslo_config import cfg"},{"line_number":21,"context_line":"from oslo_log import log as logging"},{"line_number":22,"context_line":"from oslo_utils import units"}],"source_content_type":"text/x-python","patch_set":2,"id":"3ac371cc_3901d33a","line":19,"in_reply_to":"3ac371cc_4a2b1795","updated":"2016-08-18 19:03:37.000000000","message":"pep8 checker should point that.","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"ed47b40fadbc5fc482966af63a5fff924e8f801c","unresolved":false,"context_lines":[{"line_number":16,"context_line":"INFINIDAT InfiniBox Volume Driver"},{"line_number":17,"context_line":"\"\"\""},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"from cinder.i18n import _"},{"line_number":20,"context_line":"from oslo_config import cfg"},{"line_number":21,"context_line":"from oslo_log import log as logging"},{"line_number":22,"context_line":"from oslo_utils import units"}],"source_content_type":"text/x-python","patch_set":2,"id":"3ac371cc_4a2b1795","line":19,"in_reply_to":"3ac371cc_6ab8932b","updated":"2016-08-18 17:37:37.000000000","message":"The order should be grouped by standard modules, third party modules, then local project imports. So move cinder.i18n down to the cinder imports below.","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"c6b558244e69a28c8fb9f990da2b61e67d774cb5","unresolved":false,"context_lines":[{"line_number":16,"context_line":"INFINIDAT InfiniBox Volume Driver"},{"line_number":17,"context_line":"\"\"\""},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"from cinder.i18n import _"},{"line_number":20,"context_line":"from oslo_config import cfg"},{"line_number":21,"context_line":"from oslo_log import log as logging"},{"line_number":22,"context_line":"from oslo_utils import units"}],"source_content_type":"text/x-python","patch_set":2,"id":"3ac371cc_6ab8932b","line":19,"in_reply_to":"3ac371cc_e8b5b2ec","updated":"2016-08-18 17:30:50.000000000","message":"I think this is already ordered correctly. six and requests are not standard Python modules but third-party modules.","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":16708,"name":"Kendall Nelson","display_name":"Kendall (diablo_rojo)","email":"kennelson11@gmail.com","username":"kjnelson"},"change_message_id":"67806777062545ad8b4c209e2929987f6ded6af3","unresolved":false,"context_lines":[{"line_number":21,"context_line":"from oslo_log import log as logging"},{"line_number":22,"context_line":"from oslo_utils import units"},{"line_number":23,"context_line":"from oslo_utils import uuidutils"},{"line_number":24,"context_line":"import requests"},{"line_number":25,"context_line":"import six"},{"line_number":26,"context_line":""},{"line_number":27,"context_line":"from cinder import exception"},{"line_number":28,"context_line":"from cinder import interface"}],"source_content_type":"text/x-python","patch_set":2,"id":"5a8bc5a2_7a223003","line":25,"range":{"start_line":24,"start_character":0,"end_line":25,"end_character":10},"updated":"2016-09-27 22:15:04.000000000","message":"These should come first then a line and then the cinder imports and then the oslo imports.","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"b6ac4c2921c964b380890c6950a3400352318e38","unresolved":false,"context_lines":[{"line_number":36,"context_line":"infinidat_opts \u003d ["},{"line_number":37,"context_line":"    cfg.StrOpt(\u0027infinidat_pool_name\u0027,"},{"line_number":38,"context_line":"               help\u003d\u0027Name of the pool from which volumes are allocated\u0027),"},{"line_number":39,"context_line":"    cfg.StrOpt(\u0027infinidat_provisioning_type\u0027,"},{"line_number":40,"context_line":"               choices\u003d[\u0027thick\u0027, \u0027thin\u0027],"},{"line_number":41,"context_line":"               default\u003d\u0027thick\u0027,"},{"line_number":42,"context_line":"               help\u003d\u0027Provisioning type\u0027),"},{"line_number":43,"context_line":"    cfg.StrOpt(\u0027infinidat_management_address\u0027,"},{"line_number":44,"context_line":"               help\u003d\u0027IP address of InfiniBox array\u0027),"},{"line_number":45,"context_line":"    cfg.StrOpt(\u0027infinidat_username\u0027,"},{"line_number":46,"context_line":"               help\u003d\u0027Username for InfiniBox array\u0027),"},{"line_number":47,"context_line":"    cfg.StrOpt(\u0027infinidat_password\u0027,"},{"line_number":48,"context_line":"               help\u003d\u0027Password for InfiniBox array\u0027,"},{"line_number":49,"context_line":"               secret\u003dTrue)"},{"line_number":50,"context_line":"]"},{"line_number":51,"context_line":""},{"line_number":52,"context_line":"CONF \u003d cfg.CONF"}],"source_content_type":"text/x-python","patch_set":2,"id":"3ac371cc_08fdae6d","line":49,"range":{"start_line":39,"start_character":4,"end_line":49,"end_character":27},"updated":"2016-08-18 17:13:01.000000000","message":"It would be better to use the semi-standard config options of san_thin_provision, san_ip, san_login, and san_password.","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"c6b558244e69a28c8fb9f990da2b61e67d774cb5","unresolved":false,"context_lines":[{"line_number":36,"context_line":"infinidat_opts \u003d ["},{"line_number":37,"context_line":"    cfg.StrOpt(\u0027infinidat_pool_name\u0027,"},{"line_number":38,"context_line":"               help\u003d\u0027Name of the pool from which volumes are allocated\u0027),"},{"line_number":39,"context_line":"    cfg.StrOpt(\u0027infinidat_provisioning_type\u0027,"},{"line_number":40,"context_line":"               choices\u003d[\u0027thick\u0027, \u0027thin\u0027],"},{"line_number":41,"context_line":"               default\u003d\u0027thick\u0027,"},{"line_number":42,"context_line":"               help\u003d\u0027Provisioning type\u0027),"},{"line_number":43,"context_line":"    cfg.StrOpt(\u0027infinidat_management_address\u0027,"},{"line_number":44,"context_line":"               help\u003d\u0027IP address of InfiniBox array\u0027),"},{"line_number":45,"context_line":"    cfg.StrOpt(\u0027infinidat_username\u0027,"},{"line_number":46,"context_line":"               help\u003d\u0027Username for InfiniBox array\u0027),"},{"line_number":47,"context_line":"    cfg.StrOpt(\u0027infinidat_password\u0027,"},{"line_number":48,"context_line":"               help\u003d\u0027Password for InfiniBox array\u0027,"},{"line_number":49,"context_line":"               secret\u003dTrue)"},{"line_number":50,"context_line":"]"},{"line_number":51,"context_line":""},{"line_number":52,"context_line":"CONF \u003d cfg.CONF"}],"source_content_type":"text/x-python","patch_set":2,"id":"3ac371cc_0a50ff5d","line":49,"range":{"start_line":39,"start_character":4,"end_line":49,"end_character":27},"in_reply_to":"3ac371cc_08fdae6d","updated":"2016-08-18 17:30:50.000000000","message":"are these options automatically available or should they be redeclared here?","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"ed47b40fadbc5fc482966af63a5fff924e8f801c","unresolved":false,"context_lines":[{"line_number":36,"context_line":"infinidat_opts \u003d ["},{"line_number":37,"context_line":"    cfg.StrOpt(\u0027infinidat_pool_name\u0027,"},{"line_number":38,"context_line":"               help\u003d\u0027Name of the pool from which volumes are allocated\u0027),"},{"line_number":39,"context_line":"    cfg.StrOpt(\u0027infinidat_provisioning_type\u0027,"},{"line_number":40,"context_line":"               choices\u003d[\u0027thick\u0027, \u0027thin\u0027],"},{"line_number":41,"context_line":"               default\u003d\u0027thick\u0027,"},{"line_number":42,"context_line":"               help\u003d\u0027Provisioning type\u0027),"},{"line_number":43,"context_line":"    cfg.StrOpt(\u0027infinidat_management_address\u0027,"},{"line_number":44,"context_line":"               help\u003d\u0027IP address of InfiniBox array\u0027),"},{"line_number":45,"context_line":"    cfg.StrOpt(\u0027infinidat_username\u0027,"},{"line_number":46,"context_line":"               help\u003d\u0027Username for InfiniBox array\u0027),"},{"line_number":47,"context_line":"    cfg.StrOpt(\u0027infinidat_password\u0027,"},{"line_number":48,"context_line":"               help\u003d\u0027Password for InfiniBox array\u0027,"},{"line_number":49,"context_line":"               secret\u003dTrue)"},{"line_number":50,"context_line":"]"},{"line_number":51,"context_line":""},{"line_number":52,"context_line":"CONF \u003d cfg.CONF"}],"source_content_type":"text/x-python","patch_set":2,"id":"3ac371cc_ea10035c","line":49,"range":{"start_line":39,"start_character":4,"end_line":49,"end_character":27},"in_reply_to":"3ac371cc_0a50ff5d","updated":"2016-08-18 17:37:37.000000000","message":"Yep, they are common options.","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"3d0ee331c243a3cfa59f3d5ec6cc94c52876315c","unresolved":false,"context_lines":[{"line_number":36,"context_line":"infinidat_opts \u003d ["},{"line_number":37,"context_line":"    cfg.StrOpt(\u0027infinidat_pool_name\u0027,"},{"line_number":38,"context_line":"               help\u003d\u0027Name of the pool from which volumes are allocated\u0027),"},{"line_number":39,"context_line":"    cfg.StrOpt(\u0027infinidat_provisioning_type\u0027,"},{"line_number":40,"context_line":"               choices\u003d[\u0027thick\u0027, \u0027thin\u0027],"},{"line_number":41,"context_line":"               default\u003d\u0027thick\u0027,"},{"line_number":42,"context_line":"               help\u003d\u0027Provisioning type\u0027),"},{"line_number":43,"context_line":"    cfg.StrOpt(\u0027infinidat_management_address\u0027,"},{"line_number":44,"context_line":"               help\u003d\u0027IP address of InfiniBox array\u0027),"},{"line_number":45,"context_line":"    cfg.StrOpt(\u0027infinidat_username\u0027,"},{"line_number":46,"context_line":"               help\u003d\u0027Username for InfiniBox array\u0027),"},{"line_number":47,"context_line":"    cfg.StrOpt(\u0027infinidat_password\u0027,"},{"line_number":48,"context_line":"               help\u003d\u0027Password for InfiniBox array\u0027,"},{"line_number":49,"context_line":"               secret\u003dTrue)"},{"line_number":50,"context_line":"]"},{"line_number":51,"context_line":""},{"line_number":52,"context_line":"CONF \u003d cfg.CONF"}],"source_content_type":"text/x-python","patch_set":2,"id":"1ac06dbe_1a02c96f","line":49,"range":{"start_line":39,"start_character":4,"end_line":49,"end_character":27},"in_reply_to":"3ac371cc_ea10035c","updated":"2016-11-09 09:45:43.000000000","message":"Done","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"b6ac4c2921c964b380890c6950a3400352318e38","unresolved":false,"context_lines":[{"line_number":93,"context_line":"            response.raise_for_status()"},{"line_number":94,"context_line":"        except requests.HTTPError as ex:"},{"line_number":95,"context_line":"            # text_type(ex) includes http code and url"},{"line_number":96,"context_line":"            msg \u003d _(\u0027InfiniBox storage array returned \u0027) + six.text_type(ex)"},{"line_number":97,"context_line":"            msg +\u003d _(\u0027\\nData: \u0027) + repr(data)"},{"line_number":98,"context_line":"            msg +\u003d _(\u0027\\nResponse: \u0027) + repr(response.json())"},{"line_number":99,"context_line":"            LOG.exception(msg)"}],"source_content_type":"text/x-python","patch_set":2,"id":"3ac371cc_48de86dd","line":96,"range":{"start_line":96,"start_character":59,"end_line":96,"end_character":76},"updated":"2016-08-18 17:13:01.000000000","message":"When logging with LOG.exception you shouldn\u0027t also include the exception in your formatted text. LOG.exception behaves exactly like LOG.error with the additional behavior that it will automatically log all details for any in-scope exception.","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"c6b558244e69a28c8fb9f990da2b61e67d774cb5","unresolved":false,"context_lines":[{"line_number":93,"context_line":"            response.raise_for_status()"},{"line_number":94,"context_line":"        except requests.HTTPError as ex:"},{"line_number":95,"context_line":"            # text_type(ex) includes http code and url"},{"line_number":96,"context_line":"            msg \u003d _(\u0027InfiniBox storage array returned \u0027) + six.text_type(ex)"},{"line_number":97,"context_line":"            msg +\u003d _(\u0027\\nData: \u0027) + repr(data)"},{"line_number":98,"context_line":"            msg +\u003d _(\u0027\\nResponse: \u0027) + repr(response.json())"},{"line_number":99,"context_line":"            LOG.exception(msg)"}],"source_content_type":"text/x-python","patch_set":2,"id":"3ac371cc_cae0a7fd","line":96,"range":{"start_line":96,"start_character":59,"end_line":96,"end_character":76},"in_reply_to":"3ac371cc_48de86dd","updated":"2016-08-18 17:30:50.000000000","message":"msg is passed to VolumeBackendAPIException, where this information is required. I prefer not to have two separate \"msg\"s.","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"31edccaf2fc16af697f3c2ecd56c37061a64ba91","unresolved":false,"context_lines":[{"line_number":93,"context_line":"            response.raise_for_status()"},{"line_number":94,"context_line":"        except requests.HTTPError as ex:"},{"line_number":95,"context_line":"            # text_type(ex) includes http code and url"},{"line_number":96,"context_line":"            msg \u003d _(\u0027InfiniBox storage array returned \u0027) + six.text_type(ex)"},{"line_number":97,"context_line":"            msg +\u003d _(\u0027\\nData: \u0027) + repr(data)"},{"line_number":98,"context_line":"            msg +\u003d _(\u0027\\nResponse: \u0027) + repr(response.json())"},{"line_number":99,"context_line":"            LOG.exception(msg)"}],"source_content_type":"text/x-python","patch_set":2,"id":"1ac06dbe_7acf7d7f","line":96,"range":{"start_line":96,"start_character":59,"end_line":96,"end_character":76},"in_reply_to":"3ac371cc_8d024908","updated":"2016-08-21 07:52:18.000000000","message":"With LOG.error, there will be no traceback in the log, which is important for debugging.\nDoes this really matter?","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"ed47b40fadbc5fc482966af63a5fff924e8f801c","unresolved":false,"context_lines":[{"line_number":93,"context_line":"            response.raise_for_status()"},{"line_number":94,"context_line":"        except requests.HTTPError as ex:"},{"line_number":95,"context_line":"            # text_type(ex) includes http code and url"},{"line_number":96,"context_line":"            msg \u003d _(\u0027InfiniBox storage array returned \u0027) + six.text_type(ex)"},{"line_number":97,"context_line":"            msg +\u003d _(\u0027\\nData: \u0027) + repr(data)"},{"line_number":98,"context_line":"            msg +\u003d _(\u0027\\nResponse: \u0027) + repr(response.json())"},{"line_number":99,"context_line":"            LOG.exception(msg)"}],"source_content_type":"text/x-python","patch_set":2,"id":"3ac371cc_8d024908","line":96,"range":{"start_line":96,"start_character":59,"end_line":96,"end_character":76},"in_reply_to":"3ac371cc_cae0a7fd","updated":"2016-08-18 17:37:37.000000000","message":"Then please change LOG.exception to LOG.error.","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"b6ac4c2921c964b380890c6950a3400352318e38","unresolved":false,"context_lines":[{"line_number":116,"context_line":"        return self._request(\u0027PUT\u0027, uri, data)"},{"line_number":117,"context_line":""},{"line_number":118,"context_line":"    def _cleanup_wwpn(self, wwpn):"},{"line_number":119,"context_line":"        return str(wwpn).replace(\u0027:\u0027, \u0027\u0027)"},{"line_number":120,"context_line":""},{"line_number":121,"context_line":"    def _make_volume_name(self, cinder_volume):"},{"line_number":122,"context_line":"        return \u0027openstack-vol-{0}\u0027.format(cinder_volume[\u0027id\u0027])"}],"source_content_type":"text/x-python","patch_set":2,"id":"3ac371cc_4805e643","line":119,"range":{"start_line":119,"start_character":15,"end_line":119,"end_character":18},"updated":"2016-08-18 17:13:01.000000000","message":"Would wwpn ever not already be a string?","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"3d0ee331c243a3cfa59f3d5ec6cc94c52876315c","unresolved":false,"context_lines":[{"line_number":116,"context_line":"        return self._request(\u0027PUT\u0027, uri, data)"},{"line_number":117,"context_line":""},{"line_number":118,"context_line":"    def _cleanup_wwpn(self, wwpn):"},{"line_number":119,"context_line":"        return str(wwpn).replace(\u0027:\u0027, \u0027\u0027)"},{"line_number":120,"context_line":""},{"line_number":121,"context_line":"    def _make_volume_name(self, cinder_volume):"},{"line_number":122,"context_line":"        return \u0027openstack-vol-{0}\u0027.format(cinder_volume[\u0027id\u0027])"}],"source_content_type":"text/x-python","patch_set":2,"id":"1ac06dbe_5af44186","line":119,"range":{"start_line":119,"start_character":15,"end_line":119,"end_character":18},"in_reply_to":"1ac06dbe_bac9f57a","updated":"2016-11-09 09:45:43.000000000","message":"Done","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"5ae562be108313c50a1713a70be3eee627f82291","unresolved":false,"context_lines":[{"line_number":116,"context_line":"        return self._request(\u0027PUT\u0027, uri, data)"},{"line_number":117,"context_line":""},{"line_number":118,"context_line":"    def _cleanup_wwpn(self, wwpn):"},{"line_number":119,"context_line":"        return str(wwpn).replace(\u0027:\u0027, \u0027\u0027)"},{"line_number":120,"context_line":""},{"line_number":121,"context_line":"    def _make_volume_name(self, cinder_volume):"},{"line_number":122,"context_line":"        return \u0027openstack-vol-{0}\u0027.format(cinder_volume[\u0027id\u0027])"}],"source_content_type":"text/x-python","patch_set":2,"id":"3ac371cc_b9614314","line":119,"range":{"start_line":119,"start_character":15,"end_line":119,"end_character":18},"in_reply_to":"3ac371cc_4805e643","updated":"2016-08-18 19:03:37.000000000","message":"Also, if you need to convert to string, use six.text_type(). That\u0027s for python3 compatibility.","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"31edccaf2fc16af697f3c2ecd56c37061a64ba91","unresolved":false,"context_lines":[{"line_number":116,"context_line":"        return self._request(\u0027PUT\u0027, uri, data)"},{"line_number":117,"context_line":""},{"line_number":118,"context_line":"    def _cleanup_wwpn(self, wwpn):"},{"line_number":119,"context_line":"        return str(wwpn).replace(\u0027:\u0027, \u0027\u0027)"},{"line_number":120,"context_line":""},{"line_number":121,"context_line":"    def _make_volume_name(self, cinder_volume):"},{"line_number":122,"context_line":"        return \u0027openstack-vol-{0}\u0027.format(cinder_volume[\u0027id\u0027])"}],"source_content_type":"text/x-python","patch_set":2,"id":"1ac06dbe_bac9f57a","line":119,"range":{"start_line":119,"start_character":15,"end_line":119,"end_character":18},"in_reply_to":"3ac371cc_b9614314","updated":"2016-08-21 07:52:18.000000000","message":"str is compatible with Python 3. using six.text_type will make this \"unicode\" in Python 2 which is not the intention.\nI will remove this, anyway.","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"b6ac4c2921c964b380890c6950a3400352318e38","unresolved":false,"context_lines":[{"line_number":119,"context_line":"        return str(wwpn).replace(\u0027:\u0027, \u0027\u0027)"},{"line_number":120,"context_line":""},{"line_number":121,"context_line":"    def _make_volume_name(self, cinder_volume):"},{"line_number":122,"context_line":"        return \u0027openstack-vol-{0}\u0027.format(cinder_volume[\u0027id\u0027])"},{"line_number":123,"context_line":""},{"line_number":124,"context_line":"    def _make_snapshot_name(self, cinder_snapshot):"},{"line_number":125,"context_line":"        return \u0027openstack-snap-{0}\u0027.format(cinder_snapshot[\u0027id\u0027])"}],"source_content_type":"text/x-python","patch_set":2,"id":"3ac371cc_c865561e","line":122,"range":{"start_line":122,"start_character":42,"end_line":122,"end_character":61},"updated":"2016-08-18 17:13:01.000000000","message":"This should use object notation of cinder_volume.id.","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"3d0ee331c243a3cfa59f3d5ec6cc94c52876315c","unresolved":false,"context_lines":[{"line_number":119,"context_line":"        return str(wwpn).replace(\u0027:\u0027, \u0027\u0027)"},{"line_number":120,"context_line":""},{"line_number":121,"context_line":"    def _make_volume_name(self, cinder_volume):"},{"line_number":122,"context_line":"        return \u0027openstack-vol-{0}\u0027.format(cinder_volume[\u0027id\u0027])"},{"line_number":123,"context_line":""},{"line_number":124,"context_line":"    def _make_snapshot_name(self, cinder_snapshot):"},{"line_number":125,"context_line":"        return \u0027openstack-snap-{0}\u0027.format(cinder_snapshot[\u0027id\u0027])"}],"source_content_type":"text/x-python","patch_set":2,"id":"1ac06dbe_a5c43a5f","line":122,"range":{"start_line":122,"start_character":42,"end_line":122,"end_character":61},"in_reply_to":"3ac371cc_6d338df7","updated":"2016-11-09 09:45:43.000000000","message":"Done","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"ed47b40fadbc5fc482966af63a5fff924e8f801c","unresolved":false,"context_lines":[{"line_number":119,"context_line":"        return str(wwpn).replace(\u0027:\u0027, \u0027\u0027)"},{"line_number":120,"context_line":""},{"line_number":121,"context_line":"    def _make_volume_name(self, cinder_volume):"},{"line_number":122,"context_line":"        return \u0027openstack-vol-{0}\u0027.format(cinder_volume[\u0027id\u0027])"},{"line_number":123,"context_line":""},{"line_number":124,"context_line":"    def _make_snapshot_name(self, cinder_snapshot):"},{"line_number":125,"context_line":"        return \u0027openstack-snap-{0}\u0027.format(cinder_snapshot[\u0027id\u0027])"}],"source_content_type":"text/x-python","patch_set":2,"id":"3ac371cc_6d338df7","line":122,"range":{"start_line":122,"start_character":42,"end_line":122,"end_character":61},"in_reply_to":"3ac371cc_aab8cbe9","updated":"2016-08-18 17:37:37.000000000","message":"When we started switching over to passing around dicts to using objects, we added the ability to still use the dict notation. That was just a workaround while we switched things over though. Any new code should just use the object notation.","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"c6b558244e69a28c8fb9f990da2b61e67d774cb5","unresolved":false,"context_lines":[{"line_number":119,"context_line":"        return str(wwpn).replace(\u0027:\u0027, \u0027\u0027)"},{"line_number":120,"context_line":""},{"line_number":121,"context_line":"    def _make_volume_name(self, cinder_volume):"},{"line_number":122,"context_line":"        return \u0027openstack-vol-{0}\u0027.format(cinder_volume[\u0027id\u0027])"},{"line_number":123,"context_line":""},{"line_number":124,"context_line":"    def _make_snapshot_name(self, cinder_snapshot):"},{"line_number":125,"context_line":"        return \u0027openstack-snap-{0}\u0027.format(cinder_snapshot[\u0027id\u0027])"}],"source_content_type":"text/x-python","patch_set":2,"id":"3ac371cc_aab8cbe9","line":122,"range":{"start_line":122,"start_character":42,"end_line":122,"end_character":61},"in_reply_to":"3ac371cc_c865561e","updated":"2016-08-18 17:30:50.000000000","message":"Is this a requirement? Many other drivers also access the attributes using string keys, and this simplifies the testing.","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"b6ac4c2921c964b380890c6950a3400352318e38","unresolved":false,"context_lines":[{"line_number":122,"context_line":"        return \u0027openstack-vol-{0}\u0027.format(cinder_volume[\u0027id\u0027])"},{"line_number":123,"context_line":""},{"line_number":124,"context_line":"    def _make_snapshot_name(self, cinder_snapshot):"},{"line_number":125,"context_line":"        return \u0027openstack-snap-{0}\u0027.format(cinder_snapshot[\u0027id\u0027])"},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"    def _make_host_name(self, wwpn):"},{"line_number":128,"context_line":"        wwn_for_name \u003d self._cleanup_wwpn(wwpn)"}],"source_content_type":"text/x-python","patch_set":2,"id":"3ac371cc_487a06be","line":125,"range":{"start_line":125,"start_character":43,"end_line":125,"end_character":64},"updated":"2016-08-18 17:13:01.000000000","message":"Same.","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"3d0ee331c243a3cfa59f3d5ec6cc94c52876315c","unresolved":false,"context_lines":[{"line_number":122,"context_line":"        return \u0027openstack-vol-{0}\u0027.format(cinder_volume[\u0027id\u0027])"},{"line_number":123,"context_line":""},{"line_number":124,"context_line":"    def _make_snapshot_name(self, cinder_snapshot):"},{"line_number":125,"context_line":"        return \u0027openstack-snap-{0}\u0027.format(cinder_snapshot[\u0027id\u0027])"},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"    def _make_host_name(self, wwpn):"},{"line_number":128,"context_line":"        wwn_for_name \u003d self._cleanup_wwpn(wwpn)"}],"source_content_type":"text/x-python","patch_set":2,"id":"1ac06dbe_05a26eae","line":125,"range":{"start_line":125,"start_character":43,"end_line":125,"end_character":64},"in_reply_to":"3ac371cc_487a06be","updated":"2016-11-09 09:45:43.000000000","message":"Done","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"b6ac4c2921c964b380890c6950a3400352318e38","unresolved":false,"context_lines":[{"line_number":220,"context_line":"                continue"},{"line_number":221,"context_line":"            host_id \u003d infinidat_hosts[0][\u0027id\u0027]"},{"line_number":222,"context_line":"            # unmap"},{"line_number":223,"context_line":"            uri \u003d \u0027hosts/{0}/luns/volume_id/{1}\u0027.format(host_id, volume_id) + \\"},{"line_number":224,"context_line":"                  \u0027?approved\u003dtrue\u0027"},{"line_number":225,"context_line":"            self._delete(uri)"},{"line_number":226,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"3ac371cc_23388bd2","line":223,"range":{"start_line":223,"start_character":78,"end_line":223,"end_character":79},"updated":"2016-08-18 17:13:01.000000000","message":"Move the closing ) from the format call to the next line so you can avoid using \\","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"3d0ee331c243a3cfa59f3d5ec6cc94c52876315c","unresolved":false,"context_lines":[{"line_number":220,"context_line":"                continue"},{"line_number":221,"context_line":"            host_id \u003d infinidat_hosts[0][\u0027id\u0027]"},{"line_number":222,"context_line":"            # unmap"},{"line_number":223,"context_line":"            uri \u003d \u0027hosts/{0}/luns/volume_id/{1}\u0027.format(host_id, volume_id) + \\"},{"line_number":224,"context_line":"                  \u0027?approved\u003dtrue\u0027"},{"line_number":225,"context_line":"            self._delete(uri)"},{"line_number":226,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"1ac06dbe_e5a472ba","line":223,"range":{"start_line":223,"start_character":78,"end_line":223,"end_character":79},"in_reply_to":"3ac371cc_23388bd2","updated":"2016-11-09 09:45:43.000000000","message":"Done. I wrapped the lines with parentheses like the guideline suggests instead of breaking the \"format\" line, which I don\u0027t think would have made the code look better.","commit_id":"2a93abc1fdbd579d6182eb387647bc5520a9f1ae"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"5d2be3a224969c7b8cbc3602cc60ed73606dae3a","unresolved":false,"context_lines":[{"line_number":197,"context_line":"                   and port[\u0027state\u0027] \u003d\u003d \u0027OK\u0027):"},{"line_number":198,"context_line":"                    yield self._cleanup_wwpn(port[\u0027wwpn\u0027])"},{"line_number":199,"context_line":""},{"line_number":200,"context_line":"    def initialize_connection(self, volume, connector):"},{"line_number":201,"context_line":"        \"\"\"Map an InfiniBox volume to the host\"\"\""},{"line_number":202,"context_line":"        volume_name \u003d self._make_volume_name(volume)"},{"line_number":203,"context_line":"        infinidat_volume \u003d self._get_infinidat_volume_by_name(volume_name)"}],"source_content_type":"text/x-python","patch_set":4,"id":"9a629dbe_65213f9f","line":200,"updated":"2016-11-09 14:26:32.000000000","message":"Needs the FC zone manager decorators. See:\n\nhttps://github.com/openstack/cinder/blob/master/cinder/volume/drivers/dell/dell_storagecenter_fc.py#L191","commit_id":"6c20718e2da330d3321c064c6bba4794d0cd5049"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"1afab0b0f18f794dd360105c1a82118414d17ee5","unresolved":false,"context_lines":[{"line_number":197,"context_line":"                   and port[\u0027state\u0027] \u003d\u003d \u0027OK\u0027):"},{"line_number":198,"context_line":"                    yield self._cleanup_wwpn(port[\u0027wwpn\u0027])"},{"line_number":199,"context_line":""},{"line_number":200,"context_line":"    def initialize_connection(self, volume, connector):"},{"line_number":201,"context_line":"        \"\"\"Map an InfiniBox volume to the host\"\"\""},{"line_number":202,"context_line":"        volume_name \u003d self._make_volume_name(volume)"},{"line_number":203,"context_line":"        infinidat_volume \u003d self._get_infinidat_volume_by_name(volume_name)"}],"source_content_type":"text/x-python","patch_set":4,"id":"7a77a97e_20f91881","line":200,"in_reply_to":"9a629dbe_65213f9f","updated":"2016-11-21 08:24:24.000000000","message":"Done","commit_id":"6c20718e2da330d3321c064c6bba4794d0cd5049"},{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"33f27e0532d44b6ecce1c1bb9472d2f884f2879f","unresolved":false,"context_lines":[{"line_number":309,"context_line":"        clone_name \u003d self._make_volume_name(volume) + \u0027-internal\u0027"},{"line_number":310,"context_line":"        infinidat_clone \u003d self._post(\u0027volumes\u0027, dict(parent_id\u003dsnapshot_id,"},{"line_number":311,"context_line":"                                                     name\u003dclone_name))"},{"line_number":312,"context_line":"        clone \u003d mock.Mock(id\u003dstr(volume.id) + \u0027-internal\u0027)"},{"line_number":313,"context_line":"        try:"},{"line_number":314,"context_line":"            infinidat_volume \u003d self._create_volume(volume)"},{"line_number":315,"context_line":"            try:"}],"source_content_type":"text/x-python","patch_set":4,"id":"7a77a97e_db5ad629","line":312,"range":{"start_line":312,"start_character":8,"end_line":312,"end_character":58},"updated":"2016-11-17 12:14:45.000000000","message":"Why do you need this mock? Can\u0027t you pass the volume you\u0027v just created?","commit_id":"6c20718e2da330d3321c064c6bba4794d0cd5049"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"1afab0b0f18f794dd360105c1a82118414d17ee5","unresolved":false,"context_lines":[{"line_number":309,"context_line":"        clone_name \u003d self._make_volume_name(volume) + \u0027-internal\u0027"},{"line_number":310,"context_line":"        infinidat_clone \u003d self._post(\u0027volumes\u0027, dict(parent_id\u003dsnapshot_id,"},{"line_number":311,"context_line":"                                                     name\u003dclone_name))"},{"line_number":312,"context_line":"        clone \u003d mock.Mock(id\u003dstr(volume.id) + \u0027-internal\u0027)"},{"line_number":313,"context_line":"        try:"},{"line_number":314,"context_line":"            infinidat_volume \u003d self._create_volume(volume)"},{"line_number":315,"context_line":"            try:"}],"source_content_type":"text/x-python","patch_set":4,"id":"7a77a97e_9ec12c57","line":312,"range":{"start_line":312,"start_character":8,"end_line":312,"end_character":58},"in_reply_to":"7a77a97e_db5ad629","updated":"2016-11-21 08:24:24.000000000","message":"\"infinidat_clone\" (the volume I\u0027ve just created) is an infinidat volume object (it has an id but it\u0027s an internal number). \"clone\" mocks an openstack volume object, and its id (GUID + \"-internal\") is later used to calculate the expected volume name (it is the name of the object I just created, but the dicts are different)","commit_id":"6c20718e2da330d3321c064c6bba4794d0cd5049"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"13d17499479878e4981632cfcdcfee784538e550","unresolved":false,"context_lines":[{"line_number":156,"context_line":"        if len(pools) !\u003d 1:"},{"line_number":157,"context_line":"            msg \u003d _(\u0027Pool \"%s\" not found\u0027) % pool_name"},{"line_number":158,"context_line":"            LOG.error(msg)"},{"line_number":159,"context_line":"            raise exception.VolumeDriverException(msg)"},{"line_number":160,"context_line":"        return pools[0]"},{"line_number":161,"context_line":""},{"line_number":162,"context_line":"    def _get_host(self, wwpn):"}],"source_content_type":"text/x-python","patch_set":5,"id":"5a74a57a_9802903d","line":159,"updated":"2016-11-23 17:35:11.000000000","message":"message\u003dmsg","commit_id":"f96e4812de7550660fc3b3abfeb3cd55df560f93"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"b657ff1a9d22219016514beb338728589ca13f28","unresolved":false,"context_lines":[{"line_number":156,"context_line":"        if len(pools) !\u003d 1:"},{"line_number":157,"context_line":"            msg \u003d _(\u0027Pool \"%s\" not found\u0027) % pool_name"},{"line_number":158,"context_line":"            LOG.error(msg)"},{"line_number":159,"context_line":"            raise exception.VolumeDriverException(msg)"},{"line_number":160,"context_line":"        return pools[0]"},{"line_number":161,"context_line":""},{"line_number":162,"context_line":"    def _get_host(self, wwpn):"}],"source_content_type":"text/x-python","patch_set":5,"id":"5a74a57a_e6745169","line":159,"in_reply_to":"5a74a57a_9802903d","updated":"2016-11-27 16:13:36.000000000","message":"Done","commit_id":"f96e4812de7550660fc3b3abfeb3cd55df560f93"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"13d17499479878e4981632cfcdcfee784538e550","unresolved":false,"context_lines":[{"line_number":215,"context_line":"                    data\u003ddict(target_discovered\u003dFalse,"},{"line_number":216,"context_line":"                              target_wwn\u003dtarget_wwn,"},{"line_number":217,"context_line":"                              target_lun\u003dlun,"},{"line_number":218,"context_line":"                              access_mode\u003daccess_mode))"},{"line_number":219,"context_line":""},{"line_number":220,"context_line":"    @fczm_utils.RemoveFCZone"},{"line_number":221,"context_line":"    def terminate_connection(self, volume, connector, **kwargs):"}],"source_content_type":"text/x-python","patch_set":5,"id":"5a74a57a_7b492e8b","line":218,"updated":"2016-11-23 17:35:11.000000000","message":"You are not returning initiator_target_map.  Zone won\u0027t be created without that.","commit_id":"f96e4812de7550660fc3b3abfeb3cd55df560f93"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"b657ff1a9d22219016514beb338728589ca13f28","unresolved":false,"context_lines":[{"line_number":215,"context_line":"                    data\u003ddict(target_discovered\u003dFalse,"},{"line_number":216,"context_line":"                              target_wwn\u003dtarget_wwn,"},{"line_number":217,"context_line":"                              target_lun\u003dlun,"},{"line_number":218,"context_line":"                              access_mode\u003daccess_mode))"},{"line_number":219,"context_line":""},{"line_number":220,"context_line":"    @fczm_utils.RemoveFCZone"},{"line_number":221,"context_line":"    def terminate_connection(self, volume, connector, **kwargs):"}],"source_content_type":"text/x-python","patch_set":5,"id":"5a74a57a_e64d313f","line":218,"in_reply_to":"5a74a57a_7b492e8b","updated":"2016-11-27 16:13:36.000000000","message":"Done","commit_id":"f96e4812de7550660fc3b3abfeb3cd55df560f93"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"13d17499479878e4981632cfcdcfee784538e550","unresolved":false,"context_lines":[{"line_number":231,"context_line":"            # unmap"},{"line_number":232,"context_line":"            uri \u003d (\u0027hosts/{0}/luns/volume_id/{1}\u0027.format(host_id, volume_id) +"},{"line_number":233,"context_line":"                   \u0027?approved\u003dtrue\u0027)"},{"line_number":234,"context_line":"            self._delete(uri)"},{"line_number":235,"context_line":""},{"line_number":236,"context_line":"    def get_volume_stats(self, refresh\u003dFalse):"},{"line_number":237,"context_line":"        if self._volume_stats is None or refresh:"}],"source_content_type":"text/x-python","patch_set":5,"id":"5a74a57a_bb510665","line":234,"updated":"2016-11-23 17:35:11.000000000","message":"This function needs to return initiator_target_map to remove the zone.   See example below:\n\nhttps://github.com/openstack/cinder/blob/master/cinder/volume/drivers/hpe/hpe_3par_fc.py#L392","commit_id":"f96e4812de7550660fc3b3abfeb3cd55df560f93"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"b657ff1a9d22219016514beb338728589ca13f28","unresolved":false,"context_lines":[{"line_number":231,"context_line":"            # unmap"},{"line_number":232,"context_line":"            uri \u003d (\u0027hosts/{0}/luns/volume_id/{1}\u0027.format(host_id, volume_id) +"},{"line_number":233,"context_line":"                   \u0027?approved\u003dtrue\u0027)"},{"line_number":234,"context_line":"            self._delete(uri)"},{"line_number":235,"context_line":""},{"line_number":236,"context_line":"    def get_volume_stats(self, refresh\u003dFalse):"},{"line_number":237,"context_line":"        if self._volume_stats is None or refresh:"}],"source_content_type":"text/x-python","patch_set":5,"id":"5a74a57a_2b053213","line":234,"in_reply_to":"5a74a57a_bb510665","updated":"2016-11-27 16:13:36.000000000","message":"Done. The _build_initiator_target_map looks like a big boilerplate that all drivers copy around. Shouldn\u0027t there be a shared implementation?","commit_id":"f96e4812de7550660fc3b3abfeb3cd55df560f93"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"13d17499479878e4981632cfcdcfee784538e550","unresolved":false,"context_lines":[{"line_number":256,"context_line":"        data \u003d dict(pool_id\u003dpool[\u0027id\u0027],"},{"line_number":257,"context_line":"                    provtype\u003dprovtype,"},{"line_number":258,"context_line":"                    name\u003dvolume_name,"},{"line_number":259,"context_line":"                    size\u003dvolume.size * units.Gi)"},{"line_number":260,"context_line":"        return self._post(\u0027volumes\u0027, data)"},{"line_number":261,"context_line":""},{"line_number":262,"context_line":"    def create_volume(self, volume):"}],"source_content_type":"text/x-python","patch_set":5,"id":"5a74a57a_9b136a5c","line":259,"updated":"2016-11-23 17:35:11.000000000","message":"Does the driver support both thin and thick provisioning in the same pool?\n\nAlso since the driver supports thin provisioning, is there plan to add oversubscription support?","commit_id":"f96e4812de7550660fc3b3abfeb3cd55df560f93"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"b657ff1a9d22219016514beb338728589ca13f28","unresolved":false,"context_lines":[{"line_number":256,"context_line":"        data \u003d dict(pool_id\u003dpool[\u0027id\u0027],"},{"line_number":257,"context_line":"                    provtype\u003dprovtype,"},{"line_number":258,"context_line":"                    name\u003dvolume_name,"},{"line_number":259,"context_line":"                    size\u003dvolume.size * units.Gi)"},{"line_number":260,"context_line":"        return self._post(\u0027volumes\u0027, data)"},{"line_number":261,"context_line":""},{"line_number":262,"context_line":"    def create_volume(self, volume):"}],"source_content_type":"text/x-python","patch_set":5,"id":"5a74a57a_66012105","line":259,"in_reply_to":"5a74a57a_9b136a5c","updated":"2016-11-27 16:13:36.000000000","message":"Yes, we support thick and thin provisioning in the same pool.\nThere is currently no plan for oversubscription support","commit_id":"f96e4812de7550660fc3b3abfeb3cd55df560f93"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"13d17499479878e4981632cfcdcfee784538e550","unresolved":false,"context_lines":[{"line_number":312,"context_line":"        clone_name \u003d self._make_volume_name(volume) + \u0027-internal\u0027"},{"line_number":313,"context_line":"        infinidat_clone \u003d self._post(\u0027volumes\u0027, dict(parent_id\u003dsnapshot_id,"},{"line_number":314,"context_line":"                                                     name\u003dclone_name))"},{"line_number":315,"context_line":"        clone \u003d mock.Mock(id\u003dstr(volume.id) + \u0027-internal\u0027)"},{"line_number":316,"context_line":"        try:"},{"line_number":317,"context_line":"            infinidat_volume \u003d self._create_volume(volume)"},{"line_number":318,"context_line":"            try:"}],"source_content_type":"text/x-python","patch_set":5,"id":"5a74a57a_7b2bee30","line":315,"updated":"2016-11-23 17:35:11.000000000","message":"str -\u003e six.text_type\n\nWhy using mock here?","commit_id":"f96e4812de7550660fc3b3abfeb3cd55df560f93"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"b657ff1a9d22219016514beb338728589ca13f28","unresolved":false,"context_lines":[{"line_number":312,"context_line":"        clone_name \u003d self._make_volume_name(volume) + \u0027-internal\u0027"},{"line_number":313,"context_line":"        infinidat_clone \u003d self._post(\u0027volumes\u0027, dict(parent_id\u003dsnapshot_id,"},{"line_number":314,"context_line":"                                                     name\u003dclone_name))"},{"line_number":315,"context_line":"        clone \u003d mock.Mock(id\u003dstr(volume.id) + \u0027-internal\u0027)"},{"line_number":316,"context_line":"        try:"},{"line_number":317,"context_line":"            infinidat_volume \u003d self._create_volume(volume)"},{"line_number":318,"context_line":"            try:"}],"source_content_type":"text/x-python","patch_set":5,"id":"5a74a57a_86063d1b","line":315,"in_reply_to":"5a74a57a_7b2bee30","updated":"2016-11-27 16:13:36.000000000","message":"I am not using unicode anywhere so I want this to be str in both Python versions.\nThe reason for mock was explained in revision 4.","commit_id":"f96e4812de7550660fc3b3abfeb3cd55df560f93"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"885f50622266bcb23a7fa5fab509dae8325c3e0c","unresolved":false,"context_lines":[{"line_number":312,"context_line":"        clone_name \u003d self._make_volume_name(volume) + \u0027-internal\u0027"},{"line_number":313,"context_line":"        infinidat_clone \u003d self._post(\u0027volumes\u0027, dict(parent_id\u003dsnapshot_id,"},{"line_number":314,"context_line":"                                                     name\u003dclone_name))"},{"line_number":315,"context_line":"        clone \u003d mock.Mock(id\u003dstr(volume.id) + \u0027-internal\u0027)"},{"line_number":316,"context_line":"        try:"},{"line_number":317,"context_line":"            infinidat_volume \u003d self._create_volume(volume)"},{"line_number":318,"context_line":"            try:"}],"source_content_type":"text/x-python","patch_set":5,"id":"3a71b18c_857e97e2","line":315,"in_reply_to":"5a74a57a_86063d1b","updated":"2016-12-02 05:13:13.000000000","message":"Ok.  I looked at your explanation in patch set 4.  There are already two reviewers asking about this.  Please add those as comments before this line.","commit_id":"f96e4812de7550660fc3b3abfeb3cd55df560f93"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"13d17499479878e4981632cfcdcfee784538e550","unresolved":false,"context_lines":[{"line_number":327,"context_line":"                                          sparse\u003dTrue)"},{"line_number":328,"context_line":"            except Exception:"},{"line_number":329,"context_line":"                self._delete(DELETE_URI.format(infinidat_volume[\u0027id\u0027]))"},{"line_number":330,"context_line":"                raise"},{"line_number":331,"context_line":"        finally:"},{"line_number":332,"context_line":"            self._delete(DELETE_URI.format(infinidat_clone[\u0027id\u0027]))"},{"line_number":333,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"5a74a57a_3bbfb6d1","line":330,"updated":"2016-11-23 17:35:11.000000000","message":"Please raise a VolumeDriverException here.","commit_id":"f96e4812de7550660fc3b3abfeb3cd55df560f93"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"b657ff1a9d22219016514beb338728589ca13f28","unresolved":false,"context_lines":[{"line_number":327,"context_line":"                                          sparse\u003dTrue)"},{"line_number":328,"context_line":"            except Exception:"},{"line_number":329,"context_line":"                self._delete(DELETE_URI.format(infinidat_volume[\u0027id\u0027]))"},{"line_number":330,"context_line":"                raise"},{"line_number":331,"context_line":"        finally:"},{"line_number":332,"context_line":"            self._delete(DELETE_URI.format(infinidat_clone[\u0027id\u0027]))"},{"line_number":333,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"5a74a57a_46198578","line":330,"in_reply_to":"5a74a57a_3bbfb6d1","updated":"2016-11-27 16:13:36.000000000","message":"This is only a cleanup, I don\u0027t want to change the original exceptions.","commit_id":"f96e4812de7550660fc3b3abfeb3cd55df560f93"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"13d17499479878e4981632cfcdcfee784538e550","unresolved":false,"context_lines":[{"line_number":381,"context_line":"                                      sparse\u003dTrue)"},{"line_number":382,"context_line":"        except Exception:"},{"line_number":383,"context_line":"            self._delete(DELETE_URI.format(infinidat_volume[\u0027id\u0027]))"},{"line_number":384,"context_line":"            raise"}],"source_content_type":"text/x-python","patch_set":5,"id":"5a74a57a_5bd1d2cc","line":384,"updated":"2016-11-23 17:35:11.000000000","message":"Please raise VolumeDriverException.","commit_id":"f96e4812de7550660fc3b3abfeb3cd55df560f93"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"b657ff1a9d22219016514beb338728589ca13f28","unresolved":false,"context_lines":[{"line_number":381,"context_line":"                                      sparse\u003dTrue)"},{"line_number":382,"context_line":"        except Exception:"},{"line_number":383,"context_line":"            self._delete(DELETE_URI.format(infinidat_volume[\u0027id\u0027]))"},{"line_number":384,"context_line":"            raise"}],"source_content_type":"text/x-python","patch_set":5,"id":"5a74a57a_a61ed95c","line":384,"in_reply_to":"5a74a57a_5bd1d2cc","updated":"2016-11-27 16:13:36.000000000","message":"This is only a cleanup, I don\u0027t want to change the original exceptions.","commit_id":"f96e4812de7550660fc3b3abfeb3cd55df560f93"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"c82e3c87b9d66dfcc16e05fac110c722cf40b831","unresolved":false,"context_lines":[{"line_number":118,"context_line":"        return wwpn.replace(\u0027:\u0027, \u0027\u0027)"},{"line_number":119,"context_line":""},{"line_number":120,"context_line":"    def _make_volume_name(self, cinder_volume):"},{"line_number":121,"context_line":"        return \u0027openstack-vol-{0}\u0027.format(cinder_volume.id)"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"    def _make_snapshot_name(self, cinder_snapshot):"},{"line_number":124,"context_line":"        return \u0027openstack-snap-{0}\u0027.format(cinder_snapshot.id)"}],"source_content_type":"text/x-python","patch_set":7,"id":"3a71b18c_c00ebd33","line":121,"updated":"2016-12-02 05:28:13.000000000","message":"Please replace this with %(var)s format.  Please change other places too.","commit_id":"7ec20b3897e8577f746c023b186cd36f0ea15a86"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"475d09db2a420ef5e7535e962210dcf82daed3ed","unresolved":false,"context_lines":[{"line_number":118,"context_line":"        return wwpn.replace(\u0027:\u0027, \u0027\u0027)"},{"line_number":119,"context_line":""},{"line_number":120,"context_line":"    def _make_volume_name(self, cinder_volume):"},{"line_number":121,"context_line":"        return \u0027openstack-vol-{0}\u0027.format(cinder_volume.id)"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"    def _make_snapshot_name(self, cinder_snapshot):"},{"line_number":124,"context_line":"        return \u0027openstack-snap-{0}\u0027.format(cinder_snapshot.id)"}],"source_content_type":"text/x-python","patch_set":7,"id":"3a71b18c_839d6f5b","line":121,"in_reply_to":"3a71b18c_03c5df59","updated":"2016-12-04 16:06:34.000000000","message":"For i18n I understand that strings in logs/exceptions should use %-formatting (in order \"... to support automatic translations of exception and log strings\"), so I use this where relevant in this driver, and this is also the case in the comments you linked (strings that go to logs/exceptions). I prefer to keep this type of formatting here (no i18n needed).","commit_id":"7ec20b3897e8577f746c023b186cd36f0ea15a86"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"440429e61439e07a57d9e027a512eb7c6e1e72ff","unresolved":false,"context_lines":[{"line_number":118,"context_line":"        return wwpn.replace(\u0027:\u0027, \u0027\u0027)"},{"line_number":119,"context_line":""},{"line_number":120,"context_line":"    def _make_volume_name(self, cinder_volume):"},{"line_number":121,"context_line":"        return \u0027openstack-vol-{0}\u0027.format(cinder_volume.id)"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"    def _make_snapshot_name(self, cinder_snapshot):"},{"line_number":124,"context_line":"        return \u0027openstack-snap-{0}\u0027.format(cinder_snapshot.id)"}],"source_content_type":"text/x-python","patch_set":7,"id":"3a71b18c_e7c63648","line":121,"in_reply_to":"3a71b18c_c00ebd33","updated":"2016-12-04 13:03:37.000000000","message":"Is there a good reason to change this? There is nothing in the style guide about string formatting, and other drivers (Kaminario, EMC, Datera and others) are using this formatting method.","commit_id":"7ec20b3897e8577f746c023b186cd36f0ea15a86"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"bedb43bf5b48a36c35bcca3796323be74d453a5e","unresolved":false,"context_lines":[{"line_number":118,"context_line":"        return wwpn.replace(\u0027:\u0027, \u0027\u0027)"},{"line_number":119,"context_line":""},{"line_number":120,"context_line":"    def _make_volume_name(self, cinder_volume):"},{"line_number":121,"context_line":"        return \u0027openstack-vol-{0}\u0027.format(cinder_volume.id)"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"    def _make_snapshot_name(self, cinder_snapshot):"},{"line_number":124,"context_line":"        return \u0027openstack-snap-{0}\u0027.format(cinder_snapshot.id)"}],"source_content_type":"text/x-python","patch_set":7,"id":"3a71b18c_03c5df59","line":121,"in_reply_to":"3a71b18c_e7c63648","updated":"2016-12-04 15:53:41.000000000","message":"Although nothing in the style guide says \u0027{0}\u0027.format(xxx) cannot be used, the examples on strings in the hacking rules guide all use %s format.\n\nhttp://docs.openstack.org/developer/hacking/#internationalization-i18n-strings\n\nAlso this comment has been given to a few drivers during reviews:\n\nhttps://review.openstack.org/#/c/396477/7/cinder/volume/drivers/dell_emc/unity/utils.py@104\n\nhttps://review.openstack.org/#/c/399967/5/cinder/volume/drivers/open_e/iscsi.py@686","commit_id":"7ec20b3897e8577f746c023b186cd36f0ea15a86"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"c82e3c87b9d66dfcc16e05fac110c722cf40b831","unresolved":false,"context_lines":[{"line_number":210,"context_line":"                                                  infinidat_volume[\u0027id\u0027])"},{"line_number":211,"context_line":"            lun \u003d mapping[\u0027lun\u0027]"},{"line_number":212,"context_line":""},{"line_number":213,"context_line":"        access_mode \u003d \u0027ro\u0027 if infinidat_volume[\u0027write_protected\u0027] else \u0027rw\u0027"},{"line_number":214,"context_line":"        # Create initiator-target mapping."},{"line_number":215,"context_line":"        target_wwpns \u003d list(self._get_online_fc_ports())"},{"line_number":216,"context_line":"        target_wwpns, init_target_map \u003d self._build_initiator_target_map("}],"source_content_type":"text/x-python","patch_set":7,"id":"3a71b18c_00e51508","line":213,"updated":"2016-12-02 05:28:13.000000000","message":"Actually volume manager will set access_mode depends on volume_metadata.  If you set it to \u0027rw\u0027, it will prevent read only volume from working.  It is controlled from nova side.\n\nSo I suggest that you remove \"else \u0027rw\u0027\".","commit_id":"7ec20b3897e8577f746c023b186cd36f0ea15a86"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"440429e61439e07a57d9e027a512eb7c6e1e72ff","unresolved":false,"context_lines":[{"line_number":210,"context_line":"                                                  infinidat_volume[\u0027id\u0027])"},{"line_number":211,"context_line":"            lun \u003d mapping[\u0027lun\u0027]"},{"line_number":212,"context_line":""},{"line_number":213,"context_line":"        access_mode \u003d \u0027ro\u0027 if infinidat_volume[\u0027write_protected\u0027] else \u0027rw\u0027"},{"line_number":214,"context_line":"        # Create initiator-target mapping."},{"line_number":215,"context_line":"        target_wwpns \u003d list(self._get_online_fc_ports())"},{"line_number":216,"context_line":"        target_wwpns, init_target_map \u003d self._build_initiator_target_map("}],"source_content_type":"text/x-python","patch_set":7,"id":"3a71b18c_67e146d0","line":213,"in_reply_to":"3a71b18c_00e51508","updated":"2016-12-04 13:03:37.000000000","message":"I will remove \"access_mode\" from the return value. I see few vendors return this data.","commit_id":"7ec20b3897e8577f746c023b186cd36f0ea15a86"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"c82e3c87b9d66dfcc16e05fac110c722cf40b831","unresolved":false,"context_lines":[{"line_number":333,"context_line":"        clone_name \u003d self._make_volume_name(volume) + \u0027-internal\u0027"},{"line_number":334,"context_line":"        infinidat_clone \u003d self._post(\u0027volumes\u0027, dict(parent_id\u003dsnapshot_id,"},{"line_number":335,"context_line":"                                                     name\u003dclone_name))"},{"line_number":336,"context_line":"        clone \u003d mock.Mock(id\u003dstr(volume.id) + \u0027-internal\u0027)"},{"line_number":337,"context_line":"        try:"},{"line_number":338,"context_line":"            infinidat_volume \u003d self._create_volume(volume)"},{"line_number":339,"context_line":"            try:"}],"source_content_type":"text/x-python","patch_set":7,"id":"3a71b18c_80bbe5c3","line":336,"updated":"2016-12-02 05:28:13.000000000","message":"Please add a comment to explain why mock is used here.","commit_id":"7ec20b3897e8577f746c023b186cd36f0ea15a86"},{"author":{"_account_id":22683,"name":"Arnon Yaari","email":"arnony@infinidat.com","username":"arnony"},"change_message_id":"440429e61439e07a57d9e027a512eb7c6e1e72ff","unresolved":false,"context_lines":[{"line_number":333,"context_line":"        clone_name \u003d self._make_volume_name(volume) + \u0027-internal\u0027"},{"line_number":334,"context_line":"        infinidat_clone \u003d self._post(\u0027volumes\u0027, dict(parent_id\u003dsnapshot_id,"},{"line_number":335,"context_line":"                                                     name\u003dclone_name))"},{"line_number":336,"context_line":"        clone \u003d mock.Mock(id\u003dstr(volume.id) + \u0027-internal\u0027)"},{"line_number":337,"context_line":"        try:"},{"line_number":338,"context_line":"            infinidat_volume \u003d self._create_volume(volume)"},{"line_number":339,"context_line":"            try:"}],"source_content_type":"text/x-python","patch_set":7,"id":"3a71b18c_87e822b6","line":336,"in_reply_to":"3a71b18c_80bbe5c3","updated":"2016-12-04 13:03:37.000000000","message":"Done","commit_id":"7ec20b3897e8577f746c023b186cd36f0ea15a86"},{"author":{"_account_id":11904,"name":"Sean McGinnis","email":"sean.mcginnis@gmail.com","username":"SeanM"},"change_message_id":"a5d21021b7854759a2be41087cbac11b7c4d3e23","unresolved":false,"context_lines":[{"line_number":118,"context_line":"        return wwpn.replace(\u0027:\u0027, \u0027\u0027)"},{"line_number":119,"context_line":""},{"line_number":120,"context_line":"    def _make_volume_name(self, cinder_volume):"},{"line_number":121,"context_line":"        return \u0027openstack-vol-{0}\u0027.format(cinder_volume.id)"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"    def _make_snapshot_name(self, cinder_snapshot):"},{"line_number":124,"context_line":"        return \u0027openstack-snap-{0}\u0027.format(cinder_snapshot.id)"}],"source_content_type":"text/x-python","patch_set":9,"id":"3a71b18c_e4bf0aa8","line":121,"updated":"2016-12-04 22:10:35.000000000","message":"Please change string formatting style as Xing has asked to be consistent.","commit_id":"fe520fd3442eba0f7286df42f735e1267a1f86c9"}]}
