)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":2417,"name":"Ben Swartzlander","email":"ben@swartzlander.org","username":"bswartz"},"change_message_id":"4966de593ef0d96a9ddcf079c91646f6b8441111","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"[POC] Allow drivers to ask for additional share_servers"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Add new method is_share_server_suitable_for_share() to "},{"line_number":10,"context_line":"Share Driver interface. This method is executed in"},{"line_number":11,"context_line":"Share Manager on share creation step to filter existing"},{"line_number":12,"context_line":"share servers. By default, this method returns True, "}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"3acd31a7_31f9974e","line":9,"updated":"2015-04-29 17:22:12.000000000","message":"white space","commit_id":"3f9bcd3093ce15387c5644502ad1fed8241b79c3"},{"author":{"_account_id":14232,"name":"Igor Malinovskiy","email":"u.glide@gmail.com","username":"imalinovskiy"},"change_message_id":"98e15561d2e90c6dc4a62a34839cf027fab43e10","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"[POC] Allow drivers to ask for additional share_servers"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Add new method is_share_server_suitable_for_share() to "},{"line_number":10,"context_line":"Share Driver interface. This method is executed in"},{"line_number":11,"context_line":"Share Manager on share creation step to filter existing"},{"line_number":12,"context_line":"share servers. By default, this method returns True, "}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"3acd31a7_8d3a6b35","line":9,"in_reply_to":"3acd31a7_31f9974e","updated":"2015-04-30 15:23:53.000000000","message":"Done","commit_id":"3f9bcd3093ce15387c5644502ad1fed8241b79c3"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"04d92455aa07d59ce8247e716576ef50a21cf151","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     Igor Malinovskiy \u003cimalinovskiy@mirantis.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2015-05-05 10:24:42 +0000"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"[POC] Allow drivers to ask for additional share_servers"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Add new method is_share_server_suitable_for_share() to"},{"line_number":10,"context_line":"Share Driver interface. This method is executed in"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"3acd31a7_ab5a41f0","line":7,"updated":"2015-05-05 17:02:51.000000000","message":"Is \"POC\" still required? Is this commit merge-candidate? If yes, then tests are required.","commit_id":"4fbb38d8e92803b2b814935f6ffba627be5583aa"},{"author":{"_account_id":14232,"name":"Igor Malinovskiy","email":"u.glide@gmail.com","username":"imalinovskiy"},"change_message_id":"0961e819486b53d24fcb4c962cafcd83c00d6903","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     Igor Malinovskiy \u003cimalinovskiy@mirantis.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2015-05-05 10:24:42 +0000"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"[POC] Allow drivers to ask for additional share_servers"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Add new method is_share_server_suitable_for_share() to"},{"line_number":10,"context_line":"Share Driver interface. This method is executed in"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"1aca2d91_e25ea144","line":7,"in_reply_to":"3acd31a7_ab5a41f0","updated":"2015-05-06 14:53:32.000000000","message":"Done","commit_id":"4fbb38d8e92803b2b814935f6ffba627be5583aa"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"04d92455aa07d59ce8247e716576ef50a21cf151","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"[POC] Allow drivers to ask for additional share_servers"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Add new method is_share_server_suitable_for_share() to"},{"line_number":10,"context_line":"Share Driver interface. This method is executed in"},{"line_number":11,"context_line":"Share Manager on share creation step to filter existing"},{"line_number":12,"context_line":"share servers. By default, this method returns True,"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"3acd31a7_4be5ed35","line":9,"updated":"2015-05-05 17:02:51.000000000","message":"In code used name \"is_share_server_compatible_with_share\" instead of \"is_share_server_suitable_for_share\".","commit_id":"4fbb38d8e92803b2b814935f6ffba627be5583aa"},{"author":{"_account_id":15100,"name":"zhongjun","email":"jun.zhongjun2@gmail.com","username":"zhongjun2"},"change_message_id":"6243dc141b1a8d322a646eaf2b47be3da37df5ae","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"[POC] Allow drivers to ask for additional share_servers"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Add new method is_share_server_suitable_for_share() to"},{"line_number":10,"context_line":"Share Driver interface. This method is executed in"},{"line_number":11,"context_line":"Share Manager on share creation step to filter existing"},{"line_number":12,"context_line":"share servers. By default, this method returns True,"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"1aca2d91_4db91d2e","line":9,"in_reply_to":"3acd31a7_4be5ed35","updated":"2015-05-06 06:16:11.000000000","message":"+1","commit_id":"4fbb38d8e92803b2b814935f6ffba627be5583aa"},{"author":{"_account_id":14232,"name":"Igor Malinovskiy","email":"u.glide@gmail.com","username":"imalinovskiy"},"change_message_id":"0961e819486b53d24fcb4c962cafcd83c00d6903","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"[POC] Allow drivers to ask for additional share_servers"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Add new method is_share_server_suitable_for_share() to"},{"line_number":10,"context_line":"Share Driver interface. This method is executed in"},{"line_number":11,"context_line":"Share Manager on share creation step to filter existing"},{"line_number":12,"context_line":"share servers. By default, this method returns True,"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"1aca2d91_02499d8b","line":9,"in_reply_to":"3acd31a7_4be5ed35","updated":"2015-05-06 14:53:32.000000000","message":"Done","commit_id":"4fbb38d8e92803b2b814935f6ffba627be5583aa"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"04d92455aa07d59ce8247e716576ef50a21cf151","unresolved":false,"context_lines":[{"line_number":12,"context_line":"share servers. By default, this method returns True,"},{"line_number":13,"context_line":"which means that any existing share server is suitable"},{"line_number":14,"context_line":"for share creation. If this method returns False, then"},{"line_number":15,"context_line":"Share Manager starts the creation of new share server."},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"Also, this commit adds a possibility to create share"},{"line_number":18,"context_line":"from a snapshot on share server which differs from original"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"3acd31a7_6b4ae927","line":15,"updated":"2015-05-05 17:02:51.000000000","message":"Why new? If we have more than one? Try another existing one?","commit_id":"4fbb38d8e92803b2b814935f6ffba627be5583aa"},{"author":{"_account_id":14232,"name":"Igor Malinovskiy","email":"u.glide@gmail.com","username":"imalinovskiy"},"change_message_id":"0961e819486b53d24fcb4c962cafcd83c00d6903","unresolved":false,"context_lines":[{"line_number":12,"context_line":"share servers. By default, this method returns True,"},{"line_number":13,"context_line":"which means that any existing share server is suitable"},{"line_number":14,"context_line":"for share creation. If this method returns False, then"},{"line_number":15,"context_line":"Share Manager starts the creation of new share server."},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"Also, this commit adds a possibility to create share"},{"line_number":18,"context_line":"from a snapshot on share server which differs from original"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"1aca2d91_8255ad1e","line":15,"in_reply_to":"3acd31a7_6b4ae927","updated":"2015-05-06 14:53:32.000000000","message":"Done","commit_id":"4fbb38d8e92803b2b814935f6ffba627be5583aa"}],"manila/db/sqlalchemy/api.py":[{"author":{"_account_id":7652,"name":"Luis Pabón","email":"lpabon@gmail.com","username":"lpabon"},"change_message_id":"e64f2067cce191944c08afb1d50a0308af0fb2e0","unresolved":false,"context_lines":[{"line_number":2008,"context_line":"        .filter_by(share_network_id\u003dshare_net_id)\\"},{"line_number":2009,"context_line":"        .filter(models.ShareServer.status.in_("},{"line_number":2010,"context_line":"            (constants.STATUS_CREATING, constants.STATUS_ACTIVE))).all()"},{"line_number":2011,"context_line":"    if not result:"},{"line_number":2012,"context_line":"        filters_description \u003d (\u0027share_network_id is \"%(share_net_id)s\",\u0027"},{"line_number":2013,"context_line":"                               \u0027 host is \"%(host)s\" and status in\u0027"},{"line_number":2014,"context_line":"                               \u0027 \"%(status_cr)s\" or \"%(status_act)s\"\u0027) % {"}],"source_content_type":"text/x-python","patch_set":6,"id":"1aca2d91_18f34a0c","line":2011,"updated":"2015-05-06 15:37:19.000000000","message":"Just curious, why change this line?  Isn\u0027t it more explicit with the value must be None?  Is this line fixing an issue?","commit_id":"71a0844686dec42ca119dabac5b1cd868a5cd791"},{"author":{"_account_id":14232,"name":"Igor Malinovskiy","email":"u.glide@gmail.com","username":"imalinovskiy"},"change_message_id":"d6c75961b19f40c32cf8721f53fb232347dbc15b","unresolved":false,"context_lines":[{"line_number":2008,"context_line":"        .filter_by(share_network_id\u003dshare_net_id)\\"},{"line_number":2009,"context_line":"        .filter(models.ShareServer.status.in_("},{"line_number":2010,"context_line":"            (constants.STATUS_CREATING, constants.STATUS_ACTIVE))).all()"},{"line_number":2011,"context_line":"    if not result:"},{"line_number":2012,"context_line":"        filters_description \u003d (\u0027share_network_id is \"%(share_net_id)s\",\u0027"},{"line_number":2013,"context_line":"                               \u0027 host is \"%(host)s\" and status in\u0027"},{"line_number":2014,"context_line":"                               \u0027 \"%(status_cr)s\" or \"%(status_act)s\"\u0027) % {"}],"source_content_type":"text/x-python","patch_set":6,"id":"1aca2d91_1e2f91f7","line":2011,"in_reply_to":"1aca2d91_18f34a0c","updated":"2015-05-07 11:40:11.000000000","message":"Because all() method returns empty list instead of None.","commit_id":"71a0844686dec42ca119dabac5b1cd868a5cd791"}],"manila/share/driver.py":[{"author":{"_account_id":2417,"name":"Ben Swartzlander","email":"ben@swartzlander.org","username":"bswartz"},"change_message_id":"4966de593ef0d96a9ddcf079c91646f6b8441111","unresolved":false,"context_lines":[{"line_number":328,"context_line":"        if self.get_network_allocations_number():"},{"line_number":329,"context_line":"            self.network_api.deallocate_network(context, share_server_id)"},{"line_number":330,"context_line":""},{"line_number":331,"context_line":"    def is_share_server_suitable_for_share(self, context, share_server, share,"},{"line_number":332,"context_line":"                                           snapshot\u003dNone):"},{"line_number":333,"context_line":"        return True"},{"line_number":334,"context_line":""}],"source_content_type":"text/x-python","patch_set":3,"id":"3acd31a7_9154eb54","line":331,"updated":"2015-04-29 17:22:12.000000000","message":"rename this to\n\ncan_share_server_create_share()\n\nor \n\nis_share_server_compatible_with_share()\n\nI don\u0027t like the word \"suitable\" because it implies really fuzzy semantics.","commit_id":"3f9bcd3093ce15387c5644502ad1fed8241b79c3"},{"author":{"_account_id":14232,"name":"Igor Malinovskiy","email":"u.glide@gmail.com","username":"imalinovskiy"},"change_message_id":"98e15561d2e90c6dc4a62a34839cf027fab43e10","unresolved":false,"context_lines":[{"line_number":328,"context_line":"        if self.get_network_allocations_number():"},{"line_number":329,"context_line":"            self.network_api.deallocate_network(context, share_server_id)"},{"line_number":330,"context_line":""},{"line_number":331,"context_line":"    def is_share_server_suitable_for_share(self, context, share_server, share,"},{"line_number":332,"context_line":"                                           snapshot\u003dNone):"},{"line_number":333,"context_line":"        return True"},{"line_number":334,"context_line":""}],"source_content_type":"text/x-python","patch_set":3,"id":"3acd31a7_0d1e5bba","line":331,"in_reply_to":"3acd31a7_9154eb54","updated":"2015-04-30 15:23:53.000000000","message":"Done","commit_id":"3f9bcd3093ce15387c5644502ad1fed8241b79c3"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"04d92455aa07d59ce8247e716576ef50a21cf151","unresolved":false,"context_lines":[{"line_number":233,"context_line":""},{"line_number":234,"context_line":"    def create_share_from_snapshot(self, context, share, snapshot,"},{"line_number":235,"context_line":"                                   share_server\u003dNone,"},{"line_number":236,"context_line":"                                   source_share_server\u003dNone):"},{"line_number":237,"context_line":"        \"\"\"Is called to create share from snapshot.\"\"\""},{"line_number":238,"context_line":"        raise NotImplementedError()"},{"line_number":239,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"3acd31a7_6b254907","line":236,"updated":"2015-05-05 17:02:51.000000000","message":"\"source_share_server\" is unused. Why do you need it?","commit_id":"4fbb38d8e92803b2b814935f6ffba627be5583aa"},{"author":{"_account_id":14232,"name":"Igor Malinovskiy","email":"u.glide@gmail.com","username":"imalinovskiy"},"change_message_id":"0961e819486b53d24fcb4c962cafcd83c00d6903","unresolved":false,"context_lines":[{"line_number":233,"context_line":""},{"line_number":234,"context_line":"    def create_share_from_snapshot(self, context, share, snapshot,"},{"line_number":235,"context_line":"                                   share_server\u003dNone,"},{"line_number":236,"context_line":"                                   source_share_server\u003dNone):"},{"line_number":237,"context_line":"        \"\"\"Is called to create share from snapshot.\"\"\""},{"line_number":238,"context_line":"        raise NotImplementedError()"},{"line_number":239,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"1aca2d91_f9c9bdad","line":236,"in_reply_to":"3acd31a7_6b254907","updated":"2015-05-06 14:53:32.000000000","message":"Done","commit_id":"4fbb38d8e92803b2b814935f6ffba627be5583aa"},{"author":{"_account_id":15100,"name":"zhongjun","email":"jun.zhongjun2@gmail.com","username":"zhongjun2"},"change_message_id":"1fd4d81485466c9e761fe0b7e6bb8ad136d653a9","unresolved":false,"context_lines":[{"line_number":329,"context_line":""},{"line_number":330,"context_line":"    def choose_share_server_compatible_with_share(self, context, share_servers,"},{"line_number":331,"context_line":"                                                  share, snapshot\u003dNone):"},{"line_number":332,"context_line":"        \"\"\"Method that allows driver to choose share-server for provided share."},{"line_number":333,"context_line":""},{"line_number":334,"context_line":"        If compatible share-server is not found, method should return None."},{"line_number":335,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"1aca2d91_1d9445e0","line":332,"updated":"2015-05-07 02:45:19.000000000","message":"choose a share server","commit_id":"71a0844686dec42ca119dabac5b1cd868a5cd791"},{"author":{"_account_id":14232,"name":"Igor Malinovskiy","email":"u.glide@gmail.com","username":"imalinovskiy"},"change_message_id":"d6c75961b19f40c32cf8721f53fb232347dbc15b","unresolved":false,"context_lines":[{"line_number":329,"context_line":""},{"line_number":330,"context_line":"    def choose_share_server_compatible_with_share(self, context, share_servers,"},{"line_number":331,"context_line":"                                                  share, snapshot\u003dNone):"},{"line_number":332,"context_line":"        \"\"\"Method that allows driver to choose share-server for provided share."},{"line_number":333,"context_line":""},{"line_number":334,"context_line":"        If compatible share-server is not found, method should return None."},{"line_number":335,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"1aca2d91_feb61589","line":332,"in_reply_to":"1aca2d91_1d9445e0","updated":"2015-05-07 11:40:11.000000000","message":"Done","commit_id":"71a0844686dec42ca119dabac5b1cd868a5cd791"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"25de66f678528c2ab2f1c9c2c2b4e57efa0cefd6","unresolved":false,"context_lines":[{"line_number":339,"context_line":"        :param snapshot: snapshot model"},{"line_number":340,"context_line":"        :returns: share-server or None"},{"line_number":341,"context_line":"        \"\"\""},{"line_number":342,"context_line":"        return share_servers[0] if share_servers else None"},{"line_number":343,"context_line":""},{"line_number":344,"context_line":"    def setup_server(self, *args, **kwargs):"},{"line_number":345,"context_line":"        if self.driver_handles_share_servers:"}],"source_content_type":"text/x-python","patch_set":9,"id":"7a016987_8a048fc6","line":342,"updated":"2015-05-26 15:25:27.000000000","message":"We should verify here status of share server. It is very likely to have several errored share servers for share network and some correct one. In this case we can pull errored server by mistake.","commit_id":"dd737f323922cdf02d84836be86a7790878f9573"},{"author":{"_account_id":14232,"name":"Igor Malinovskiy","email":"u.glide@gmail.com","username":"imalinovskiy"},"change_message_id":"b53982335499817a1dd5b7e2e94d915621c2558e","unresolved":false,"context_lines":[{"line_number":339,"context_line":"        :param snapshot: snapshot model"},{"line_number":340,"context_line":"        :returns: share-server or None"},{"line_number":341,"context_line":"        \"\"\""},{"line_number":342,"context_line":"        return share_servers[0] if share_servers else None"},{"line_number":343,"context_line":""},{"line_number":344,"context_line":"    def setup_server(self, *args, **kwargs):"},{"line_number":345,"context_line":"        if self.driver_handles_share_servers:"}],"source_content_type":"text/x-python","patch_set":9,"id":"3afb71cf_8d804948","line":342,"in_reply_to":"7a016987_8a048fc6","updated":"2015-06-04 20:23:39.000000000","message":"Done","commit_id":"dd737f323922cdf02d84836be86a7790878f9573"},{"author":{"_account_id":14232,"name":"Igor Malinovskiy","email":"u.glide@gmail.com","username":"imalinovskiy"},"change_message_id":"4b960bbf835a34cc036a0aa60cc3972425c538aa","unresolved":false,"context_lines":[{"line_number":339,"context_line":"        :param snapshot: snapshot model"},{"line_number":340,"context_line":"        :returns: share-server or None"},{"line_number":341,"context_line":"        \"\"\""},{"line_number":342,"context_line":"        return share_servers[0] if share_servers else None"},{"line_number":343,"context_line":""},{"line_number":344,"context_line":"    def setup_server(self, *args, **kwargs):"},{"line_number":345,"context_line":"        if self.driver_handles_share_servers:"}],"source_content_type":"text/x-python","patch_set":9,"id":"7a016987_4ef7aef5","line":342,"in_reply_to":"7a016987_8a048fc6","updated":"2015-05-27 08:39:57.000000000","message":"It\u0027s possible only in case when we create share from snapshot and parent share server is not available. I will address this case in Share Manager.","commit_id":"dd737f323922cdf02d84836be86a7790878f9573"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"0c0fea6b3db41794ddf0366fb000421ce7fc475d","unresolved":false,"context_lines":[{"line_number":339,"context_line":"        :param snapshot: snapshot model"},{"line_number":340,"context_line":"        :returns: share-server or None"},{"line_number":341,"context_line":"        \"\"\""},{"line_number":342,"context_line":"        return share_servers[0] if share_servers else None"},{"line_number":343,"context_line":""},{"line_number":344,"context_line":"    def setup_server(self, *args, **kwargs):"},{"line_number":345,"context_line":"        if self.driver_handles_share_servers:"}],"source_content_type":"text/x-python","patch_set":12,"id":"fa32b979_da93a959","line":342,"updated":"2015-06-18 16:43:52.000000000","message":"This is not covered with unit tests.","commit_id":"305c66a28edde8f612c3cfffc4cdbe030ce6fe6c"},{"author":{"_account_id":14232,"name":"Igor Malinovskiy","email":"u.glide@gmail.com","username":"imalinovskiy"},"change_message_id":"5a6317bb5d52f118a3cd765cbe067d7aea55e3a4","unresolved":false,"context_lines":[{"line_number":339,"context_line":"        :param snapshot: snapshot model"},{"line_number":340,"context_line":"        :returns: share-server or None"},{"line_number":341,"context_line":"        \"\"\""},{"line_number":342,"context_line":"        return share_servers[0] if share_servers else None"},{"line_number":343,"context_line":""},{"line_number":344,"context_line":"    def setup_server(self, *args, **kwargs):"},{"line_number":345,"context_line":"        if self.driver_handles_share_servers:"}],"source_content_type":"text/x-python","patch_set":12,"id":"fa32b979_0c52e6dd","line":342,"in_reply_to":"fa32b979_da93a959","updated":"2015-06-22 08:12:04.000000000","message":"Done","commit_id":"305c66a28edde8f612c3cfffc4cdbe030ce6fe6c"}],"manila/share/manager.py":[{"author":{"_account_id":15100,"name":"zhongjun","email":"jun.zhongjun2@gmail.com","username":"zhongjun2"},"change_message_id":"cb0d4b8550a832ba199e57c2b39861a67606c753","unresolved":false,"context_lines":[{"line_number":255,"context_line":"                    }"},{"line_number":256,"context_line":"                )"},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"            LOG.debug(\"Using share_server %s for share %s\" % ("},{"line_number":259,"context_line":"                share_server[\u0027id\u0027], share[\u0027id\u0027]))"},{"line_number":260,"context_line":"            share_ref \u003d self.db.share_update("},{"line_number":261,"context_line":"                context,"}],"source_content_type":"text/x-python","patch_set":3,"id":"3acd31a7_a6031db8","line":258,"updated":"2015-04-30 03:27:53.000000000","message":"LOG.debug(\"Using %(share_server)s for %(share_id)s.\", \n\n       {\u0027share_server\u0027: share_server[\u0027id\u0027], \u0027share_id\u0027: share[\u0027id\u0027]})","commit_id":"3f9bcd3093ce15387c5644502ad1fed8241b79c3"},{"author":{"_account_id":14232,"name":"Igor Malinovskiy","email":"u.glide@gmail.com","username":"imalinovskiy"},"change_message_id":"98e15561d2e90c6dc4a62a34839cf027fab43e10","unresolved":false,"context_lines":[{"line_number":255,"context_line":"                    }"},{"line_number":256,"context_line":"                )"},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"            LOG.debug(\"Using share_server %s for share %s\" % ("},{"line_number":259,"context_line":"                share_server[\u0027id\u0027], share[\u0027id\u0027]))"},{"line_number":260,"context_line":"            share_ref \u003d self.db.share_update("},{"line_number":261,"context_line":"                context,"}],"source_content_type":"text/x-python","patch_set":3,"id":"3acd31a7_0dfadb42","line":258,"in_reply_to":"3acd31a7_a6031db8","updated":"2015-04-30 15:23:53.000000000","message":"Done","commit_id":"3f9bcd3093ce15387c5644502ad1fed8241b79c3"},{"author":{"_account_id":15100,"name":"zhongjun","email":"jun.zhongjun2@gmail.com","username":"zhongjun2"},"change_message_id":"cb0d4b8550a832ba199e57c2b39861a67606c753","unresolved":false,"context_lines":[{"line_number":264,"context_line":"            )"},{"line_number":265,"context_line":""},{"line_number":266,"context_line":"            if not exist:"},{"line_number":267,"context_line":"                # Create share server on backend with data from db"},{"line_number":268,"context_line":"                share_server \u003d self._setup_server(context, share_server)"},{"line_number":269,"context_line":"                LOG.info(_LI(\"Share server created successfully.\"))"},{"line_number":270,"context_line":"            else:"}],"source_content_type":"text/x-python","patch_set":3,"id":"3acd31a7_c6f5f983","line":267,"updated":"2015-04-30 03:27:53.000000000","message":"Add \u0027.\u0027 in the end.","commit_id":"3f9bcd3093ce15387c5644502ad1fed8241b79c3"},{"author":{"_account_id":14232,"name":"Igor Malinovskiy","email":"u.glide@gmail.com","username":"imalinovskiy"},"change_message_id":"98e15561d2e90c6dc4a62a34839cf027fab43e10","unresolved":false,"context_lines":[{"line_number":264,"context_line":"            )"},{"line_number":265,"context_line":""},{"line_number":266,"context_line":"            if not exist:"},{"line_number":267,"context_line":"                # Create share server on backend with data from db"},{"line_number":268,"context_line":"                share_server \u003d self._setup_server(context, share_server)"},{"line_number":269,"context_line":"                LOG.info(_LI(\"Share server created successfully.\"))"},{"line_number":270,"context_line":"            else:"}],"source_content_type":"text/x-python","patch_set":3,"id":"3acd31a7_4d87b3b5","line":267,"in_reply_to":"3acd31a7_c6f5f983","updated":"2015-04-30 15:23:53.000000000","message":"Done","commit_id":"3f9bcd3093ce15387c5644502ad1fed8241b79c3"},{"author":{"_account_id":7652,"name":"Luis Pabón","email":"lpabon@gmail.com","username":"lpabon"},"change_message_id":"e64f2067cce191944c08afb1d50a0308af0fb2e0","unresolved":false,"context_lines":[{"line_number":210,"context_line":"        share creation, which starts share_server creation."},{"line_number":211,"context_line":"        For this purpose used shared lock between this method and the one"},{"line_number":212,"context_line":"        with deletion of share_server."},{"line_number":213,"context_line":""},{"line_number":214,"context_line":"        :returns: dict, dict -- first value is share_server, that"},{"line_number":215,"context_line":"                  has been chosen for share schedule. Second value is"},{"line_number":216,"context_line":"                  share updated with share_server_id."}],"source_content_type":"text/x-python","patch_set":6,"id":"1aca2d91_1858eaf9","line":213,"updated":"2015-05-06 15:37:19.000000000","message":"Please add here comments on each of the parameters and how they will be used.","commit_id":"71a0844686dec42ca119dabac5b1cd868a5cd791"},{"author":{"_account_id":14232,"name":"Igor Malinovskiy","email":"u.glide@gmail.com","username":"imalinovskiy"},"change_message_id":"a4828266a01779b6fd0fb4c4b08c0e05897dc8a2","unresolved":false,"context_lines":[{"line_number":210,"context_line":"        share creation, which starts share_server creation."},{"line_number":211,"context_line":"        For this purpose used shared lock between this method and the one"},{"line_number":212,"context_line":"        with deletion of share_server."},{"line_number":213,"context_line":""},{"line_number":214,"context_line":"        :returns: dict, dict -- first value is share_server, that"},{"line_number":215,"context_line":"                  has been chosen for share schedule. Second value is"},{"line_number":216,"context_line":"                  share updated with share_server_id."}],"source_content_type":"text/x-python","patch_set":6,"id":"1aca2d91_524151a8","line":213,"in_reply_to":"1aca2d91_1858eaf9","updated":"2015-05-08 09:58:00.000000000","message":"Done","commit_id":"71a0844686dec42ca119dabac5b1cd868a5cd791"},{"author":{"_account_id":7652,"name":"Luis Pabón","email":"lpabon@gmail.com","username":"lpabon"},"change_message_id":"e64f2067cce191944c08afb1d50a0308af0fb2e0","unresolved":false,"context_lines":[{"line_number":235,"context_line":"            share_server \u003d None"},{"line_number":236,"context_line":""},{"line_number":237,"context_line":"            try:"},{"line_number":238,"context_line":"                share_server \u003d get_share_servers()"},{"line_number":239,"context_line":"            except exception.ShareServerNotFound:"},{"line_number":240,"context_line":"                if parent_share_server_id:"},{"line_number":241,"context_line":"                    with excutils.save_and_reraise_exception():"}],"source_content_type":"text/x-python","patch_set":6,"id":"1aca2d91_738dc17a","line":238,"updated":"2015-05-06 15:37:19.000000000","message":"I do not think changing the type of a variable in a scope is a good idea.  Here we have that share_server is going to be a list, but then in line 247 it is a dict.  It makes it hard to maintain and read the code.  Please update it so that the variables keep their type throughout the scope.","commit_id":"71a0844686dec42ca119dabac5b1cd868a5cd791"},{"author":{"_account_id":14232,"name":"Igor Malinovskiy","email":"u.glide@gmail.com","username":"imalinovskiy"},"change_message_id":"d6c75961b19f40c32cf8721f53fb232347dbc15b","unresolved":false,"context_lines":[{"line_number":235,"context_line":"            share_server \u003d None"},{"line_number":236,"context_line":""},{"line_number":237,"context_line":"            try:"},{"line_number":238,"context_line":"                share_server \u003d get_share_servers()"},{"line_number":239,"context_line":"            except exception.ShareServerNotFound:"},{"line_number":240,"context_line":"                if parent_share_server_id:"},{"line_number":241,"context_line":"                    with excutils.save_and_reraise_exception():"}],"source_content_type":"text/x-python","patch_set":6,"id":"1aca2d91_de159949","line":238,"in_reply_to":"1aca2d91_738dc17a","updated":"2015-05-07 11:40:11.000000000","message":"Done","commit_id":"71a0844686dec42ca119dabac5b1cd868a5cd791"},{"author":{"_account_id":7652,"name":"Luis Pabón","email":"lpabon@gmail.com","username":"lpabon"},"change_message_id":"e64f2067cce191944c08afb1d50a0308af0fb2e0","unresolved":false,"context_lines":[{"line_number":241,"context_line":"                    with excutils.save_and_reraise_exception():"},{"line_number":242,"context_line":"                        error(_LE(\"Share server %s does not exist.\"),"},{"line_number":243,"context_line":"                              parent_share_server_id)"},{"line_number":244,"context_line":""},{"line_number":245,"context_line":"            if share_server:"},{"line_number":246,"context_line":"                try:"},{"line_number":247,"context_line":"                    share_server \u003d ("}],"source_content_type":"text/x-python","patch_set":6,"id":"1aca2d91_78aa3e72","line":244,"updated":"2015-05-06 15:37:19.000000000","message":"Comment please","commit_id":"71a0844686dec42ca119dabac5b1cd868a5cd791"},{"author":{"_account_id":7652,"name":"Luis Pabón","email":"lpabon@gmail.com","username":"lpabon"},"change_message_id":"e64f2067cce191944c08afb1d50a0308af0fb2e0","unresolved":false,"context_lines":[{"line_number":246,"context_line":"                try:"},{"line_number":247,"context_line":"                    share_server \u003d ("},{"line_number":248,"context_line":"                        self.driver.choose_share_server_compatible_with_share("},{"line_number":249,"context_line":"                            context, share_server, share, snapshot\u003dsnapshot"},{"line_number":250,"context_line":"                        )"},{"line_number":251,"context_line":"                    )"},{"line_number":252,"context_line":"                except Exception as e:"}],"source_content_type":"text/x-python","patch_set":6,"id":"1aca2d91_333189a3","line":249,"updated":"2015-05-06 15:37:19.000000000","message":"At this point the driver could return any type of share_server, either an existing one, or a new one, correct?\n\nThis would override any value returned from get_share_servers().  Why not just talk to the driver first, and if the function returns None, then use get_share_servers()?","commit_id":"71a0844686dec42ca119dabac5b1cd868a5cd791"},{"author":{"_account_id":14232,"name":"Igor Malinovskiy","email":"u.glide@gmail.com","username":"imalinovskiy"},"change_message_id":"d6c75961b19f40c32cf8721f53fb232347dbc15b","unresolved":false,"context_lines":[{"line_number":246,"context_line":"                try:"},{"line_number":247,"context_line":"                    share_server \u003d ("},{"line_number":248,"context_line":"                        self.driver.choose_share_server_compatible_with_share("},{"line_number":249,"context_line":"                            context, share_server, share, snapshot\u003dsnapshot"},{"line_number":250,"context_line":"                        )"},{"line_number":251,"context_line":"                    )"},{"line_number":252,"context_line":"                except Exception as e:"}],"source_content_type":"text/x-python","patch_set":6,"id":"1aca2d91_3ec80d22","line":249,"in_reply_to":"1aca2d91_333189a3","updated":"2015-05-07 11:40:11.000000000","message":"Drivers doesn\u0027t have direct access to DB, that\u0027s why Share Manager should provide list of available share servers explicitly.","commit_id":"71a0844686dec42ca119dabac5b1cd868a5cd791"},{"author":{"_account_id":7652,"name":"Luis Pabón","email":"lpabon@gmail.com","username":"lpabon"},"change_message_id":"e64f2067cce191944c08afb1d50a0308af0fb2e0","unresolved":false,"context_lines":[{"line_number":253,"context_line":"                    with excutils.save_and_reraise_exception():"},{"line_number":254,"context_line":"                        error(_LE(\"Cannot choose compatible share-server: %s\"),"},{"line_number":255,"context_line":"                              six.text_type(e))"},{"line_number":256,"context_line":""},{"line_number":257,"context_line":"            if not share_server:"},{"line_number":258,"context_line":"                share_server \u003d self.db.share_server_create("},{"line_number":259,"context_line":"                    context,"}],"source_content_type":"text/x-python","patch_set":6,"id":"1aca2d91_58b662dd","line":256,"updated":"2015-05-06 15:37:19.000000000","message":"Comment please","commit_id":"71a0844686dec42ca119dabac5b1cd868a5cd791"},{"author":{"_account_id":15100,"name":"zhongjun","email":"jun.zhongjun2@gmail.com","username":"zhongjun2"},"change_message_id":"1fd4d81485466c9e761fe0b7e6bb8ad136d653a9","unresolved":false,"context_lines":[{"line_number":259,"context_line":"                    context,"},{"line_number":260,"context_line":"                    {"},{"line_number":261,"context_line":"                        \u0027host\u0027: self.host,"},{"line_number":262,"context_line":"                        \u0027share_network_id\u0027: share_network_id,"},{"line_number":263,"context_line":"                        \u0027status\u0027: constants.STATUS_CREATING"},{"line_number":264,"context_line":"                    }"},{"line_number":265,"context_line":"                )"}],"source_content_type":"text/x-python","patch_set":6,"id":"1aca2d91_78f8e7e5","line":262,"updated":"2015-05-07 02:45:19.000000000","message":"In line 321: if share_network_id or parent_share_server_id:\n\nSo the share_network_id value could be None. And not to judge share_network_id before executing share_server_create.","commit_id":"71a0844686dec42ca119dabac5b1cd868a5cd791"},{"author":{"_account_id":14232,"name":"Igor Malinovskiy","email":"u.glide@gmail.com","username":"imalinovskiy"},"change_message_id":"d6c75961b19f40c32cf8721f53fb232347dbc15b","unresolved":false,"context_lines":[{"line_number":259,"context_line":"                    context,"},{"line_number":260,"context_line":"                    {"},{"line_number":261,"context_line":"                        \u0027host\u0027: self.host,"},{"line_number":262,"context_line":"                        \u0027share_network_id\u0027: share_network_id,"},{"line_number":263,"context_line":"                        \u0027status\u0027: constants.STATUS_CREATING"},{"line_number":264,"context_line":"                    }"},{"line_number":265,"context_line":"                )"}],"source_content_type":"text/x-python","patch_set":6,"id":"1aca2d91_2430009e","line":262,"in_reply_to":"1aca2d91_78f8e7e5","updated":"2015-05-07 11:40:11.000000000","message":"Done","commit_id":"71a0844686dec42ca119dabac5b1cd868a5cd791"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"e4e928fb42044fac095365161e0a4ef82912fe55","unresolved":false,"context_lines":[{"line_number":287,"context_line":"                )"},{"line_number":288,"context_line":""},{"line_number":289,"context_line":"            msg \u003d \"Using share_server %(share_server)s for share %(share_id)s\""},{"line_number":290,"context_line":"            LOG.debug(msg % {"},{"line_number":291,"context_line":"                \u0027share_server\u0027: compatible_share_server[\u0027id\u0027],"},{"line_number":292,"context_line":"                \u0027share_id\u0027: share[\u0027id\u0027]"},{"line_number":293,"context_line":"            })"}],"source_content_type":"text/x-python","patch_set":8,"id":"9a0c5dc1_5e9e3e57","line":290,"updated":"2015-05-13 04:44:40.000000000","message":"% -\u003e ,","commit_id":"778d5bb1637138d985450b50c14774e506b84220"},{"author":{"_account_id":14232,"name":"Igor Malinovskiy","email":"u.glide@gmail.com","username":"imalinovskiy"},"change_message_id":"fa3852481df45d75347e3ce09ec7880d0580585e","unresolved":false,"context_lines":[{"line_number":287,"context_line":"                )"},{"line_number":288,"context_line":""},{"line_number":289,"context_line":"            msg \u003d \"Using share_server %(share_server)s for share %(share_id)s\""},{"line_number":290,"context_line":"            LOG.debug(msg % {"},{"line_number":291,"context_line":"                \u0027share_server\u0027: compatible_share_server[\u0027id\u0027],"},{"line_number":292,"context_line":"                \u0027share_id\u0027: share[\u0027id\u0027]"},{"line_number":293,"context_line":"            })"}],"source_content_type":"text/x-python","patch_set":8,"id":"9a0c5dc1_52406f56","line":290,"in_reply_to":"9a0c5dc1_5e9e3e57","updated":"2015-05-13 08:09:53.000000000","message":"Done","commit_id":"778d5bb1637138d985450b50c14774e506b84220"},{"author":{"_account_id":11047,"name":"Mark Sturdevant","email":"mark.sturdevant@ibm.com","username":"markstur"},"change_message_id":"8698a8ef378d79504be71363ad6d50893a695230","unresolved":false,"context_lines":[{"line_number":322,"context_line":"            if compatible_share_server[\u0027status\u0027] \u003d\u003d constants.STATUS_CREATING:"},{"line_number":323,"context_line":"                # Create share server on backend with data from db."},{"line_number":324,"context_line":"                available_share_servers \u003d self._setup_server("},{"line_number":325,"context_line":"                    context, compatible_share_server)"},{"line_number":326,"context_line":"                LOG.info(_LI(\"Share server created successfully.\"))"},{"line_number":327,"context_line":"            else:"},{"line_number":328,"context_line":"                LOG.info(_LI(\"Used already existed share server \""}],"source_content_type":"text/x-python","patch_set":10,"id":"3afb71cf_24646ee2","line":325,"updated":"2015-06-08 16:18:44.000000000","message":"Since share_server_get_all_by_host_and_share_net_valid includes \"CREATING\"... available_share_servers \u003d get_available_share_servers() includes \"CREATING\" and so compatible_share_server could also include a \"CREATING\" share server.  I think this _setup_server potentially sets up an existing share_server.  It looks to me like most _setup_server() implementations do a \"find or create\", but generic would actually create an additional instance.  So I think you need to distinguish here whether it is an existing share server in \"CREATING\" mode that was selected vs. on that was just created above.","commit_id":"e825f09437451941ebde99fbb503fdb636e44a56"},{"author":{"_account_id":14232,"name":"Igor Malinovskiy","email":"u.glide@gmail.com","username":"imalinovskiy"},"change_message_id":"575c6f0187f46b0ae00d6c14caf2bbf6382e8095","unresolved":false,"context_lines":[{"line_number":322,"context_line":"            if compatible_share_server[\u0027status\u0027] \u003d\u003d constants.STATUS_CREATING:"},{"line_number":323,"context_line":"                # Create share server on backend with data from db."},{"line_number":324,"context_line":"                available_share_servers \u003d self._setup_server("},{"line_number":325,"context_line":"                    context, compatible_share_server)"},{"line_number":326,"context_line":"                LOG.info(_LI(\"Share server created successfully.\"))"},{"line_number":327,"context_line":"            else:"},{"line_number":328,"context_line":"                LOG.info(_LI(\"Used already existed share server \""}],"source_content_type":"text/x-python","patch_set":10,"id":"3afb71cf_14eaa4ac","line":325,"in_reply_to":"3afb71cf_24646ee2","updated":"2015-06-09 07:18:11.000000000","message":"_setup_server() calls setup_server() method of a driver which should verify that same server doesn\u0027t exist and create a new one. The driver doesn\u0027t provide existing share server here. Furthermore with this patch driver could decide - use existing share server in \u0027creating\u0027 state or create a new one.","commit_id":"e825f09437451941ebde99fbb503fdb636e44a56"},{"author":{"_account_id":11865,"name":"Clinton Knight","email":"cknight@netapp.com","username":"cknight"},"change_message_id":"3089329f62962904d556eeeea38b67eeba77fc3b","unresolved":false,"context_lines":[{"line_number":295,"context_line":"                except Exception as e:"},{"line_number":296,"context_line":"                    with excutils.save_and_reraise_exception():"},{"line_number":297,"context_line":"                        error(_LE(\"Cannot choose compatible share-server: %s\"),"},{"line_number":298,"context_line":"                              six.text_type(e))"},{"line_number":299,"context_line":""},{"line_number":300,"context_line":"            if not compatible_share_server:"},{"line_number":301,"context_line":"                compatible_share_server \u003d self.db.share_server_create("}],"source_content_type":"text/x-python","patch_set":11,"id":"fa32b979_13516c62","line":298,"updated":"2015-06-16 17:24:56.000000000","message":"Not necessary to cast an exception being passed to _LE():\n\nhttp://docs.openstack.org/developer/oslo.i18n/guidelines.html","commit_id":"55ddab25674404cf4980f9c9749d86ac2e67022a"},{"author":{"_account_id":14232,"name":"Igor Malinovskiy","email":"u.glide@gmail.com","username":"imalinovskiy"},"change_message_id":"85b97bac31d25bc24b702a6e66f9f52224dc85f8","unresolved":false,"context_lines":[{"line_number":295,"context_line":"                except Exception as e:"},{"line_number":296,"context_line":"                    with excutils.save_and_reraise_exception():"},{"line_number":297,"context_line":"                        error(_LE(\"Cannot choose compatible share-server: %s\"),"},{"line_number":298,"context_line":"                              six.text_type(e))"},{"line_number":299,"context_line":""},{"line_number":300,"context_line":"            if not compatible_share_server:"},{"line_number":301,"context_line":"                compatible_share_server \u003d self.db.share_server_create("}],"source_content_type":"text/x-python","patch_set":11,"id":"fa32b979_5b4b662a","line":298,"in_reply_to":"fa32b979_13516c62","updated":"2015-06-17 12:15:31.000000000","message":"Thanks for the link! Done.","commit_id":"55ddab25674404cf4980f9c9749d86ac2e67022a"},{"author":{"_account_id":11865,"name":"Clinton Knight","email":"cknight@netapp.com","username":"cknight"},"change_message_id":"3089329f62962904d556eeeea38b67eeba77fc3b","unresolved":false,"context_lines":[{"line_number":325,"context_line":"                    context, compatible_share_server)"},{"line_number":326,"context_line":"                LOG.info(_LI(\"Share server created successfully.\"))"},{"line_number":327,"context_line":"            else:"},{"line_number":328,"context_line":"                LOG.info(_LI(\"Used already existed share server \""},{"line_number":329,"context_line":"                             \"\u0027%(share_server_id)s\u0027\"),"},{"line_number":330,"context_line":"                         {\u0027share_server_id\u0027: compatible_share_server[\u0027id\u0027]})"},{"line_number":331,"context_line":"            return compatible_share_server, share_ref"}],"source_content_type":"text/x-python","patch_set":11,"id":"fa32b979_737a38f3","line":328,"updated":"2015-06-16 17:24:56.000000000","message":"s/already existed/preexisting/","commit_id":"55ddab25674404cf4980f9c9749d86ac2e67022a"},{"author":{"_account_id":14232,"name":"Igor Malinovskiy","email":"u.glide@gmail.com","username":"imalinovskiy"},"change_message_id":"85b97bac31d25bc24b702a6e66f9f52224dc85f8","unresolved":false,"context_lines":[{"line_number":325,"context_line":"                    context, compatible_share_server)"},{"line_number":326,"context_line":"                LOG.info(_LI(\"Share server created successfully.\"))"},{"line_number":327,"context_line":"            else:"},{"line_number":328,"context_line":"                LOG.info(_LI(\"Used already existed share server \""},{"line_number":329,"context_line":"                             \"\u0027%(share_server_id)s\u0027\"),"},{"line_number":330,"context_line":"                         {\u0027share_server_id\u0027: compatible_share_server[\u0027id\u0027]})"},{"line_number":331,"context_line":"            return compatible_share_server, share_ref"}],"source_content_type":"text/x-python","patch_set":11,"id":"fa32b979_1b515ed8","line":328,"in_reply_to":"fa32b979_737a38f3","updated":"2015-06-17 12:15:31.000000000","message":"Done","commit_id":"55ddab25674404cf4980f9c9749d86ac2e67022a"},{"author":{"_account_id":11047,"name":"Mark Sturdevant","email":"mark.sturdevant@ibm.com","username":"markstur"},"change_message_id":"fd863dac12a99625fd52bd52d03931c913d6f2e6","unresolved":false,"context_lines":[{"line_number":268,"context_line":""},{"line_number":269,"context_line":"        def get_available_share_servers():"},{"line_number":270,"context_line":"            if parent_share_server:"},{"line_number":271,"context_line":"                return [parent_share_server]"},{"line_number":272,"context_line":"            else:"},{"line_number":273,"context_line":"                return ("},{"line_number":274,"context_line":"                    self.db.share_server_get_all_by_host_and_share_net_valid("}],"source_content_type":"text/x-python","patch_set":12,"id":"fa32b979_8f29619d","line":271,"updated":"2015-06-18 16:50:24.000000000","message":"Not sure what we\u0027d do if a share from snap was able to use a new share server and the parent one was \"full\".  You might want to use get_available... in that special case. I think you have it OK for now, though.  I\u0027m speculating.","commit_id":"305c66a28edde8f612c3cfffc4cdbe030ce6fe6c"},{"author":{"_account_id":11047,"name":"Mark Sturdevant","email":"mark.sturdevant@ibm.com","username":"markstur"},"change_message_id":"e84750dc1b13c0b4c885bdff1168452decaa9574","unresolved":false,"context_lines":[{"line_number":268,"context_line":""},{"line_number":269,"context_line":"        def get_available_share_servers():"},{"line_number":270,"context_line":"            if parent_share_server:"},{"line_number":271,"context_line":"                return [parent_share_server]"},{"line_number":272,"context_line":"            else:"},{"line_number":273,"context_line":"                return ("},{"line_number":274,"context_line":"                    self.db.share_server_get_all_by_host_and_share_net_valid("}],"source_content_type":"text/x-python","patch_set":12,"id":"fa32b979_8c25a15d","line":271,"in_reply_to":"fa32b979_48c4935e","updated":"2015-06-21 05:08:12.000000000","message":"So get_available_share_servers() returns [parent_share_server] instead of all-valid and then the driver implements choose to just create a new one anyway?  That still doesn\u0027t seem right.  I still think it is just a corner case. Not sure what to do about it.  Maybe this if/else decision should be left to the driver. Always pass in all.","commit_id":"305c66a28edde8f612c3cfffc4cdbe030ce6fe6c"},{"author":{"_account_id":14232,"name":"Igor Malinovskiy","email":"u.glide@gmail.com","username":"imalinovskiy"},"change_message_id":"5a6317bb5d52f118a3cd765cbe067d7aea55e3a4","unresolved":false,"context_lines":[{"line_number":268,"context_line":""},{"line_number":269,"context_line":"        def get_available_share_servers():"},{"line_number":270,"context_line":"            if parent_share_server:"},{"line_number":271,"context_line":"                return [parent_share_server]"},{"line_number":272,"context_line":"            else:"},{"line_number":273,"context_line":"                return ("},{"line_number":274,"context_line":"                    self.db.share_server_get_all_by_host_and_share_net_valid("}],"source_content_type":"text/x-python","patch_set":12,"id":"fa32b979_09b6583d","line":271,"in_reply_to":"fa32b979_8c25a15d","updated":"2015-06-22 08:12:04.000000000","message":"I agree, it\u0027s a corner case. We will be able to address it in future if some drivers require it.","commit_id":"305c66a28edde8f612c3cfffc4cdbe030ce6fe6c"},{"author":{"_account_id":14232,"name":"Igor Malinovskiy","email":"u.glide@gmail.com","username":"imalinovskiy"},"change_message_id":"a2124937cee211d62b6ea951f4b1444ef28d70c9","unresolved":false,"context_lines":[{"line_number":268,"context_line":""},{"line_number":269,"context_line":"        def get_available_share_servers():"},{"line_number":270,"context_line":"            if parent_share_server:"},{"line_number":271,"context_line":"                return [parent_share_server]"},{"line_number":272,"context_line":"            else:"},{"line_number":273,"context_line":"                return ("},{"line_number":274,"context_line":"                    self.db.share_server_get_all_by_host_and_share_net_valid("}],"source_content_type":"text/x-python","patch_set":12,"id":"fa32b979_48c4935e","line":271,"in_reply_to":"fa32b979_8f29619d","updated":"2015-06-19 08:50:02.000000000","message":"In that case, driver is able to create new share server.","commit_id":"305c66a28edde8f612c3cfffc4cdbe030ce6fe6c"}],"manila/tests/test_db.py":[{"author":{"_account_id":11865,"name":"Clinton Knight","email":"cknight@netapp.com","username":"cknight"},"change_message_id":"3089329f62962904d556eeeea38b67eeba77fc3b","unresolved":false,"context_lines":[{"line_number":104,"context_line":"        self.assertRaises(exception.ShareServerNotFound,"},{"line_number":105,"context_line":"                          db.share_server_update,"},{"line_number":106,"context_line":"                          self.ctxt, fake_id, {})"},{"line_number":107,"context_line":""},{"line_number":108,"context_line":"    def test_share_server_get_by_host_and_share_net_valid(self):"},{"line_number":109,"context_line":"        valid \u003d {"},{"line_number":110,"context_line":"            \u0027share_network_id\u0027: \u00271\u0027,"}],"source_content_type":"text/x-python","patch_set":11,"id":"fa32b979_5e393b40","line":107,"updated":"2015-06-16 17:24:56.000000000","message":"Wouldn\u0027t you rename this method to match the change in the method being tested?","commit_id":"55ddab25674404cf4980f9c9749d86ac2e67022a"},{"author":{"_account_id":14232,"name":"Igor Malinovskiy","email":"u.glide@gmail.com","username":"imalinovskiy"},"change_message_id":"85b97bac31d25bc24b702a6e66f9f52224dc85f8","unresolved":false,"context_lines":[{"line_number":104,"context_line":"        self.assertRaises(exception.ShareServerNotFound,"},{"line_number":105,"context_line":"                          db.share_server_update,"},{"line_number":106,"context_line":"                          self.ctxt, fake_id, {})"},{"line_number":107,"context_line":""},{"line_number":108,"context_line":"    def test_share_server_get_by_host_and_share_net_valid(self):"},{"line_number":109,"context_line":"        valid \u003d {"},{"line_number":110,"context_line":"            \u0027share_network_id\u0027: \u00271\u0027,"}],"source_content_type":"text/x-python","patch_set":11,"id":"fa32b979_9b5b2ef6","line":107,"in_reply_to":"fa32b979_5e393b40","updated":"2015-06-17 12:15:31.000000000","message":"Done","commit_id":"55ddab25674404cf4980f9c9749d86ac2e67022a"},{"author":{"_account_id":11865,"name":"Clinton Knight","email":"cknight@netapp.com","username":"cknight"},"change_message_id":"3089329f62962904d556eeeea38b67eeba77fc3b","unresolved":false,"context_lines":[{"line_number":131,"context_line":"            share_net_id\u003d\u00271\u0027)"},{"line_number":132,"context_line":"        self.assertEqual(servers[0][\u0027id\u0027], valid[\u0027id\u0027])"},{"line_number":133,"context_line":""},{"line_number":134,"context_line":"    def test_share_server_get_by_host_and_share_net_not_found(self):"},{"line_number":135,"context_line":"        self.assertRaises(exception.ShareServerNotFound,"},{"line_number":136,"context_line":"                          db.share_server_get_all_by_host_and_share_net_valid,"},{"line_number":137,"context_line":"                          self.ctxt, host\u003d\u0027fake\u0027, share_net_id\u003d\u0027fake\u0027)"}],"source_content_type":"text/x-python","patch_set":11,"id":"fa32b979_1e3c132e","line":134,"updated":"2015-06-16 17:24:56.000000000","message":"Same.","commit_id":"55ddab25674404cf4980f9c9749d86ac2e67022a"},{"author":{"_account_id":14232,"name":"Igor Malinovskiy","email":"u.glide@gmail.com","username":"imalinovskiy"},"change_message_id":"85b97bac31d25bc24b702a6e66f9f52224dc85f8","unresolved":false,"context_lines":[{"line_number":131,"context_line":"            share_net_id\u003d\u00271\u0027)"},{"line_number":132,"context_line":"        self.assertEqual(servers[0][\u0027id\u0027], valid[\u0027id\u0027])"},{"line_number":133,"context_line":""},{"line_number":134,"context_line":"    def test_share_server_get_by_host_and_share_net_not_found(self):"},{"line_number":135,"context_line":"        self.assertRaises(exception.ShareServerNotFound,"},{"line_number":136,"context_line":"                          db.share_server_get_all_by_host_and_share_net_valid,"},{"line_number":137,"context_line":"                          self.ctxt, host\u003d\u0027fake\u0027, share_net_id\u003d\u0027fake\u0027)"}],"source_content_type":"text/x-python","patch_set":11,"id":"fa32b979_3b754263","line":134,"in_reply_to":"fa32b979_1e3c132e","updated":"2015-06-17 12:15:31.000000000","message":"Done","commit_id":"55ddab25674404cf4980f9c9749d86ac2e67022a"}]}
