)]}'
{"swift/proxy/controllers/container.py":[{"author":{"_account_id":6968,"name":"Christian Schwede","email":"cschwede@nvidia.com","username":"cschwede"},"change_message_id":"76893b2aa1d650fe8a6635b666460039306b9fb2","unresolved":false,"context_lines":[{"line_number":108,"context_line":"            resp \u003d HTTPBadRequest(request\u003dreq)"},{"line_number":109,"context_line":"            resp.body \u003d \u0027Container name length of %d longer than %d\u0027 % \\"},{"line_number":110,"context_line":"                        (len(self.container_name),"},{"line_number":111,"context_line":"                         constraints.MAX_CONTAINER_NAME_LENGTH)"},{"line_number":112,"context_line":"            return resp"},{"line_number":113,"context_line":"        account_partition, accounts, container_count \u003d \\"},{"line_number":114,"context_line":"            self.account_info(self.account_name, req)"}],"source_content_type":"text/x-python","patch_set":1,"id":"1ae5cdf2_7de2ef01","line":111,"updated":"2014-06-27 14:27:15.000000000","message":"You could avoid clearing the cache if not required if you just use this:\n\n if self.app.max_containers_per_account \u003e 0:\n     clear_info_cache(self.app, req.environ, self.account_name, self.container_name)","commit_id":"9ffd9935811eb4de3869aee1b2b5beb8f753a44f"},{"author":{"_account_id":6968,"name":"Christian Schwede","email":"cschwede@nvidia.com","username":"cschwede"},"change_message_id":"0a10069a4cbd4e3eab6354879fc2152a523e5348","unresolved":false,"context_lines":[{"line_number":108,"context_line":"            resp \u003d HTTPBadRequest(request\u003dreq)"},{"line_number":109,"context_line":"            resp.body \u003d \u0027Container name length of %d longer than %d\u0027 % \\"},{"line_number":110,"context_line":"                        (len(self.container_name),"},{"line_number":111,"context_line":"                         constraints.MAX_CONTAINER_NAME_LENGTH)"},{"line_number":112,"context_line":"            return resp"},{"line_number":113,"context_line":"        account_partition, accounts, container_count \u003d \\"},{"line_number":114,"context_line":"            self.account_info(self.account_name, req)"}],"source_content_type":"text/x-python","patch_set":1,"id":"1ae5cdf2_00833f56","line":111,"in_reply_to":"1ae5cdf2_7de2ef01","updated":"2014-06-27 16:58:35.000000000","message":"And while thinking more about this, it is required to clear the cache at this point because the other clear_info_cache calls might be executed on a different proxy, thus not clearing the env cache for the this proxy.","commit_id":"9ffd9935811eb4de3869aee1b2b5beb8f753a44f"},{"author":{"_account_id":6968,"name":"Christian Schwede","email":"cschwede@nvidia.com","username":"cschwede"},"change_message_id":"cf4c9fdd3d069669a49b93b78cbfa18b1f934f50","unresolved":false,"context_lines":[{"line_number":108,"context_line":"            resp \u003d HTTPBadRequest(request\u003dreq)"},{"line_number":109,"context_line":"            resp.body \u003d \u0027Container name length of %d longer than %d\u0027 % \\"},{"line_number":110,"context_line":"                        (len(self.container_name),"},{"line_number":111,"context_line":"                         constraints.MAX_CONTAINER_NAME_LENGTH)"},{"line_number":112,"context_line":"            return resp"},{"line_number":113,"context_line":"        account_partition, accounts, container_count \u003d \\"},{"line_number":114,"context_line":"            self.account_info(self.account_name, req)"}],"source_content_type":"text/x-python","patch_set":1,"id":"baada198_1083f856","line":111,"in_reply_to":"1ae5cdf2_7de2ef01","updated":"2014-07-10 16:10:53.000000000","message":"Oh you\u0027re right, of course I meant \n\n clear_info_cache(self.app, req.environ, self.account_name)\n\nhere","commit_id":"9ffd9935811eb4de3869aee1b2b5beb8f753a44f"},{"author":{"_account_id":6968,"name":"Christian Schwede","email":"cschwede@nvidia.com","username":"cschwede"},"change_message_id":"76893b2aa1d650fe8a6635b666460039306b9fb2","unresolved":false,"context_lines":[{"line_number":134,"context_line":"        resp \u003d self.make_requests("},{"line_number":135,"context_line":"            req, self.app.container_ring,"},{"line_number":136,"context_line":"            container_partition, \u0027PUT\u0027, req.swift_entity_path, headers)"},{"line_number":137,"context_line":"        clear_info_cache(self.app, req.environ, self.account_name)"},{"line_number":138,"context_line":"        return resp"},{"line_number":139,"context_line":""},{"line_number":140,"context_line":"    @public"}],"source_content_type":"text/x-python","patch_set":1,"id":"1ae5cdf2_1db1eb00","line":137,"updated":"2014-06-27 14:27:15.000000000","message":"No need to clear the cache if using the idea from above","commit_id":"9ffd9935811eb4de3869aee1b2b5beb8f753a44f"},{"author":{"_account_id":6968,"name":"Christian Schwede","email":"cschwede@nvidia.com","username":"cschwede"},"change_message_id":"76893b2aa1d650fe8a6635b666460039306b9fb2","unresolved":false,"context_lines":[{"line_number":160,"context_line":"        resp \u003d self.make_requests("},{"line_number":161,"context_line":"            req, self.app.container_ring, container_partition, \u0027POST\u0027,"},{"line_number":162,"context_line":"            req.swift_entity_path, [headers] * len(containers))"},{"line_number":163,"context_line":"        clear_info_cache(self.app, req.environ, self.account_name)"},{"line_number":164,"context_line":"        return resp"},{"line_number":165,"context_line":""},{"line_number":166,"context_line":"    @public"}],"source_content_type":"text/x-python","patch_set":1,"id":"1ae5cdf2_9dc41b61","line":163,"updated":"2014-06-27 14:27:15.000000000","message":"No need to clear the cache if using the idea from above","commit_id":"9ffd9935811eb4de3869aee1b2b5beb8f753a44f"},{"author":{"_account_id":6968,"name":"Christian Schwede","email":"cschwede@nvidia.com","username":"cschwede"},"change_message_id":"cf4c9fdd3d069669a49b93b78cbfa18b1f934f50","unresolved":false,"context_lines":[{"line_number":160,"context_line":"        resp \u003d self.make_requests("},{"line_number":161,"context_line":"            req, self.app.container_ring, container_partition, \u0027POST\u0027,"},{"line_number":162,"context_line":"            req.swift_entity_path, [headers] * len(containers))"},{"line_number":163,"context_line":"        clear_info_cache(self.app, req.environ, self.account_name)"},{"line_number":164,"context_line":"        return resp"},{"line_number":165,"context_line":""},{"line_number":166,"context_line":"    @public"}],"source_content_type":"text/x-python","patch_set":1,"id":"baada198_d0db4019","line":163,"in_reply_to":"1ae5cdf2_9dc41b61","updated":"2014-07-10 16:10:53.000000000","message":"So, after thinking more about this my comment is wrong, but I would make this conditional using something like\n\n if self.app.max_containers_per_account \u003e 0:\n        clear_info_cache(self.app, req.environ, self.account_name)","commit_id":"9ffd9935811eb4de3869aee1b2b5beb8f753a44f"},{"author":{"_account_id":6968,"name":"Christian Schwede","email":"cschwede@nvidia.com","username":"cschwede"},"change_message_id":"76893b2aa1d650fe8a6635b666460039306b9fb2","unresolved":false,"context_lines":[{"line_number":180,"context_line":"        resp \u003d self.make_requests("},{"line_number":181,"context_line":"            req, self.app.container_ring, container_partition, \u0027DELETE\u0027,"},{"line_number":182,"context_line":"            req.swift_entity_path, headers)"},{"line_number":183,"context_line":"        clear_info_cache(self.app, req.environ, self.account_name)"},{"line_number":184,"context_line":"        # Indicates no server had the container"},{"line_number":185,"context_line":"        if resp.status_int \u003d\u003d HTTP_ACCEPTED:"},{"line_number":186,"context_line":"            return HTTPNotFound(request\u003dreq)"}],"source_content_type":"text/x-python","patch_set":1,"id":"1ae5cdf2_dda143aa","line":183,"updated":"2014-06-27 14:27:15.000000000","message":"No need to clear the cache if using the idea from above","commit_id":"9ffd9935811eb4de3869aee1b2b5beb8f753a44f"},{"author":{"_account_id":7233,"name":"Matthew Oliver","email":"matt@oliver.net.au","username":"mattoliverau"},"change_message_id":"81adc973fcdf37b09674d08e2cff598aee74b2b2","unresolved":false,"context_lines":[{"line_number":180,"context_line":"        resp \u003d self.make_requests("},{"line_number":181,"context_line":"            req, self.app.container_ring, container_partition, \u0027DELETE\u0027,"},{"line_number":182,"context_line":"            req.swift_entity_path, headers)"},{"line_number":183,"context_line":"        clear_info_cache(self.app, req.environ, self.account_name)"},{"line_number":184,"context_line":"        # Indicates no server had the container"},{"line_number":185,"context_line":"        if resp.status_int \u003d\u003d HTTP_ACCEPTED:"},{"line_number":186,"context_line":"            return HTTPNotFound(request\u003dreq)"}],"source_content_type":"text/x-python","patch_set":1,"id":"dab895d6_1bc5365b","line":183,"in_reply_to":"1ae5cdf2_dda143aa","updated":"2014-06-30 00:35:24.000000000","message":"Clearing it on a delete (if self.app.max_containers_per_account \u003e 0) is a good idea to keep the counters all good. Although the next put should fix the cache. Still adding it here makes sense.","commit_id":"9ffd9935811eb4de3869aee1b2b5beb8f753a44f"},{"author":{"_account_id":6968,"name":"Christian Schwede","email":"cschwede@nvidia.com","username":"cschwede"},"change_message_id":"cf4c9fdd3d069669a49b93b78cbfa18b1f934f50","unresolved":false,"context_lines":[{"line_number":180,"context_line":"        resp \u003d self.make_requests("},{"line_number":181,"context_line":"            req, self.app.container_ring, container_partition, \u0027DELETE\u0027,"},{"line_number":182,"context_line":"            req.swift_entity_path, headers)"},{"line_number":183,"context_line":"        clear_info_cache(self.app, req.environ, self.account_name)"},{"line_number":184,"context_line":"        # Indicates no server had the container"},{"line_number":185,"context_line":"        if resp.status_int \u003d\u003d HTTP_ACCEPTED:"},{"line_number":186,"context_line":"            return HTTPNotFound(request\u003dreq)"}],"source_content_type":"text/x-python","patch_set":1,"id":"baada198_f0a84479","line":183,"in_reply_to":"dab895d6_1bc5365b","updated":"2014-07-10 16:10:53.000000000","message":"Yep, you\u0027re right! But I think using an if-condition makes sense here (see above comment)","commit_id":"9ffd9935811eb4de3869aee1b2b5beb8f753a44f"},{"author":{"_account_id":6968,"name":"Christian Schwede","email":"cschwede@nvidia.com","username":"cschwede"},"change_message_id":"fcaf8e5222e46069980cee3283e5c2ac48d9944d","unresolved":false,"context_lines":[{"line_number":139,"context_line":"            self.autocreate_account(req.environ, self.account_name)"},{"line_number":140,"context_line":"            account_partition, accounts, container_count \u003d \\"},{"line_number":141,"context_line":"                self.account_info(self.account_name, req)"},{"line_number":142,"context_line":"        if not accounts:"},{"line_number":143,"context_line":"            return HTTPNotFound(request\u003dreq)"},{"line_number":144,"context_line":"        if self.app.max_containers_per_account \u003e 0 and \\"},{"line_number":145,"context_line":"                container_count \u003e\u003d self.app.max_containers_per_account and \\"}],"source_content_type":"text/x-python","patch_set":2,"id":"baada198_17b02e42","line":142,"updated":"2014-07-11 09:43:47.000000000","message":"You need to clear the cache here, otherwise the request will suceed if another proxy using a different cache created a container in the meantime, not clearing the cache used for this proxy.","commit_id":"6cab53e970f0ed693f2d488ad1cedd36b1df39e4"}]}
