)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"b8796654d6d211b5f090775528313ec7b2ae6ec8","unresolved":false,"context_lines":[{"line_number":29,"context_line":"added to the API response for /share-instances."},{"line_number":30,"context_line":"Also, deletion of a share that has replicas is forbidden,"},{"line_number":31,"context_line":"returning error code 403."},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"Co-Authored-By: Alex Meade \u003cmr.alex.meade@gmail.com\u003e"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"Implements: blueprint manila-share-replication"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":31,"id":"3a57f1b5_03f928c7","line":32,"updated":"2016-02-11 19:39:59.000000000","message":"This patch set will also need a DocImpact tag as we\u0027re adding new functionality that will need to be documented.","commit_id":"1135ed7a36ee404494639b22831263ba02ea9087"}],"manila/api/openstack/rest_api_version_history.rst":[{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"d1755246f54a6f982803dacf1b62917e2a30f9ac","unresolved":false,"context_lines":[{"line_number":83,"context_line":"2.11"},{"line_number":84,"context_line":"----"},{"line_number":85,"context_line":"  Share Replication support added. Share APIs return two new attributes:"},{"line_number":86,"context_line":"  \u0027has_replicas\u0027 and \u0027replication_type\u0027. Share instance APIs return a new"},{"line_number":87,"context_line":"  attribute, \u0027replica_state\u0027."}],"source_content_type":"text/x-rst","patch_set":23,"id":"7a5de9d1_18129c57","line":87,"range":{"start_line":86,"start_character":41,"end_line":87,"end_character":28},"updated":"2016-02-01 17:38:54.000000000","message":"I don\u0027t see such change in the code.","commit_id":"08799ad6674f3bd54a1fd9984ad78dbd8e862a93"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"46d881f3f99c89564e0743a1e2b74cef64d9d07f","unresolved":false,"context_lines":[{"line_number":83,"context_line":"2.11"},{"line_number":84,"context_line":"----"},{"line_number":85,"context_line":"  Share Replication support added. Share APIs return two new attributes:"},{"line_number":86,"context_line":"  \u0027has_replicas\u0027 and \u0027replication_type\u0027. Share instance APIs return a new"},{"line_number":87,"context_line":"  attribute, \u0027replica_state\u0027."}],"source_content_type":"text/x-rst","patch_set":23,"id":"7a5de9d1_906bb2b6","line":87,"range":{"start_line":86,"start_character":41,"end_line":87,"end_character":28},"in_reply_to":"7a5de9d1_18129c57","updated":"2016-02-02 02:45:12.000000000","message":"Thanks! done.","commit_id":"08799ad6674f3bd54a1fd9984ad78dbd8e862a93"},{"author":{"_account_id":7102,"name":"Thomas Bechtold","email":"thomas.bechtold@chainguard.dev","username":"toabctl"},"change_message_id":"bb9a313dac4f6947e609d11a31cee5f12ba014a4","unresolved":false,"context_lines":[{"line_number":81,"context_line":""},{"line_number":82,"context_line":"2.11"},{"line_number":83,"context_line":"----"},{"line_number":84,"context_line":"  Share Replication support added. Share APIs return two new attributes:"},{"line_number":85,"context_line":"  \u0027has_replicas\u0027 and \u0027replication_type\u0027. Share instance APIs return a new"},{"line_number":86,"context_line":"  attribute, \u0027replica_state\u0027."}],"source_content_type":"text/x-rst","patch_set":26,"id":"5a5ae5dd_cadefa6c","line":84,"updated":"2016-02-04 07:26:14.000000000","message":"Not sure, but should we mention that it\u0027s experimental (so the experimental header is needed when you want use it) ?","commit_id":"08e8c095b09c875b4940a292067029e9e2fc9065"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"95ff3f899fc56904d8ef54c3fe5171211ff0a5ca","unresolved":false,"context_lines":[{"line_number":81,"context_line":""},{"line_number":82,"context_line":"2.11"},{"line_number":83,"context_line":"----"},{"line_number":84,"context_line":"  Share Replication support added. Share APIs return two new attributes:"},{"line_number":85,"context_line":"  \u0027has_replicas\u0027 and \u0027replication_type\u0027. Share instance APIs return a new"},{"line_number":86,"context_line":"  attribute, \u0027replica_state\u0027."}],"source_content_type":"text/x-rst","patch_set":26,"id":"5a5ae5dd_ae35a9da","line":84,"in_reply_to":"5a5ae5dd_cadefa6c","updated":"2016-02-07 16:24:09.000000000","message":"Done","commit_id":"08e8c095b09c875b4940a292067029e9e2fc9065"}],"manila/api/openstack/wsgi.py":[{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"7a6638d6f2d08c50908d44eb13264466627f6118","unresolved":false,"context_lines":[{"line_number":1112,"context_line":"        return decorator"},{"line_number":1113,"context_line":""},{"line_number":1114,"context_line":"    @staticmethod"},{"line_number":1115,"context_line":"    def authorize(arg):"},{"line_number":1116,"context_line":"        \"\"\"Decorator for checking the policy on API methods."},{"line_number":1117,"context_line":""},{"line_number":1118,"context_line":"        Add this decorator to any API method which takes a request object"}],"source_content_type":"text/x-python","patch_set":1,"id":"da85f559_c96bc7ef","line":1115,"updated":"2015-11-12 16:08:44.000000000","message":"Please, split this to another commit and all related usages of this func.","commit_id":"dac7938116cfdbee468b3fbdfe42a3ab397fd347"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1d44846ad1c530ff7c7ed1dcf4ce2265bb331768","unresolved":false,"context_lines":[{"line_number":1112,"context_line":"        return decorator"},{"line_number":1113,"context_line":""},{"line_number":1114,"context_line":"    @staticmethod"},{"line_number":1115,"context_line":"    def authorize(arg):"},{"line_number":1116,"context_line":"        \"\"\"Decorator for checking the policy on API methods."},{"line_number":1117,"context_line":""},{"line_number":1118,"context_line":"        Add this decorator to any API method which takes a request object"}],"source_content_type":"text/x-python","patch_set":1,"id":"da85f559_4f459240","line":1115,"in_reply_to":"da85f559_c96bc7ef","updated":"2015-11-19 19:44:49.000000000","message":"Sure thing. I opened a bug just to do that. Thanks!\n\nhttps://bugs.launchpad.net/manila/+bug/1515397\n\nhttps://review.openstack.org/#/c/246555/","commit_id":"dac7938116cfdbee468b3fbdfe42a3ab397fd347"}],"manila/api/v1/share_instances.py":[{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":33,"context_line":"        super(ShareInstancesController, self).__init__()"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"    @wsgi.Controller.api_version(\"2.3\")"},{"line_number":36,"context_line":"    @wsgi.Controller.authorize"},{"line_number":37,"context_line":"    def index(self, req):"},{"line_number":38,"context_line":"        context \u003d req.environ[\u0027manila.context\u0027]"},{"line_number":39,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_0548992c","line":36,"updated":"2015-11-13 20:26:31.000000000","message":"The old code uses \u0027index\u0027 in the self.authorize() call. Does the decorator here need the same?","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":33,"context_line":"        super(ShareInstancesController, self).__init__()"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"    @wsgi.Controller.api_version(\"2.3\")"},{"line_number":36,"context_line":"    @wsgi.Controller.authorize"},{"line_number":37,"context_line":"    def index(self, req):"},{"line_number":38,"context_line":"        context \u003d req.environ[\u0027manila.context\u0027]"},{"line_number":39,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_8fbb55c4","line":36,"in_reply_to":"da85f559_0548992c","updated":"2015-11-19 19:45:53.000000000","message":"Nah, the good thing about the decorator is it can be used like this if the function name is the one we\u0027re doing the policy check on. \n\nFor now reverting this change.. hoping https://review.openstack.org/#/c/246555/ merges","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"}],"manila/api/v1/share_replicas.py":[{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"7a6638d6f2d08c50908d44eb13264466627f6118","unresolved":false,"context_lines":[{"line_number":154,"context_line":"        active_replicas \u003d list(filter("},{"line_number":155,"context_line":"            lambda x: x[\u0027replica_state\u0027] \u003d\u003d constants.REPLICA_STATE_ACTIVE,"},{"line_number":156,"context_line":"            replicas))"},{"line_number":157,"context_line":"        if(replica.get(\u0027replica_state\u0027) \u003d\u003d constants.REPLICA_STATE_ACTIVE"},{"line_number":158,"context_line":"           and len(active_replicas) \u003d\u003d 1):"},{"line_number":159,"context_line":"            msg \u003d _(\"Cannot delete last active replica.\")"},{"line_number":160,"context_line":"            raise exc.HTTPBadRequest(explanation\u003dmsg)"}],"source_content_type":"text/x-python","patch_set":1,"id":"da85f559_69297b9a","line":157,"updated":"2015-11-12 16:08:44.000000000","message":"I wonder how pep did pass here... Should be \"space\" after \"if\".","commit_id":"dac7938116cfdbee468b3fbdfe42a3ab397fd347"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1d44846ad1c530ff7c7ed1dcf4ce2265bb331768","unresolved":false,"context_lines":[{"line_number":154,"context_line":"        active_replicas \u003d list(filter("},{"line_number":155,"context_line":"            lambda x: x[\u0027replica_state\u0027] \u003d\u003d constants.REPLICA_STATE_ACTIVE,"},{"line_number":156,"context_line":"            replicas))"},{"line_number":157,"context_line":"        if(replica.get(\u0027replica_state\u0027) \u003d\u003d constants.REPLICA_STATE_ACTIVE"},{"line_number":158,"context_line":"           and len(active_replicas) \u003d\u003d 1):"},{"line_number":159,"context_line":"            msg \u003d _(\"Cannot delete last active replica.\")"},{"line_number":160,"context_line":"            raise exc.HTTPBadRequest(explanation\u003dmsg)"}],"source_content_type":"text/x-python","patch_set":1,"id":"ba8a016a_cc540056","line":157,"in_reply_to":"da85f559_69297b9a","updated":"2015-11-19 19:44:49.000000000","message":"Done","commit_id":"dac7938116cfdbee468b3fbdfe42a3ab397fd347"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"7a6638d6f2d08c50908d44eb13264466627f6118","unresolved":false,"context_lines":[{"line_number":169,"context_line":"        return webob.Response(status_int\u003d202)"},{"line_number":170,"context_line":""},{"line_number":171,"context_line":"    @wsgi.Controller.api_version(API_VERSION, experimental\u003dTrue)"},{"line_number":172,"context_line":"    @wsgi.action(\u0027os-promote_replica\u0027)"},{"line_number":173,"context_line":"    @wsgi.Controller.authorize"},{"line_number":174,"context_line":"    def promote(self, req, id, body):"},{"line_number":175,"context_line":"        \"\"\"Promote a replica to active state.\"\"\""}],"source_content_type":"text/x-python","patch_set":1,"id":"da85f559_ac38d1d3","line":172,"updated":"2015-11-12 16:08:44.000000000","message":"It is not extension. So it should be without \"os-\" prefix.","commit_id":"dac7938116cfdbee468b3fbdfe42a3ab397fd347"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1d44846ad1c530ff7c7ed1dcf4ce2265bb331768","unresolved":false,"context_lines":[{"line_number":169,"context_line":"        return webob.Response(status_int\u003d202)"},{"line_number":170,"context_line":""},{"line_number":171,"context_line":"    @wsgi.Controller.api_version(API_VERSION, experimental\u003dTrue)"},{"line_number":172,"context_line":"    @wsgi.action(\u0027os-promote_replica\u0027)"},{"line_number":173,"context_line":"    @wsgi.Controller.authorize"},{"line_number":174,"context_line":"    def promote(self, req, id, body):"},{"line_number":175,"context_line":"        \"\"\"Promote a replica to active state.\"\"\""}],"source_content_type":"text/x-python","patch_set":1,"id":"ba8a016a_ec51c463","line":172,"in_reply_to":"da85f559_ac38d1d3","updated":"2015-11-19 19:44:49.000000000","message":"Thanks. Will change this and update the design. Why would extensions need the os- prefix?","commit_id":"dac7938116cfdbee468b3fbdfe42a3ab397fd347"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"7a6638d6f2d08c50908d44eb13264466627f6118","unresolved":false,"context_lines":[{"line_number":187,"context_line":"            return webob.Response(status_int\u003d200)"},{"line_number":188,"context_line":""},{"line_number":189,"context_line":"        if replica.get(\u0027status\u0027) !\u003d constants.STATUS_AVAILABLE:"},{"line_number":190,"context_line":"            msg \u003d _(\"Replica %s must be in \u0027available\u0027 state to be \""},{"line_number":191,"context_line":"                    \"promoted.\")"},{"line_number":192,"context_line":"            raise exc.HTTPBadRequest(explanation\u003dmsg % id)"},{"line_number":193,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"da85f559_4c8fe574","line":190,"updated":"2015-11-12 16:08:44.000000000","message":"Message should use substitution for value of status -\u003e constants.STATUS_AVAILABLE","commit_id":"dac7938116cfdbee468b3fbdfe42a3ab397fd347"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1d44846ad1c530ff7c7ed1dcf4ce2265bb331768","unresolved":false,"context_lines":[{"line_number":187,"context_line":"            return webob.Response(status_int\u003d200)"},{"line_number":188,"context_line":""},{"line_number":189,"context_line":"        if replica.get(\u0027status\u0027) !\u003d constants.STATUS_AVAILABLE:"},{"line_number":190,"context_line":"            msg \u003d _(\"Replica %s must be in \u0027available\u0027 state to be \""},{"line_number":191,"context_line":"                    \"promoted.\")"},{"line_number":192,"context_line":"            raise exc.HTTPBadRequest(explanation\u003dmsg % id)"},{"line_number":193,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"ba8a016a_ac7e5cac","line":190,"in_reply_to":"da85f559_4c8fe574","updated":"2015-11-19 19:44:49.000000000","message":"Done","commit_id":"dac7938116cfdbee468b3fbdfe42a3ab397fd347"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"7a6638d6f2d08c50908d44eb13264466627f6118","unresolved":false,"context_lines":[{"line_number":191,"context_line":"                    \"promoted.\")"},{"line_number":192,"context_line":"            raise exc.HTTPBadRequest(explanation\u003dmsg % id)"},{"line_number":193,"context_line":""},{"line_number":194,"context_line":"        if (replica_state in [constants.REPLICA_STATE_OUT_OF_SYNC,"},{"line_number":195,"context_line":"                              constants.STATUS_ERROR]"},{"line_number":196,"context_line":"                and not context.is_admin):"},{"line_number":197,"context_line":"            msg \u003d _(\"Promoting an replica with \u0027replica_state\u0027: %s requires \""}],"source_content_type":"text/x-python","patch_set":1,"id":"da85f559_2cd94157","line":194,"updated":"2015-11-12 16:08:44.000000000","message":"Use tuple for cases when you do not need list-specific methods. Tuple is 10 times faster than list.","commit_id":"dac7938116cfdbee468b3fbdfe42a3ab397fd347"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1d44846ad1c530ff7c7ed1dcf4ce2265bb331768","unresolved":false,"context_lines":[{"line_number":191,"context_line":"                    \"promoted.\")"},{"line_number":192,"context_line":"            raise exc.HTTPBadRequest(explanation\u003dmsg % id)"},{"line_number":193,"context_line":""},{"line_number":194,"context_line":"        if (replica_state in [constants.REPLICA_STATE_OUT_OF_SYNC,"},{"line_number":195,"context_line":"                              constants.STATUS_ERROR]"},{"line_number":196,"context_line":"                and not context.is_admin):"},{"line_number":197,"context_line":"            msg \u003d _(\"Promoting an replica with \u0027replica_state\u0027: %s requires \""}],"source_content_type":"text/x-python","patch_set":1,"id":"ba8a016a_4c4a5085","line":194,"in_reply_to":"da85f559_2cd94157","updated":"2015-11-19 19:44:49.000000000","message":"Done","commit_id":"dac7938116cfdbee468b3fbdfe42a3ab397fd347"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":32,"context_line":""},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"LOG \u003d log.getLogger(__name__)"},{"line_number":35,"context_line":"API_VERSION \u003d \u00272.7\u0027"},{"line_number":36,"context_line":""},{"line_number":37,"context_line":""},{"line_number":38,"context_line":"class ShareReplicationController(wsgi.Controller):"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_a5e42dac","line":35,"updated":"2015-11-13 20:26:31.000000000","message":"What\u0027s the context of this API_VERSION constant here? Is it a minimum value, a maximum value, or a current value?","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":32,"context_line":""},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"LOG \u003d log.getLogger(__name__)"},{"line_number":35,"context_line":"API_VERSION \u003d \u00272.7\u0027"},{"line_number":36,"context_line":""},{"line_number":37,"context_line":""},{"line_number":38,"context_line":"class ShareReplicationController(wsgi.Controller):"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_0ff6858f","line":35,"in_reply_to":"da85f559_a5e42dac","updated":"2015-11-19 19:45:53.000000000","message":"Current Value.. It\u0027s just pulled up so its easier to know what API micro version is required to use this feature.\n\nAlso, its up here so that it is easy to switch the API_VERSION for share_replicas if required. Many more features may beat this one to the merge race..","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":14567,"name":"Rodrigo Barbieri","email":"rodrigo.barbieri2010@gmail.com","username":"ganso"},"change_message_id":"fe76a9113ae4d5b83e057a5813d735652531929d","unresolved":false,"context_lines":[{"line_number":125,"context_line":"            msg \u003d _(\"Replication not supported for share %s.\")"},{"line_number":126,"context_line":"            raise exc.HTTPBadRequest(explanation\u003dmsg % share_id)"},{"line_number":127,"context_line":""},{"line_number":128,"context_line":"        if share_ref.get(\u0027task_state\u0027) in constants.BUSY_TASK_STATES:"},{"line_number":129,"context_line":"            msg \u003d _(\"Share %s is migrating. Replica cannot be created.\")"},{"line_number":130,"context_line":"            raise exc.HTTPBadRequest(explanation\u003dmsg % share_id)"},{"line_number":131,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_dced95f0","line":128,"updated":"2015-11-13 13:37:11.000000000","message":"I am not sure if this type of check (and some others) should be performed here... I believe this layer should only parse and validate HTTP headers and pass the parameters to share/api.py for further validation... but well, this may be debatable.","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":125,"context_line":"            msg \u003d _(\"Replication not supported for share %s.\")"},{"line_number":126,"context_line":"            raise exc.HTTPBadRequest(explanation\u003dmsg % share_id)"},{"line_number":127,"context_line":""},{"line_number":128,"context_line":"        if share_ref.get(\u0027task_state\u0027) in constants.BUSY_TASK_STATES:"},{"line_number":129,"context_line":"            msg \u003d _(\"Share %s is migrating. Replica cannot be created.\")"},{"line_number":130,"context_line":"            raise exc.HTTPBadRequest(explanation\u003dmsg % share_id)"},{"line_number":131,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_40a9afde","line":128,"in_reply_to":"da85f559_dced95f0","updated":"2015-11-13 20:26:31.000000000","message":"I\u0027m on board with Rodrigo\u0027s sentiment here. I feel like this level should do  basic input validation and then the state-based validation should be done in the share/api.py layer.","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":125,"context_line":"            msg \u003d _(\"Replication not supported for share %s.\")"},{"line_number":126,"context_line":"            raise exc.HTTPBadRequest(explanation\u003dmsg % share_id)"},{"line_number":127,"context_line":""},{"line_number":128,"context_line":"        if share_ref.get(\u0027task_state\u0027) in constants.BUSY_TASK_STATES:"},{"line_number":129,"context_line":"            msg \u003d _(\"Share %s is migrating. Replica cannot be created.\")"},{"line_number":130,"context_line":"            raise exc.HTTPBadRequest(explanation\u003dmsg % share_id)"},{"line_number":131,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_b6d78dec","line":128,"in_reply_to":"da85f559_dced95f0","updated":"2015-11-19 19:45:53.000000000","message":"Thanks! Many APIs in this layer perform similar checks, so I\u0027ve no opinion on this. I\u0027ll move these checks out to the share/api.py layer like you guys suggested.","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":142,"context_line":""},{"line_number":143,"context_line":"    @wsgi.Controller.api_version(API_VERSION, experimental\u003dTrue)"},{"line_number":144,"context_line":"    @wsgi.Controller.authorize"},{"line_number":145,"context_line":"    def delete(self, req, id):"},{"line_number":146,"context_line":"        \"\"\"Delete a replica.\"\"\""},{"line_number":147,"context_line":"        context \u003d req.environ[\u0027manila.context\u0027]"},{"line_number":148,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_a08f3b74","line":145,"updated":"2015-11-13 20:26:31.000000000","message":"s/id/replica_id","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":142,"context_line":""},{"line_number":143,"context_line":"    @wsgi.Controller.api_version(API_VERSION, experimental\u003dTrue)"},{"line_number":144,"context_line":"    @wsgi.Controller.authorize"},{"line_number":145,"context_line":"    def delete(self, req, id):"},{"line_number":146,"context_line":"        \"\"\"Delete a replica.\"\"\""},{"line_number":147,"context_line":"        context \u003d req.environ[\u0027manila.context\u0027]"},{"line_number":148,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_217a7825","line":145,"in_reply_to":"da85f559_a08f3b74","updated":"2015-11-19 19:45:53.000000000","message":"The Controller expects an \u0027id\u0027 attribute. Its some magic coming down from webob.Request into wsgi.py\u0027s Controller.","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":175,"context_line":"    @wsgi.Controller.api_version(API_VERSION, experimental\u003dTrue)"},{"line_number":176,"context_line":"    @wsgi.action(\u0027os-promote_replica\u0027)"},{"line_number":177,"context_line":"    @wsgi.Controller.authorize"},{"line_number":178,"context_line":"    def promote(self, req, id, body):"},{"line_number":179,"context_line":"        \"\"\"Promote a replica to active state.\"\"\""},{"line_number":180,"context_line":"        context \u003d req.environ[\u0027manila.context\u0027]"},{"line_number":181,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_20afcb7e","line":178,"updated":"2015-11-13 20:26:31.000000000","message":"s/id/replica_id","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":175,"context_line":"    @wsgi.Controller.api_version(API_VERSION, experimental\u003dTrue)"},{"line_number":176,"context_line":"    @wsgi.action(\u0027os-promote_replica\u0027)"},{"line_number":177,"context_line":"    @wsgi.Controller.authorize"},{"line_number":178,"context_line":"    def promote(self, req, id, body):"},{"line_number":179,"context_line":"        \"\"\"Promote a replica to active state.\"\"\""},{"line_number":180,"context_line":"        context \u003d req.environ[\u0027manila.context\u0027]"},{"line_number":181,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_619e4058","line":178,"in_reply_to":"da85f559_20afcb7e","updated":"2015-11-19 19:45:53.000000000","message":"Same as above","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":190,"context_line":"        if replica_state \u003d\u003d constants.REPLICA_STATE_ACTIVE:"},{"line_number":191,"context_line":"            return webob.Response(status_int\u003d200)"},{"line_number":192,"context_line":""},{"line_number":193,"context_line":"        if replica.get(\u0027status\u0027) !\u003d constants.STATUS_AVAILABLE:"},{"line_number":194,"context_line":"            msg \u003d _(\"Replica %s must be in \u0027available\u0027 state to be \""},{"line_number":195,"context_line":"                    \"promoted.\")"},{"line_number":196,"context_line":"            raise exc.HTTPBadRequest(explanation\u003dmsg % id)"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_a01f3bb6","line":193,"updated":"2015-11-13 20:26:31.000000000","message":"According to the spec, there is no \"available\" state for share replicas. Did you mean \"active\" here? If so, the constant should be renamed as well to reflect this change.","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":190,"context_line":"        if replica_state \u003d\u003d constants.REPLICA_STATE_ACTIVE:"},{"line_number":191,"context_line":"            return webob.Response(status_int\u003d200)"},{"line_number":192,"context_line":""},{"line_number":193,"context_line":"        if replica.get(\u0027status\u0027) !\u003d constants.STATUS_AVAILABLE:"},{"line_number":194,"context_line":"            msg \u003d _(\"Replica %s must be in \u0027available\u0027 state to be \""},{"line_number":195,"context_line":"                    \"promoted.\")"},{"line_number":196,"context_line":"            raise exc.HTTPBadRequest(explanation\u003dmsg % id)"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_41e77ce4","line":193,"in_reply_to":"da85f559_a01f3bb6","updated":"2015-11-19 19:45:53.000000000","message":"Nah, this is the replica\u0027s \u0027status\u0027 field. When share_instances were introduced, \u0027status\u0027 became an attribute of the instance.. \n\nreplica[\u0027replica_state\u0027] !\u003d replica[\u0027status\u0027]","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":14567,"name":"Rodrigo Barbieri","email":"rodrigo.barbieri2010@gmail.com","username":"ganso"},"change_message_id":"fe76a9113ae4d5b83e057a5813d735652531929d","unresolved":false,"context_lines":[{"line_number":198,"context_line":"        if (replica_state in [constants.REPLICA_STATE_OUT_OF_SYNC,"},{"line_number":199,"context_line":"                              constants.STATUS_ERROR]"},{"line_number":200,"context_line":"                and not context.is_admin):"},{"line_number":201,"context_line":"            msg \u003d _(\"Promoting an replica with \u0027replica_state\u0027: %s requires \""},{"line_number":202,"context_line":"                    \"administrator privileges.\")"},{"line_number":203,"context_line":"            raise exc.HTTPUnauthorized(explanation\u003dmsg % replica_state)"},{"line_number":204,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_5cb8c5e5","line":201,"updated":"2015-11-13 13:37:11.000000000","message":"a replica","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":198,"context_line":"        if (replica_state in [constants.REPLICA_STATE_OUT_OF_SYNC,"},{"line_number":199,"context_line":"                              constants.STATUS_ERROR]"},{"line_number":200,"context_line":"                and not context.is_admin):"},{"line_number":201,"context_line":"            msg \u003d _(\"Promoting an replica with \u0027replica_state\u0027: %s requires \""},{"line_number":202,"context_line":"                    \"administrator privileges.\")"},{"line_number":203,"context_line":"            raise exc.HTTPUnauthorized(explanation\u003dmsg % replica_state)"},{"line_number":204,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_01d2d400","line":201,"in_reply_to":"da85f559_5cb8c5e5","updated":"2015-11-19 19:45:53.000000000","message":"Thanks! Done.","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"71ba533b590a228a423a3fcdfccc5c8d84bdc4d1","unresolved":false,"context_lines":[{"line_number":34,"context_line":"API_VERSION \u003d \u00272.7\u0027"},{"line_number":35,"context_line":""},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"class ShareReplicationController(wsgi.Controller):"},{"line_number":38,"context_line":"    \"\"\"The Share Replication API controller for the OpenStack API.\"\"\""},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"    resource_name \u003d \u0027share_replica\u0027"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_16178a55","line":37,"updated":"2015-11-20 17:08:26.000000000","message":"It does not have \"force_delete\" and \"reset_state\" actions, is it intended? Mentioned actions can be inherited with mixin located at [1].\n\n[1] https://github.com/openstack/manila/blob/9912d296/manila/api/openstack/wsgi.py#L1139","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"e47967aed0fcad689a3aec42a79654a5b12a6c45","unresolved":false,"context_lines":[{"line_number":34,"context_line":"API_VERSION \u003d \u00272.7\u0027"},{"line_number":35,"context_line":""},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"class ShareReplicationController(wsgi.Controller):"},{"line_number":38,"context_line":"    \"\"\"The Share Replication API controller for the OpenStack API.\"\"\""},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"    resource_name \u003d \u0027share_replica\u0027"}],"source_content_type":"text/x-python","patch_set":4,"id":"9a8ffd7b_80dc8019","line":37,"in_reply_to":"ba8a016a_16178a55","updated":"2015-12-01 16:30:42.000000000","message":"Yes. Intentional.. Since replicas are just share instances and the admin already has access to that functionality. \n\nHowever, i don\u0027t have a strong feeling against inheriting the mixin you mentioned and providing the feature here as well. Let me know what you think.","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"71ba533b590a228a423a3fcdfccc5c8d84bdc4d1","unresolved":false,"context_lines":[{"line_number":107,"context_line":"            raise exc.HTTPUnprocessableEntity(explanation\u003dmsg)"},{"line_number":108,"context_line":""},{"line_number":109,"context_line":"        share_id \u003d body.get(\u0027share_replica\u0027).get(\u0027share_id\u0027)"},{"line_number":110,"context_line":"        availability_zone \u003d body.get(\u0027share_replica\u0027).get(\u0027availability_zone\u0027)"},{"line_number":111,"context_line":"        share_network_id \u003d body.get(\u0027share_replica\u0027).get(\u0027share_network_id\u0027)"},{"line_number":112,"context_line":""},{"line_number":113,"context_line":"        if not share_id:"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_518f5c75","line":110,"updated":"2015-11-20 17:08:26.000000000","message":"Here, you take AZ object and then you take only its ID. So, would be better to take AZ ID at start then make no conditions that you do in \"manila.shre.api\".\n\nKey you need called \"availability_zone_id\".","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"e47967aed0fcad689a3aec42a79654a5b12a6c45","unresolved":false,"context_lines":[{"line_number":107,"context_line":"            raise exc.HTTPUnprocessableEntity(explanation\u003dmsg)"},{"line_number":108,"context_line":""},{"line_number":109,"context_line":"        share_id \u003d body.get(\u0027share_replica\u0027).get(\u0027share_id\u0027)"},{"line_number":110,"context_line":"        availability_zone \u003d body.get(\u0027share_replica\u0027).get(\u0027availability_zone\u0027)"},{"line_number":111,"context_line":"        share_network_id \u003d body.get(\u0027share_replica\u0027).get(\u0027share_network_id\u0027)"},{"line_number":112,"context_line":""},{"line_number":113,"context_line":"        if not share_id:"}],"source_content_type":"text/x-python","patch_set":4,"id":"9a8ffd7b_a01664a5","line":110,"in_reply_to":"ba8a016a_518f5c75","updated":"2015-12-01 16:30:42.000000000","message":"I\u0027m allowing the use of AZ Name or ID... like the shares controller does, for consistency...","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"71ba533b590a228a423a3fcdfccc5c8d84bdc4d1","unresolved":false,"context_lines":[{"line_number":154,"context_line":"        return webob.Response(status_int\u003d202)"},{"line_number":155,"context_line":""},{"line_number":156,"context_line":"    @wsgi.Controller.api_version(API_VERSION, experimental\u003dTrue)"},{"line_number":157,"context_line":"    @wsgi.action(\u0027promote_replica\u0027)"},{"line_number":158,"context_line":"    def promote(self, req, id, body):"},{"line_number":159,"context_line":"        \"\"\"Promote a replica to active state.\"\"\""},{"line_number":160,"context_line":"        context \u003d req.environ[\u0027manila.context\u0027]"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_110474c4","line":157,"updated":"2015-11-20 17:08:26.000000000","message":"Maybe better to use same value for action and policy names?","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"e47967aed0fcad689a3aec42a79654a5b12a6c45","unresolved":false,"context_lines":[{"line_number":154,"context_line":"        return webob.Response(status_int\u003d202)"},{"line_number":155,"context_line":""},{"line_number":156,"context_line":"    @wsgi.Controller.api_version(API_VERSION, experimental\u003dTrue)"},{"line_number":157,"context_line":"    @wsgi.action(\u0027promote_replica\u0027)"},{"line_number":158,"context_line":"    def promote(self, req, id, body):"},{"line_number":159,"context_line":"        \"\"\"Promote a replica to active state.\"\"\""},{"line_number":160,"context_line":"        context \u003d req.environ[\u0027manila.context\u0027]"}],"source_content_type":"text/x-python","patch_set":4,"id":"9a8ffd7b_80d24033","line":157,"in_reply_to":"ba8a016a_110474c4","updated":"2015-12-01 16:30:42.000000000","message":"Done","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"}],"manila/api/v1/shares.py":[{"author":{"_account_id":14567,"name":"Rodrigo Barbieri","email":"rodrigo.barbieri2010@gmail.com","username":"ganso"},"change_message_id":"fe76a9113ae4d5b83e057a5813d735652531929d","unresolved":false,"context_lines":[{"line_number":72,"context_line":"            if share_replica_count \u003e 1:"},{"line_number":73,"context_line":"                msg \u003d _(\"Share %s has replicas. Remove the replicas before \""},{"line_number":74,"context_line":"                        \"deleting the share.\") % id"},{"line_number":75,"context_line":"                raise exc.HTTPBadRequest(explanation\u003dmsg)"},{"line_number":76,"context_line":""},{"line_number":77,"context_line":"            # NOTE(ameade): If the share is in a consistency group, we require"},{"line_number":78,"context_line":"            # it\u0027s id be specified as a param."}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_e21c70c3","line":75,"updated":"2015-11-13 13:37:11.000000000","message":"Looks like you are already doing this check in share/api.py. I recommend removing from here.","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":72,"context_line":"            if share_replica_count \u003e 1:"},{"line_number":73,"context_line":"                msg \u003d _(\"Share %s has replicas. Remove the replicas before \""},{"line_number":74,"context_line":"                        \"deleting the share.\") % id"},{"line_number":75,"context_line":"                raise exc.HTTPBadRequest(explanation\u003dmsg)"},{"line_number":76,"context_line":""},{"line_number":77,"context_line":"            # NOTE(ameade): If the share is in a consistency group, we require"},{"line_number":78,"context_line":"            # it\u0027s id be specified as a param."}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_87a011f6","line":75,"in_reply_to":"da85f559_e21c70c3","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"}],"manila/api/v2/share_replicas.py":[{"author":{"_account_id":15100,"name":"zhongjun","email":"jun.zhongjun2@gmail.com","username":"zhongjun2"},"change_message_id":"3d0c37c63ac09aaa044015cc3dbac09c53efc27d","unresolved":false,"context_lines":[{"line_number":59,"context_line":"        \"\"\"Returns list of replicas.\"\"\""},{"line_number":60,"context_line":"        context \u003d req.environ[\u0027manila.context\u0027]"},{"line_number":61,"context_line":""},{"line_number":62,"context_line":"        share_id \u003d req.params.get(\u0027share_id\u0027)"},{"line_number":63,"context_line":"        if share_id:"},{"line_number":64,"context_line":"            try:"},{"line_number":65,"context_line":"                replicas \u003d db.share_replicas_get_all_by_share("}],"source_content_type":"text/x-python","patch_set":15,"id":"da6ed579_c69785ea","line":62,"range":{"start_line":62,"start_character":8,"end_line":62,"end_character":45},"updated":"2016-01-14 09:30:55.000000000","message":"In https://review.openstack.org/#/c/235448/1/manilaclient/v1/share_replicas.py, Code line 61:  .. \u003d \u0027?share-id\u003d\u0027...\n\nThe \"share-id\"(share_replicas.py) is diffenrent with \"share_id\"(this line), so can not get share id in this line. \n\nChange this to share-id or Change share_replicas.py to share_id.","commit_id":"c158ce297cbd6648ef1d3d8eb9cf2588a1d17c17"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"690c3c7cdf0f7acd889c08d1f1a5320c8c9fffdb","unresolved":false,"context_lines":[{"line_number":59,"context_line":"        \"\"\"Returns list of replicas.\"\"\""},{"line_number":60,"context_line":"        context \u003d req.environ[\u0027manila.context\u0027]"},{"line_number":61,"context_line":""},{"line_number":62,"context_line":"        share_id \u003d req.params.get(\u0027share_id\u0027)"},{"line_number":63,"context_line":"        if share_id:"},{"line_number":64,"context_line":"            try:"},{"line_number":65,"context_line":"                replicas \u003d db.share_replicas_get_all_by_share("}],"source_content_type":"text/x-python","patch_set":15,"id":"9a68dd71_8e2f4887","line":62,"range":{"start_line":62,"start_character":8,"end_line":62,"end_character":45},"in_reply_to":"da6ed579_c69785ea","updated":"2016-01-24 05:57:55.000000000","message":"Thanks for pointing this out Jun! I\u0027ll update the client patch... client\u0027s been sending share_id in other cases, it should remain the same.","commit_id":"c158ce297cbd6648ef1d3d8eb9cf2588a1d17c17"}],"manila/api/views/share_replicas.py":[{"author":{"_account_id":14567,"name":"Rodrigo Barbieri","email":"rodrigo.barbieri2010@gmail.com","username":"ganso"},"change_message_id":"fe76a9113ae4d5b83e057a5813d735652531929d","unresolved":false,"context_lines":[{"line_number":31,"context_line":"        return self._list_view(self.detail, request, replicas)"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"    def summary(self, request, replica):"},{"line_number":34,"context_line":"        \"\"\"Generic, non-detailed view of an share replica.\"\"\""},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"        replica_dict \u003d {"},{"line_number":37,"context_line":"            \u0027id\u0027: replica.get(\u0027id\u0027),"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_7c7829f9","line":34,"updated":"2015-11-13 13:37:11.000000000","message":"a share replica","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":31,"context_line":"        return self._list_view(self.detail, request, replicas)"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"    def summary(self, request, replica):"},{"line_number":34,"context_line":"        \"\"\"Generic, non-detailed view of an share replica.\"\"\""},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"        replica_dict \u003d {"},{"line_number":37,"context_line":"            \u0027id\u0027: replica.get(\u0027id\u0027),"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_e7c47d93","line":34,"in_reply_to":"da85f559_7c7829f9","updated":"2015-11-19 19:45:53.000000000","message":"Thanks! Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":11865,"name":"Clinton Knight","email":"cknight@netapp.com","username":"cknight"},"change_message_id":"49d23c047af5a8c287a69ba2d8ecd6cb971795df","unresolved":false,"context_lines":[{"line_number":52,"context_line":"            \u0027host\u0027: replica.get(\u0027host\u0027),"},{"line_number":53,"context_line":"            \u0027status\u0027: replica.get(\u0027status\u0027),"},{"line_number":54,"context_line":"            \u0027share_network_id\u0027: replica.get(\u0027share_network_id\u0027),"},{"line_number":55,"context_line":"            \u0027share_server_id\u0027: replica.get(\u0027share_server_id\u0027),"},{"line_number":56,"context_line":"            \u0027replica_state\u0027: replica.get(\u0027replica_state\u0027)"},{"line_number":57,"context_line":"        }"},{"line_number":58,"context_line":""}],"source_content_type":"text/x-python","patch_set":32,"id":"3a57f1b5_66f10001","line":55,"range":{"start_line":55,"start_character":13,"end_line":55,"end_character":28},"updated":"2016-02-11 22:44:41.000000000","message":"Share server ID should only be returned for an admin context.  See the share view builder for an example.","commit_id":"f858e537dd2f408b125fa4bd27b76feed73d749d"}],"manila/api/views/shares.py":[{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"7a6638d6f2d08c50908d44eb13264466627f6118","unresolved":false,"context_lines":[{"line_number":123,"context_line":"    def add_replication_fields(self, share_dict, share):"},{"line_number":124,"context_line":"        share_dict[\u0027replication\u0027] \u003d share.get(\u0027replication\u0027)"},{"line_number":125,"context_line":"        replica_count \u003d share.get(\u0027replica_count\u0027) or 0"},{"line_number":126,"context_line":"        share_dict[\u0027has_replicas\u0027] \u003d replica_count \u003e 1"},{"line_number":127,"context_line":""},{"line_number":128,"context_line":"    def _list_view(self, func, request, shares):"},{"line_number":129,"context_line":"        \"\"\"Provide a view for a list of shares.\"\"\""}],"source_content_type":"text/x-python","patch_set":1,"id":"da85f559_acc8d155","line":126,"updated":"2015-11-12 16:08:44.000000000","message":"It is confusing:\n\nDo you use word \"replica\" for all instances of a share or only \"back-up\" ones?\n\nIf the former, then you use incorrect naming, if the latter then condition is wrong.","commit_id":"dac7938116cfdbee468b3fbdfe42a3ab397fd347"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1d44846ad1c530ff7c7ed1dcf4ce2265bb331768","unresolved":false,"context_lines":[{"line_number":123,"context_line":"    def add_replication_fields(self, share_dict, share):"},{"line_number":124,"context_line":"        share_dict[\u0027replication\u0027] \u003d share.get(\u0027replication\u0027)"},{"line_number":125,"context_line":"        replica_count \u003d share.get(\u0027replica_count\u0027) or 0"},{"line_number":126,"context_line":"        share_dict[\u0027has_replicas\u0027] \u003d replica_count \u003e 1"},{"line_number":127,"context_line":""},{"line_number":128,"context_line":"    def _list_view(self, func, request, shares):"},{"line_number":129,"context_line":"        \"\"\"Provide a view for a list of shares.\"\"\""}],"source_content_type":"text/x-python","patch_set":1,"id":"ba8a016a_b6714c78","line":126,"in_reply_to":"da85f559_acc8d155","updated":"2015-11-19 19:44:49.000000000","message":"vponomaryov:\n\nhttps://review.openstack.org/#/c/238572/1/manila/db/sqlalchemy/api.py Line#1448.\n\nThis DB field (replica_count) is the number of instances that are treated as replicas. For a replicated share, the \u0027active\u0027 replica is also a replica, just as much as any other replica, whether it has a replica_state set to \u0027in_sync\u0027, \u0027out_of_sync\u0027 or \u0027error\u0027","commit_id":"dac7938116cfdbee468b3fbdfe42a3ab397fd347"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"d015a822e3a464fc20396e53ac428dd4588b9572","unresolved":false,"context_lines":[{"line_number":119,"context_line":"            \u0027share_type\u0027: share_type,"},{"line_number":120,"context_line":"        })"},{"line_number":121,"context_line":""},{"line_number":122,"context_line":"    @common.ViewBuilder.versioned_method(share_replicas.API_VERSION)"},{"line_number":123,"context_line":"    def add_replication_fields(self, share_dict, share):"},{"line_number":124,"context_line":"        share_dict[\u0027replication_type\u0027] \u003d share.get(\u0027replication_type\u0027)"},{"line_number":125,"context_line":"        # NOTE(gouthamr): Replica Count includes all instances of the"}],"source_content_type":"text/x-python","patch_set":9,"id":"7a740942_d49a4214","line":122,"updated":"2015-12-04 11:44:31.000000000","message":"Not sure that it is good reason to upload whole module just because of version.\n\nWould like to see explicit version definition else it requires additional looking at that module.","commit_id":"4ce0386bf01fc255bbf752978f09865992c4ec1f"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"b25160fd8aa84eb7b7e544cd1e4bf546811af9d4","unresolved":false,"context_lines":[{"line_number":119,"context_line":"            \u0027share_type\u0027: share_type,"},{"line_number":120,"context_line":"        })"},{"line_number":121,"context_line":""},{"line_number":122,"context_line":"    @common.ViewBuilder.versioned_method(share_replicas.API_VERSION)"},{"line_number":123,"context_line":"    def add_replication_fields(self, share_dict, share):"},{"line_number":124,"context_line":"        share_dict[\u0027replication_type\u0027] \u003d share.get(\u0027replication_type\u0027)"},{"line_number":125,"context_line":"        # NOTE(gouthamr): Replica Count includes all instances of the"}],"source_content_type":"text/x-python","patch_set":9,"id":"7a740942_8f17c350","line":122,"in_reply_to":"7a740942_d49a4214","updated":"2015-12-04 18:42:01.000000000","message":"Done","commit_id":"4ce0386bf01fc255bbf752978f09865992c4ec1f"},{"author":{"_account_id":15100,"name":"zhongjun","email":"jun.zhongjun2@gmail.com","username":"zhongjun2"},"change_message_id":"2c5aaab86189d038d8d04736300c2cec2fd4719a","unresolved":false,"context_lines":[{"line_number":118,"context_line":"            \u0027share_type\u0027: share_type,"},{"line_number":119,"context_line":"        })"},{"line_number":120,"context_line":""},{"line_number":121,"context_line":"    @common.ViewBuilder.versioned_method(\u00272.9\u0027)"},{"line_number":122,"context_line":"    def add_replication_fields(self, share_dict, share):"},{"line_number":123,"context_line":"        share_dict[\u0027replication_type\u0027] \u003d share.get(\u0027replication_type\u0027)"},{"line_number":124,"context_line":"        # NOTE(gouthamr): Replica Count includes all instances of the"}],"source_content_type":"text/x-python","patch_set":14,"id":"3a7e1126_275bd6f7","line":121,"range":{"start_line":121,"start_character":42,"end_line":121,"end_character":45},"updated":"2015-12-21 07:16:47.000000000","message":"Why not use MIN_SUPPORTED_API_VERSION in https://review.openstack.org/#/c/238572/14/manila/api/v2/share_replicas.py","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"32ae9a9907eb4d488a7df8a40b98dc8c26616485","unresolved":false,"context_lines":[{"line_number":118,"context_line":"            \u0027share_type\u0027: share_type,"},{"line_number":119,"context_line":"        })"},{"line_number":120,"context_line":""},{"line_number":121,"context_line":"    @common.ViewBuilder.versioned_method(\u00272.9\u0027)"},{"line_number":122,"context_line":"    def add_replication_fields(self, share_dict, share):"},{"line_number":123,"context_line":"        share_dict[\u0027replication_type\u0027] \u003d share.get(\u0027replication_type\u0027)"},{"line_number":124,"context_line":"        # NOTE(gouthamr): Replica Count includes all instances of the"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a7b0d38_38b069dd","line":121,"range":{"start_line":121,"start_character":42,"end_line":121,"end_character":45},"in_reply_to":"3a7e1126_275bd6f7","updated":"2015-12-23 09:13:55.000000000","message":"Thanks zhongjun. \n\nI did use the constant here until Patchset#9:\n\n\nhttps://review.openstack.org/#/c/238572/9..14/manila/api/views/shares.py\n\n\nI do think share_replicas.MIN_SUPPORTED_API_VERSION makes sense, but would it warrant the import?","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"}],"manila/common/constants.py":[{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":114,"context_line":"    # Extra specs key names"},{"line_number":115,"context_line":"    DRIVER_HANDLES_SHARE_SERVERS \u003d \"driver_handles_share_servers\""},{"line_number":116,"context_line":"    SNAPSHOT_SUPPORT \u003d \"snapshot_support\""},{"line_number":117,"context_line":"    REPLICATION_SPEC \u003d \"replication\""},{"line_number":118,"context_line":""},{"line_number":119,"context_line":"    # Extra specs containers"},{"line_number":120,"context_line":"    REQUIRED \u003d ("}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_d003280c","line":117,"updated":"2015-11-13 20:26:31.000000000","message":"You will want to change the name of the extra spec to something more appropriate for its purpose.","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":114,"context_line":"    # Extra specs key names"},{"line_number":115,"context_line":"    DRIVER_HANDLES_SHARE_SERVERS \u003d \"driver_handles_share_servers\""},{"line_number":116,"context_line":"    SNAPSHOT_SUPPORT \u003d \"snapshot_support\""},{"line_number":117,"context_line":"    REPLICATION_SPEC \u003d \"replication\""},{"line_number":118,"context_line":""},{"line_number":119,"context_line":"    # Extra specs containers"},{"line_number":120,"context_line":"    REQUIRED \u003d ("}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_e720fd4b","line":117,"in_reply_to":"da85f559_d003280c","updated":"2015-11-19 19:45:53.000000000","message":"Spoke with bswartz. He agrees replication_type may be more descriptive. Thanks for the suggestion.","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"d1755246f54a6f982803dacf1b62917e2a30f9ac","unresolved":false,"context_lines":[{"line_number":115,"context_line":"    # Extra specs key names"},{"line_number":116,"context_line":"    DRIVER_HANDLES_SHARE_SERVERS \u003d \"driver_handles_share_servers\""},{"line_number":117,"context_line":"    SNAPSHOT_SUPPORT \u003d \"snapshot_support\""},{"line_number":118,"context_line":"    REPLICATION_TYPE_SPEC \u003d \"replication_type\""},{"line_number":119,"context_line":""},{"line_number":120,"context_line":"    # Extra specs containers"},{"line_number":121,"context_line":"    REQUIRED \u003d ("}],"source_content_type":"text/x-python","patch_set":23,"id":"7a5de9d1_787710a0","line":118,"range":{"start_line":118,"start_character":4,"end_line":118,"end_character":46},"updated":"2016-02-01 17:38:54.000000000","message":"Is it required or optional? Deletable or not?","commit_id":"08799ad6674f3bd54a1fd9984ad78dbd8e862a93"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"46d881f3f99c89564e0743a1e2b74cef64d9d07f","unresolved":false,"context_lines":[{"line_number":115,"context_line":"    # Extra specs key names"},{"line_number":116,"context_line":"    DRIVER_HANDLES_SHARE_SERVERS \u003d \"driver_handles_share_servers\""},{"line_number":117,"context_line":"    SNAPSHOT_SUPPORT \u003d \"snapshot_support\""},{"line_number":118,"context_line":"    REPLICATION_TYPE_SPEC \u003d \"replication_type\""},{"line_number":119,"context_line":""},{"line_number":120,"context_line":"    # Extra specs containers"},{"line_number":121,"context_line":"    REQUIRED \u003d ("}],"source_content_type":"text/x-python","patch_set":23,"id":"7a5de9d1_f3b1d0e0","line":118,"range":{"start_line":118,"start_character":4,"end_line":118,"end_character":46},"in_reply_to":"7a5de9d1_787710a0","updated":"2016-02-02 02:45:12.000000000","message":"I\u0027m guessing its neither. It\u0027s definitely \"deletable\" (if i understand the usage below correctly.. However, it is tenant visible, extending tenant_visible below. Please feel free to correct my assumption.","commit_id":"08799ad6674f3bd54a1fd9984ad78dbd8e862a93"}],"manila/db/api.py":[{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"56c3e93a257daee2390d00f4ba887f982bf3e4d8","unresolved":false,"context_lines":[{"line_number":80,"context_line":""},{"line_number":81,"context_line":""},{"line_number":82,"context_line":"###################"},{"line_number":83,"context_line":"def return_as_primitive(function):"},{"line_number":84,"context_line":"    \"\"\"Returns sqlalchemy objects in their primitive form.\"\"\""},{"line_number":85,"context_line":""},{"line_number":86,"context_line":"    def wrapper(*args, **kwargs):"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a7b0d38_5f486d87","line":83,"range":{"start_line":83,"start_character":4,"end_line":83,"end_character":23},"updated":"2015-12-25 17:04:54.000000000","message":"Why do you need it? This will work only with attached DB objects and fail with detached if they have relationships.\n\nEach DB Model instance has \"__getitem__\" method that allows to use it in the same way as dicts - \"instance[\u0027shiny_item\u0027]\".","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"c97b01f81c7397898dc6e90e0b2501c40412ca30","unresolved":false,"context_lines":[{"line_number":80,"context_line":""},{"line_number":81,"context_line":""},{"line_number":82,"context_line":"###################"},{"line_number":83,"context_line":"def return_as_primitive(function):"},{"line_number":84,"context_line":"    \"\"\"Returns sqlalchemy objects in their primitive form.\"\"\""},{"line_number":85,"context_line":""},{"line_number":86,"context_line":"    def wrapper(*args, **kwargs):"}],"source_content_type":"text/x-python","patch_set":14,"id":"fa69d971_bc5e4410","line":83,"range":{"start_line":83,"start_character":4,"end_line":83,"end_character":23},"in_reply_to":"1a7b0d38_5f486d87","updated":"2016-01-04 19:45:42.000000000","message":"I wanted to explicitly disable lazy loading for objects... I was having failures with lazy loading when a particular relationship exists because the database session no longer exists outside the DB layer.. \n\n\nAlso, take a look at the docstring on top of this file:\n\n\"All functions in this module return objects that implement a dictionary-like\ninterface. Currently, many of these objects are sqlalchemy objects that\nimplement a dictionary interface. However, a future goal is to have all of\nthese objects be simple dictionaries.\"","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":7102,"name":"Thomas Bechtold","email":"thomas.bechtold@chainguard.dev","username":"toabctl"},"change_message_id":"bb9a313dac4f6947e609d11a31cee5f12ba014a4","unresolved":false,"context_lines":[{"line_number":1094,"context_line":"    return IMPL.share_replica_delete(context, share_replica_id)"},{"line_number":1095,"context_line":""},{"line_number":1096,"context_line":""},{"line_number":1097,"context_line":"def count_share_replicas_get_all_by_share(context, share_id):"},{"line_number":1098,"context_line":"    \"\"\"Returns count of replicas for a given share.\"\"\""},{"line_number":1099,"context_line":"    return IMPL.count_share_replicas_get_all_by_share(context, share_id)"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a5ae5dd_ca7d9a1d","line":1097,"updated":"2016-02-04 07:26:14.000000000","message":"I would name it \"share_replicas_get_all_by_share_count\" to start all replica functions with \"share_replica...\"","commit_id":"08e8c095b09c875b4940a292067029e9e2fc9065"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"95ff3f899fc56904d8ef54c3fe5171211ff0a5ca","unresolved":false,"context_lines":[{"line_number":1094,"context_line":"    return IMPL.share_replica_delete(context, share_replica_id)"},{"line_number":1095,"context_line":""},{"line_number":1096,"context_line":""},{"line_number":1097,"context_line":"def count_share_replicas_get_all_by_share(context, share_id):"},{"line_number":1098,"context_line":"    \"\"\"Returns count of replicas for a given share.\"\"\""},{"line_number":1099,"context_line":"    return IMPL.count_share_replicas_get_all_by_share(context, share_id)"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a5ae5dd_2ef459f0","line":1097,"in_reply_to":"5a5ae5dd_ca7d9a1d","updated":"2016-02-07 16:24:09.000000000","message":"removed this method.","commit_id":"08e8c095b09c875b4940a292067029e9e2fc9065"}],"manila/db/migrations/alembic/versions/293fac1130ca_add_replication_attrs.py":[{"author":{"_account_id":14567,"name":"Rodrigo Barbieri","email":"rodrigo.barbieri2010@gmail.com","username":"ganso"},"change_message_id":"fe76a9113ae4d5b83e057a5813d735652531929d","unresolved":false,"context_lines":[{"line_number":12,"context_line":"# License for the specific language governing permissions and limitations"},{"line_number":13,"context_line":"# under the License."},{"line_number":14,"context_line":""},{"line_number":15,"context_line":"\"\"\"Add replication attributes to share and share instance models"},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"Revision ID: 293fac1130ca"},{"line_number":18,"context_line":"Revises: 323840a08dc4"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_5cba0570","line":15,"updated":"2015-11-13 13:37:11.000000000","message":"end with period","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":12,"context_line":"# License for the specific language governing permissions and limitations"},{"line_number":13,"context_line":"# under the License."},{"line_number":14,"context_line":""},{"line_number":15,"context_line":"\"\"\"Add replication attributes to share and share instance models"},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"Revision ID: 293fac1130ca"},{"line_number":18,"context_line":"Revises: 323840a08dc4"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_e7955d40","line":15,"in_reply_to":"da85f559_5cba0570","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"d015a822e3a464fc20396e53ac428dd4588b9572","unresolved":false,"context_lines":[{"line_number":30,"context_line":""},{"line_number":31,"context_line":"def upgrade():"},{"line_number":32,"context_line":"    \"\"\"Add replication attributes to Shares and ShareInstances.\"\"\""},{"line_number":33,"context_line":"    op.add_column(\u0027shares\u0027, sa.Column(\u0027replication_type\u0027, sa.String(255)))"},{"line_number":34,"context_line":"    op.add_column(\u0027share_instances\u0027,"},{"line_number":35,"context_line":"                  sa.Column(\u0027replica_state\u0027, sa.String(255)))"},{"line_number":36,"context_line":""}],"source_content_type":"text/x-python","patch_set":9,"id":"7a740942_347866c4","line":33,"updated":"2015-12-04 11:44:31.000000000","message":"Please. cover it with test data, examples:\n\n1) https://github.com/openstack/manila/blob/fa153781/manila/tests/db/migrations/alembic/migrations_data_checks.py#L123\n\n2) https://review.openstack.org/#/c/251930/9/manila/tests/db/migrations/alembic/migrations_data_checks.py","commit_id":"4ce0386bf01fc255bbf752978f09865992c4ec1f"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"b25160fd8aa84eb7b7e544cd1e4bf546811af9d4","unresolved":false,"context_lines":[{"line_number":30,"context_line":""},{"line_number":31,"context_line":"def upgrade():"},{"line_number":32,"context_line":"    \"\"\"Add replication attributes to Shares and ShareInstances.\"\"\""},{"line_number":33,"context_line":"    op.add_column(\u0027shares\u0027, sa.Column(\u0027replication_type\u0027, sa.String(255)))"},{"line_number":34,"context_line":"    op.add_column(\u0027share_instances\u0027,"},{"line_number":35,"context_line":"                  sa.Column(\u0027replica_state\u0027, sa.String(255)))"},{"line_number":36,"context_line":""}],"source_content_type":"text/x-python","patch_set":9,"id":"7a740942_fa6c079e","line":33,"in_reply_to":"7a740942_347866c4","updated":"2015-12-04 18:42:01.000000000","message":"Done","commit_id":"4ce0386bf01fc255bbf752978f09865992c4ec1f"}],"manila/db/sqlalchemy/api.py":[{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"061b886705c42cea2f9f63e8dead3e7ea59c2219","unresolved":false,"context_lines":[{"line_number":1415,"context_line":"    )"},{"line_number":1416,"context_line":""},{"line_number":1417,"context_line":"    if result is None:"},{"line_number":1418,"context_line":"        raise exception.NotFound()"},{"line_number":1419,"context_line":""},{"line_number":1420,"context_line":"    if with_share_data:"},{"line_number":1421,"context_line":"        parent_share \u003d share_get(context, result[\u0027share_id\u0027], session\u003dsession)"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_8c7f1114","line":1418,"updated":"2015-11-20 03:30:03.000000000","message":"Can you add an exception for ShareReplicaNotFound?","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"3b45c7a4783e66821748ec9cf5859baf7bb088da","unresolved":false,"context_lines":[{"line_number":1415,"context_line":"    )"},{"line_number":1416,"context_line":""},{"line_number":1417,"context_line":"    if result is None:"},{"line_number":1418,"context_line":"        raise exception.NotFound()"},{"line_number":1419,"context_line":""},{"line_number":1420,"context_line":"    if with_share_data:"},{"line_number":1421,"context_line":"        parent_share \u003d share_get(context, result[\u0027share_id\u0027], session\u003dsession)"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_10c0f9df","line":1418,"in_reply_to":"ba8a016a_8c7f1114","updated":"2015-11-20 17:09:27.000000000","message":"Done","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"71ba533b590a228a423a3fcdfccc5c8d84bdc4d1","unresolved":false,"context_lines":[{"line_number":1465,"context_line":"    if session is None:"},{"line_number":1466,"context_line":"        session \u003d get_session()"},{"line_number":1467,"context_line":"    result \u003d ("},{"line_number":1468,"context_line":"        model_query(context, models.Share, session\u003dsession).options("},{"line_number":1469,"context_line":"            joinedload(\u0027share_metadata\u0027)).options(joinedload(\u0027share_type\u0027))"},{"line_number":1470,"context_line":"    )"},{"line_number":1471,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_119474e6","line":1468,"updated":"2015-11-20 17:08:26.000000000","message":"Why this is changed/updated? What does it have for the goal of commit?","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"e47967aed0fcad689a3aec42a79654a5b12a6c45","unresolved":false,"context_lines":[{"line_number":1465,"context_line":"    if session is None:"},{"line_number":1466,"context_line":"        session \u003d get_session()"},{"line_number":1467,"context_line":"    result \u003d ("},{"line_number":1468,"context_line":"        model_query(context, models.Share, session\u003dsession).options("},{"line_number":1469,"context_line":"            joinedload(\u0027share_metadata\u0027)).options(joinedload(\u0027share_type\u0027))"},{"line_number":1470,"context_line":"    )"},{"line_number":1471,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"9a8ffd7b_944a8154","line":1468,"in_reply_to":"ba8a016a_119474e6","updated":"2015-12-01 16:30:42.000000000","message":"Yes. I needed the share_type information to grab the share_replicas in the share get query instead of making another DB call... Also, this is useful to have when we\u0027re introducing more  things that need share_type related validation.","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"d015a822e3a464fc20396e53ac428dd4588b9572","unresolved":false,"context_lines":[{"line_number":1468,"context_line":"def _share_get_query(context, session\u003dNone):"},{"line_number":1469,"context_line":"    if session is None:"},{"line_number":1470,"context_line":"        session \u003d get_session()"},{"line_number":1471,"context_line":"    result \u003d ("},{"line_number":1472,"context_line":"        model_query(context, models.Share, session\u003dsession).options("},{"line_number":1473,"context_line":"            joinedload(\u0027share_metadata\u0027)).options(joinedload(\u0027share_type\u0027))"},{"line_number":1474,"context_line":"    )"}],"source_content_type":"text/x-python","patch_set":9,"id":"7a740942_f4065e1f","line":1471,"updated":"2015-12-04 11:44:31.000000000","message":"This changes looks redundant. Your commit even without this change is very big. Please, avoid such things.","commit_id":"4ce0386bf01fc255bbf752978f09865992c4ec1f"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"b25160fd8aa84eb7b7e544cd1e4bf546811af9d4","unresolved":false,"context_lines":[{"line_number":1468,"context_line":"def _share_get_query(context, session\u003dNone):"},{"line_number":1469,"context_line":"    if session is None:"},{"line_number":1470,"context_line":"        session \u003d get_session()"},{"line_number":1471,"context_line":"    result \u003d ("},{"line_number":1472,"context_line":"        model_query(context, models.Share, session\u003dsession).options("},{"line_number":1473,"context_line":"            joinedload(\u0027share_metadata\u0027)).options(joinedload(\u0027share_type\u0027))"},{"line_number":1474,"context_line":"    )"}],"source_content_type":"text/x-python","patch_set":9,"id":"7a740942_1a747333","line":1471,"in_reply_to":"7a740942_f4065e1f","updated":"2015-12-04 18:42:01.000000000","message":"Done","commit_id":"4ce0386bf01fc255bbf752978f09865992c4ec1f"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"56c3e93a257daee2390d00f4ba887f982bf3e4d8","unresolved":false,"context_lines":[{"line_number":1458,"context_line":"                    read_deleted\u003d\"no\").filter("},{"line_number":1459,"context_line":"            and_(models.ShareInstance.share_id \u003d\u003d share_id,"},{"line_number":1460,"context_line":"                 models.ShareInstance.replica_state.isnot(None))).count()"},{"line_number":1461,"context_line":"    )"},{"line_number":1462,"context_line":""},{"line_number":1463,"context_line":"    return result"},{"line_number":1464,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"1a7b0d38_82275eb5","line":1461,"updated":"2015-12-25 17:04:54.000000000","message":"Following is more readable:\n\n\"\"\"\n\nresult \u003d model_query(\n    context, models.ShareInstance, session\u003dsession, read_deleted\u003d\"no\",\n).filter(\n    and_(models.ShareInstance.share_id \u003d\u003d share_id,\n         models.ShareInstance.replica_state.isnot(None))\n).count()\n\n\"\"\"","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":177,"name":"Alex Meade","email":"mr.alex.meade@gmail.com","username":"alex-meade"},"change_message_id":"42ec7ecf31e99adfd9beaa2b6fa0768545f0f731","unresolved":false,"context_lines":[{"line_number":1458,"context_line":"                    read_deleted\u003d\"no\").filter("},{"line_number":1459,"context_line":"            and_(models.ShareInstance.share_id \u003d\u003d share_id,"},{"line_number":1460,"context_line":"                 models.ShareInstance.replica_state.isnot(None))).count()"},{"line_number":1461,"context_line":"    )"},{"line_number":1462,"context_line":""},{"line_number":1463,"context_line":"    return result"},{"line_number":1464,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"da6ed579_d0f54dcb","line":1461,"in_reply_to":"1a7b0d38_82275eb5","updated":"2016-01-13 02:54:38.000000000","message":"If we are only using this to know if there are any replicas, you can do .exists() instead of .count()","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"0aace059b282267e3e01c44cbb73c7bc0b3213f4","unresolved":false,"context_lines":[{"line_number":1458,"context_line":"                    read_deleted\u003d\"no\").filter("},{"line_number":1459,"context_line":"            and_(models.ShareInstance.share_id \u003d\u003d share_id,"},{"line_number":1460,"context_line":"                 models.ShareInstance.replica_state.isnot(None))).count()"},{"line_number":1461,"context_line":"    )"},{"line_number":1462,"context_line":""},{"line_number":1463,"context_line":"    return result"},{"line_number":1464,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"9a68dd71_4cfd98af","line":1461,"in_reply_to":"da6ed579_d0f54dcb","updated":"2016-01-26 03:46:07.000000000","message":"I\u0027ll fix the wrapping. Alex, I intend to keep this method for counting the replicas, over the has_replicas that\u0027s added to the Share Model now.","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"56c3e93a257daee2390d00f4ba887f982bf3e4d8","unresolved":false,"context_lines":[{"line_number":1552,"context_line":"    if result is None:"},{"line_number":1553,"context_line":"        raise exception.NotFound()"},{"line_number":1554,"context_line":""},{"line_number":1555,"context_line":"    if result.get(\u0027replication_type\u0027):"},{"line_number":1556,"context_line":"        result[\u0027replica_count\u0027] \u003d count_share_replicas_get_all_by_share("},{"line_number":1557,"context_line":"            context, result[\u0027id\u0027], session"},{"line_number":1558,"context_line":"        )"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a7b0d38_8200be02","line":1555,"updated":"2015-12-25 17:04:54.000000000","message":"This logic should be part of a \"Share\" model.","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":7102,"name":"Thomas Bechtold","email":"thomas.bechtold@chainguard.dev","username":"toabctl"},"change_message_id":"bb9a313dac4f6947e609d11a31cee5f12ba014a4","unresolved":false,"context_lines":[{"line_number":1323,"context_line":""},{"line_number":1324,"context_line":""},{"line_number":1325,"context_line":"@require_context"},{"line_number":1326,"context_line":"def share_replicas_get_all_by_share(context, share_id,"},{"line_number":1327,"context_line":"                                    with_share_data\u003dFalse,"},{"line_number":1328,"context_line":"                                    with_share_server\u003dFalse, session\u003dNone):"},{"line_number":1329,"context_line":"    \"\"\"Returns replica instances for a given share.\"\"\""}],"source_content_type":"text/x-python","patch_set":26,"id":"5a5ae5dd_aaee1eb2","line":1326,"updated":"2016-02-04 07:26:14.000000000","message":"The only difference to share_replicas_get_all() is a single line (\"and_(models.ShareInstance.share_id \u003d\u003d share_id\"). Can you refactor to reuse the common code?","commit_id":"08e8c095b09c875b4940a292067029e9e2fc9065"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"95ff3f899fc56904d8ef54c3fe5171211ff0a5ca","unresolved":false,"context_lines":[{"line_number":1323,"context_line":""},{"line_number":1324,"context_line":""},{"line_number":1325,"context_line":"@require_context"},{"line_number":1326,"context_line":"def share_replicas_get_all_by_share(context, share_id,"},{"line_number":1327,"context_line":"                                    with_share_data\u003dFalse,"},{"line_number":1328,"context_line":"                                    with_share_server\u003dFalse, session\u003dNone):"},{"line_number":1329,"context_line":"    \"\"\"Returns replica instances for a given share.\"\"\""}],"source_content_type":"text/x-python","patch_set":26,"id":"5a5ae5dd_7ef51555","line":1326,"in_reply_to":"5a5ae5dd_aaee1eb2","updated":"2016-02-07 16:24:09.000000000","message":"Done","commit_id":"08e8c095b09c875b4940a292067029e9e2fc9065"},{"author":{"_account_id":7102,"name":"Thomas Bechtold","email":"thomas.bechtold@chainguard.dev","username":"toabctl"},"change_message_id":"bb9a313dac4f6947e609d11a31cee5f12ba014a4","unresolved":false,"context_lines":[{"line_number":1351,"context_line":""},{"line_number":1352,"context_line":""},{"line_number":1353,"context_line":"@require_context"},{"line_number":1354,"context_line":"def share_replicas_get_available_active_replica(context, share_id,"},{"line_number":1355,"context_line":"                                                with_share_data\u003dFalse,"},{"line_number":1356,"context_line":"                                                with_share_server\u003dFalse,"},{"line_number":1357,"context_line":"                                                session\u003dNone):"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a5ae5dd_8a4a42c4","line":1354,"updated":"2016-02-04 07:26:14.000000000","message":"same here. just one extra line in the query.filter() method","commit_id":"08e8c095b09c875b4940a292067029e9e2fc9065"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"95ff3f899fc56904d8ef54c3fe5171211ff0a5ca","unresolved":false,"context_lines":[{"line_number":1351,"context_line":""},{"line_number":1352,"context_line":""},{"line_number":1353,"context_line":"@require_context"},{"line_number":1354,"context_line":"def share_replicas_get_available_active_replica(context, share_id,"},{"line_number":1355,"context_line":"                                                with_share_data\u003dFalse,"},{"line_number":1356,"context_line":"                                                with_share_server\u003dFalse,"},{"line_number":1357,"context_line":"                                                session\u003dNone):"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a5ae5dd_5ef05967","line":1354,"in_reply_to":"5a5ae5dd_8a4a42c4","updated":"2016-02-07 16:24:09.000000000","message":"Done","commit_id":"08e8c095b09c875b4940a292067029e9e2fc9065"},{"author":{"_account_id":7102,"name":"Thomas Bechtold","email":"thomas.bechtold@chainguard.dev","username":"toabctl"},"change_message_id":"bb9a313dac4f6947e609d11a31cee5f12ba014a4","unresolved":false,"context_lines":[{"line_number":1381,"context_line":""},{"line_number":1382,"context_line":""},{"line_number":1383,"context_line":"@require_context"},{"line_number":1384,"context_line":"def share_replicas_get_active_replicas_by_share(context, share_id,"},{"line_number":1385,"context_line":"                                                with_share_data\u003dFalse,"},{"line_number":1386,"context_line":"                                                with_share_server\u003dFalse,"},{"line_number":1387,"context_line":"                                                session\u003dNone):"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a5ae5dd_ca27da10","line":1384,"updated":"2016-02-04 07:26:14.000000000","message":"same here","commit_id":"08e8c095b09c875b4940a292067029e9e2fc9065"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"95ff3f899fc56904d8ef54c3fe5171211ff0a5ca","unresolved":false,"context_lines":[{"line_number":1381,"context_line":""},{"line_number":1382,"context_line":""},{"line_number":1383,"context_line":"@require_context"},{"line_number":1384,"context_line":"def share_replicas_get_active_replicas_by_share(context, share_id,"},{"line_number":1385,"context_line":"                                                with_share_data\u003dFalse,"},{"line_number":1386,"context_line":"                                                with_share_server\u003dFalse,"},{"line_number":1387,"context_line":"                                                session\u003dNone):"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a5ae5dd_bee06d97","line":1384,"in_reply_to":"5a5ae5dd_ca27da10","updated":"2016-02-07 16:24:09.000000000","message":"Done","commit_id":"08e8c095b09c875b4940a292067029e9e2fc9065"},{"author":{"_account_id":7102,"name":"Thomas Bechtold","email":"thomas.bechtold@chainguard.dev","username":"toabctl"},"change_message_id":"bb9a313dac4f6947e609d11a31cee5f12ba014a4","unresolved":false,"context_lines":[{"line_number":1411,"context_line":""},{"line_number":1412,"context_line":""},{"line_number":1413,"context_line":"@require_context"},{"line_number":1414,"context_line":"def share_replica_get(context, replica_id, with_share_data\u003dFalse,"},{"line_number":1415,"context_line":"                      with_share_server\u003dFalse, session\u003dNone):"},{"line_number":1416,"context_line":"    \"\"\"Returns summary of requested replica if available.\"\"\""},{"line_number":1417,"context_line":"    session \u003d session or get_session()"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a5ae5dd_8a21e2fd","line":1414,"updated":"2016-02-04 07:26:14.000000000","message":"more or less same here (except the \"if result is None\").","commit_id":"08e8c095b09c875b4940a292067029e9e2fc9065"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"95ff3f899fc56904d8ef54c3fe5171211ff0a5ca","unresolved":false,"context_lines":[{"line_number":1411,"context_line":""},{"line_number":1412,"context_line":""},{"line_number":1413,"context_line":"@require_context"},{"line_number":1414,"context_line":"def share_replica_get(context, replica_id, with_share_data\u003dFalse,"},{"line_number":1415,"context_line":"                      with_share_server\u003dFalse, session\u003dNone):"},{"line_number":1416,"context_line":"    \"\"\"Returns summary of requested replica if available.\"\"\""},{"line_number":1417,"context_line":"    session \u003d session or get_session()"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a5ae5dd_9ee331a4","line":1414,"in_reply_to":"5a5ae5dd_8a21e2fd","updated":"2016-02-07 16:24:09.000000000","message":"Done","commit_id":"08e8c095b09c875b4940a292067029e9e2fc9065"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"123033e1de89dae676f8dd0a65834cf5be2bc10c","unresolved":false,"context_lines":[{"line_number":1567,"context_line":"        raise exception.NotFound()"},{"line_number":1568,"context_line":""},{"line_number":1569,"context_line":"    # Execute the has_replicas property to avoid per-call queries."},{"line_number":1570,"context_line":"    # result[\u0027has_replicas\u0027] \u003d result.has_replicas"},{"line_number":1571,"context_line":""},{"line_number":1572,"context_line":"    return result"},{"line_number":1573,"context_line":""}],"source_content_type":"text/x-python","patch_set":26,"id":"5a5ae5dd_5ed675c6","line":1570,"updated":"2016-02-04 03:07:17.000000000","message":"The commented-out line should be removed.","commit_id":"08e8c095b09c875b4940a292067029e9e2fc9065"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"95ff3f899fc56904d8ef54c3fe5171211ff0a5ca","unresolved":false,"context_lines":[{"line_number":1567,"context_line":"        raise exception.NotFound()"},{"line_number":1568,"context_line":""},{"line_number":1569,"context_line":"    # Execute the has_replicas property to avoid per-call queries."},{"line_number":1570,"context_line":"    # result[\u0027has_replicas\u0027] \u003d result.has_replicas"},{"line_number":1571,"context_line":""},{"line_number":1572,"context_line":"    return result"},{"line_number":1573,"context_line":""}],"source_content_type":"text/x-python","patch_set":26,"id":"5a5ae5dd_de04494b","line":1570,"in_reply_to":"5a5ae5dd_5ed675c6","updated":"2016-02-07 16:24:09.000000000","message":"Done. Thanks!","commit_id":"08e8c095b09c875b4940a292067029e9e2fc9065"},{"author":{"_account_id":7102,"name":"Thomas Bechtold","email":"thomas.bechtold@chainguard.dev","username":"toabctl"},"change_message_id":"bb9a313dac4f6947e609d11a31cee5f12ba014a4","unresolved":false,"context_lines":[{"line_number":1774,"context_line":"            \u0027share_instance_id\u0027: instance_id,"},{"line_number":1775,"context_line":"            \u0027access_id\u0027: access_rule[\u0027id\u0027],"},{"line_number":1776,"context_line":"        }"},{"line_number":1777,"context_line":""},{"line_number":1778,"context_line":"        _share_instance_access_create(values, session)"},{"line_number":1779,"context_line":""},{"line_number":1780,"context_line":"    return share_access_rules"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a5ae5dd_ca8a7abf","line":1777,"updated":"2016-02-04 07:26:14.000000000","message":"Not sure but this looks racy. What if somebody creates a new rule after \"share_access_get_all_for_share\" but before \"_share_instance_access_create\" ?","commit_id":"08e8c095b09c875b4940a292067029e9e2fc9065"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"95ff3f899fc56904d8ef54c3fe5171211ff0a5ca","unresolved":false,"context_lines":[{"line_number":1774,"context_line":"            \u0027share_instance_id\u0027: instance_id,"},{"line_number":1775,"context_line":"            \u0027access_id\u0027: access_rule[\u0027id\u0027],"},{"line_number":1776,"context_line":"        }"},{"line_number":1777,"context_line":""},{"line_number":1778,"context_line":"        _share_instance_access_create(values, session)"},{"line_number":1779,"context_line":""},{"line_number":1780,"context_line":"    return share_access_rules"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a5ae5dd_a9e9d0b8","line":1777,"in_reply_to":"5a5ae5dd_ca8a7abf","updated":"2016-02-07 16:24:09.000000000","message":"maybe true, in that very small window of time... what do you suggest we do?","commit_id":"08e8c095b09c875b4940a292067029e9e2fc9065"}],"manila/db/sqlalchemy/models.py":[{"author":{"_account_id":14567,"name":"Rodrigo Barbieri","email":"rodrigo.barbieri2010@gmail.com","username":"ganso"},"change_message_id":"fe76a9113ae4d5b83e057a5813d735652531929d","unresolved":false,"context_lines":[{"line_number":243,"context_line":"        # NOTE(gouthamr): The order of preference: status \u0027replication_change\u0027,"},{"line_number":244,"context_line":"        # followed  by \u0027available\u0027 and \u0027creating\u0027. If replicated share and"},{"line_number":245,"context_line":"        # not undergoing a \u0027replication_change\u0027, only \u0027active\u0027 instances are"},{"line_number":246,"context_line":"        # preferred."},{"line_number":247,"context_line":"        result \u003d None"},{"line_number":248,"context_line":"        if len(self.instances) \u003e 0:"},{"line_number":249,"context_line":"            order \u003d [constants.STATUS_REPLICATION_CHANGE,"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_825d64ee","line":246,"updated":"2015-11-13 13:37:11.000000000","message":"I think I just found a bug in the old code... if we want to show any other status than CREATING, then I believe the condition should have been:\n\nelif instance.status !\u003d constants.STATUS_CREATING:\n\nso error status would be preferred than creating status. \n\nCould you change your code to reflect this behavior?","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":243,"context_line":"        # NOTE(gouthamr): The order of preference: status \u0027replication_change\u0027,"},{"line_number":244,"context_line":"        # followed  by \u0027available\u0027 and \u0027creating\u0027. If replicated share and"},{"line_number":245,"context_line":"        # not undergoing a \u0027replication_change\u0027, only \u0027active\u0027 instances are"},{"line_number":246,"context_line":"        # preferred."},{"line_number":247,"context_line":"        result \u003d None"},{"line_number":248,"context_line":"        if len(self.instances) \u003e 0:"},{"line_number":249,"context_line":"            order \u003d [constants.STATUS_REPLICATION_CHANGE,"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_87bb31c4","line":246,"in_reply_to":"da85f559_825d64ee","updated":"2015-11-19 19:45:53.000000000","message":"Thanks. Changed the order\n\n    order \u003d [constants.STATUS_REPLICATION_CHANGE,\t     \n                   constants.STATUS_AVAILABLE,           \n                   constants.STATUS_ERROR]","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"56c3e93a257daee2390d00f4ba887f982bf3e4d8","unresolved":false,"context_lines":[{"line_number":191,"context_line":"    _extra_keys \u003d [\u0027name\u0027, \u0027export_location\u0027, \u0027export_locations\u0027, \u0027status\u0027,"},{"line_number":192,"context_line":"                   \u0027host\u0027, \u0027share_server_id\u0027, \u0027share_network_id\u0027,"},{"line_number":193,"context_line":"                   \u0027availability_zone\u0027]"},{"line_number":194,"context_line":""},{"line_number":195,"context_line":"    @property"},{"line_number":196,"context_line":"    def name(self):"},{"line_number":197,"context_line":"        return CONF.share_name_template % self.id"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a7b0d38_82eafe0d","line":194,"updated":"2015-12-25 17:04:54.000000000","message":"\"has_replicas\" property should be added to this model, instead of hacking it in DB API functions.","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":177,"name":"Alex Meade","email":"mr.alex.meade@gmail.com","username":"alex-meade"},"change_message_id":"42ec7ecf31e99adfd9beaa2b6fa0768545f0f731","unresolved":false,"context_lines":[{"line_number":191,"context_line":"    _extra_keys \u003d [\u0027name\u0027, \u0027export_location\u0027, \u0027export_locations\u0027, \u0027status\u0027,"},{"line_number":192,"context_line":"                   \u0027host\u0027, \u0027share_server_id\u0027, \u0027share_network_id\u0027,"},{"line_number":193,"context_line":"                   \u0027availability_zone\u0027]"},{"line_number":194,"context_line":""},{"line_number":195,"context_line":"    @property"},{"line_number":196,"context_line":"    def name(self):"},{"line_number":197,"context_line":"        return CONF.share_name_template % self.id"}],"source_content_type":"text/x-python","patch_set":14,"id":"da6ed579_10e1a5fe","line":194,"in_reply_to":"1a7b0d38_82eafe0d","updated":"2016-01-13 02:54:38.000000000","message":"I\u0027m wondering if that will make things messy. If we have it as a column then we must set it when we create a replica and check if there are any other replicas when we delete a replica so we can unset it.","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"0aace059b282267e3e01c44cbb73c7bc0b3213f4","unresolved":false,"context_lines":[{"line_number":191,"context_line":"    _extra_keys \u003d [\u0027name\u0027, \u0027export_location\u0027, \u0027export_locations\u0027, \u0027status\u0027,"},{"line_number":192,"context_line":"                   \u0027host\u0027, \u0027share_server_id\u0027, \u0027share_network_id\u0027,"},{"line_number":193,"context_line":"                   \u0027availability_zone\u0027]"},{"line_number":194,"context_line":""},{"line_number":195,"context_line":"    @property"},{"line_number":196,"context_line":"    def name(self):"},{"line_number":197,"context_line":"        return CONF.share_name_template % self.id"}],"source_content_type":"text/x-python","patch_set":14,"id":"9a68dd71_ec2ecc41","line":194,"in_reply_to":"da6ed579_10e1a5fe","updated":"2016-01-26 03:46:07.000000000","message":"I added it as a property as suggested..","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"}],"manila/scheduler/driver.py":[{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"71ba533b590a228a423a3fcdfccc5c8d84bdc4d1","unresolved":false,"context_lines":[{"line_number":62,"context_line":""},{"line_number":63,"context_line":""},{"line_number":64,"context_line":"def cg_update_db(context, cg_id, host):"},{"line_number":65,"context_line":"    \"\"\"Set the host and the updated_at field of a consistency group."},{"line_number":66,"context_line":""},{"line_number":67,"context_line":"    :returns: A CG with the updated fields set."},{"line_number":68,"context_line":"    \"\"\""}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_7c735716","line":65,"updated":"2015-11-20 17:08:26.000000000","message":"Update of \"cg_update_db\" is unrelated to the goal of commit too. This change without such changes is big, no need to add more.","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"e47967aed0fcad689a3aec42a79654a5b12a6c45","unresolved":false,"context_lines":[{"line_number":62,"context_line":""},{"line_number":63,"context_line":""},{"line_number":64,"context_line":"def cg_update_db(context, cg_id, host):"},{"line_number":65,"context_line":"    \"\"\"Set the host and the updated_at field of a consistency group."},{"line_number":66,"context_line":""},{"line_number":67,"context_line":"    :returns: A CG with the updated fields set."},{"line_number":68,"context_line":"    \"\"\""}],"source_content_type":"text/x-python","patch_set":4,"id":"9a8ffd7b_541179ae","line":65,"in_reply_to":"ba8a016a_7c735716","updated":"2015-12-01 16:30:42.000000000","message":"Done","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"}],"manila/scheduler/filter_scheduler.py":[{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":115,"context_line":"            context, request_spec, filter_properties)"},{"line_number":116,"context_line":""},{"line_number":117,"context_line":"        if not weighed_host:"},{"line_number":118,"context_line":"            raise exception.NoValidHost(reason\u003d\"\")"},{"line_number":119,"context_line":""},{"line_number":120,"context_line":"        host \u003d weighed_host.obj.host"},{"line_number":121,"context_line":"        share_replica_id \u003d request_spec[\u0027share_instance_properties\u0027].get(\u0027id\u0027)"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_d599da20","line":118,"updated":"2015-11-13 20:26:31.000000000","message":"Could we specify more than just a blank reason for the NoValidHost exception?","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":115,"context_line":"            context, request_spec, filter_properties)"},{"line_number":116,"context_line":""},{"line_number":117,"context_line":"        if not weighed_host:"},{"line_number":118,"context_line":"            raise exception.NoValidHost(reason\u003d\"\")"},{"line_number":119,"context_line":""},{"line_number":120,"context_line":"        host \u003d weighed_host.obj.host"},{"line_number":121,"context_line":"        share_replica_id \u003d request_spec[\u0027share_instance_properties\u0027].get(\u0027id\u0027)"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_073d012b","line":118,"in_reply_to":"da85f559_d599da20","updated":"2015-11-19 19:45:53.000000000","message":"Done. Thanks.","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"}],"manila/scheduler/host_manager.py":[{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":296,"context_line":"        if \u0027compression\u0027 not in pool_cap:"},{"line_number":297,"context_line":"            pool_cap[\u0027compression\u0027] \u003d self.compression"},{"line_number":298,"context_line":""},{"line_number":299,"context_line":"        if not pool_cap.get(\u0027replication\u0027):"},{"line_number":300,"context_line":"            pool_cap[\u0027replication\u0027] \u003d self.replication"},{"line_number":301,"context_line":""},{"line_number":302,"context_line":"    def update_backend(self, capability):"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_f5a97e25","line":299,"updated":"2015-11-13 20:26:31.000000000","message":"You\u0027ll want to make sure to update these fields as well with the new name for the extra spec.","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":296,"context_line":"        if \u0027compression\u0027 not in pool_cap:"},{"line_number":297,"context_line":"            pool_cap[\u0027compression\u0027] \u003d self.compression"},{"line_number":298,"context_line":""},{"line_number":299,"context_line":"        if not pool_cap.get(\u0027replication\u0027):"},{"line_number":300,"context_line":"            pool_cap[\u0027replication\u0027] \u003d self.replication"},{"line_number":301,"context_line":""},{"line_number":302,"context_line":"    def update_backend(self, capability):"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_270cc593","line":299,"in_reply_to":"da85f559_f5a97e25","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"123033e1de89dae676f8dd0a65834cf5be2bc10c","unresolved":false,"context_lines":[{"line_number":130,"context_line":"        self.replication_type \u003d None"},{"line_number":131,"context_line":"        # TODO(gouthamr): Need to update driver_name from backend to filter"},{"line_number":132,"context_line":"        # for replication"},{"line_number":133,"context_line":"        # self.driver_name \u003d None"},{"line_number":134,"context_line":""},{"line_number":135,"context_line":"        # PoolState for all pools"},{"line_number":136,"context_line":"        self.pools \u003d {}"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a5ae5dd_9663631a","line":133,"updated":"2016-02-04 03:07:17.000000000","message":"When are you planning to make this change","commit_id":"08e8c095b09c875b4940a292067029e9e2fc9065"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"95ff3f899fc56904d8ef54c3fe5171211ff0a5ca","unresolved":false,"context_lines":[{"line_number":130,"context_line":"        self.replication_type \u003d None"},{"line_number":131,"context_line":"        # TODO(gouthamr): Need to update driver_name from backend to filter"},{"line_number":132,"context_line":"        # for replication"},{"line_number":133,"context_line":"        # self.driver_name \u003d None"},{"line_number":134,"context_line":""},{"line_number":135,"context_line":"        # PoolState for all pools"},{"line_number":136,"context_line":"        self.pools \u003d {}"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a5ae5dd_c949f1b8","line":133,"in_reply_to":"5a5ae5dd_9663631a","updated":"2016-02-07 16:24:09.000000000","message":"Thanks for pointing this out. I was working on a follow on patch. I\u0027ll upload it soon. I\u0027ll remove this comment though, since it\u0027s going to be addressed through that patch","commit_id":"08e8c095b09c875b4940a292067029e9e2fc9065"}],"manila/share/api.py":[{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"7a6638d6f2d08c50908d44eb13264466627f6118","unresolved":false,"context_lines":[{"line_number":486,"context_line":"                                          project_id\u003dproject_id,"},{"line_number":487,"context_line":"                                          shares\u003d-1,"},{"line_number":488,"context_line":"                                          gigabytes\u003d-share[\u0027size\u0027])"},{"line_number":489,"context_line":""},{"line_number":490,"context_line":"        except Exception as e:"},{"line_number":491,"context_line":"            reservations \u003d None"},{"line_number":492,"context_line":"            LOG.exception("}],"source_content_type":"text/x-python","patch_set":1,"id":"da85f559_97387ad4","line":489,"updated":"2015-11-12 16:08:44.000000000","message":"It was better before. try-block was separate by empty lines from other parts of code.","commit_id":"dac7938116cfdbee468b3fbdfe42a3ab397fd347"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1d44846ad1c530ff7c7ed1dcf4ce2265bb331768","unresolved":false,"context_lines":[{"line_number":486,"context_line":"                                          project_id\u003dproject_id,"},{"line_number":487,"context_line":"                                          shares\u003d-1,"},{"line_number":488,"context_line":"                                          gigabytes\u003d-share[\u0027size\u0027])"},{"line_number":489,"context_line":""},{"line_number":490,"context_line":"        except Exception as e:"},{"line_number":491,"context_line":"            reservations \u003d None"},{"line_number":492,"context_line":"            LOG.exception("}],"source_content_type":"text/x-python","patch_set":1,"id":"ba8a016a_87cc9136","line":489,"in_reply_to":"da85f559_97387ad4","updated":"2015-11-19 19:44:49.000000000","message":"Done","commit_id":"dac7938116cfdbee468b3fbdfe42a3ab397fd347"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":168,"context_line":"                share_type.get(\u0027extra_specs\u0027, {}).get("},{"line_number":169,"context_line":"                    \u0027snapshot_support\u0027, True) if share_type else True,"},{"line_number":170,"context_line":"                strict\u003dTrue)"},{"line_number":171,"context_line":"            replication \u003d share_type.get(\u0027extra_specs\u0027, {}).get("},{"line_number":172,"context_line":"                \u0027replication\u0027, None) if share_type else None"},{"line_number":173,"context_line":"        except ValueError as e:"},{"line_number":174,"context_line":"            raise exception.InvalidParameterValue(six.text_type(e))"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_af164cef","line":171,"updated":"2015-11-13 20:26:31.000000000","message":"This variable name should be changed to \"replication_style\" to make it a bit clearer what the intent of this value is. The Extra Spec should also be renamed in kind.","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":168,"context_line":"                share_type.get(\u0027extra_specs\u0027, {}).get("},{"line_number":169,"context_line":"                    \u0027snapshot_support\u0027, True) if share_type else True,"},{"line_number":170,"context_line":"                strict\u003dTrue)"},{"line_number":171,"context_line":"            replication \u003d share_type.get(\u0027extra_specs\u0027, {}).get("},{"line_number":172,"context_line":"                \u0027replication\u0027, None) if share_type else None"},{"line_number":173,"context_line":"        except ValueError as e:"},{"line_number":174,"context_line":"            raise exception.InvalidParameterValue(six.text_type(e))"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_e726bd15","line":171,"in_reply_to":"da85f559_af164cef","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":14567,"name":"Rodrigo Barbieri","email":"rodrigo.barbieri2010@gmail.com","username":"ganso"},"change_message_id":"fe76a9113ae4d5b83e057a5813d735652531929d","unresolved":false,"context_lines":[{"line_number":460,"context_line":"        if share_replica_count \u003e 1:"},{"line_number":461,"context_line":"            msg \u003d _(\"Cannot delete a share with replicas.\")"},{"line_number":462,"context_line":"            raise exception.InvalidShare(reason\u003dmsg)"},{"line_number":463,"context_line":""},{"line_number":464,"context_line":"        snapshots \u003d self.db.share_snapshot_get_all_for_share(context, share_id)"},{"line_number":465,"context_line":"        if len(snapshots):"},{"line_number":466,"context_line":"            msg \u003d _(\"Share still has %d dependent snapshots\") % len(snapshots)"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_827804fa","line":463,"updated":"2015-11-13 13:37:11.000000000","message":"Looks like you are already performing this check in /v1/shares.py... I recommend removing from here.","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":460,"context_line":"        if share_replica_count \u003e 1:"},{"line_number":461,"context_line":"            msg \u003d _(\"Cannot delete a share with replicas.\")"},{"line_number":462,"context_line":"            raise exception.InvalidShare(reason\u003dmsg)"},{"line_number":463,"context_line":""},{"line_number":464,"context_line":"        snapshots \u003d self.db.share_snapshot_get_all_for_share(context, share_id)"},{"line_number":465,"context_line":"        if len(snapshots):"},{"line_number":466,"context_line":"            msg \u003d _(\"Share still has %d dependent snapshots\") % len(snapshots)"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_67796dfc","line":463,"in_reply_to":"da85f559_827804fa","updated":"2015-11-19 19:45:53.000000000","message":"Thanks. Will keep the check here and remove it from /v1/shares.py","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"71ba533b590a228a423a3fcdfccc5c8d84bdc4d1","unresolved":false,"context_lines":[{"line_number":298,"context_line":"            consistency_group\u003dNone, host\u003dNone, share_network_id\u003dNone):"},{"line_number":299,"context_line":""},{"line_number":300,"context_line":"        availability_zone_id \u003d None"},{"line_number":301,"context_line":"        if availability_zone:"},{"line_number":302,"context_line":"            availability_zone_id \u003d self.db.availability_zone_get("},{"line_number":303,"context_line":"                context, availability_zone).id"},{"line_number":304,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_7ce35734","line":301,"updated":"2015-11-20 17:08:26.000000000","message":"\"availability_zone_id\" should be expected, not AZ object.","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"e47967aed0fcad689a3aec42a79654a5b12a6c45","unresolved":false,"context_lines":[{"line_number":298,"context_line":"            consistency_group\u003dNone, host\u003dNone, share_network_id\u003dNone):"},{"line_number":299,"context_line":""},{"line_number":300,"context_line":"        availability_zone_id \u003d None"},{"line_number":301,"context_line":"        if availability_zone:"},{"line_number":302,"context_line":"            availability_zone_id \u003d self.db.availability_zone_get("},{"line_number":303,"context_line":"                context, availability_zone).id"},{"line_number":304,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"9a8ffd7b_d467a9e8","line":301,"in_reply_to":"ba8a016a_7ce35734","updated":"2015-12-01 16:30:42.000000000","message":"This is either the AZ ID or the AZ Name..","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"061b886705c42cea2f9f63e8dead3e7ea59c2219","unresolved":false,"context_lines":[{"line_number":311,"context_line":"                \u0027share_network_id\u0027: share_network_id,"},{"line_number":312,"context_line":"                \u0027status\u0027: constants.STATUS_CREATING,"},{"line_number":313,"context_line":"                \u0027scheduled_at\u0027: timeutils.utcnow(),"},{"line_number":314,"context_line":"                \u0027host\u0027: host if host else \u0027\u0027,"},{"line_number":315,"context_line":"                \u0027availability_zone_id\u0027: availability_zone_id,"},{"line_number":316,"context_line":"            }"},{"line_number":317,"context_line":"        )"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_8c8cf1da","line":314,"updated":"2015-11-20 03:30:03.000000000","message":"Should it be None instead of an empty string?","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"3b45c7a4783e66821748ec9cf5859baf7bb088da","unresolved":false,"context_lines":[{"line_number":311,"context_line":"                \u0027share_network_id\u0027: share_network_id,"},{"line_number":312,"context_line":"                \u0027status\u0027: constants.STATUS_CREATING,"},{"line_number":313,"context_line":"                \u0027scheduled_at\u0027: timeutils.utcnow(),"},{"line_number":314,"context_line":"                \u0027host\u0027: host if host else \u0027\u0027,"},{"line_number":315,"context_line":"                \u0027availability_zone_id\u0027: availability_zone_id,"},{"line_number":316,"context_line":"            }"},{"line_number":317,"context_line":"        )"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_4b3336f7","line":314,"in_reply_to":"ba8a016a_8c8cf1da","updated":"2015-11-20 17:09:27.000000000","message":"No Xing, this has to be a string because it is expected as one in all the methods that use the \u0027host\u0027 field for scheduled instances. (They\u0027re performing string ops like split and indexing)\n\nExample:\n\nhttps://github.com/openstack/manila/blob/85c6cc56/manila/share/utils.py#L30","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"71ba533b590a228a423a3fcdfccc5c8d84bdc4d1","unresolved":false,"context_lines":[{"line_number":497,"context_line":""},{"line_number":498,"context_line":"        # NOTE(gouthamr): If the share has more than one replica,"},{"line_number":499,"context_line":"        # it can\u0027t be deleted until the additional replicas are removed."},{"line_number":500,"context_line":"        share_replica_count \u003d share.get(\u0027replica_count\u0027) or 0"},{"line_number":501,"context_line":"        if share_replica_count \u003e 1:"},{"line_number":502,"context_line":"            msg \u003d _(\"Share %s has replicas. Remove the replicas before \""},{"line_number":503,"context_line":"                    \"deleting the share.\") % id"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_dc8043fa","line":500,"updated":"2015-11-20 17:08:26.000000000","message":"Is it right that now, replicated share should be deleted in several \"delete\" operations? If yes, then it looks strange, we should be able to delete all related things at once.","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"e47967aed0fcad689a3aec42a79654a5b12a6c45","unresolved":false,"context_lines":[{"line_number":497,"context_line":""},{"line_number":498,"context_line":"        # NOTE(gouthamr): If the share has more than one replica,"},{"line_number":499,"context_line":"        # it can\u0027t be deleted until the additional replicas are removed."},{"line_number":500,"context_line":"        share_replica_count \u003d share.get(\u0027replica_count\u0027) or 0"},{"line_number":501,"context_line":"        if share_replica_count \u003e 1:"},{"line_number":502,"context_line":"            msg \u003d _(\"Share %s has replicas. Remove the replicas before \""},{"line_number":503,"context_line":"                    \"deleting the share.\") % id"}],"source_content_type":"text/x-python","patch_set":4,"id":"9a8ffd7b_549ad9c6","line":500,"in_reply_to":"ba8a016a_dc8043fa","updated":"2015-12-01 16:30:42.000000000","message":"In two ops.. get rid of the replicas, then get rid of the share. \n\nThis is just like snapshots, isn\u0027t it?","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"061b886705c42cea2f9f63e8dead3e7ea59c2219","unresolved":false,"context_lines":[{"line_number":658,"context_line":"        # Ensure share does not have replicas. Currently share migrations"},{"line_number":659,"context_line":"        # are disallowed for replicated shares."},{"line_number":660,"context_line":"        share_replica_count \u003d share.get(\u0027replica_count\u0027) or 0"},{"line_number":661,"context_line":"        if share_replica_count \u003e 1:"},{"line_number":662,"context_line":"            msg \u003d _(\u0027Share %s has replicas. Remove the replicas before \u0027"},{"line_number":663,"context_line":"                    \u0027attempting to migrate the share.\u0027) % share[\u0027id\u0027]"},{"line_number":664,"context_line":"            LOG.error(msg)"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_afc20783","line":661,"updated":"2015-11-20 03:30:03.000000000","message":"Should this be \"if share_replica_count \u003e 0\"?  According to the comments, migrate share is not allowed if a share has any replica.","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"71ba533b590a228a423a3fcdfccc5c8d84bdc4d1","unresolved":false,"context_lines":[{"line_number":658,"context_line":"        # Ensure share does not have replicas. Currently share migrations"},{"line_number":659,"context_line":"        # are disallowed for replicated shares."},{"line_number":660,"context_line":"        share_replica_count \u003d share.get(\u0027replica_count\u0027) or 0"},{"line_number":661,"context_line":"        if share_replica_count \u003e 1:"},{"line_number":662,"context_line":"            msg \u003d _(\u0027Share %s has replicas. Remove the replicas before \u0027"},{"line_number":663,"context_line":"                    \u0027attempting to migrate the share.\u0027) % share[\u0027id\u0027]"},{"line_number":664,"context_line":"            LOG.error(msg)"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_3ce14fd1","line":661,"in_reply_to":"ba8a016a_afc20783","updated":"2015-11-20 17:08:26.000000000","message":"If I understand correctly, then condition here is ok, because \"absence of replication\" equals to \"share_replica_count\u003d1\".","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"3b45c7a4783e66821748ec9cf5859baf7bb088da","unresolved":false,"context_lines":[{"line_number":658,"context_line":"        # Ensure share does not have replicas. Currently share migrations"},{"line_number":659,"context_line":"        # are disallowed for replicated shares."},{"line_number":660,"context_line":"        share_replica_count \u003d share.get(\u0027replica_count\u0027) or 0"},{"line_number":661,"context_line":"        if share_replica_count \u003e 1:"},{"line_number":662,"context_line":"            msg \u003d _(\u0027Share %s has replicas. Remove the replicas before \u0027"},{"line_number":663,"context_line":"                    \u0027attempting to migrate the share.\u0027) % share[\u0027id\u0027]"},{"line_number":664,"context_line":"            LOG.error(msg)"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_8bc91e5d","line":661,"in_reply_to":"ba8a016a_afc20783","updated":"2015-11-20 17:09:27.000000000","message":"replica_count is also counting the primary share instance. In the design, we thought about how we can define or classify a primary instance from the copies.\n\nWould a primary instance be the \u0027active\u0027 instance? In that case, in a \u0027writable\u0027 style of replication, all instances would be \u0027active\u0027. \n\nWe then asked if we really should worry about the primary instance... \n\nSo we stuck to the notion that for a replicated share, all the instances that have their replica_state set to something other than None should be treated as replicas. So this \u0027replica_count\u0027 considers the primary instance as well. \n\nI added a docstring to clarify this in all places this value is used and defined. \n\nWould that work?","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":15100,"name":"zhongjun","email":"jun.zhongjun2@gmail.com","username":"zhongjun2"},"change_message_id":"2c5aaab86189d038d8d04736300c2cec2fd4719a","unresolved":false,"context_lines":[{"line_number":169,"context_line":"                    \u0027snapshot_support\u0027, True) if share_type else True,"},{"line_number":170,"context_line":"                strict\u003dTrue)"},{"line_number":171,"context_line":"            replication_type \u003d share_type.get(\u0027extra_specs\u0027, {}).get("},{"line_number":172,"context_line":"                \u0027replication_type\u0027, None) if share_type else None"},{"line_number":173,"context_line":"        except ValueError as e:"},{"line_number":174,"context_line":"            raise exception.InvalidParameterValue(six.text_type(e))"},{"line_number":175,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"3a7e1126_efe5a4a3","line":172,"range":{"start_line":172,"start_character":36,"end_line":172,"end_character":40},"updated":"2015-12-21 07:16:47.000000000","message":"None is the default for dict\u0027s get method:\nhttps://docs.python.org/2/library/stdtypes.html#dict.get\n\ns/get(\u0027replication_type\u0027, None)/get(\u0027replication_type\u0027)","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"32ae9a9907eb4d488a7df8a40b98dc8c26616485","unresolved":false,"context_lines":[{"line_number":169,"context_line":"                    \u0027snapshot_support\u0027, True) if share_type else True,"},{"line_number":170,"context_line":"                strict\u003dTrue)"},{"line_number":171,"context_line":"            replication_type \u003d share_type.get(\u0027extra_specs\u0027, {}).get("},{"line_number":172,"context_line":"                \u0027replication_type\u0027, None) if share_type else None"},{"line_number":173,"context_line":"        except ValueError as e:"},{"line_number":174,"context_line":"            raise exception.InvalidParameterValue(six.text_type(e))"},{"line_number":175,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"1a7b0d38_7804b17d","line":172,"range":{"start_line":172,"start_character":36,"end_line":172,"end_character":40},"in_reply_to":"3a7e1126_efe5a4a3","updated":"2015-12-23 09:13:55.000000000","message":"Yes it is.. I was being consistent with some other places where dict get was used here. I\u0027ll update this in the next patchset.","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"56c3e93a257daee2390d00f4ba887f982bf3e4d8","unresolved":false,"context_lines":[{"line_number":325,"context_line":"                context, share[\u0027share_type_id\u0027])"},{"line_number":326,"context_line":"        request_spec \u003d {"},{"line_number":327,"context_line":"            \u0027share_properties\u0027: share_instance_with_share_data,"},{"line_number":328,"context_line":"            \u0027share_instance_properties\u0027: share_instance.to_dict(),"},{"line_number":329,"context_line":"            \u0027share_proto\u0027: share[\u0027share_proto\u0027],"},{"line_number":330,"context_line":"            \u0027share_id\u0027: share[\u0027id\u0027],"},{"line_number":331,"context_line":"            \u0027snapshot_id\u0027: share[\u0027snapshot_id\u0027],"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a7b0d38_2248ea2c","line":328,"range":{"start_line":328,"start_character":56,"end_line":328,"end_character":65},"updated":"2015-12-25 17:04:54.000000000","message":"Please, do no use \"to_dict\" translation. This method and its usage, IMHO, should be eliminated. Construct dict setting only expected keys.\n\nExample: https://review.openstack.org/#/c/251930/34/manila/share/api.py","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"0aace059b282267e3e01c44cbb73c7bc0b3213f4","unresolved":false,"context_lines":[{"line_number":325,"context_line":"                context, share[\u0027share_type_id\u0027])"},{"line_number":326,"context_line":"        request_spec \u003d {"},{"line_number":327,"context_line":"            \u0027share_properties\u0027: share_instance_with_share_data,"},{"line_number":328,"context_line":"            \u0027share_instance_properties\u0027: share_instance.to_dict(),"},{"line_number":329,"context_line":"            \u0027share_proto\u0027: share[\u0027share_proto\u0027],"},{"line_number":330,"context_line":"            \u0027share_id\u0027: share[\u0027id\u0027],"},{"line_number":331,"context_line":"            \u0027snapshot_id\u0027: share[\u0027snapshot_id\u0027],"}],"source_content_type":"text/x-python","patch_set":14,"id":"9a68dd71_6cd41ceb","line":328,"range":{"start_line":328,"start_character":56,"end_line":328,"end_character":65},"in_reply_to":"1a7b0d38_2248ea2c","updated":"2016-01-26 03:46:07.000000000","message":"I got this fix for free when 251930 merged. Thanks.","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"56c3e93a257daee2390d00f4ba887f982bf3e4d8","unresolved":false,"context_lines":[{"line_number":388,"context_line":"            self.db.share_replica_update("},{"line_number":389,"context_line":"                context, share_replica[\u0027id\u0027],"},{"line_number":390,"context_line":"                {\u0027status\u0027: constants.STATUS_DELETING,"},{"line_number":391,"context_line":"                 \u0027terminated_at\u0027: timeutils.utcnow()}"},{"line_number":392,"context_line":"            )"},{"line_number":393,"context_line":""},{"line_number":394,"context_line":"            self.share_rpcapi.delete_share_replica("}],"source_content_type":"text/x-python","patch_set":14,"id":"1a7b0d38_c26d6699","line":391,"updated":"2015-12-25 17:04:54.000000000","message":"\"terminated_at\" seems to be \"finished\" action, but you set \"transitional\" status. These are incompatible. I guess, you should use \"soft_delete()\" method here.","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"0aace059b282267e3e01c44cbb73c7bc0b3213f4","unresolved":false,"context_lines":[{"line_number":388,"context_line":"            self.db.share_replica_update("},{"line_number":389,"context_line":"                context, share_replica[\u0027id\u0027],"},{"line_number":390,"context_line":"                {\u0027status\u0027: constants.STATUS_DELETING,"},{"line_number":391,"context_line":"                 \u0027terminated_at\u0027: timeutils.utcnow()}"},{"line_number":392,"context_line":"            )"},{"line_number":393,"context_line":""},{"line_number":394,"context_line":"            self.share_rpcapi.delete_share_replica("}],"source_content_type":"text/x-python","patch_set":14,"id":"9a68dd71_8c24f00c","line":391,"in_reply_to":"1a7b0d38_c26d6699","updated":"2016-01-26 03:46:07.000000000","message":"That seems semantically right. How about these instances though?\n\n1) https://github.com/openstack/manila/blob/master/manila/share/api.py#L391\n \n2) https://github.com/openstack/manila/blob/master/manila/share/api.py#L464","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"56c3e93a257daee2390d00f4ba887f982bf3e4d8","unresolved":false,"context_lines":[{"line_number":503,"context_line":"        if share_replica_count \u003e 1:"},{"line_number":504,"context_line":"            msg \u003d _(\"Share %s has replicas. Remove the replicas before \""},{"line_number":505,"context_line":"                    \"deleting the share.\") % id"},{"line_number":506,"context_line":"            raise exception.InvalidShare(message\u003dmsg)"},{"line_number":507,"context_line":""},{"line_number":508,"context_line":"        snapshots \u003d self.db.share_snapshot_get_all_for_share(context, share_id)"},{"line_number":509,"context_line":"        if len(snapshots):"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a7b0d38_822d1e48","line":506,"range":{"start_line":506,"start_character":28,"end_line":506,"end_character":40},"updated":"2015-12-25 17:04:54.000000000","message":"Why \"InvalidShare\"? \"Forbidden\"?","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":177,"name":"Alex Meade","email":"mr.alex.meade@gmail.com","username":"alex-meade"},"change_message_id":"b2bb7af1baf8b66101e757dafd3c9658c0448f0b","unresolved":false,"context_lines":[{"line_number":503,"context_line":"        if share_replica_count \u003e 1:"},{"line_number":504,"context_line":"            msg \u003d _(\"Share %s has replicas. Remove the replicas before \""},{"line_number":505,"context_line":"                    \"deleting the share.\") % id"},{"line_number":506,"context_line":"            raise exception.InvalidShare(message\u003dmsg)"},{"line_number":507,"context_line":""},{"line_number":508,"context_line":"        snapshots \u003d self.db.share_snapshot_get_all_for_share(context, share_id)"},{"line_number":509,"context_line":"        if len(snapshots):"}],"source_content_type":"text/x-python","patch_set":14,"id":"da6ed579_105be52f","line":506,"range":{"start_line":506,"start_character":28,"end_line":506,"end_character":40},"in_reply_to":"1a7b0d38_822d1e48","updated":"2016-01-13 02:42:15.000000000","message":"This should result in an HTTP 409. Not forbidden, forbidden means the user is not authorized to do the action and never will be. 409 is that the resource (share) is in a state where you cannot perform the action, but this state can be resolved and the action retried.","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"0aace059b282267e3e01c44cbb73c7bc0b3213f4","unresolved":false,"context_lines":[{"line_number":503,"context_line":"        if share_replica_count \u003e 1:"},{"line_number":504,"context_line":"            msg \u003d _(\"Share %s has replicas. Remove the replicas before \""},{"line_number":505,"context_line":"                    \"deleting the share.\") % id"},{"line_number":506,"context_line":"            raise exception.InvalidShare(message\u003dmsg)"},{"line_number":507,"context_line":""},{"line_number":508,"context_line":"        snapshots \u003d self.db.share_snapshot_get_all_for_share(context, share_id)"},{"line_number":509,"context_line":"        if len(snapshots):"}],"source_content_type":"text/x-python","patch_set":14,"id":"9a68dd71_6c709c0b","line":506,"range":{"start_line":506,"start_character":28,"end_line":506,"end_character":40},"in_reply_to":"da6ed579_105be52f","updated":"2016-01-26 03:46:07.000000000","message":"+1 on 409 HTTPConflict. Updated.","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"56c3e93a257daee2390d00f4ba887f982bf3e4d8","unresolved":false,"context_lines":[{"line_number":657,"context_line":""},{"line_number":658,"context_line":"        share_instance \u003d share.instance"},{"line_number":659,"context_line":""},{"line_number":660,"context_line":"        # NOTE(gouthamr) Ensure share does not have replicas."},{"line_number":661,"context_line":"        # Currently share migrations are disallowed for replicated shares."},{"line_number":662,"context_line":"        # replica_count includes all instances of the share that have their"},{"line_number":663,"context_line":"        # replica_state set to anything but \u0027None\u0027."}],"source_content_type":"text/x-python","patch_set":14,"id":"1a7b0d38_02228e52","line":660,"range":{"start_line":660,"start_character":14,"end_line":660,"end_character":25},"updated":"2015-12-25 17:04:54.000000000","message":"NOTE(gouthamr): foo\n              _","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"0aace059b282267e3e01c44cbb73c7bc0b3213f4","unresolved":false,"context_lines":[{"line_number":657,"context_line":""},{"line_number":658,"context_line":"        share_instance \u003d share.instance"},{"line_number":659,"context_line":""},{"line_number":660,"context_line":"        # NOTE(gouthamr) Ensure share does not have replicas."},{"line_number":661,"context_line":"        # Currently share migrations are disallowed for replicated shares."},{"line_number":662,"context_line":"        # replica_count includes all instances of the share that have their"},{"line_number":663,"context_line":"        # replica_state set to anything but \u0027None\u0027."}],"source_content_type":"text/x-python","patch_set":14,"id":"9a68dd71_af58c68a","line":660,"range":{"start_line":660,"start_character":14,"end_line":660,"end_character":25},"in_reply_to":"1a7b0d38_02228e52","updated":"2016-01-26 03:46:07.000000000","message":"Done. Thanks","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"56c3e93a257daee2390d00f4ba887f982bf3e4d8","unresolved":false,"context_lines":[{"line_number":666,"context_line":"            msg \u003d _(\u0027Share %s has replicas. Remove the replicas before \u0027"},{"line_number":667,"context_line":"                    \u0027attempting to migrate the share.\u0027) % share[\u0027id\u0027]"},{"line_number":668,"context_line":"            LOG.error(msg)"},{"line_number":669,"context_line":"            raise exception.InvalidShare(reason\u003dmsg)"},{"line_number":670,"context_line":""},{"line_number":671,"context_line":"        # We only handle \"available\" share for now"},{"line_number":672,"context_line":"        if share_instance[\u0027status\u0027] !\u003d constants.STATUS_AVAILABLE:"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a7b0d38_a2d7fa21","line":669,"range":{"start_line":669,"start_character":28,"end_line":669,"end_character":40},"updated":"2015-12-25 17:04:54.000000000","message":"Same here as above. Also, it duplicates block of code and better to split it to separate private method.","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"0aace059b282267e3e01c44cbb73c7bc0b3213f4","unresolved":false,"context_lines":[{"line_number":666,"context_line":"            msg \u003d _(\u0027Share %s has replicas. Remove the replicas before \u0027"},{"line_number":667,"context_line":"                    \u0027attempting to migrate the share.\u0027) % share[\u0027id\u0027]"},{"line_number":668,"context_line":"            LOG.error(msg)"},{"line_number":669,"context_line":"            raise exception.InvalidShare(reason\u003dmsg)"},{"line_number":670,"context_line":""},{"line_number":671,"context_line":"        # We only handle \"available\" share for now"},{"line_number":672,"context_line":"        if share_instance[\u0027status\u0027] !\u003d constants.STATUS_AVAILABLE:"}],"source_content_type":"text/x-python","patch_set":14,"id":"9a68dd71_0fcd5230","line":669,"range":{"start_line":669,"start_character":28,"end_line":669,"end_character":40},"in_reply_to":"1a7b0d38_a2d7fa21","updated":"2016-01-26 03:46:07.000000000","message":"Would you still want this behavior after the has_replicas property?","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"123033e1de89dae676f8dd0a65834cf5be2bc10c","unresolved":false,"context_lines":[{"line_number":530,"context_line":"        if share.has_replicas:"},{"line_number":531,"context_line":"            msg \u003d _(\"Share %s has replicas. Remove the replicas before \""},{"line_number":532,"context_line":"                    \"deleting the share.\") % id"},{"line_number":533,"context_line":"            raise exception.Conflict(message\u003dmsg)"},{"line_number":534,"context_line":""},{"line_number":535,"context_line":"        snapshots \u003d self.db.share_snapshot_get_all_for_share(context, share_id)"},{"line_number":536,"context_line":"        if len(snapshots):"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a5ae5dd_b9c1b0e6","line":533,"updated":"2016-02-04 03:07:17.000000000","message":"exception.Conflict(err\u003dmsg)","commit_id":"08e8c095b09c875b4940a292067029e9e2fc9065"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"95ff3f899fc56904d8ef54c3fe5171211ff0a5ca","unresolved":false,"context_lines":[{"line_number":530,"context_line":"        if share.has_replicas:"},{"line_number":531,"context_line":"            msg \u003d _(\"Share %s has replicas. Remove the replicas before \""},{"line_number":532,"context_line":"                    \"deleting the share.\") % id"},{"line_number":533,"context_line":"            raise exception.Conflict(message\u003dmsg)"},{"line_number":534,"context_line":""},{"line_number":535,"context_line":"        snapshots \u003d self.db.share_snapshot_get_all_for_share(context, share_id)"},{"line_number":536,"context_line":"        if len(snapshots):"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a5ae5dd_29e685b0","line":533,"in_reply_to":"5a5ae5dd_b9c1b0e6","updated":"2016-02-07 16:24:09.000000000","message":"Done","commit_id":"08e8c095b09c875b4940a292067029e9e2fc9065"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"0c389735b2181ef92ac362ac53ccc3e90c544770","unresolved":false,"context_lines":[{"line_number":366,"context_line":"        }"},{"line_number":367,"context_line":"        return request_spec, share_instance"},{"line_number":368,"context_line":""},{"line_number":369,"context_line":"    def create_share_replica(self, context, share, availability_zone\u003dNone,"},{"line_number":370,"context_line":"                             share_network_id\u003dNone):"},{"line_number":371,"context_line":""},{"line_number":372,"context_line":"        if not share.get(\u0027replication_type\u0027):"},{"line_number":373,"context_line":"            msg \u003d _(\"Replication not supported for share %s.\")"},{"line_number":374,"context_line":"            raise exception.InvalidShare(message\u003dmsg % share[\u0027id\u0027])"},{"line_number":375,"context_line":""},{"line_number":376,"context_line":"        self._check_is_share_busy(share)"},{"line_number":377,"context_line":""},{"line_number":378,"context_line":"        if not self.db.share_replicas_get_available_active_replica("},{"line_number":379,"context_line":"                context, share[\u0027id\u0027]):"},{"line_number":380,"context_line":"            msg \u003d _(\"Share %s does not have any active replica in available \""},{"line_number":381,"context_line":"                    \"state.\")"},{"line_number":382,"context_line":"            raise exception.ReplicationException(reason\u003dmsg % share[\u0027id\u0027])"},{"line_number":383,"context_line":""},{"line_number":384,"context_line":"        request_spec, share_replica \u003d ("},{"line_number":385,"context_line":"            self._create_share_instance_and_get_request_spec("},{"line_number":386,"context_line":"                context, share, availability_zone\u003davailability_zone,"},{"line_number":387,"context_line":"                share_network_id\u003dshare_network_id))"},{"line_number":388,"context_line":""},{"line_number":389,"context_line":"        self.db.share_replica_update("},{"line_number":390,"context_line":"            context, share_replica[\u0027id\u0027],"},{"line_number":391,"context_line":"            {\u0027replica_state\u0027: constants.REPLICA_STATE_OUT_OF_SYNC})"},{"line_number":392,"context_line":""},{"line_number":393,"context_line":"        self.scheduler_rpcapi.create_share_replica("},{"line_number":394,"context_line":"            context, request_spec\u003drequest_spec, filter_properties\u003d{})"},{"line_number":395,"context_line":""},{"line_number":396,"context_line":"        return share_replica"},{"line_number":397,"context_line":""},{"line_number":398,"context_line":"    def delete_share_replica(self, context, share_replica):"},{"line_number":399,"context_line":"        # Disallow deletion of ONLY active replica"}],"source_content_type":"text/x-python","patch_set":27,"id":"5a5ae5dd_09e584a6","line":396,"range":{"start_line":369,"start_character":4,"end_line":396,"end_character":28},"updated":"2016-02-07 16:45:13.000000000","message":"Replication feature should be covered with Manila quotas. Right now any user can create any amount of replicas that is completely unacceptable.","commit_id":"76561d28d20260ac52ca3b18002c71b342020813"}],"manila/share/driver.py":[{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"7a6638d6f2d08c50908d44eb13264466627f6118","unresolved":false,"context_lines":[{"line_number":1286,"context_line":"        \"\"\""},{"line_number":1287,"context_line":"        raise NotImplementedError()"},{"line_number":1288,"context_line":""},{"line_number":1289,"context_line":"    def update_replica_status(self, context, replica, share_server\u003dNone):"},{"line_number":1290,"context_line":"        \"\"\"Update the status and replica_state of a replica."},{"line_number":1291,"context_line":""},{"line_number":1292,"context_line":"        Drivers should fix replication relationships that were broken if"}],"source_content_type":"text/x-python","patch_set":1,"id":"da85f559_52454040","line":1289,"updated":"2015-11-12 16:08:44.000000000","message":"Here \"status\"","commit_id":"dac7938116cfdbee468b3fbdfe42a3ab397fd347"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1d44846ad1c530ff7c7ed1dcf4ce2265bb331768","unresolved":false,"context_lines":[{"line_number":1286,"context_line":"        \"\"\""},{"line_number":1287,"context_line":"        raise NotImplementedError()"},{"line_number":1288,"context_line":""},{"line_number":1289,"context_line":"    def update_replica_status(self, context, replica, share_server\u003dNone):"},{"line_number":1290,"context_line":"        \"\"\"Update the status and replica_state of a replica."},{"line_number":1291,"context_line":""},{"line_number":1292,"context_line":"        Drivers should fix replication relationships that were broken if"}],"source_content_type":"text/x-python","patch_set":1,"id":"ba8a016a_6763ad1b","line":1289,"in_reply_to":"da85f559_52454040","updated":"2015-11-19 19:44:49.000000000","message":"Artifact from a previous version of the method. Thanks for noticing.","commit_id":"dac7938116cfdbee468b3fbdfe42a3ab397fd347"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"7a6638d6f2d08c50908d44eb13264466627f6118","unresolved":false,"context_lines":[{"line_number":1315,"context_line":"            \u0027share_server_id\u0027: \u00274ce78e7b-0ef6-4730-ac2a-fd2defefbd05\u0027,"},{"line_number":1316,"context_line":"            }"},{"line_number":1317,"context_line":"        :param share_server: \u003cmodels.ShareServer\u003e._as_dict() or None"},{"line_number":1318,"context_line":"        :return: replica_state"},{"line_number":1319,"context_line":"            replica_state - a str value denoting the replica_state that the"},{"line_number":1320,"context_line":"            replica can have. Valid values are \u0027in_sync\u0027 and \u0027out_of_sync\u0027"},{"line_number":1321,"context_line":"            or None (to leave the current replica_state unchanged)."}],"source_content_type":"text/x-python","patch_set":1,"id":"da85f559_b2a34cff","line":1318,"updated":"2015-11-12 16:08:44.000000000","message":"here \"state\". Same in other places. Please, choose one and use it everywhere.","commit_id":"dac7938116cfdbee468b3fbdfe42a3ab397fd347"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1d44846ad1c530ff7c7ed1dcf4ce2265bb331768","unresolved":false,"context_lines":[{"line_number":1315,"context_line":"            \u0027share_server_id\u0027: \u00274ce78e7b-0ef6-4730-ac2a-fd2defefbd05\u0027,"},{"line_number":1316,"context_line":"            }"},{"line_number":1317,"context_line":"        :param share_server: \u003cmodels.ShareServer\u003e._as_dict() or None"},{"line_number":1318,"context_line":"        :return: replica_state"},{"line_number":1319,"context_line":"            replica_state - a str value denoting the replica_state that the"},{"line_number":1320,"context_line":"            replica can have. Valid values are \u0027in_sync\u0027 and \u0027out_of_sync\u0027"},{"line_number":1321,"context_line":"            or None (to leave the current replica_state unchanged)."}],"source_content_type":"text/x-python","patch_set":1,"id":"ba8a016a_874fb191","line":1318,"in_reply_to":"da85f559_b2a34cff","updated":"2015-11-19 19:44:49.000000000","message":"Corrected method name","commit_id":"dac7938116cfdbee468b3fbdfe42a3ab397fd347"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"71ba533b590a228a423a3fcdfccc5c8d84bdc4d1","unresolved":false,"context_lines":[{"line_number":1058,"context_line":"        \"\"\""},{"line_number":1059,"context_line":"        return share_instances"},{"line_number":1060,"context_line":""},{"line_number":1061,"context_line":"    def create_replica(self, context, active_replica, new_replica,"},{"line_number":1062,"context_line":"                       access_rules, share_server\u003dNone):"},{"line_number":1063,"context_line":"        \"\"\"Replicate the active replica to a new replica on this backend."},{"line_number":1064,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_d7333c61","line":1061,"updated":"2015-11-20 17:08:26.000000000","message":"Please, add unit tests for these new methods that will verify their presence and raise of expected exception.","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"e47967aed0fcad689a3aec42a79654a5b12a6c45","unresolved":false,"context_lines":[{"line_number":1058,"context_line":"        \"\"\""},{"line_number":1059,"context_line":"        return share_instances"},{"line_number":1060,"context_line":""},{"line_number":1061,"context_line":"    def create_replica(self, context, active_replica, new_replica,"},{"line_number":1062,"context_line":"                       access_rules, share_server\u003dNone):"},{"line_number":1063,"context_line":"        \"\"\"Replicate the active replica to a new replica on this backend."},{"line_number":1064,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"9a8ffd7b_f4caed6d","line":1061,"in_reply_to":"ba8a016a_d7333c61","updated":"2015-12-01 16:30:42.000000000","message":"Done","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"061b886705c42cea2f9f63e8dead3e7ea59c2219","unresolved":false,"context_lines":[{"line_number":1062,"context_line":"                       access_rules, share_server\u003dNone):"},{"line_number":1063,"context_line":"        \"\"\"Replicate the active replica to a new replica on this backend."},{"line_number":1064,"context_line":""},{"line_number":1065,"context_line":"        :param context:Current context"},{"line_number":1066,"context_line":"        :param active_replica: A current active replica instance dictionary."},{"line_number":1067,"context_line":"            EXAMPLE:"},{"line_number":1068,"context_line":"             .. code::"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_0f2f933f","line":1065,"updated":"2015-11-20 03:30:03.000000000","message":"missing space before \"Current\".","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"3b45c7a4783e66821748ec9cf5859baf7bb088da","unresolved":false,"context_lines":[{"line_number":1062,"context_line":"                       access_rules, share_server\u003dNone):"},{"line_number":1063,"context_line":"        \"\"\"Replicate the active replica to a new replica on this backend."},{"line_number":1064,"context_line":""},{"line_number":1065,"context_line":"        :param context:Current context"},{"line_number":1066,"context_line":"        :param active_replica: A current active replica instance dictionary."},{"line_number":1067,"context_line":"            EXAMPLE:"},{"line_number":1068,"context_line":"             .. code::"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_46e48bab","line":1065,"in_reply_to":"ba8a016a_0f2f933f","updated":"2015-11-20 17:09:27.000000000","message":"Done","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"56c3e93a257daee2390d00f4ba887f982bf3e4d8","unresolved":false,"context_lines":[{"line_number":1068,"context_line":"             .. code::"},{"line_number":1069,"context_line":""},{"line_number":1070,"context_line":"            {"},{"line_number":1071,"context_line":"            \u0027id\u0027: \u0027d487b88d-e428-4230-a465-a800c2cce5f8\u0027,"},{"line_number":1072,"context_line":"            \u0027share_id\u0027: \u0027f0e4bb5e-65f0-11e5-9d70-feff819cdc9f\u0027,"},{"line_number":1073,"context_line":"            \u0027deleted\u0027: False,"},{"line_number":1074,"context_line":"            \u0027host\u0027: \u0027openstack2@cmodeSSVMNFS1\u0027,"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a7b0d38_42b5f6eb","line":1071,"range":{"start_line":1071,"start_character":33,"end_line":1071,"end_character":37},"updated":"2015-12-25 17:04:54.000000000","message":"Better not to use real-like example values.\n\n{\n    \u0027id\u0027: \u0027FOO-UUID\u0027,\n    \u0027share_id\u0027: \u0027BAR-UUID\u0027,\n    ...\n}","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"0aace059b282267e3e01c44cbb73c7bc0b3213f4","unresolved":false,"context_lines":[{"line_number":1068,"context_line":"             .. code::"},{"line_number":1069,"context_line":""},{"line_number":1070,"context_line":"            {"},{"line_number":1071,"context_line":"            \u0027id\u0027: \u0027d487b88d-e428-4230-a465-a800c2cce5f8\u0027,"},{"line_number":1072,"context_line":"            \u0027share_id\u0027: \u0027f0e4bb5e-65f0-11e5-9d70-feff819cdc9f\u0027,"},{"line_number":1073,"context_line":"            \u0027deleted\u0027: False,"},{"line_number":1074,"context_line":"            \u0027host\u0027: \u0027openstack2@cmodeSSVMNFS1\u0027,"}],"source_content_type":"text/x-python","patch_set":14,"id":"9a68dd71_ca0ac81f","line":1071,"range":{"start_line":1071,"start_character":33,"end_line":1071,"end_character":37},"in_reply_to":"1a7b0d38_42b5f6eb","updated":"2016-01-26 03:46:07.000000000","message":"Being consistent with other driver documentation in this file.. bswartz prefers being explicit. however, I did abstract some models for reason stated below.","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"56c3e93a257daee2390d00f4ba887f982bf3e4d8","unresolved":false,"context_lines":[{"line_number":1083,"context_line":"            ],"},{"line_number":1084,"context_line":"            \u0027share_network_id\u0027: \u00274ccd5318-65f1-11e5-9d70-feff819cdc9f\u0027,"},{"line_number":1085,"context_line":"            \u0027share_server_id\u0027: \u00274ce78e7b-0ef6-4730-ac2a-fd2defefbd05\u0027,"},{"line_number":1086,"context_line":"            \u0027share_server\u0027: \u003cmodels.ShareServer\u003e._as_dict() or None,"},{"line_number":1087,"context_line":"            }"},{"line_number":1088,"context_line":"        :param new_replica: The share replica dictionary."},{"line_number":1089,"context_line":"            EXAMPLE:"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a7b0d38_e2ed02f0","line":1086,"range":{"start_line":1086,"start_character":49,"end_line":1086,"end_character":59},"updated":"2015-12-25 17:04:54.000000000","message":"\"_as_dict()\"?","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"0aace059b282267e3e01c44cbb73c7bc0b3213f4","unresolved":false,"context_lines":[{"line_number":1083,"context_line":"            ],"},{"line_number":1084,"context_line":"            \u0027share_network_id\u0027: \u00274ccd5318-65f1-11e5-9d70-feff819cdc9f\u0027,"},{"line_number":1085,"context_line":"            \u0027share_server_id\u0027: \u00274ce78e7b-0ef6-4730-ac2a-fd2defefbd05\u0027,"},{"line_number":1086,"context_line":"            \u0027share_server\u0027: \u003cmodels.ShareServer\u003e._as_dict() or None,"},{"line_number":1087,"context_line":"            }"},{"line_number":1088,"context_line":"        :param new_replica: The share replica dictionary."},{"line_number":1089,"context_line":"            EXAMPLE:"}],"source_content_type":"text/x-python","patch_set":14,"id":"9a68dd71_af10c659","line":1086,"range":{"start_line":1086,"start_character":49,"end_line":1086,"end_character":59},"in_reply_to":"1a7b0d38_e2ed02f0","updated":"2016-01-26 03:46:07.000000000","message":":) go easy on that one. Would be messy to expand all internal models..","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"d1755246f54a6f982803dacf1b62917e2a30f9ac","unresolved":false,"context_lines":[{"line_number":617,"context_line":"        should be added/deleted. Driver can ignore rules in \u0027access_rules\u0027 and"},{"line_number":618,"context_line":"        apply only rules from \u0027add_rules\u0027 and \u0027delete_rules\u0027."},{"line_number":619,"context_line":""},{"line_number":620,"context_line":"        Drivers must be mindful of this call for share replicas. When"},{"line_number":621,"context_line":"        \u0027update_access\u0027 is called on one of the replicas, the call is likely"},{"line_number":622,"context_line":"        propagated to all replicas belonging to the share, especially when"},{"line_number":623,"context_line":"        individual rules  are added or removed. If a particular access rule"},{"line_number":624,"context_line":"        does not make sense to the driver in the context of a given replica,"},{"line_number":625,"context_line":"        the driver should be careful to report a correct behavior. Note that"},{"line_number":626,"context_line":"        raising an exception *will* result in the access_rules_status on the"},{"line_number":627,"context_line":"        replica, and the share itself being \"out_of_sync\". Drivers can sync"},{"line_number":628,"context_line":"        on the valid access rules that are provided on the create_replica"},{"line_number":629,"context_line":"        and promote_replica calls."},{"line_number":630,"context_line":""},{"line_number":631,"context_line":"        :param context: Current context"},{"line_number":632,"context_line":"        :param share: Share model with share data."}],"source_content_type":"text/x-python","patch_set":23,"id":"7a5de9d1_d843a4ad","line":629,"range":{"start_line":620,"start_character":8,"end_line":629,"end_character":33},"updated":"2016-02-01 17:38:54.000000000","message":"So, what should driver do in case of \"readable\" replica and RW rules? Just apply all rules as RO?","commit_id":"08799ad6674f3bd54a1fd9984ad78dbd8e862a93"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"46d881f3f99c89564e0743a1e2b74cef64d9d07f","unresolved":false,"context_lines":[{"line_number":617,"context_line":"        should be added/deleted. Driver can ignore rules in \u0027access_rules\u0027 and"},{"line_number":618,"context_line":"        apply only rules from \u0027add_rules\u0027 and \u0027delete_rules\u0027."},{"line_number":619,"context_line":""},{"line_number":620,"context_line":"        Drivers must be mindful of this call for share replicas. When"},{"line_number":621,"context_line":"        \u0027update_access\u0027 is called on one of the replicas, the call is likely"},{"line_number":622,"context_line":"        propagated to all replicas belonging to the share, especially when"},{"line_number":623,"context_line":"        individual rules  are added or removed. If a particular access rule"},{"line_number":624,"context_line":"        does not make sense to the driver in the context of a given replica,"},{"line_number":625,"context_line":"        the driver should be careful to report a correct behavior. Note that"},{"line_number":626,"context_line":"        raising an exception *will* result in the access_rules_status on the"},{"line_number":627,"context_line":"        replica, and the share itself being \"out_of_sync\". Drivers can sync"},{"line_number":628,"context_line":"        on the valid access rules that are provided on the create_replica"},{"line_number":629,"context_line":"        and promote_replica calls."},{"line_number":630,"context_line":""},{"line_number":631,"context_line":"        :param context: Current context"},{"line_number":632,"context_line":"        :param share: Share model with share data."}],"source_content_type":"text/x-python","patch_set":23,"id":"7a5de9d1_132eecfa","line":629,"range":{"start_line":620,"start_character":8,"end_line":629,"end_character":33},"in_reply_to":"7a5de9d1_d843a4ad","updated":"2016-02-02 02:45:12.000000000","message":"True. I\u0027ve added another line to clarify this.","commit_id":"08799ad6674f3bd54a1fd9984ad78dbd8e862a93"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"123033e1de89dae676f8dd0a65834cf5be2bc10c","unresolved":false,"context_lines":[{"line_number":620,"context_line":"        Drivers must be mindful of this call for share replicas. When"},{"line_number":621,"context_line":"        \u0027update_access\u0027 is called on one of the replicas, the call is likely"},{"line_number":622,"context_line":"        propagated to all replicas belonging to the share, especially when"},{"line_number":623,"context_line":"        individual rules  are added or removed. If a particular access rule"},{"line_number":624,"context_line":"        does not make sense to the driver in the context of a given replica,"},{"line_number":625,"context_line":"        the driver should be careful to report a correct behavior, and take"},{"line_number":626,"context_line":"        meaningful action. For example, if R/W access is requested on a"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a5ae5dd_b968d0f6","line":623,"updated":"2016-02-04 03:07:17.000000000","message":"Extra space between \"rules\" and \"are\".","commit_id":"08e8c095b09c875b4940a292067029e9e2fc9065"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"95ff3f899fc56904d8ef54c3fe5171211ff0a5ca","unresolved":false,"context_lines":[{"line_number":620,"context_line":"        Drivers must be mindful of this call for share replicas. When"},{"line_number":621,"context_line":"        \u0027update_access\u0027 is called on one of the replicas, the call is likely"},{"line_number":622,"context_line":"        propagated to all replicas belonging to the share, especially when"},{"line_number":623,"context_line":"        individual rules  are added or removed. If a particular access rule"},{"line_number":624,"context_line":"        does not make sense to the driver in the context of a given replica,"},{"line_number":625,"context_line":"        the driver should be careful to report a correct behavior, and take"},{"line_number":626,"context_line":"        meaningful action. For example, if R/W access is requested on a"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a5ae5dd_0902a93d","line":623,"in_reply_to":"5a5ae5dd_b968d0f6","updated":"2016-02-07 16:24:09.000000000","message":"Done","commit_id":"08e8c095b09c875b4940a292067029e9e2fc9065"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"0c389735b2181ef92ac362ac53ccc3e90c544770","unresolved":false,"context_lines":[{"line_number":1335,"context_line":"        \"\"\""},{"line_number":1336,"context_line":"        raise NotImplementedError()"},{"line_number":1337,"context_line":""},{"line_number":1338,"context_line":"    def update_replica_state(self, context, replica, share_server\u003dNone):"},{"line_number":1339,"context_line":"        \"\"\"Update the replica_state of a replica."},{"line_number":1340,"context_line":""},{"line_number":1341,"context_line":"        Drivers should fix replication relationships that were broken if"}],"source_content_type":"text/x-python","patch_set":27,"id":"5a5ae5dd_c9ca0c1b","line":1338,"range":{"start_line":1338,"start_character":29,"end_line":1338,"end_character":70},"updated":"2016-02-07 16:45:13.000000000","message":"Why access rules data not provided as it is done for creation of replica? Right now, there is no way to sync access rules after replica creation.","commit_id":"76561d28d20260ac52ca3b18002c71b342020813"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"933db275f4b26ab1d6a8921f63776b38bfd058cf","unresolved":false,"context_lines":[{"line_number":1308,"context_line":"            \u0027scheduled_at\u0027: datetime.datetime(2015, 8, 10, 0, 5, 58),"},{"line_number":1309,"context_line":"            \u0027launched_at\u0027: datetime.datetime(2015, 8, 10, 0, 5, 58),"},{"line_number":1310,"context_line":"            \u0027terminated_at\u0027: None,"},{"line_number":1311,"context_line":"            \u0027replica_state\u0027: \u0027in_sync\u0027,"},{"line_number":1312,"context_line":"            \u0027availability_zone_id\u0027: \u0027f6e146d0-65f0-11e5-9d70-feff819cdc9f\u0027,"},{"line_number":1313,"context_line":"            \u0027export_locations\u0027: ["},{"line_number":1314,"context_line":"                models.ShareInstanceExportLocations"}],"source_content_type":"text/x-python","patch_set":29,"id":"3a57f1b5_e66d3a05","line":1311,"range":{"start_line":1311,"start_character":30,"end_line":1311,"end_character":37},"updated":"2016-02-10 19:48:49.000000000","message":"There is no such status. There is \"in-sync\" in constants. Same in all other such occurrences.","commit_id":"e800b1aff6c92eea013d2ca2af6c11c19c546ec0"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"bd038c58c991c5569981b3a126bc94780b4a90b3","unresolved":false,"context_lines":[{"line_number":1308,"context_line":"            \u0027scheduled_at\u0027: datetime.datetime(2015, 8, 10, 0, 5, 58),"},{"line_number":1309,"context_line":"            \u0027launched_at\u0027: datetime.datetime(2015, 8, 10, 0, 5, 58),"},{"line_number":1310,"context_line":"            \u0027terminated_at\u0027: None,"},{"line_number":1311,"context_line":"            \u0027replica_state\u0027: \u0027in_sync\u0027,"},{"line_number":1312,"context_line":"            \u0027availability_zone_id\u0027: \u0027f6e146d0-65f0-11e5-9d70-feff819cdc9f\u0027,"},{"line_number":1313,"context_line":"            \u0027export_locations\u0027: ["},{"line_number":1314,"context_line":"                models.ShareInstanceExportLocations"}],"source_content_type":"text/x-python","patch_set":29,"id":"3a57f1b5_4cd46c46","line":1311,"range":{"start_line":1311,"start_character":30,"end_line":1311,"end_character":37},"in_reply_to":"3a57f1b5_e66d3a05","updated":"2016-02-10 21:12:45.000000000","message":"Nice catch.. i just ran into this while fixing Yogesh\u0027s tests. Corrected in patch 30","commit_id":"e800b1aff6c92eea013d2ca2af6c11c19c546ec0"}],"manila/share/manager.py":[{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"7a6638d6f2d08c50908d44eb13264466627f6118","unresolved":false,"context_lines":[{"line_number":1071,"context_line":"                    {\u0027replica_state\u0027: replica_state,"},{"line_number":1072,"context_line":"                     \u0027status\u0027: constants.STATUS_ERROR})"},{"line_number":1073,"context_line":""},{"line_number":1074,"context_line":"            elif replica_state in [constants.REPLICA_STATE_IN_SYNC,"},{"line_number":1075,"context_line":"                                   constants.REPLICA_STATE_OUT_OF_SYNC]:"},{"line_number":1076,"context_line":"                self.db.share_replica_update(context, replica[\u0027id\u0027],"},{"line_number":1077,"context_line":"                                             {\u0027replica_state\u0027: replica_state})"}],"source_content_type":"text/x-python","patch_set":1,"id":"da85f559_5266a0bb","line":1074,"updated":"2015-11-12 16:08:44.000000000","message":"Same here. Please, use \"tuple\" instead of \"list\".","commit_id":"dac7938116cfdbee468b3fbdfe42a3ab397fd347"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1d44846ad1c530ff7c7ed1dcf4ce2265bb331768","unresolved":false,"context_lines":[{"line_number":1071,"context_line":"                    {\u0027replica_state\u0027: replica_state,"},{"line_number":1072,"context_line":"                     \u0027status\u0027: constants.STATUS_ERROR})"},{"line_number":1073,"context_line":""},{"line_number":1074,"context_line":"            elif replica_state in [constants.REPLICA_STATE_IN_SYNC,"},{"line_number":1075,"context_line":"                                   constants.REPLICA_STATE_OUT_OF_SYNC]:"},{"line_number":1076,"context_line":"                self.db.share_replica_update(context, replica[\u0027id\u0027],"},{"line_number":1077,"context_line":"                                             {\u0027replica_state\u0027: replica_state})"}],"source_content_type":"text/x-python","patch_set":1,"id":"ba8a016a_273b65ed","line":1074,"in_reply_to":"da85f559_5266a0bb","updated":"2015-11-19 19:44:49.000000000","message":"Done","commit_id":"dac7938116cfdbee468b3fbdfe42a3ab397fd347"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":91,"context_line":"    cfg.IntOpt(\u0027replica_state_update_interval\u0027,"},{"line_number":92,"context_line":"               default\u003d300,"},{"line_number":93,"context_line":"               help\u003d\u0027This value, specified in seconds, determines how often \u0027"},{"line_number":94,"context_line":"                    \u0027the share manager will poll for status of each \u0027"},{"line_number":95,"context_line":"                    \u0027replica instance.\u0027,"},{"line_number":96,"context_line":"               deprecated_group\u003d\u0027DEFAULT\u0027),"},{"line_number":97,"context_line":"]"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_306874ba","line":94,"updated":"2015-11-13 20:26:31.000000000","message":"\"will poll for the status of\"","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":91,"context_line":"    cfg.IntOpt(\u0027replica_state_update_interval\u0027,"},{"line_number":92,"context_line":"               default\u003d300,"},{"line_number":93,"context_line":"               help\u003d\u0027This value, specified in seconds, determines how often \u0027"},{"line_number":94,"context_line":"                    \u0027the share manager will poll for status of each \u0027"},{"line_number":95,"context_line":"                    \u0027replica instance.\u0027,"},{"line_number":96,"context_line":"               deprecated_group\u003d\u0027DEFAULT\u0027),"},{"line_number":97,"context_line":"]"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_624ddb71","line":94,"in_reply_to":"da85f559_306874ba","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":14567,"name":"Rodrigo Barbieri","email":"rodrigo.barbieri2010@gmail.com","username":"ganso"},"change_message_id":"fe76a9113ae4d5b83e057a5813d735652531929d","unresolved":false,"context_lines":[{"line_number":841,"context_line":"                    \"not exist to add replica to share %s.\")"},{"line_number":842,"context_line":"            raise exception.ReplicationException(msg % replica[\u0027share_id\u0027])"},{"line_number":843,"context_line":""},{"line_number":844,"context_line":"        # We need the share_network_id in case of multi-svm"},{"line_number":845,"context_line":"        share_network_id \u003d replica.get(\u0027share_network_id\u0027, None)"},{"line_number":846,"context_line":""},{"line_number":847,"context_line":"        if share_network_id and not self.driver.driver_handles_share_servers:"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_8217a453","line":844,"updated":"2015-11-13 13:37:11.000000000","message":"in case of driver handles share servers","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":841,"context_line":"                    \"not exist to add replica to share %s.\")"},{"line_number":842,"context_line":"            raise exception.ReplicationException(msg % replica[\u0027share_id\u0027])"},{"line_number":843,"context_line":""},{"line_number":844,"context_line":"        # We need the share_network_id in case of multi-svm"},{"line_number":845,"context_line":"        share_network_id \u003d replica.get(\u0027share_network_id\u0027, None)"},{"line_number":846,"context_line":""},{"line_number":847,"context_line":"        if share_network_id and not self.driver.driver_handles_share_servers:"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_2220339b","line":844,"in_reply_to":"da85f559_8217a453","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"56c3e93a257daee2390d00f4ba887f982bf3e4d8","unresolved":false,"context_lines":[{"line_number":841,"context_line":"            context, share_replica_id, with_share_data\u003dTrue,"},{"line_number":842,"context_line":"            with_share_server\u003dTrue)"},{"line_number":843,"context_line":""},{"line_number":844,"context_line":"        with utils.lock(replica.get(\u0027share_id\u0027)):"},{"line_number":845,"context_line":"            active_instance \u003d ("},{"line_number":846,"context_line":"                self.db.share_replicas_get_available_active_replica("},{"line_number":847,"context_line":"                    context, replica[\u0027share_id\u0027], with_share_data\u003dTrue,"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a7b0d38_62afd294","line":844,"range":{"start_line":844,"start_character":8,"end_line":844,"end_character":49},"updated":"2015-12-25 17:04:54.000000000","message":"In case of concurrent calls, all of them will read object of same state (line 840) and one of them will change it, and logic of others will differ depending locking of line 840. So, better to use locking decorator for whole method.","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":177,"name":"Alex Meade","email":"mr.alex.meade@gmail.com","username":"alex-meade"},"change_message_id":"42ec7ecf31e99adfd9beaa2b6fa0768545f0f731","unresolved":false,"context_lines":[{"line_number":841,"context_line":"            context, share_replica_id, with_share_data\u003dTrue,"},{"line_number":842,"context_line":"            with_share_server\u003dTrue)"},{"line_number":843,"context_line":""},{"line_number":844,"context_line":"        with utils.lock(replica.get(\u0027share_id\u0027)):"},{"line_number":845,"context_line":"            active_instance \u003d ("},{"line_number":846,"context_line":"                self.db.share_replicas_get_available_active_replica("},{"line_number":847,"context_line":"                    context, replica[\u0027share_id\u0027], with_share_data\u003dTrue,"}],"source_content_type":"text/x-python","patch_set":14,"id":"da6ed579_90e35533","line":844,"range":{"start_line":844,"start_character":8,"end_line":844,"end_character":49},"in_reply_to":"1a7b0d38_62afd294","updated":"2016-01-13 02:54:38.000000000","message":"This is locking on the specific share id, which we can\u0027t know until inside the create_share_replica method. Valeriy, you have a good point, we should regrab the replica object inside the with.","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"0aace059b282267e3e01c44cbb73c7bc0b3213f4","unresolved":false,"context_lines":[{"line_number":841,"context_line":"            context, share_replica_id, with_share_data\u003dTrue,"},{"line_number":842,"context_line":"            with_share_server\u003dTrue)"},{"line_number":843,"context_line":""},{"line_number":844,"context_line":"        with utils.lock(replica.get(\u0027share_id\u0027)):"},{"line_number":845,"context_line":"            active_instance \u003d ("},{"line_number":846,"context_line":"                self.db.share_replicas_get_available_active_replica("},{"line_number":847,"context_line":"                    context, replica[\u0027share_id\u0027], with_share_data\u003dTrue,"}],"source_content_type":"text/x-python","patch_set":14,"id":"9a68dd71_8a3ff0b2","line":844,"range":{"start_line":844,"start_character":8,"end_line":844,"end_character":49},"in_reply_to":"da6ed579_90e35533","updated":"2016-01-26 03:46:07.000000000","message":"reverted the context manager locks with decorator locks, a.la cinder\u0027s manager:\n\n\n\n    https://github.com/openstack/cinder/blob/master/cinder/volume/manager.py#L182","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"56c3e93a257daee2390d00f4ba887f982bf3e4d8","unresolved":false,"context_lines":[{"line_number":944,"context_line":"            context, share_replica_id, with_share_data\u003dTrue,"},{"line_number":945,"context_line":"            with_share_server\u003dTrue)"},{"line_number":946,"context_line":""},{"line_number":947,"context_line":"        with utils.lock(replica.get(\u0027share_id\u0027)):"},{"line_number":948,"context_line":"            # Get the active replica"},{"line_number":949,"context_line":"            current_active_replica \u003d ("},{"line_number":950,"context_line":"                self.db.share_replicas_get_available_active_replica("}],"source_content_type":"text/x-python","patch_set":14,"id":"1a7b0d38_a2937a4e","line":947,"updated":"2015-12-25 17:04:54.000000000","message":"same here.","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"0aace059b282267e3e01c44cbb73c7bc0b3213f4","unresolved":false,"context_lines":[{"line_number":944,"context_line":"            context, share_replica_id, with_share_data\u003dTrue,"},{"line_number":945,"context_line":"            with_share_server\u003dTrue)"},{"line_number":946,"context_line":""},{"line_number":947,"context_line":"        with utils.lock(replica.get(\u0027share_id\u0027)):"},{"line_number":948,"context_line":"            # Get the active replica"},{"line_number":949,"context_line":"            current_active_replica \u003d ("},{"line_number":950,"context_line":"                self.db.share_replicas_get_available_active_replica("}],"source_content_type":"text/x-python","patch_set":14,"id":"9a68dd71_857a8322","line":947,"in_reply_to":"1a7b0d38_a2937a4e","updated":"2016-01-26 03:46:07.000000000","message":"Done","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"56c3e93a257daee2390d00f4ba887f982bf3e4d8","unresolved":false,"context_lines":[{"line_number":979,"context_line":"                                            with_share_server\u003dTrue)"},{"line_number":980,"context_line":"        share_server \u003d self._get_share_server(context, replica)"},{"line_number":981,"context_line":""},{"line_number":982,"context_line":"        with utils.lock(replica.get(\u0027share_id\u0027)):"},{"line_number":983,"context_line":""},{"line_number":984,"context_line":"            # Get list of all replicas for share"},{"line_number":985,"context_line":"            replica_list \u003d ("}],"source_content_type":"text/x-python","patch_set":14,"id":"1a7b0d38_629d9258","line":982,"updated":"2015-12-25 17:04:54.000000000","message":"and here.","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"0aace059b282267e3e01c44cbb73c7bc0b3213f4","unresolved":false,"context_lines":[{"line_number":979,"context_line":"                                            with_share_server\u003dTrue)"},{"line_number":980,"context_line":"        share_server \u003d self._get_share_server(context, replica)"},{"line_number":981,"context_line":""},{"line_number":982,"context_line":"        with utils.lock(replica.get(\u0027share_id\u0027)):"},{"line_number":983,"context_line":""},{"line_number":984,"context_line":"            # Get list of all replicas for share"},{"line_number":985,"context_line":"            replica_list \u003d ("}],"source_content_type":"text/x-python","patch_set":14,"id":"9a68dd71_2575d730","line":982,"in_reply_to":"1a7b0d38_629d9258","updated":"2016-01-26 03:46:07.000000000","message":"Done","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"56c3e93a257daee2390d00f4ba887f982bf3e4d8","unresolved":false,"context_lines":[{"line_number":1066,"context_line":"            LOG.info(_LI(\"Share replica %s: promoted to active state \""},{"line_number":1067,"context_line":"                         \"successfully.\"), share_replica_id)"},{"line_number":1068,"context_line":""},{"line_number":1069,"context_line":"    @periodic_task.periodic_task(spacing\u003dCONF.replica_state_update_interval)"},{"line_number":1070,"context_line":"    def periodic_share_replica_update(self, context):"},{"line_number":1071,"context_line":"        LOG.debug(\"Updating status of share replica instances.\")"},{"line_number":1072,"context_line":"        replicas \u003d self.db.share_replicas_get_all(context,"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a7b0d38_c2aec684","line":1069,"updated":"2015-12-25 17:04:54.000000000","message":"@add_hooks ?","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"0aace059b282267e3e01c44cbb73c7bc0b3213f4","unresolved":false,"context_lines":[{"line_number":1066,"context_line":"            LOG.info(_LI(\"Share replica %s: promoted to active state \""},{"line_number":1067,"context_line":"                         \"successfully.\"), share_replica_id)"},{"line_number":1068,"context_line":""},{"line_number":1069,"context_line":"    @periodic_task.periodic_task(spacing\u003dCONF.replica_state_update_interval)"},{"line_number":1070,"context_line":"    def periodic_share_replica_update(self, context):"},{"line_number":1071,"context_line":"        LOG.debug(\"Updating status of share replica instances.\")"},{"line_number":1072,"context_line":"        replicas \u003d self.db.share_replicas_get_all(context,"}],"source_content_type":"text/x-python","patch_set":14,"id":"9a68dd71_e591ff47","line":1069,"in_reply_to":"1a7b0d38_c2aec684","updated":"2016-01-26 03:46:07.000000000","message":"Done","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"d1755246f54a6f982803dacf1b62917e2a30f9ac","unresolved":false,"context_lines":[{"line_number":94,"context_line":"               help\u003d\u0027This value, specified in seconds, determines how often \u0027"},{"line_number":95,"context_line":"                    \u0027the share manager will poll for the health \u0027"},{"line_number":96,"context_line":"                    \u0027(replica_state) of each replica instance.\u0027,"},{"line_number":97,"context_line":"               deprecated_group\u003d\u0027DEFAULT\u0027),"},{"line_number":98,"context_line":"]"},{"line_number":99,"context_line":""},{"line_number":100,"context_line":"CONF \u003d cfg.CONF"}],"source_content_type":"text/x-python","patch_set":23,"id":"7a5de9d1_22df223b","line":97,"range":{"start_line":97,"start_character":15,"end_line":97,"end_character":41},"updated":"2016-02-01 17:38:54.000000000","message":"It is incorrect to say that \u0027DEFAULT\u0027 group is deprecated/fallback one. It is target config group and should be the only allowed because we should have only one value for this opt.\n\nProof - you call \"CONF.replica_state_update_interval\" on line 1138, it belongs exactly to \u0027DEFAULT\u0027 group.","commit_id":"08799ad6674f3bd54a1fd9984ad78dbd8e862a93"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"46d881f3f99c89564e0743a1e2b74cef64d9d07f","unresolved":false,"context_lines":[{"line_number":94,"context_line":"               help\u003d\u0027This value, specified in seconds, determines how often \u0027"},{"line_number":95,"context_line":"                    \u0027the share manager will poll for the health \u0027"},{"line_number":96,"context_line":"                    \u0027(replica_state) of each replica instance.\u0027,"},{"line_number":97,"context_line":"               deprecated_group\u003d\u0027DEFAULT\u0027),"},{"line_number":98,"context_line":"]"},{"line_number":99,"context_line":""},{"line_number":100,"context_line":"CONF \u003d cfg.CONF"}],"source_content_type":"text/x-python","patch_set":23,"id":"7a5de9d1_b666e6ea","line":97,"range":{"start_line":97,"start_character":15,"end_line":97,"end_character":41},"in_reply_to":"7a5de9d1_22df223b","updated":"2016-02-02 02:45:12.000000000","message":"removed.","commit_id":"08799ad6674f3bd54a1fd9984ad78dbd8e862a93"},{"author":{"_account_id":7102,"name":"Thomas Bechtold","email":"thomas.bechtold@chainguard.dev","username":"toabctl"},"change_message_id":"bb9a313dac4f6947e609d11a31cee5f12ba014a4","unresolved":false,"context_lines":[{"line_number":90,"context_line":"                    \u0027deleting it.\u0027,"},{"line_number":91,"context_line":"               deprecated_group\u003d\u0027DEFAULT\u0027),"},{"line_number":92,"context_line":"    cfg.IntOpt(\u0027replica_state_update_interval\u0027,"},{"line_number":93,"context_line":"               default\u003d300,"},{"line_number":94,"context_line":"               help\u003d\u0027This value, specified in seconds, determines how often \u0027"},{"line_number":95,"context_line":"                    \u0027the share manager will poll for the health \u0027"},{"line_number":96,"context_line":"                    \u0027(replica_state) of each replica instance.\u0027),"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a5ae5dd_e5f529cb","line":93,"updated":"2016-02-04 07:26:14.000000000","message":"not sure, but isn\u0027t 300 s to much? I would expect something like 10 s or so.","commit_id":"08e8c095b09c875b4940a292067029e9e2fc9065"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"95ff3f899fc56904d8ef54c3fe5171211ff0a5ca","unresolved":false,"context_lines":[{"line_number":90,"context_line":"                    \u0027deleting it.\u0027,"},{"line_number":91,"context_line":"               deprecated_group\u003d\u0027DEFAULT\u0027),"},{"line_number":92,"context_line":"    cfg.IntOpt(\u0027replica_state_update_interval\u0027,"},{"line_number":93,"context_line":"               default\u003d300,"},{"line_number":94,"context_line":"               help\u003d\u0027This value, specified in seconds, determines how often \u0027"},{"line_number":95,"context_line":"                    \u0027the share manager will poll for the health \u0027"},{"line_number":96,"context_line":"                    \u0027(replica_state) of each replica instance.\u0027),"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a5ae5dd_445ac82b","line":93,"in_reply_to":"5a5ae5dd_e5f529cb","updated":"2016-02-07 16:24:09.000000000","message":"The update interval for every backend may be different, so 5 minutes was chosen as a compromise in this design:\n\nhttps://wiki.openstack.org/wiki/Manila/design/manila-mitaka-data-replication\n\n- 10s would probably cause a lot of races since all replica operations are not \ncoordinated at the moment. Currently, we\u0027re using file locks from oslo\u0027s lockutils.. \n but they do not solve the case of multiple, distributed share services. Manila, \nCinder and many other projects are looking to solve this distributed lock problem. \nThis is a candidate for benefit/change when we have a viable solution.\n- Also,multiple periodic tasks run here; so lowering it to anything less than 60 will \nstagger these updates and force them to be 60 or more. (update_stats for \nreporting pool information is a major time hog)\n- For running tempest, we tried lowering this to 60 and it worked spectacularly ;) \nSo, not saying it doesn\u0027t work.. but i think we need to delegate this configuration \nto the administrator for now.","commit_id":"08e8c095b09c875b4940a292067029e9e2fc9065"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"9757688e4b720da2871c613719a78582424c35e0","unresolved":false,"context_lines":[{"line_number":1144,"context_line":"                    r[\u0027replica_state\u0027] !\u003d constants.REPLICA_STATE_ACTIVE)"},{"line_number":1145,"context_line":""},{"line_number":1146,"context_line":"        replicas \u003d list(filter(lambda x: qualified_replica(x), replicas))"},{"line_number":1147,"context_line":"        for replica in replicas:"},{"line_number":1148,"context_line":"            self._share_replica_update("},{"line_number":1149,"context_line":"                context, replica, share_id\u003dreplica[\u0027share_id\u0027])"},{"line_number":1150,"context_line":""},{"line_number":1151,"context_line":"    @locked_share_replica_operation"},{"line_number":1152,"context_line":"    def _share_replica_update(self, context, share_replica, share_id\u003dNone):"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a5ae5dd_e67f0515","line":1149,"range":{"start_line":1147,"start_character":8,"end_line":1149,"end_character":63},"updated":"2016-02-06 15:17:35.000000000","message":"Not scalable. If we have lots of replicated shares and each takes some time then it will be endless call of this method.","commit_id":"08e8c095b09c875b4940a292067029e9e2fc9065"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"95ff3f899fc56904d8ef54c3fe5171211ff0a5ca","unresolved":false,"context_lines":[{"line_number":1144,"context_line":"                    r[\u0027replica_state\u0027] !\u003d constants.REPLICA_STATE_ACTIVE)"},{"line_number":1145,"context_line":""},{"line_number":1146,"context_line":"        replicas \u003d list(filter(lambda x: qualified_replica(x), replicas))"},{"line_number":1147,"context_line":"        for replica in replicas:"},{"line_number":1148,"context_line":"            self._share_replica_update("},{"line_number":1149,"context_line":"                context, replica, share_id\u003dreplica[\u0027share_id\u0027])"},{"line_number":1150,"context_line":""},{"line_number":1151,"context_line":"    @locked_share_replica_operation"},{"line_number":1152,"context_line":"    def _share_replica_update(self, context, share_replica, share_id\u003dNone):"}],"source_content_type":"text/x-python","patch_set":26,"id":"5a5ae5dd_29bf20ab","line":1149,"range":{"start_line":1147,"start_character":8,"end_line":1149,"end_character":63},"in_reply_to":"5a5ae5dd_e67f0515","updated":"2016-02-07 16:24:09.000000000","message":"As with any other kind of polling.. how do we prevent that from happening?","commit_id":"08e8c095b09c875b4940a292067029e9e2fc9065"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"9ffba8b9e6eb5ea94dcafd4ebbd3dc266403551e","unresolved":false,"context_lines":[{"line_number":1003,"context_line":"                context, current_active_replica, share_replica,"},{"line_number":1004,"context_line":"                share_server\u003dshare_server)"},{"line_number":1005,"context_line":""},{"line_number":1006,"context_line":"        except Exception:"},{"line_number":1007,"context_line":"            with excutils.save_and_reraise_exception():"},{"line_number":1008,"context_line":"                self.db.share_replica_update("},{"line_number":1009,"context_line":"                    context, share_replica[\u0027id\u0027],"},{"line_number":1010,"context_line":"                    {\u0027status\u0027: constants.STATUS_ERROR_DELETING,"},{"line_number":1011,"context_line":"                     \u0027replica_state\u0027: constants.STATUS_ERROR})"},{"line_number":1012,"context_line":""},{"line_number":1013,"context_line":"        self.db.share_replica_delete(context, share_replica[\u0027id\u0027])"},{"line_number":1014,"context_line":"        LOG.info(_LI(\"Share replica %s deleted successfully.\"),"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a57f1b5_e8d8c4f1","line":1011,"range":{"start_line":1006,"start_character":8,"end_line":1011,"end_character":62},"updated":"2016-02-10 12:20:16.000000000","message":"Doing so, it is impossible to get rid of DB record if original creation of replica failed for some reason and access rules just cannot be applied.","commit_id":"dcb5f2bb1de2faea4bdb9553c27dee30a6a386f4"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"832935e7d09b6d8e6071c66e1ba79968e0027c1e","unresolved":false,"context_lines":[{"line_number":1003,"context_line":"                context, current_active_replica, share_replica,"},{"line_number":1004,"context_line":"                share_server\u003dshare_server)"},{"line_number":1005,"context_line":""},{"line_number":1006,"context_line":"        except Exception:"},{"line_number":1007,"context_line":"            with excutils.save_and_reraise_exception():"},{"line_number":1008,"context_line":"                self.db.share_replica_update("},{"line_number":1009,"context_line":"                    context, share_replica[\u0027id\u0027],"},{"line_number":1010,"context_line":"                    {\u0027status\u0027: constants.STATUS_ERROR_DELETING,"},{"line_number":1011,"context_line":"                     \u0027replica_state\u0027: constants.STATUS_ERROR})"},{"line_number":1012,"context_line":""},{"line_number":1013,"context_line":"        self.db.share_replica_delete(context, share_replica[\u0027id\u0027])"},{"line_number":1014,"context_line":"        LOG.info(_LI(\"Share replica %s deleted successfully.\"),"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a57f1b5_e0045416","line":1011,"range":{"start_line":1006,"start_character":8,"end_line":1011,"end_character":62},"in_reply_to":"3a57f1b5_e8d8c4f1","updated":"2016-02-10 14:06:13.000000000","message":"Hmm, both these are driver errors.. Should we log the access rules error, update the access_rules_status and then attempt to delete the replica?","commit_id":"dcb5f2bb1de2faea4bdb9553c27dee30a6a386f4"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"8b3f1395ffaf95aaa404975160ae7e2ab59be34b","unresolved":false,"context_lines":[{"line_number":1057,"context_line":"        share_replica \u003d self._get_share_replica_dict(context, share_replica)"},{"line_number":1058,"context_line":""},{"line_number":1059,"context_line":"        try:"},{"line_number":1060,"context_line":"            updated_replica_list \u003d ("},{"line_number":1061,"context_line":"                self.driver.promote_replica("},{"line_number":1062,"context_line":"                    context, replica_list, share_replica, access_rules,"},{"line_number":1063,"context_line":"                    share_server\u003dshare_server)"},{"line_number":1064,"context_line":"            )"},{"line_number":1065,"context_line":"        except Exception:"},{"line_number":1066,"context_line":"            with excutils.save_and_reraise_exception():"},{"line_number":1067,"context_line":"                # (NOTE) gouthamr: If the driver throws an exception at"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a57f1b5_a362edd6","line":1064,"range":{"start_line":1060,"start_character":12,"end_line":1064,"end_character":13},"updated":"2016-02-10 12:27:24.000000000","message":"It also tries to update replicas with \"error\" status. And they have replica state equal to \"out-of-sync\".","commit_id":"dcb5f2bb1de2faea4bdb9553c27dee30a6a386f4"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"832935e7d09b6d8e6071c66e1ba79968e0027c1e","unresolved":false,"context_lines":[{"line_number":1057,"context_line":"        share_replica \u003d self._get_share_replica_dict(context, share_replica)"},{"line_number":1058,"context_line":""},{"line_number":1059,"context_line":"        try:"},{"line_number":1060,"context_line":"            updated_replica_list \u003d ("},{"line_number":1061,"context_line":"                self.driver.promote_replica("},{"line_number":1062,"context_line":"                    context, replica_list, share_replica, access_rules,"},{"line_number":1063,"context_line":"                    share_server\u003dshare_server)"},{"line_number":1064,"context_line":"            )"},{"line_number":1065,"context_line":"        except Exception:"},{"line_number":1066,"context_line":"            with excutils.save_and_reraise_exception():"},{"line_number":1067,"context_line":"                # (NOTE) gouthamr: If the driver throws an exception at"}],"source_content_type":"text/x-python","patch_set":28,"id":"3a57f1b5_1d56b929","line":1064,"range":{"start_line":1060,"start_character":12,"end_line":1064,"end_character":13},"in_reply_to":"3a57f1b5_a362edd6","updated":"2016-02-10 14:06:13.000000000","message":"Is this related to the creation error that you pointed out above?","commit_id":"dcb5f2bb1de2faea4bdb9553c27dee30a6a386f4"}],"manila/share/rpcapi.py":[{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":202,"context_line":"        new_host \u003d utils.extract_host(host)"},{"line_number":203,"context_line":"        cctxt \u003d self.client.prepare(server\u003dnew_host, version\u003d\u00271.7\u0027)"},{"line_number":204,"context_line":"        request_spec_p \u003d jsonutils.to_primitive(request_spec)"},{"line_number":205,"context_line":"        cctxt.cast("},{"line_number":206,"context_line":"            ctxt,"},{"line_number":207,"context_line":"            \u0027create_share_replica\u0027,"},{"line_number":208,"context_line":"            share_replica_id\u003dshare_replica[\u0027id\u0027],"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_b02b0433","line":205,"updated":"2015-11-13 20:26:31.000000000","message":"Though it\u0027s used elsewhere in this file, the usage of \"ctxt\" and \"cctxt\" is pretty confusing. Could be refactored to \"context\" and \"client_context\"?","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":202,"context_line":"        new_host \u003d utils.extract_host(host)"},{"line_number":203,"context_line":"        cctxt \u003d self.client.prepare(server\u003dnew_host, version\u003d\u00271.7\u0027)"},{"line_number":204,"context_line":"        request_spec_p \u003d jsonutils.to_primitive(request_spec)"},{"line_number":205,"context_line":"        cctxt.cast("},{"line_number":206,"context_line":"            ctxt,"},{"line_number":207,"context_line":"            \u0027create_share_replica\u0027,"},{"line_number":208,"context_line":"            share_replica_id\u003dshare_replica[\u0027id\u0027],"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_8279df95","line":205,"in_reply_to":"da85f559_b02b0433","updated":"2015-11-19 19:45:53.000000000","message":"True. I will open a bug on the existing code and make this refactor..","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"d1755246f54a6f982803dacf1b62917e2a30f9ac","unresolved":false,"context_lines":[{"line_number":48,"context_line":"        1.7 - Update target call API in allow/deny access methods"},{"line_number":49,"context_line":"        1.8 - Introduce Share Replication:"},{"line_number":50,"context_line":"            create_share_replica()"},{"line_number":51,"context_line":"            remove_share_replica()"},{"line_number":52,"context_line":"            promote_share_replica()"},{"line_number":53,"context_line":"    \"\"\""},{"line_number":54,"context_line":""}],"source_content_type":"text/x-python","patch_set":23,"id":"7a5de9d1_0298e668","line":51,"range":{"start_line":51,"start_character":12,"end_line":51,"end_character":32},"updated":"2016-02-01 17:38:54.000000000","message":"There is \"delete_share_replica\", but no \"remove_share_replica\".","commit_id":"08799ad6674f3bd54a1fd9984ad78dbd8e862a93"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"46d881f3f99c89564e0743a1e2b74cef64d9d07f","unresolved":false,"context_lines":[{"line_number":48,"context_line":"        1.7 - Update target call API in allow/deny access methods"},{"line_number":49,"context_line":"        1.8 - Introduce Share Replication:"},{"line_number":50,"context_line":"            create_share_replica()"},{"line_number":51,"context_line":"            remove_share_replica()"},{"line_number":52,"context_line":"            promote_share_replica()"},{"line_number":53,"context_line":"    \"\"\""},{"line_number":54,"context_line":""}],"source_content_type":"text/x-python","patch_set":23,"id":"7a5de9d1_96b2ca4a","line":51,"range":{"start_line":51,"start_character":12,"end_line":51,"end_character":32},"in_reply_to":"7a5de9d1_0298e668","updated":"2016-02-02 02:45:12.000000000","message":"Done","commit_id":"08799ad6674f3bd54a1fd9984ad78dbd8e862a93"}],"manila/tests/api/contrib/stubs.py":[{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":42,"context_line":"        \u0027share_server_id\u0027: \u0027fake_share_server_id\u0027,"},{"line_number":43,"context_line":"        \u0027is_public\u0027: False,"},{"line_number":44,"context_line":"        \u0027snapshot_support\u0027: True,"},{"line_number":45,"context_line":"        \u0027replication\u0027: None,"},{"line_number":46,"context_line":"    }"},{"line_number":47,"context_line":"    share.update(kwargs)"},{"line_number":48,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_50e4180c","line":45,"updated":"2015-11-13 20:26:31.000000000","message":"Be sure to update this name here with the new name of the extra spec.","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":42,"context_line":"        \u0027share_server_id\u0027: \u0027fake_share_server_id\u0027,"},{"line_number":43,"context_line":"        \u0027is_public\u0027: False,"},{"line_number":44,"context_line":"        \u0027snapshot_support\u0027: True,"},{"line_number":45,"context_line":"        \u0027replication\u0027: None,"},{"line_number":46,"context_line":"    }"},{"line_number":47,"context_line":"    share.update(kwargs)"},{"line_number":48,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_02adefe8","line":45,"in_reply_to":"da85f559_50e4180c","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"}],"manila/tests/api/v1/test_share_replicas.py":[{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":94,"context_line":"                         mock.Mock(return_value\u003d[fake_replica]))"},{"line_number":95,"context_line":""},{"line_number":96,"context_line":"        req \u003d fakes.HTTPRequest.blank("},{"line_number":97,"context_line":"            \u0027/share-replicas?share_id\u003dFAKE_SHARE_ID\u0027,"},{"line_number":98,"context_line":"            version\u003dself.api_version, experimental\u003dTrue)"},{"line_number":99,"context_line":""},{"line_number":100,"context_line":"        res_dict \u003d self.controller.index(req)"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_70fd9c6d","line":97,"updated":"2015-11-13 20:26:31.000000000","message":"These fake share ID values should be captured in the fakes.py file.","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":94,"context_line":"                         mock.Mock(return_value\u003d[fake_replica]))"},{"line_number":95,"context_line":""},{"line_number":96,"context_line":"        req \u003d fakes.HTTPRequest.blank("},{"line_number":97,"context_line":"            \u0027/share-replicas?share_id\u003dFAKE_SHARE_ID\u0027,"},{"line_number":98,"context_line":"            version\u003dself.api_version, experimental\u003dTrue)"},{"line_number":99,"context_line":""},{"line_number":100,"context_line":"        res_dict \u003d self.controller.index(req)"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_e296ab93","line":97,"in_reply_to":"da85f559_70fd9c6d","updated":"2015-11-19 19:45:53.000000000","message":"Too small a token to come through the fakes file.. :)","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"}],"manila/tests/api/v1/test_shares.py":[{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"56c3e93a257daee2390d00f4ba887f982bf3e4d8","unresolved":false,"context_lines":[{"line_number":26,"context_line":"from manila.api import common"},{"line_number":27,"context_line":"from manila.api.openstack import api_version_request as api_version"},{"line_number":28,"context_line":"from manila.api.v1 import shares"},{"line_number":29,"context_line":"from manila.api.v2 import share_replicas"},{"line_number":30,"context_line":"from manila.common import constants"},{"line_number":31,"context_line":"from manila import context"},{"line_number":32,"context_line":"from manila import db"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a7b0d38_42e896b4","line":29,"updated":"2015-12-25 17:04:54.000000000","message":"It testing module is for \"v1\" shares API. Why it is changed?","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"0aace059b282267e3e01c44cbb73c7bc0b3213f4","unresolved":false,"context_lines":[{"line_number":26,"context_line":"from manila.api import common"},{"line_number":27,"context_line":"from manila.api.openstack import api_version_request as api_version"},{"line_number":28,"context_line":"from manila.api.v1 import shares"},{"line_number":29,"context_line":"from manila.api.v2 import share_replicas"},{"line_number":30,"context_line":"from manila.common import constants"},{"line_number":31,"context_line":"from manila import context"},{"line_number":32,"context_line":"from manila import db"}],"source_content_type":"text/x-python","patch_set":14,"id":"9a68dd71_c59abb61","line":29,"in_reply_to":"1a7b0d38_42e896b4","updated":"2016-01-26 03:46:07.000000000","message":"Done","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"}],"manila/tests/api/v2/test_share_replicas.py":[{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"56c3e93a257daee2390d00f4ba887f982bf3e4d8","unresolved":false,"context_lines":[{"line_number":34,"context_line":""},{"line_number":35,"context_line":"@ddt.ddt"},{"line_number":36,"context_line":"class ShareReplicasApiTest(test.TestCase):"},{"line_number":37,"context_line":"    \"\"\"Share Replicas Api Test Cases.\"\"\""},{"line_number":38,"context_line":"    def setUp(self):"},{"line_number":39,"context_line":"        super(ShareReplicasApiTest, self).setUp()"},{"line_number":40,"context_line":"        self.controller \u003d share_replicas.ShareReplicationController()"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a7b0d38_62eb52b1","line":37,"range":{"start_line":37,"start_character":22,"end_line":37,"end_character":25},"updated":"2015-12-25 17:04:54.000000000","message":"s/Api/API/","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"0aace059b282267e3e01c44cbb73c7bc0b3213f4","unresolved":false,"context_lines":[{"line_number":34,"context_line":""},{"line_number":35,"context_line":"@ddt.ddt"},{"line_number":36,"context_line":"class ShareReplicasApiTest(test.TestCase):"},{"line_number":37,"context_line":"    \"\"\"Share Replicas Api Test Cases.\"\"\""},{"line_number":38,"context_line":"    def setUp(self):"},{"line_number":39,"context_line":"        super(ShareReplicasApiTest, self).setUp()"},{"line_number":40,"context_line":"        self.controller \u003d share_replicas.ShareReplicationController()"}],"source_content_type":"text/x-python","patch_set":14,"id":"9a68dd71_45a7aba6","line":37,"range":{"start_line":37,"start_character":22,"end_line":37,"end_character":25},"in_reply_to":"1a7b0d38_62eb52b1","updated":"2016-01-26 03:46:07.000000000","message":"Done","commit_id":"81471ca128e5192cf240e23da343a989eee99d04"}],"manila/tests/db/sqlalchemy/test_api.py":[{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":414,"context_line":"    def test_share_replicas_get_active_replicas_by_share(self):"},{"line_number":415,"context_line":"        db_utils.create_share_replica("},{"line_number":416,"context_line":"            id\u003d\u0027Replica1\u0027,"},{"line_number":417,"context_line":"            share_id\u003d\u0027FAKE_SHARE_ID1\u0027,"},{"line_number":418,"context_line":"            status\u003dconstants.STATUS_AVAILABLE,"},{"line_number":419,"context_line":"            replica_state\u003dconstants.REPLICA_STATE_ACTIVE)"},{"line_number":420,"context_line":"        db_utils.create_share_replica("}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_90160054","line":417,"updated":"2015-11-13 20:26:31.000000000","message":"These fake IDs should be put into fakes.py.","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":414,"context_line":"    def test_share_replicas_get_active_replicas_by_share(self):"},{"line_number":415,"context_line":"        db_utils.create_share_replica("},{"line_number":416,"context_line":"            id\u003d\u0027Replica1\u0027,"},{"line_number":417,"context_line":"            share_id\u003d\u0027FAKE_SHARE_ID1\u0027,"},{"line_number":418,"context_line":"            status\u003dconstants.STATUS_AVAILABLE,"},{"line_number":419,"context_line":"            replica_state\u003dconstants.REPLICA_STATE_ACTIVE)"},{"line_number":420,"context_line":"        db_utils.create_share_replica("}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_42f8d7e5","line":417,"in_reply_to":"da85f559_90160054","updated":"2015-11-19 19:45:53.000000000","message":"Using a bunch of these small tokens.. Should we really put them in the fakes file? Might make the code less readable..","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"}],"manila/tests/fake_share.py":[{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":29,"context_line":"        \u0027project_id\u0027: \u0027fake_project_uuid\u0027,"},{"line_number":30,"context_line":"        \u0027availability_zone\u0027: \u0027fake_az\u0027,"},{"line_number":31,"context_line":"        \u0027snapshot_support\u0027: \u0027True\u0027,"},{"line_number":32,"context_line":"        \u0027replication\u0027: None,"},{"line_number":33,"context_line":"    }"},{"line_number":34,"context_line":"    share.update(kwargs)"},{"line_number":35,"context_line":"    return db_fakes.FakeModel(share)"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_641f1d5c","line":32,"updated":"2015-11-13 20:26:31.000000000","message":"Be sure to update the name of the extra spec here.","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":29,"context_line":"        \u0027project_id\u0027: \u0027fake_project_uuid\u0027,"},{"line_number":30,"context_line":"        \u0027availability_zone\u0027: \u0027fake_az\u0027,"},{"line_number":31,"context_line":"        \u0027snapshot_support\u0027: \u0027True\u0027,"},{"line_number":32,"context_line":"        \u0027replication\u0027: None,"},{"line_number":33,"context_line":"    }"},{"line_number":34,"context_line":"    share.update(kwargs)"},{"line_number":35,"context_line":"    return db_fakes.FakeModel(share)"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_c2e4c73c","line":32,"in_reply_to":"da85f559_641f1d5c","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"}],"manila/tests/scheduler/fakes.py":[{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":79,"context_line":"                      timestamp\u003dNone, reserved_percentage\u003d0,"},{"line_number":80,"context_line":"                      driver_handles_share_servers\u003dFalse,"},{"line_number":81,"context_line":"                      snapshot_support\u003dTrue,"},{"line_number":82,"context_line":"                      replication\u003dNone,"},{"line_number":83,"context_line":"                      pools\u003d[dict(pool_name\u003d\u0027pool1\u0027,"},{"line_number":84,"context_line":"                                  total_capacity_gb\u003d51,"},{"line_number":85,"context_line":"                                  free_capacity_gb\u003d41,"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_c49fe9b2","line":82,"updated":"2015-11-13 20:26:31.000000000","message":"Be sure to update the name of the extra spec here.","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":79,"context_line":"                      timestamp\u003dNone, reserved_percentage\u003d0,"},{"line_number":80,"context_line":"                      driver_handles_share_servers\u003dFalse,"},{"line_number":81,"context_line":"                      snapshot_support\u003dTrue,"},{"line_number":82,"context_line":"                      replication\u003dNone,"},{"line_number":83,"context_line":"                      pools\u003d[dict(pool_name\u003d\u0027pool1\u0027,"},{"line_number":84,"context_line":"                                  total_capacity_gb\u003d51,"},{"line_number":85,"context_line":"                                  free_capacity_gb\u003d41,"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_22ca73a2","line":82,"in_reply_to":"da85f559_c49fe9b2","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":91,"context_line":"                      timestamp\u003dNone, reserved_percentage\u003d0,"},{"line_number":92,"context_line":"                      driver_handles_share_servers\u003dFalse,"},{"line_number":93,"context_line":"                      snapshot_support\u003dTrue,"},{"line_number":94,"context_line":"                      replication\u003dNone,"},{"line_number":95,"context_line":"                      pools\u003d[dict(pool_name\u003d\u0027pool2\u0027,"},{"line_number":96,"context_line":"                                  total_capacity_gb\u003d52,"},{"line_number":97,"context_line":"                                  free_capacity_gb\u003d42,"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_e4b8ed2c","line":94,"updated":"2015-11-13 20:26:31.000000000","message":"Ditto","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":91,"context_line":"                      timestamp\u003dNone, reserved_percentage\u003d0,"},{"line_number":92,"context_line":"                      driver_handles_share_servers\u003dFalse,"},{"line_number":93,"context_line":"                      snapshot_support\u003dTrue,"},{"line_number":94,"context_line":"                      replication\u003dNone,"},{"line_number":95,"context_line":"                      pools\u003d[dict(pool_name\u003d\u0027pool2\u0027,"},{"line_number":96,"context_line":"                                  total_capacity_gb\u003d52,"},{"line_number":97,"context_line":"                                  free_capacity_gb\u003d42,"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_42cf77b0","line":94,"in_reply_to":"da85f559_e4b8ed2c","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":103,"context_line":"                      timestamp\u003dNone, reserved_percentage\u003d0,"},{"line_number":104,"context_line":"                      driver_handles_share_servers\u003dFalse,"},{"line_number":105,"context_line":"                      snapshot_support\u003dTrue,"},{"line_number":106,"context_line":"                      replication\u003dNone,"},{"line_number":107,"context_line":"                      pools\u003d[dict(pool_name\u003d\u0027pool3\u0027,"},{"line_number":108,"context_line":"                                  total_capacity_gb\u003d53,"},{"line_number":109,"context_line":"                                  free_capacity_gb\u003d43,"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_c4860965","line":106,"updated":"2015-11-13 20:26:31.000000000","message":"Ditto","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":103,"context_line":"                      timestamp\u003dNone, reserved_percentage\u003d0,"},{"line_number":104,"context_line":"                      driver_handles_share_servers\u003dFalse,"},{"line_number":105,"context_line":"                      snapshot_support\u003dTrue,"},{"line_number":106,"context_line":"                      replication\u003dNone,"},{"line_number":107,"context_line":"                      pools\u003d[dict(pool_name\u003d\u0027pool3\u0027,"},{"line_number":108,"context_line":"                                  total_capacity_gb\u003d53,"},{"line_number":109,"context_line":"                                  free_capacity_gb\u003d43,"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_e2c46b93","line":106,"in_reply_to":"da85f559_c4860965","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":116,"context_line":"                      timestamp\u003dNone, reserved_percentage\u003d0,"},{"line_number":117,"context_line":"                      driver_handles_share_servers\u003dFalse,"},{"line_number":118,"context_line":"                      snapshot_support\u003dTrue,"},{"line_number":119,"context_line":"                      replication\u003dNone,"},{"line_number":120,"context_line":"                      pools\u003d[dict(pool_name\u003d\u0027pool4a\u0027,"},{"line_number":121,"context_line":"                                  total_capacity_gb\u003d541,"},{"line_number":122,"context_line":"                                  free_capacity_gb\u003d441,"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_84800148","line":119,"updated":"2015-11-13 20:26:31.000000000","message":"Ditto","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":116,"context_line":"                      timestamp\u003dNone, reserved_percentage\u003d0,"},{"line_number":117,"context_line":"                      driver_handles_share_servers\u003dFalse,"},{"line_number":118,"context_line":"                      snapshot_support\u003dTrue,"},{"line_number":119,"context_line":"                      replication\u003dNone,"},{"line_number":120,"context_line":"                      pools\u003d[dict(pool_name\u003d\u0027pool4a\u0027,"},{"line_number":121,"context_line":"                                  total_capacity_gb\u003d541,"},{"line_number":122,"context_line":"                                  free_capacity_gb\u003d441,"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_02c2cf85","line":119,"in_reply_to":"da85f559_84800148","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":137,"context_line":"                      timestamp\u003dNone, reserved_percentage\u003d0,"},{"line_number":138,"context_line":"                      driver_handles_share_servers\u003dFalse,"},{"line_number":139,"context_line":"                      snapshot_support\u003dTrue,"},{"line_number":140,"context_line":"                      replication\u003dNone,"},{"line_number":141,"context_line":"                      pools\u003d[dict(pool_name\u003d\u0027pool5a\u0027,"},{"line_number":142,"context_line":"                                  total_capacity_gb\u003d551,"},{"line_number":143,"context_line":"                                  free_capacity_gb\u003d451,"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_2496f594","line":140,"updated":"2015-11-13 20:26:31.000000000","message":"Ditto","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":137,"context_line":"                      timestamp\u003dNone, reserved_percentage\u003d0,"},{"line_number":138,"context_line":"                      driver_handles_share_servers\u003dFalse,"},{"line_number":139,"context_line":"                      snapshot_support\u003dTrue,"},{"line_number":140,"context_line":"                      replication\u003dNone,"},{"line_number":141,"context_line":"                      pools\u003d[dict(pool_name\u003d\u0027pool5a\u0027,"},{"line_number":142,"context_line":"                                  total_capacity_gb\u003d551,"},{"line_number":143,"context_line":"                                  free_capacity_gb\u003d451,"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_a2be63fd","line":140,"in_reply_to":"da85f559_2496f594","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":156,"context_line":"                      timestamp\u003dNone, reserved_percentage\u003d0,"},{"line_number":157,"context_line":"                      driver_handles_share_servers\u003dFalse,"},{"line_number":158,"context_line":"                      snapshot_support\u003dTrue,"},{"line_number":159,"context_line":"                      replication\u003dNone,"},{"line_number":160,"context_line":"                      pools\u003d[dict(pool_name\u003d\u0027pool6a\u0027,"},{"line_number":161,"context_line":"                                  total_capacity_gb\u003d\u0027unknown\u0027,"},{"line_number":162,"context_line":"                                  free_capacity_gb\u003d\u0027unknown\u0027,"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_4493f9a3","line":159,"updated":"2015-11-13 20:26:31.000000000","message":"Ditto","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":156,"context_line":"                      timestamp\u003dNone, reserved_percentage\u003d0,"},{"line_number":157,"context_line":"                      driver_handles_share_servers\u003dFalse,"},{"line_number":158,"context_line":"                      snapshot_support\u003dTrue,"},{"line_number":159,"context_line":"                      replication\u003dNone,"},{"line_number":160,"context_line":"                      pools\u003d[dict(pool_name\u003d\u0027pool6a\u0027,"},{"line_number":161,"context_line":"                                  total_capacity_gb\u003d\u0027unknown\u0027,"},{"line_number":162,"context_line":"                                  free_capacity_gb\u003d\u0027unknown\u0027,"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_62371bb1","line":159,"in_reply_to":"da85f559_4493f9a3","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":192,"context_line":"                      \u0027reserved_percentage\u0027: 10,"},{"line_number":193,"context_line":"                      \u0027timestamp\u0027: None,"},{"line_number":194,"context_line":"                      \u0027snapshot_support\u0027: True,"},{"line_number":195,"context_line":"                      \u0027replication\u0027: \u0027writable\u0027,"},{"line_number":196,"context_line":"                      },"},{"line_number":197,"context_line":"            \u0027host2\u0027: {\u0027total_capacity_gb\u0027: 2048,"},{"line_number":198,"context_line":"                      \u0027free_capacity_gb\u0027: 300,"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_84f7a1f4","line":195,"updated":"2015-11-13 20:26:31.000000000","message":"Ditto","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":192,"context_line":"                      \u0027reserved_percentage\u0027: 10,"},{"line_number":193,"context_line":"                      \u0027timestamp\u0027: None,"},{"line_number":194,"context_line":"                      \u0027snapshot_support\u0027: True,"},{"line_number":195,"context_line":"                      \u0027replication\u0027: \u0027writable\u0027,"},{"line_number":196,"context_line":"                      },"},{"line_number":197,"context_line":"            \u0027host2\u0027: {\u0027total_capacity_gb\u0027: 2048,"},{"line_number":198,"context_line":"                      \u0027free_capacity_gb\u0027: 300,"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_823c7f94","line":195,"in_reply_to":"da85f559_84f7a1f4","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":203,"context_line":"                      \u0027reserved_percentage\u0027: 10,"},{"line_number":204,"context_line":"                      \u0027timestamp\u0027: None,"},{"line_number":205,"context_line":"                      \u0027snapshot_support\u0027: True,"},{"line_number":206,"context_line":"                      \u0027replication\u0027: \u0027readable\u0027,"},{"line_number":207,"context_line":"                      },"},{"line_number":208,"context_line":"            \u0027host3\u0027: {\u0027total_capacity_gb\u0027: 512,"},{"line_number":209,"context_line":"                      \u0027free_capacity_gb\u0027: 256,"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_e4e6ad43","line":206,"updated":"2015-11-13 20:26:31.000000000","message":"Ditto","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":203,"context_line":"                      \u0027reserved_percentage\u0027: 10,"},{"line_number":204,"context_line":"                      \u0027timestamp\u0027: None,"},{"line_number":205,"context_line":"                      \u0027snapshot_support\u0027: True,"},{"line_number":206,"context_line":"                      \u0027replication\u0027: \u0027readable\u0027,"},{"line_number":207,"context_line":"                      },"},{"line_number":208,"context_line":"            \u0027host3\u0027: {\u0027total_capacity_gb\u0027: 512,"},{"line_number":209,"context_line":"                      \u0027free_capacity_gb\u0027: 256,"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_42469724","line":206,"in_reply_to":"da85f559_e4e6ad43","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":225,"context_line":"                      \u0027reserved_percentage\u0027: 5,"},{"line_number":226,"context_line":"                      \u0027timestamp\u0027: None,"},{"line_number":227,"context_line":"                      \u0027snapshot_support\u0027: True,"},{"line_number":228,"context_line":"                      \u0027replication\u0027: \u0027dr\u0027,"},{"line_number":229,"context_line":"                      },"},{"line_number":230,"context_line":"            \u0027host5\u0027: {\u0027total_capacity_gb\u0027: 2048,"},{"line_number":231,"context_line":"                      \u0027free_capacity_gb\u0027: 500,"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_44c1b97f","line":228,"updated":"2015-11-13 20:26:31.000000000","message":"Ditto","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":225,"context_line":"                      \u0027reserved_percentage\u0027: 5,"},{"line_number":226,"context_line":"                      \u0027timestamp\u0027: None,"},{"line_number":227,"context_line":"                      \u0027snapshot_support\u0027: True,"},{"line_number":228,"context_line":"                      \u0027replication\u0027: \u0027dr\u0027,"},{"line_number":229,"context_line":"                      },"},{"line_number":230,"context_line":"            \u0027host5\u0027: {\u0027total_capacity_gb\u0027: 2048,"},{"line_number":231,"context_line":"                      \u0027free_capacity_gb\u0027: 500,"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_e24b0b2a","line":228,"in_reply_to":"da85f559_44c1b97f","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":237,"context_line":"                      \u0027timestamp\u0027: None,"},{"line_number":238,"context_line":"                      \u0027snapshot_support\u0027: True,"},{"line_number":239,"context_line":"                      \u0027consistency_group_support\u0027: \u0027pool\u0027,"},{"line_number":240,"context_line":"                      \u0027replication\u0027: None,"},{"line_number":241,"context_line":"                      },"},{"line_number":242,"context_line":"            \u0027host6\u0027: {\u0027total_capacity_gb\u0027: \u0027unknown\u0027,"},{"line_number":243,"context_line":"                      \u0027free_capacity_gb\u0027: \u0027unknown\u0027,"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_c43b699b","line":240,"updated":"2015-11-13 20:26:31.000000000","message":"Ditto","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":237,"context_line":"                      \u0027timestamp\u0027: None,"},{"line_number":238,"context_line":"                      \u0027snapshot_support\u0027: True,"},{"line_number":239,"context_line":"                      \u0027consistency_group_support\u0027: \u0027pool\u0027,"},{"line_number":240,"context_line":"                      \u0027replication\u0027: None,"},{"line_number":241,"context_line":"                      },"},{"line_number":242,"context_line":"            \u0027host6\u0027: {\u0027total_capacity_gb\u0027: \u0027unknown\u0027,"},{"line_number":243,"context_line":"                      \u0027free_capacity_gb\u0027: \u0027unknown\u0027,"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_02496f31","line":240,"in_reply_to":"da85f559_c43b699b","updated":"2015-11-19 19:45:53.000000000","message":":) Thanks dustins","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"}],"manila/tests/scheduler/test_host_manager.py":[{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":198,"context_line":"                        \u0027consistency_group_support\u0027: False,"},{"line_number":199,"context_line":"                        \u0027dedupe\u0027: False,"},{"line_number":200,"context_line":"                        \u0027compression\u0027: False,"},{"line_number":201,"context_line":"                        \u0027replication\u0027: None,"},{"line_number":202,"context_line":"                    },"},{"line_number":203,"context_line":"                }, {"},{"line_number":204,"context_line":"                    \u0027name\u0027: \u0027host2@back1#BBB\u0027,"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_07aad370","line":201,"updated":"2015-11-13 20:26:31.000000000","message":"Be sure to change the name of this extra spec.","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":198,"context_line":"                        \u0027consistency_group_support\u0027: False,"},{"line_number":199,"context_line":"                        \u0027dedupe\u0027: False,"},{"line_number":200,"context_line":"                        \u0027compression\u0027: False,"},{"line_number":201,"context_line":"                        \u0027replication\u0027: None,"},{"line_number":202,"context_line":"                    },"},{"line_number":203,"context_line":"                }, {"},{"line_number":204,"context_line":"                    \u0027name\u0027: \u0027host2@back1#BBB\u0027,"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_425d37e8","line":201,"in_reply_to":"da85f559_07aad370","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":222,"context_line":"                        \u0027consistency_group_support\u0027: False,"},{"line_number":223,"context_line":"                        \u0027dedupe\u0027: False,"},{"line_number":224,"context_line":"                        \u0027compression\u0027: False,"},{"line_number":225,"context_line":"                        \u0027replication\u0027: None,"},{"line_number":226,"context_line":"                    },"},{"line_number":227,"context_line":"                }, {"},{"line_number":228,"context_line":"                    \u0027name\u0027: \u0027host2@back2#CCC\u0027,"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_67af1f7e","line":225,"updated":"2015-11-13 20:26:31.000000000","message":"Ditto","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":222,"context_line":"                        \u0027consistency_group_support\u0027: False,"},{"line_number":223,"context_line":"                        \u0027dedupe\u0027: False,"},{"line_number":224,"context_line":"                        \u0027compression\u0027: False,"},{"line_number":225,"context_line":"                        \u0027replication\u0027: None,"},{"line_number":226,"context_line":"                    },"},{"line_number":227,"context_line":"                }, {"},{"line_number":228,"context_line":"                    \u0027name\u0027: \u0027host2@back2#CCC\u0027,"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_e2722b7c","line":225,"in_reply_to":"da85f559_67af1f7e","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":246,"context_line":"                        \u0027consistency_group_support\u0027: False,"},{"line_number":247,"context_line":"                        \u0027dedupe\u0027: False,"},{"line_number":248,"context_line":"                        \u0027compression\u0027: False,"},{"line_number":249,"context_line":"                        \u0027replication\u0027: None,"},{"line_number":250,"context_line":"                    },"},{"line_number":251,"context_line":"                },"},{"line_number":252,"context_line":"            ]"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_47c77b45","line":249,"updated":"2015-11-13 20:26:31.000000000","message":"Ditto","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":246,"context_line":"                        \u0027consistency_group_support\u0027: False,"},{"line_number":247,"context_line":"                        \u0027dedupe\u0027: False,"},{"line_number":248,"context_line":"                        \u0027compression\u0027: False,"},{"line_number":249,"context_line":"                        \u0027replication\u0027: None,"},{"line_number":250,"context_line":"                    },"},{"line_number":251,"context_line":"                },"},{"line_number":252,"context_line":"            ]"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_02708f71","line":249,"in_reply_to":"da85f559_47c77b45","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":292,"context_line":"                        \u0027consistency_group_support\u0027: False,"},{"line_number":293,"context_line":"                        \u0027dedupe\u0027: False,"},{"line_number":294,"context_line":"                        \u0027compression\u0027: False,"},{"line_number":295,"context_line":"                        \u0027replication\u0027: None,"},{"line_number":296,"context_line":"                    },"},{"line_number":297,"context_line":"                }, {"},{"line_number":298,"context_line":"                    \u0027name\u0027: \u0027host2@BBB#pool2\u0027,"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_07c1732e","line":295,"updated":"2015-11-13 20:26:31.000000000","message":"Ditto","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":292,"context_line":"                        \u0027consistency_group_support\u0027: False,"},{"line_number":293,"context_line":"                        \u0027dedupe\u0027: False,"},{"line_number":294,"context_line":"                        \u0027compression\u0027: False,"},{"line_number":295,"context_line":"                        \u0027replication\u0027: None,"},{"line_number":296,"context_line":"                    },"},{"line_number":297,"context_line":"                }, {"},{"line_number":298,"context_line":"                    \u0027name\u0027: \u0027host2@BBB#pool2\u0027,"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_a26c239d","line":295,"in_reply_to":"da85f559_07c1732e","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":317,"context_line":"                        \u0027consistency_group_support\u0027: False,"},{"line_number":318,"context_line":"                        \u0027dedupe\u0027: False,"},{"line_number":319,"context_line":"                        \u0027compression\u0027: False,"},{"line_number":320,"context_line":"                        \u0027replication\u0027: None,"},{"line_number":321,"context_line":"                    },"},{"line_number":322,"context_line":"                }, {"},{"line_number":323,"context_line":"                    \u0027name\u0027: \u0027host3@CCC#pool3\u0027,"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_c7e12bd2","line":320,"updated":"2015-11-13 20:26:31.000000000","message":"Ditto","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":317,"context_line":"                        \u0027consistency_group_support\u0027: False,"},{"line_number":318,"context_line":"                        \u0027dedupe\u0027: False,"},{"line_number":319,"context_line":"                        \u0027compression\u0027: False,"},{"line_number":320,"context_line":"                        \u0027replication\u0027: None,"},{"line_number":321,"context_line":"                    },"},{"line_number":322,"context_line":"                }, {"},{"line_number":323,"context_line":"                    \u0027name\u0027: \u0027host3@CCC#pool3\u0027,"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_6205dbc0","line":320,"in_reply_to":"da85f559_c7e12bd2","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":342,"context_line":"                        \u0027consistency_group_support\u0027: \u0027pool\u0027,"},{"line_number":343,"context_line":"                        \u0027dedupe\u0027: False,"},{"line_number":344,"context_line":"                        \u0027compression\u0027: False,"},{"line_number":345,"context_line":"                        \u0027replication\u0027: None,"},{"line_number":346,"context_line":"                    },"},{"line_number":347,"context_line":"                }, {"},{"line_number":348,"context_line":"                    \u0027name\u0027: \u0027host4@DDD#pool4a\u0027,"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_87eb23b0","line":345,"updated":"2015-11-13 20:26:31.000000000","message":"Ditto","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":342,"context_line":"                        \u0027consistency_group_support\u0027: \u0027pool\u0027,"},{"line_number":343,"context_line":"                        \u0027dedupe\u0027: False,"},{"line_number":344,"context_line":"                        \u0027compression\u0027: False,"},{"line_number":345,"context_line":"                        \u0027replication\u0027: None,"},{"line_number":346,"context_line":"                    },"},{"line_number":347,"context_line":"                }, {"},{"line_number":348,"context_line":"                    \u0027name\u0027: \u0027host4@DDD#pool4a\u0027,"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_02f72fd4","line":345,"in_reply_to":"da85f559_87eb23b0","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":367,"context_line":"                        \u0027consistency_group_support\u0027: \u0027host\u0027,"},{"line_number":368,"context_line":"                        \u0027dedupe\u0027: False,"},{"line_number":369,"context_line":"                        \u0027compression\u0027: False,"},{"line_number":370,"context_line":"                        \u0027replication\u0027: None,"},{"line_number":371,"context_line":"                    },"},{"line_number":372,"context_line":"                }, {"},{"line_number":373,"context_line":"                    \u0027name\u0027: \u0027host4@DDD#pool4b\u0027,"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_27d117fc","line":370,"updated":"2015-11-13 20:26:31.000000000","message":"Ditto","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":367,"context_line":"                        \u0027consistency_group_support\u0027: \u0027host\u0027,"},{"line_number":368,"context_line":"                        \u0027dedupe\u0027: False,"},{"line_number":369,"context_line":"                        \u0027compression\u0027: False,"},{"line_number":370,"context_line":"                        \u0027replication\u0027: None,"},{"line_number":371,"context_line":"                    },"},{"line_number":372,"context_line":"                }, {"},{"line_number":373,"context_line":"                    \u0027name\u0027: \u0027host4@DDD#pool4b\u0027,"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_a203c3b7","line":370,"in_reply_to":"da85f559_27d117fc","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":392,"context_line":"                        \u0027consistency_group_support\u0027: \u0027host\u0027,"},{"line_number":393,"context_line":"                        \u0027dedupe\u0027: False,"},{"line_number":394,"context_line":"                        \u0027compression\u0027: False,"},{"line_number":395,"context_line":"                        \u0027replication\u0027: None,"},{"line_number":396,"context_line":"                    },"},{"line_number":397,"context_line":"                },"},{"line_number":398,"context_line":"            ]"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_67e71fad","line":395,"updated":"2015-11-13 20:26:31.000000000","message":"Ditto","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":392,"context_line":"                        \u0027consistency_group_support\u0027: \u0027host\u0027,"},{"line_number":393,"context_line":"                        \u0027dedupe\u0027: False,"},{"line_number":394,"context_line":"                        \u0027compression\u0027: False,"},{"line_number":395,"context_line":"                        \u0027replication\u0027: None,"},{"line_number":396,"context_line":"                    },"},{"line_number":397,"context_line":"                },"},{"line_number":398,"context_line":"            ]"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_2a60d700","line":395,"in_reply_to":"da85f559_67e71fad","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":450,"context_line":"                        \u0027consistency_group_support\u0027: False,"},{"line_number":451,"context_line":"                        \u0027dedupe\u0027: False,"},{"line_number":452,"context_line":"                        \u0027compression\u0027: False,"},{"line_number":453,"context_line":"                        \u0027replication\u0027: None,"},{"line_number":454,"context_line":"                    },"},{"line_number":455,"context_line":"                }, {"},{"line_number":456,"context_line":"                    \u0027name\u0027: \u0027host2@back1#BBB\u0027,"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_47ff7b34","line":453,"updated":"2015-11-13 20:26:31.000000000","message":"ditto","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":450,"context_line":"                        \u0027consistency_group_support\u0027: False,"},{"line_number":451,"context_line":"                        \u0027dedupe\u0027: False,"},{"line_number":452,"context_line":"                        \u0027compression\u0027: False,"},{"line_number":453,"context_line":"                        \u0027replication\u0027: None,"},{"line_number":454,"context_line":"                    },"},{"line_number":455,"context_line":"                }, {"},{"line_number":456,"context_line":"                    \u0027name\u0027: \u0027host2@back1#BBB\u0027,"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_622cfb4a","line":453,"in_reply_to":"da85f559_47ff7b34","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":474,"context_line":"                        \u0027consistency_group_support\u0027: False,"},{"line_number":475,"context_line":"                        \u0027dedupe\u0027: False,"},{"line_number":476,"context_line":"                        \u0027compression\u0027: False,"},{"line_number":477,"context_line":"                        \u0027replication\u0027: None,"},{"line_number":478,"context_line":"                    },"},{"line_number":479,"context_line":"                },"},{"line_number":480,"context_line":"            ]"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_e7fb0f46","line":477,"updated":"2015-11-13 20:26:31.000000000","message":"Ditto","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":474,"context_line":"                        \u0027consistency_group_support\u0027: False,"},{"line_number":475,"context_line":"                        \u0027dedupe\u0027: False,"},{"line_number":476,"context_line":"                        \u0027compression\u0027: False,"},{"line_number":477,"context_line":"                        \u0027replication\u0027: None,"},{"line_number":478,"context_line":"                    },"},{"line_number":479,"context_line":"                },"},{"line_number":480,"context_line":"            ]"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_2226f368","line":477,"in_reply_to":"da85f559_e7fb0f46","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":524,"context_line":"                        \u0027consistency_group_support\u0027: False,"},{"line_number":525,"context_line":"                        \u0027dedupe\u0027: False,"},{"line_number":526,"context_line":"                        \u0027compression\u0027: False,"},{"line_number":527,"context_line":"                        \u0027replication\u0027: None,"},{"line_number":528,"context_line":"                    },"},{"line_number":529,"context_line":"                },"},{"line_number":530,"context_line":"            ]"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_a79427e8","line":527,"updated":"2015-11-13 20:26:31.000000000","message":"Ditto","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":524,"context_line":"                        \u0027consistency_group_support\u0027: False,"},{"line_number":525,"context_line":"                        \u0027dedupe\u0027: False,"},{"line_number":526,"context_line":"                        \u0027compression\u0027: False,"},{"line_number":527,"context_line":"                        \u0027replication\u0027: None,"},{"line_number":528,"context_line":"                    },"},{"line_number":529,"context_line":"                },"},{"line_number":530,"context_line":"            ]"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_422bf730","line":527,"in_reply_to":"da85f559_a79427e8","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"}],"manila/tests/share/test_api.py":[{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":109,"context_line":""},{"line_number":110,"context_line":""},{"line_number":111,"context_line":"def fake_replica(id, **kwargs):"},{"line_number":112,"context_line":"    replica \u003d {"},{"line_number":113,"context_line":"        \u0027id\u0027: id,"},{"line_number":114,"context_line":"        \u0027share_id\u0027: \u0027f0e4bb5e-65f0-11e5-9d70-feff819cdc9f\u0027,"},{"line_number":115,"context_line":"        \u0027deleted\u0027: False,"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_27b0378b","line":112,"updated":"2015-11-13 20:26:31.000000000","message":"This replica dictionary could probably be stored in the fakes.py file.","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":109,"context_line":""},{"line_number":110,"context_line":""},{"line_number":111,"context_line":"def fake_replica(id, **kwargs):"},{"line_number":112,"context_line":"    replica \u003d {"},{"line_number":113,"context_line":"        \u0027id\u0027: id,"},{"line_number":114,"context_line":"        \u0027share_id\u0027: \u0027f0e4bb5e-65f0-11e5-9d70-feff819cdc9f\u0027,"},{"line_number":115,"context_line":"        \u0027deleted\u0027: False,"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_353cab2e","line":112,"in_reply_to":"da85f559_27b0378b","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":129,"context_line":""},{"line_number":130,"context_line":""},{"line_number":131,"context_line":"def fake_request_spec(**kwargs):"},{"line_number":132,"context_line":"    request_spec \u003d {"},{"line_number":133,"context_line":"        \u0027share_properties\u0027: fake_share(\u0027f0e4bb5e-65f0-11e5-9d70-feff819cdc9f\u0027),"},{"line_number":134,"context_line":"        \u0027share_instance_properties\u0027: fake_replica("},{"line_number":135,"context_line":"            \u00279c0db763-a109-4862-b010-10f2bd395295\u0027),"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_2777d7d5","line":132,"updated":"2015-11-13 20:26:31.000000000","message":"The request spec here could be stored in the fakes.py file.","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":129,"context_line":""},{"line_number":130,"context_line":""},{"line_number":131,"context_line":"def fake_request_spec(**kwargs):"},{"line_number":132,"context_line":"    request_spec \u003d {"},{"line_number":133,"context_line":"        \u0027share_properties\u0027: fake_share(\u0027f0e4bb5e-65f0-11e5-9d70-feff819cdc9f\u0027),"},{"line_number":134,"context_line":"        \u0027share_instance_properties\u0027: fake_replica("},{"line_number":135,"context_line":"            \u00279c0db763-a109-4862-b010-10f2bd395295\u0027),"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_d54affc4","line":132,"in_reply_to":"da85f559_2777d7d5","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"}],"manila/tests/share/test_manager.py":[{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":42,"context_line":""},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"def fake_replica(**kwargs):"},{"line_number":45,"context_line":"    replica \u003d {"},{"line_number":46,"context_line":"        \u0027id\u0027: \u00279c0db763-a109-4862-b010-10f2bd395295\u0027,"},{"line_number":47,"context_line":"        \u0027share_id\u0027: \u0027f0e4bb5e-65f0-11e5-9d70-feff819cdc9f\u0027,"},{"line_number":48,"context_line":"        \u0027deleted\u0027: False,"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_b84e8694","line":45,"updated":"2015-11-13 20:26:31.000000000","message":"You\u0027re duplicating the code from the test_api.py file. You should move this into the common fakes.py file","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":42,"context_line":""},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"def fake_replica(**kwargs):"},{"line_number":45,"context_line":"    replica \u003d {"},{"line_number":46,"context_line":"        \u0027id\u0027: \u00279c0db763-a109-4862-b010-10f2bd395295\u0027,"},{"line_number":47,"context_line":"        \u0027share_id\u0027: \u0027f0e4bb5e-65f0-11e5-9d70-feff819cdc9f\u0027,"},{"line_number":48,"context_line":"        \u0027deleted\u0027: False,"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_555b6f87","line":45,"in_reply_to":"da85f559_b84e8694","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"}],"manila/utils.py":[{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"d015a822e3a464fc20396e53ac428dd4588b9572","unresolved":false,"context_lines":[{"line_number":50,"context_line":"LOG \u003d log.getLogger(__name__)"},{"line_number":51,"context_line":""},{"line_number":52,"context_line":"synchronized \u003d lockutils.synchronized_with_prefix(\u0027manila-\u0027)"},{"line_number":53,"context_line":"lock \u003d functools.partial(lockutils.lock, lock_file_prefix\u003d\u0027manila-\u0027)"},{"line_number":54,"context_line":""},{"line_number":55,"context_line":""},{"line_number":56,"context_line":"def _get_root_helper():"}],"source_content_type":"text/x-python","patch_set":9,"id":"7a740942_6fa5b702","line":53,"updated":"2015-12-04 11:44:31.000000000","message":"Where do you use it and why do you need it?\n\nif it is needed only for tests, then it should be in \"manila/tests/utils.py\" module.","commit_id":"4ce0386bf01fc255bbf752978f09865992c4ec1f"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"b25160fd8aa84eb7b7e544cd1e4bf546811af9d4","unresolved":false,"context_lines":[{"line_number":50,"context_line":"LOG \u003d log.getLogger(__name__)"},{"line_number":51,"context_line":""},{"line_number":52,"context_line":"synchronized \u003d lockutils.synchronized_with_prefix(\u0027manila-\u0027)"},{"line_number":53,"context_line":"lock \u003d functools.partial(lockutils.lock, lock_file_prefix\u003d\u0027manila-\u0027)"},{"line_number":54,"context_line":""},{"line_number":55,"context_line":""},{"line_number":56,"context_line":"def _get_root_helper():"}],"source_content_type":"text/x-python","patch_set":9,"id":"7a740942_daf34b72","line":53,"in_reply_to":"7a740942_6fa5b702","updated":"2015-12-04 18:42:01.000000000","message":"Im using this as a context manager in:\n\nmanila/share/manage.py\n\nI\u0027m locking on the share_id in all replica methods to avoid failures due to races. This is an interim solution before we lock resources using, possibly: https://github.com/openstack/tooz\n\nhttps://review.openstack.org/#/c/238572/9/manila/share/manager.py","commit_id":"4ce0386bf01fc255bbf752978f09865992c4ec1f"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"d1755246f54a6f982803dacf1b62917e2a30f9ac","unresolved":false,"context_lines":[{"line_number":50,"context_line":"LOG \u003d log.getLogger(__name__)"},{"line_number":51,"context_line":""},{"line_number":52,"context_line":"synchronized \u003d lockutils.synchronized_with_prefix(\u0027manila-\u0027)"},{"line_number":53,"context_line":"lock \u003d functools.partial(lockutils.lock, lock_file_prefix\u003d\u0027manila-\u0027)"},{"line_number":54,"context_line":""},{"line_number":55,"context_line":""},{"line_number":56,"context_line":"def _get_root_helper():"}],"source_content_type":"text/x-python","patch_set":23,"id":"7a5de9d1_a24312ae","line":53,"range":{"start_line":53,"start_character":0,"end_line":53,"end_character":68},"updated":"2016-02-01 17:38:54.000000000","message":"It is not used. Should be removed.","commit_id":"08799ad6674f3bd54a1fd9984ad78dbd8e862a93"}],"manila_tempest_tests/tests/api/base.py":[{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"7a6638d6f2d08c50908d44eb13264466627f6118","unresolved":false,"context_lines":[{"line_number":322,"context_line":"        if consistency_group_id:"},{"line_number":323,"context_line":"            kwargs[\u0027consistency_group_id\u0027] \u003d consistency_group_id"},{"line_number":324,"context_line":""},{"line_number":325,"context_line":"        if client \u003d\u003d cls.shares_v2_client:"},{"line_number":326,"context_line":"            kwargs[\u0027version\u0027] \u003d version"},{"line_number":327,"context_line":""},{"line_number":328,"context_line":"        share \u003d client.create_share(**kwargs)"}],"source_content_type":"text/x-python","patch_set":1,"id":"da85f559_b2b26c04","line":325,"updated":"2015-11-12 16:08:44.000000000","message":"It is duplication effort. V2 client already does it.","commit_id":"dac7938116cfdbee468b3fbdfe42a3ab397fd347"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1d44846ad1c530ff7c7ed1dcf4ce2265bb331768","unresolved":false,"context_lines":[{"line_number":322,"context_line":"        if consistency_group_id:"},{"line_number":323,"context_line":"            kwargs[\u0027consistency_group_id\u0027] \u003d consistency_group_id"},{"line_number":324,"context_line":""},{"line_number":325,"context_line":"        if client \u003d\u003d cls.shares_v2_client:"},{"line_number":326,"context_line":"            kwargs[\u0027version\u0027] \u003d version"},{"line_number":327,"context_line":""},{"line_number":328,"context_line":"        share \u003d client.create_share(**kwargs)"}],"source_content_type":"text/x-python","patch_set":1,"id":"ba8a016a_368f9c2b","line":325,"in_reply_to":"da85f559_b2b26c04","updated":"2015-11-19 19:44:49.000000000","message":"Done","commit_id":"dac7938116cfdbee468b3fbdfe42a3ab397fd347"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"7a6638d6f2d08c50908d44eb13264466627f6118","unresolved":false,"context_lines":[{"line_number":378,"context_line":"                    \"Provided %s\" % list(d))"},{"line_number":379,"context_line":"            d[\"kwargs\"][\"client\"] \u003d d[\"kwargs\"].get("},{"line_number":380,"context_line":"                \"client\", cls.shares_v2_client)"},{"line_number":381,"context_line":"            d[\"kwargs\"][\"version\"] \u003d d[\"kwargs\"].get("},{"line_number":382,"context_line":"                \"version\", LATEST_MICROVERSION)"},{"line_number":383,"context_line":"            d[\"share\"] \u003d cls._create_share(*d[\"args\"], **d[\"kwargs\"])"},{"line_number":384,"context_line":"            d[\"cnt\"] \u003d 0"}],"source_content_type":"text/x-python","patch_set":1,"id":"da85f559_b2802cf8","line":381,"updated":"2015-11-12 16:08:44.000000000","message":"Same here. No need to update this file at all.","commit_id":"dac7938116cfdbee468b3fbdfe42a3ab397fd347"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1d44846ad1c530ff7c7ed1dcf4ce2265bb331768","unresolved":false,"context_lines":[{"line_number":378,"context_line":"                    \"Provided %s\" % list(d))"},{"line_number":379,"context_line":"            d[\"kwargs\"][\"client\"] \u003d d[\"kwargs\"].get("},{"line_number":380,"context_line":"                \"client\", cls.shares_v2_client)"},{"line_number":381,"context_line":"            d[\"kwargs\"][\"version\"] \u003d d[\"kwargs\"].get("},{"line_number":382,"context_line":"                \"version\", LATEST_MICROVERSION)"},{"line_number":383,"context_line":"            d[\"share\"] \u003d cls._create_share(*d[\"args\"], **d[\"kwargs\"])"},{"line_number":384,"context_line":"            d[\"cnt\"] \u003d 0"}],"source_content_type":"text/x-python","patch_set":1,"id":"ba8a016a_d67f3015","line":381,"in_reply_to":"da85f559_b2802cf8","updated":"2015-11-19 19:44:49.000000000","message":"Done","commit_id":"dac7938116cfdbee468b3fbdfe42a3ab397fd347"}],"manila_tempest_tests/tests/api/test_consistency_group_actions.py":[{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"7a6638d6f2d08c50908d44eb13264466627f6118","unresolved":false,"context_lines":[{"line_number":132,"context_line":"                         msg)"},{"line_number":133,"context_line":""},{"line_number":134,"context_line":"    @test.attr(type\u003d[\"gate\", ])"},{"line_number":135,"context_line":"    def test_get_share_v2_4(self):"},{"line_number":136,"context_line":""},{"line_number":137,"context_line":"        # Get share"},{"line_number":138,"context_line":"        share \u003d self.shares_v2_client.get_share(self.share[\u0027id\u0027],"}],"source_content_type":"text/x-python","patch_set":1,"id":"da85f559_32751c31","side":"PARENT","line":135,"updated":"2015-11-12 16:08:44.000000000","message":"Why it is removed?","commit_id":"7523165b56ccbe565e3e97933aec7c0e6c0a3d2c"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1d44846ad1c530ff7c7ed1dcf4ce2265bb331768","unresolved":false,"context_lines":[{"line_number":132,"context_line":"                         msg)"},{"line_number":133,"context_line":""},{"line_number":134,"context_line":"    @test.attr(type\u003d[\"gate\", ])"},{"line_number":135,"context_line":"    def test_get_share_v2_4(self):"},{"line_number":136,"context_line":""},{"line_number":137,"context_line":"        # Get share"},{"line_number":138,"context_line":"        share \u003d self.shares_v2_client.get_share(self.share[\u0027id\u0027],"}],"source_content_type":"text/x-python","patch_set":1,"id":"ba8a016a_8230ff57","side":"PARENT","line":135,"in_reply_to":"da85f559_32751c31","updated":"2015-11-19 19:44:49.000000000","message":"This test was moved to:\n\n\nhttps://review.openstack.org/#/c/238572/1/manila_tempest_tests/tests/api/test_shares_actions.py\n\nfor consistency with the rest of the share getter methods. \n\n(It shouldn\u0027t have been here when it was written, unless someone was looking in the wrong place)","commit_id":"7523165b56ccbe565e3e97933aec7c0e6c0a3d2c"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"061b886705c42cea2f9f63e8dead3e7ea59c2219","unresolved":false,"context_lines":[{"line_number":131,"context_line":"        self.assertEqual(self.cg_desc, str(consistency_group[\"description\"]),"},{"line_number":132,"context_line":"                         msg)"},{"line_number":133,"context_line":""},{"line_number":134,"context_line":"    @test.attr(type\u003d[\"gate\", ])"},{"line_number":135,"context_line":"    def test_list_consistency_groups_v2_4(self):"},{"line_number":136,"context_line":""},{"line_number":137,"context_line":"        # List consistency groups"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_0f66b329","line":134,"updated":"2015-11-20 03:30:03.000000000","message":"Why is this removed?  Is this change related?","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"71ba533b590a228a423a3fcdfccc5c8d84bdc4d1","unresolved":false,"context_lines":[{"line_number":131,"context_line":"        self.assertEqual(self.cg_desc, str(consistency_group[\"description\"]),"},{"line_number":132,"context_line":"                         msg)"},{"line_number":133,"context_line":""},{"line_number":134,"context_line":"    @test.attr(type\u003d[\"gate\", ])"},{"line_number":135,"context_line":"    def test_list_consistency_groups_v2_4(self):"},{"line_number":136,"context_line":""},{"line_number":137,"context_line":"        # List consistency groups"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_17cf84b4","line":134,"in_reply_to":"ba8a016a_0f66b329","updated":"2015-11-20 17:08:26.000000000","message":"+1","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"3b45c7a4783e66821748ec9cf5859baf7bb088da","unresolved":false,"context_lines":[{"line_number":131,"context_line":"        self.assertEqual(self.cg_desc, str(consistency_group[\"description\"]),"},{"line_number":132,"context_line":"                         msg)"},{"line_number":133,"context_line":""},{"line_number":134,"context_line":"    @test.attr(type\u003d[\"gate\", ])"},{"line_number":135,"context_line":"    def test_list_consistency_groups_v2_4(self):"},{"line_number":136,"context_line":""},{"line_number":137,"context_line":"        # List consistency groups"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_8167bde9","line":134,"in_reply_to":"ba8a016a_0f66b329","updated":"2015-11-20 17:09:27.000000000","message":"This test was failing when I was testing this code for inconsistency in keys being evaluated. I moved this test to its rightful place in:\n\nhttps://review.openstack.org/#/c/238572/4/manila_tempest_tests/tests/api/test_shares_actions.py \n\nLines 169, 194.. I\u0027ll make a note in the commit message.","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"e47967aed0fcad689a3aec42a79654a5b12a6c45","unresolved":false,"context_lines":[{"line_number":131,"context_line":"        self.assertEqual(self.cg_desc, str(consistency_group[\"description\"]),"},{"line_number":132,"context_line":"                         msg)"},{"line_number":133,"context_line":""},{"line_number":134,"context_line":"    @test.attr(type\u003d[\"gate\", ])"},{"line_number":135,"context_line":"    def test_list_consistency_groups_v2_4(self):"},{"line_number":136,"context_line":""},{"line_number":137,"context_line":"        # List consistency groups"}],"source_content_type":"text/x-python","patch_set":4,"id":"9a8ffd7b_d95d79ed","line":134,"in_reply_to":"ba8a016a_8167bde9","updated":"2015-12-01 16:30:42.000000000","message":"This test was restored. I\u0027m keeping the related test in:\n\nmanila_tempest_tests/tests/api/test_shares_actions.py however","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"}],"manila_tempest_tests/tests/api/test_shares.py":[{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":50,"context_line":"        }"},{"line_number":51,"context_line":"        if version \u003e 2.2:"},{"line_number":52,"context_line":"            detailed_elements.add(\u0027snapshot_support\u0027)"},{"line_number":53,"context_line":"        if version \u003e 2.6:"},{"line_number":54,"context_line":"            detailed_elements.add(\u0027replication\u0027)"},{"line_number":55,"context_line":""},{"line_number":56,"context_line":"        self.assertTrue(detailed_elements.issubset(share.keys()),"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_b351c910","line":53,"updated":"2015-11-13 20:26:31.000000000","message":"I feel like these if statements should read \n\n if version \u003e\u003d \u003cminimum_api_version\u003e:\n\nJust to make it clear what the minimum version that supports the new API.","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":50,"context_line":"        }"},{"line_number":51,"context_line":"        if version \u003e 2.2:"},{"line_number":52,"context_line":"            detailed_elements.add(\u0027snapshot_support\u0027)"},{"line_number":53,"context_line":"        if version \u003e 2.6:"},{"line_number":54,"context_line":"            detailed_elements.add(\u0027replication\u0027)"},{"line_number":55,"context_line":""},{"line_number":56,"context_line":"        self.assertTrue(detailed_elements.issubset(share.keys()),"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_02cc0f88","line":53,"in_reply_to":"da85f559_b351c910","updated":"2015-11-19 19:45:53.000000000","message":"I guess we were trying to avoid the famous floating point equality comparisons:\n\nhttp://stackoverflow.com/questions/4915462/how-should-i-do-floating-point-comparison","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"71ba533b590a228a423a3fcdfccc5c8d84bdc4d1","unresolved":false,"context_lines":[{"line_number":68,"context_line":"                          share[\u0027id\u0027])"},{"line_number":69,"context_line":""},{"line_number":70,"context_line":"    @test.attr(type\u003d[\"gate\", ])"},{"line_number":71,"context_line":"    def test_create_delete_share_v2_1(self):"},{"line_number":72,"context_line":"        self._create_delete_share(2.1)"},{"line_number":73,"context_line":""},{"line_number":74,"context_line":"    @test.attr(type\u003d[\"gate\", ])"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_57bd0c01","line":71,"updated":"2015-11-20 17:08:26.000000000","message":"this one renamed","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"e47967aed0fcad689a3aec42a79654a5b12a6c45","unresolved":false,"context_lines":[{"line_number":68,"context_line":"                          share[\u0027id\u0027])"},{"line_number":69,"context_line":""},{"line_number":70,"context_line":"    @test.attr(type\u003d[\"gate\", ])"},{"line_number":71,"context_line":"    def test_create_delete_share_v2_1(self):"},{"line_number":72,"context_line":"        self._create_delete_share(2.1)"},{"line_number":73,"context_line":""},{"line_number":74,"context_line":"    @test.attr(type\u003d[\"gate\", ])"}],"source_content_type":"text/x-python","patch_set":4,"id":"9a8ffd7b_34d5d5b8","line":71,"in_reply_to":"ba8a016a_57bd0c01","updated":"2015-12-01 16:30:42.000000000","message":"Done","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"71ba533b590a228a423a3fcdfccc5c8d84bdc4d1","unresolved":false,"context_lines":[{"line_number":72,"context_line":"        self._create_delete_share(2.1)"},{"line_number":73,"context_line":""},{"line_number":74,"context_line":"    @test.attr(type\u003d[\"gate\", ])"},{"line_number":75,"context_line":"    def test_create_delete_share_with_snapshot_support_feature(self):"},{"line_number":76,"context_line":"        self._create_delete_share(2.2)"},{"line_number":77,"context_line":""},{"line_number":78,"context_line":"    @test.attr(type\u003d[\"gate\", ])"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_f744401c","line":75,"updated":"2015-11-20 17:08:26.000000000","message":"This one not. Better to leave both as is as not related to the goal of commit already having big change.","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"e47967aed0fcad689a3aec42a79654a5b12a6c45","unresolved":false,"context_lines":[{"line_number":72,"context_line":"        self._create_delete_share(2.1)"},{"line_number":73,"context_line":""},{"line_number":74,"context_line":"    @test.attr(type\u003d[\"gate\", ])"},{"line_number":75,"context_line":"    def test_create_delete_share_with_snapshot_support_feature(self):"},{"line_number":76,"context_line":"        self._create_delete_share(2.2)"},{"line_number":77,"context_line":""},{"line_number":78,"context_line":"    @test.attr(type\u003d[\"gate\", ])"}],"source_content_type":"text/x-python","patch_set":4,"id":"9a8ffd7b_d4da49e9","line":75,"in_reply_to":"ba8a016a_f744401c","updated":"2015-12-01 16:30:42.000000000","message":"Done","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"71ba533b590a228a423a3fcdfccc5c8d84bdc4d1","unresolved":false,"context_lines":[{"line_number":77,"context_line":""},{"line_number":78,"context_line":"    @test.attr(type\u003d[\"gate\", ])"},{"line_number":79,"context_line":"    def test_create_delete_share_with_replication_type(self):"},{"line_number":80,"context_line":"        self._create_delete_share(2.7)"},{"line_number":81,"context_line":""},{"line_number":82,"context_line":"    @test.attr(type\u003d[\"gate\", ])"},{"line_number":83,"context_line":"    @testtools.skipUnless(CONF.share.run_snapshot_tests,"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba8a016a_370968de","line":80,"updated":"2015-11-20 17:08:26.000000000","message":"no check for enabled api version.","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"e47967aed0fcad689a3aec42a79654a5b12a6c45","unresolved":false,"context_lines":[{"line_number":77,"context_line":""},{"line_number":78,"context_line":"    @test.attr(type\u003d[\"gate\", ])"},{"line_number":79,"context_line":"    def test_create_delete_share_with_replication_type(self):"},{"line_number":80,"context_line":"        self._create_delete_share(2.7)"},{"line_number":81,"context_line":""},{"line_number":82,"context_line":"    @test.attr(type\u003d[\"gate\", ])"},{"line_number":83,"context_line":"    @testtools.skipUnless(CONF.share.run_snapshot_tests,"}],"source_content_type":"text/x-python","patch_set":4,"id":"9a8ffd7b_f4d74dbd","line":80,"in_reply_to":"ba8a016a_370968de","updated":"2015-12-01 16:30:42.000000000","message":"Done","commit_id":"3ad07da0dcd9e371bf80c7a4282c75a6b69e68af"}],"manila_tempest_tests/tests/api/test_shares_actions.py":[{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":93,"context_line":"            expected_keys.extend(cg_keys)"},{"line_number":94,"context_line":"        if version \u003e 2.5:"},{"line_number":95,"context_line":"            expected_keys.append(\"share_type_name\")"},{"line_number":96,"context_line":"        if version \u003e 2.6:"},{"line_number":97,"context_line":"            expected_keys.append(\"replication\")"},{"line_number":98,"context_line":""},{"line_number":99,"context_line":"        actual_keys \u003d list(share.keys())"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_b39f89b3","line":96,"updated":"2015-11-13 20:26:31.000000000","message":"Same as before, I feel like these if statements should be:\n\n if version \u003e\u003d \u003cminimum_api_version\u003e:\n\nSo that it\u0027s clear which version is actually required for the API functionality in question.","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":93,"context_line":"            expected_keys.extend(cg_keys)"},{"line_number":94,"context_line":"        if version \u003e 2.5:"},{"line_number":95,"context_line":"            expected_keys.append(\"share_type_name\")"},{"line_number":96,"context_line":"        if version \u003e 2.6:"},{"line_number":97,"context_line":"            expected_keys.append(\"replication\")"},{"line_number":98,"context_line":""},{"line_number":99,"context_line":"        actual_keys \u003d list(share.keys())"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_c273674c","line":96,"in_reply_to":"da85f559_b39f89b3","updated":"2015-11-19 19:45:53.000000000","message":"The bane of fp equality comparisons as cited before :(","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":17780,"name":"Dustin Schoenbrun","email":"dschoenb@redhat.com","username":"dschoenb"},"change_message_id":"92cbc52b1e7ea51dfd5b2918f000c4337938fb7a","unresolved":false,"context_lines":[{"line_number":171,"context_line":"            keys.extend(cg_keys)"},{"line_number":172,"context_line":"        if version \u003e 2.5:"},{"line_number":173,"context_line":"            keys.append(\"share_type_name\")"},{"line_number":174,"context_line":"        if version \u003e 2.6:"},{"line_number":175,"context_line":"            keys.append(\"replication\")"},{"line_number":176,"context_line":""},{"line_number":177,"context_line":"        [self.assertIn(key, sh.keys()) for sh in shares for key in keys]"}],"source_content_type":"text/x-python","patch_set":2,"id":"da85f559_13af75e4","line":174,"updated":"2015-11-13 20:26:31.000000000","message":"Same as above.","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1375775aff71f24dfcb7494e76c2387e9000d772","unresolved":false,"context_lines":[{"line_number":171,"context_line":"            keys.extend(cg_keys)"},{"line_number":172,"context_line":"        if version \u003e 2.5:"},{"line_number":173,"context_line":"            keys.append(\"share_type_name\")"},{"line_number":174,"context_line":"        if version \u003e 2.6:"},{"line_number":175,"context_line":"            keys.append(\"replication\")"},{"line_number":176,"context_line":""},{"line_number":177,"context_line":"        [self.assertIn(key, sh.keys()) for sh in shares for key in keys]"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba8a016a_628f1b24","line":174,"in_reply_to":"da85f559_13af75e4","updated":"2015-11-19 19:45:53.000000000","message":"Done","commit_id":"48586a0a9ffc2d9c95bdd84de59993394c1d064e"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"d015a822e3a464fc20396e53ac428dd4588b9572","unresolved":false,"context_lines":[{"line_number":90,"context_line":"            expected_keys.append(\"snapshot_support\")"},{"line_number":91,"context_line":"        if version \u003e 2.3:"},{"line_number":92,"context_line":"            cg_keys \u003d [\"consistency_group_id\", \"source_cgsnapshot_member_id\"]"},{"line_number":93,"context_line":"            expected_keys.extend(cg_keys)"},{"line_number":94,"context_line":"        if version \u003e 2.5:"},{"line_number":95,"context_line":"            expected_keys.append(\"share_type_name\")"},{"line_number":96,"context_line":"        if version \u003e 2.7:"}],"source_content_type":"text/x-python","patch_set":9,"id":"7a740942_cfd5cb43","line":93,"updated":"2015-12-04 11:44:31.000000000","message":"\"cg_keys\" used only once, so could be provided directly as argument.","commit_id":"4ce0386bf01fc255bbf752978f09865992c4ec1f"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"b25160fd8aa84eb7b7e544cd1e4bf546811af9d4","unresolved":false,"context_lines":[{"line_number":90,"context_line":"            expected_keys.append(\"snapshot_support\")"},{"line_number":91,"context_line":"        if version \u003e 2.3:"},{"line_number":92,"context_line":"            cg_keys \u003d [\"consistency_group_id\", \"source_cgsnapshot_member_id\"]"},{"line_number":93,"context_line":"            expected_keys.extend(cg_keys)"},{"line_number":94,"context_line":"        if version \u003e 2.5:"},{"line_number":95,"context_line":"            expected_keys.append(\"share_type_name\")"},{"line_number":96,"context_line":"        if version \u003e 2.7:"}],"source_content_type":"text/x-python","patch_set":9,"id":"7a740942_9aa4e357","line":93,"in_reply_to":"7a740942_cfd5cb43","updated":"2015-12-04 18:42:01.000000000","message":"Done","commit_id":"4ce0386bf01fc255bbf752978f09865992c4ec1f"}]}
