)]}'
{"etc/swift.conf-sample":[{"author":{"_account_id":7479,"name":"paul luse","email":"paul.e.luse@intel.com","username":"peluse"},"change_message_id":"d76d59f894b85cd8e8008c0b356796a500dec7b5","unresolved":false,"context_lines":[{"line_number":44,"context_line":"#  *         USE AT YOUR OWN RISK            *"},{"line_number":45,"context_line":"#  *******************************************"},{"line_number":46,"context_line":"#"},{"line_number":47,"context_line":"# If you\u0027ll need some new policies, don\u0027t modify the existing ones but"},{"line_number":48,"context_line":"# define a new one with some new policy index. The old policies MUST NOT be"},{"line_number":49,"context_line":"# reused."},{"line_number":50,"context_line":"#"}],"source_content_type":"application/octet-stream","patch_set":5,"id":"9ad9bd40_69d2465d","line":47,"updated":"2014-05-07 13:13:33.000000000","message":"I don\u0027t think this is the best placement of this comment, I\u0027d delete this one.  Until we introduce EC, commenting here on modifying policies can be confusing since, for example, we do allow modification of the name.  Once this patch is done/ready we can update the user docs with a more verbose description of the whole deprecation thing.","commit_id":"7d2457e529384d7b6e8ea046c7cb442f41b45faa"},{"author":{"_account_id":7479,"name":"paul luse","email":"paul.e.luse@intel.com","username":"peluse"},"change_message_id":"d76d59f894b85cd8e8008c0b356796a500dec7b5","unresolved":false,"context_lines":[{"line_number":52,"context_line":"#name \u003d turkey"},{"line_number":53,"context_line":"#default \u003d yes"},{"line_number":54,"context_line":"#"},{"line_number":55,"context_line":"# If you want to delete one policy please mark it as deprecated and"},{"line_number":56,"context_line":"# leave it there. policy 0 can not be deprecated."},{"line_number":57,"context_line":"#"},{"line_number":58,"context_line":"#[storage-policy:2]"}],"source_content_type":"application/octet-stream","patch_set":5,"id":"9ad9bd40_495022d4","line":55,"updated":"2014-05-07 13:13:33.000000000","message":"New suggested wording:  \"Policies cannot be deleted.  If a policy is no longer needed, it can be marked as deprecated as shown below.  Please see the documentation for complete details on implications of deprecating a policy.\"","commit_id":"7d2457e529384d7b6e8ea046c7cb442f41b45faa"}],"swift/common/storage_policy.py":[{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"b6c4a2df86d289492150c15a5f1522417386f05d","unresolved":false,"context_lines":[{"line_number":154,"context_line":"                    raise PolicyError(\u0027Policy 0 %s can not be deprecated\u0027 % ("},{"line_number":155,"context_line":"                        self.get_by_name(policy.name)))"},{"line_number":156,"context_line":"                else:"},{"line_number":157,"context_line":"                    continue"},{"line_number":158,"context_line":"            if policy.is_default:"},{"line_number":159,"context_line":"                if not self.default:"},{"line_number":160,"context_line":"                    self.default \u003d policy"}],"source_content_type":"text/x-python","patch_set":4,"id":"9ad9bd40_bdf1f102","line":157,"updated":"2014-05-07 01:00:29.000000000","message":"I think you want to go ahead and add it to POLICIES collection don\u0027t you?  Do backend services ever need to lookup a policy by index?  Like maybe to find out what type it used to be?","commit_id":"f74d97d1766a0d05802844d9074652104b557f24"},{"author":{"_account_id":7479,"name":"paul luse","email":"paul.e.luse@intel.com","username":"peluse"},"change_message_id":"d76d59f894b85cd8e8008c0b356796a500dec7b5","unresolved":false,"context_lines":[{"line_number":158,"context_line":"                        self.get_by_name(policy.name)))"},{"line_number":159,"context_line":"                else:"},{"line_number":160,"context_line":"                # Deprecating the default policy with non-zero index, this will"},{"line_number":161,"context_line":"                # make policy-0 the default, usually this shouldn\u0027t happen"},{"line_number":162,"context_line":"                    if policy.is_default:"},{"line_number":163,"context_line":"                        policy.is_default \u003d False"},{"line_number":164,"context_line":"            if policy.is_default:"}],"source_content_type":"text/x-python","patch_set":5,"id":"9ad9bd40_491582e3","line":161,"updated":"2014-05-07 13:13:33.000000000","message":"just a suggestion, I\u0027d remove the \"usually this shouldn\u0027t happen\" as it doesn\u0027t really serve any purpose and the action is of deprecating the default is indeed legal","commit_id":"7d2457e529384d7b6e8ea046c7cb442f41b45faa"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"850b126911e7885efd909cb5df291488877fe216","unresolved":false,"context_lines":[{"line_number":160,"context_line":"                # Deprecating the default policy with non-zero index, this will"},{"line_number":161,"context_line":"                # make policy-0 the default"},{"line_number":162,"context_line":"                    if policy.is_default:"},{"line_number":163,"context_line":"                        policy.is_default \u003d False"},{"line_number":164,"context_line":"            if policy.is_default:"},{"line_number":165,"context_line":"                if not self.default:"},{"line_number":166,"context_line":"                    self.default \u003d policy"}],"source_content_type":"text/x-python","patch_set":6,"id":"7adec928_2c3ff826","line":163,"updated":"2014-05-08 18:28:04.000000000","message":"I think this is leaky, the not is_default \u0026\u0026 is_deprecated should be handled when creating the StoragePolicy not the Collection.","commit_id":"26f983b9b682b04a53a0c26df1b15443c39da8d0"}],"swift/proxy/controllers/container.py":[{"author":{"_account_id":7479,"name":"paul luse","email":"paul.e.luse@intel.com","username":"peluse"},"change_message_id":"d76d59f894b85cd8e8008c0b356796a500dec7b5","unresolved":false,"context_lines":[{"line_number":121,"context_line":"        if error_response:"},{"line_number":122,"context_line":"            return error_response"},{"line_number":123,"context_line":"        policy_index \u003d self._convert_policy_to_index(req)"},{"line_number":124,"context_line":"        if POLICIES.get_by_index(policy_index).is_deprecated:"},{"line_number":125,"context_line":"            resp \u003d HTTPBadRequest(request\u003dreq)"},{"line_number":126,"context_line":"            resp.body \u003d \u0027Storage Policy %s is deprecated\u0027 % \\"},{"line_number":127,"context_line":"                        (POLICIES.get_by_index(policy_index).name)"}],"source_content_type":"text/x-python","patch_set":5,"id":"7adec928_1effed02","line":124,"updated":"2014-05-07 13:13:33.000000000","message":"wonder if we\u0027re better off putting this in _convert_policy_to_index as we\u0027ve got a check there already to make sure the index itself and then you\u0027d pick up POST as well","commit_id":"7d2457e529384d7b6e8ea046c7cb442f41b45faa"},{"author":{"_account_id":7479,"name":"paul luse","email":"paul.e.luse@intel.com","username":"peluse"},"change_message_id":"d76d59f894b85cd8e8008c0b356796a500dec7b5","unresolved":false,"context_lines":[{"line_number":169,"context_line":"        error_response \u003d \\"},{"line_number":170,"context_line":"            self.clean_acls(req) or check_metadata(req, \u0027container\u0027)"},{"line_number":171,"context_line":"        if error_response:"},{"line_number":172,"context_line":"            return error_response"},{"line_number":173,"context_line":"        policy_index \u003d self._convert_policy_to_index(req)"},{"line_number":174,"context_line":"        additional_headers \u003d {}"},{"line_number":175,"context_line":"        if policy_index is not None:"}],"source_content_type":"text/x-python","patch_set":5,"id":"7adec928_5e09752b","line":172,"updated":"2014-05-07 13:13:33.000000000","message":"deprecated check?  (or put check in _convert_policy_to_index)","commit_id":"7d2457e529384d7b6e8ea046c7cb442f41b45faa"}],"swift/proxy/controllers/obj.py":[{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"850b126911e7885efd909cb5df291488877fe216","unresolved":false,"context_lines":[{"line_number":467,"context_line":"            resp \u003d HTTPBadRequest(request\u003dreq)"},{"line_number":468,"context_line":"            resp.body \u003d \u0027Storage Policy %s is deprecated\u0027 % \\"},{"line_number":469,"context_line":"                        (POLICIES.get_by_index(policy_index).name)"},{"line_number":470,"context_line":"            return resp"},{"line_number":471,"context_line":"        obj_ring \u003d self.app.get_object_ring(policy_index)"},{"line_number":472,"context_line":"        # pass the policy index to storage nodes via req header"},{"line_number":473,"context_line":"        req.headers[POLICY_INDEX] \u003d policy_index"}],"source_content_type":"text/x-python","patch_set":6,"id":"7adec928_0cb6bcd9","line":470,"updated":"2014-05-08 18:28:04.000000000","message":"well, plus I don\u0027t think we can reject X-Backend-Storage-Policy-Index requests, deprecated or not the reconciler still needs to be able to deal with split brain.\n\nOh, also I don\u0027t know if it\u0027s a good idea to disable writes into existing containers - in general.","commit_id":"26f983b9b682b04a53a0c26df1b15443c39da8d0"}],"test/unit/common/test_storage_policies.py":[{"author":{"_account_id":7479,"name":"paul luse","email":"paul.e.luse@intel.com","username":"peluse"},"change_message_id":"d76d59f894b85cd8e8008c0b356796a500dec7b5","unresolved":false,"context_lines":[{"line_number":36,"context_line":"    @patch_policies([StoragePolicy(0, \u0027zero\u0027, True),"},{"line_number":37,"context_line":"                     StoragePolicy(1, \u0027one\u0027, False),"},{"line_number":38,"context_line":"                     StoragePolicy(2, \u0027two\u0027, False),"},{"line_number":39,"context_line":"                     StoragePolicy(3, \u0027three\u0027, False, is_deprecated\u003dTrue)])"},{"line_number":40,"context_line":"    def test_swift_info(self):"},{"line_number":41,"context_line":"        expect \u003d [{\u0027default\u0027: True, \u0027type\u0027: \u0027replication\u0027, \u0027name\u0027: \u0027zero\u0027},"},{"line_number":42,"context_line":"                  {\u0027type\u0027: \u0027replication\u0027, \u0027name\u0027: \u0027two\u0027},"}],"source_content_type":"text/x-python","patch_set":5,"id":"7adec928_9e769dd7","line":39,"updated":"2014-05-07 13:13:33.000000000","message":"where is \u0027three; used in the tests?","commit_id":"7d2457e529384d7b6e8ea046c7cb442f41b45faa"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"850b126911e7885efd909cb5df291488877fe216","unresolved":false,"context_lines":[{"line_number":126,"context_line":"        test_policies \u003d [StoragePolicy(0, \u0027zero\u0027, True, is_deprecated\u003dTrue),"},{"line_number":127,"context_line":"                         StoragePolicy(1, \u0027one\u0027, False),"},{"line_number":128,"context_line":"                         StoragePolicy(2, \u0027two\u0027, False)]"},{"line_number":129,"context_line":"        self.assertRaises(ValueError, StoragePolicyCollection, test_policies)"},{"line_number":130,"context_line":""},{"line_number":131,"context_line":"    def test_validate_policies_indexes(self):"},{"line_number":132,"context_line":"        # duplicate indexes"}],"source_content_type":"text/x-python","patch_set":6,"id":"7adec928_8c1d6cc0","line":129,"updated":"2014-05-08 18:28:04.000000000","message":"Is there an assertRaisesWithMessage in this module that you can use here?","commit_id":"26f983b9b682b04a53a0c26df1b15443c39da8d0"}],"test/unit/proxy/test_server.py":[{"author":{"_account_id":7479,"name":"paul luse","email":"paul.e.luse@intel.com","username":"peluse"},"change_message_id":"d76d59f894b85cd8e8008c0b356796a500dec7b5","unresolved":false,"context_lines":[{"line_number":4648,"context_line":""},{"line_number":4649,"context_line":"            # make sure both polcies are sent to the back w/correct indicies"},{"line_number":4650,"context_line":"            # while PUT with deprecated policy got HTTPBadRequest(400) error"},{"line_number":4651,"context_line":"            for func in (controller.PUT, controller.POST):"},{"line_number":4652,"context_line":"                for policy in POLICIES:"},{"line_number":4653,"context_line":"                    res \u003d test_policy_backend(policy.name, func)"},{"line_number":4654,"context_line":"                    if func \u003d\u003d controller.PUT and policy.is_deprecated:"}],"source_content_type":"text/x-python","patch_set":5,"id":"7adec928_21ff2803","line":4651,"updated":"2014-05-07 13:13:33.000000000","message":"so it looks like you purposely left out POST where I commented earlier....","commit_id":"7d2457e529384d7b6e8ea046c7cb442f41b45faa"}]}
