)]}'
{"mistral/api/service.py":[{"author":{"_account_id":8731,"name":"Renat Akhmerov","email":"renat.akhmerov@gmail.com","username":"rakhmerov"},"change_message_id":"a4fd634065c065071f22f8a8e74cf430850c8994","unresolved":false,"context_lines":[{"line_number":35,"context_line":"            self.app,"},{"line_number":36,"context_line":"            host\u003dcfg.CONF.api.host,"},{"line_number":37,"context_line":"            port\u003dcfg.CONF.api.port,"},{"line_number":38,"context_line":"            use_ssl\u003duse_ssl"},{"line_number":39,"context_line":"        )"},{"line_number":40,"context_line":""},{"line_number":41,"context_line":"    def start(self):"}],"source_content_type":"text/x-python","patch_set":4,"id":"bacf61ea_896c4b36","line":38,"range":{"start_line":38,"start_character":20,"end_line":38,"end_character":27},"updated":"2016-08-01 04:40:06.000000000","message":"Not really a critical comment but I would suggest we don\u0027t pass use_ssl and instead look at the config property here because \u0027api_workers\u0027 property are accessed from this module too. In other words, I would prefer these two options are used from the same module.","commit_id":"579a820e48a93295f4f9829f0d23d5207fa3c0fd"}],"mistral/tests/unit/api/test_service.py":[{"author":{"_account_id":19206,"name":"Dawid Deja","email":"dawdej@gmail.com","username":"ddeja"},"change_message_id":"6738c3f28f9df747fd40401aa4752f3953dc66ae","unresolved":false,"context_lines":[{"line_number":49,"context_line":"    @mock.patch(\u0027mistral.api.app.setup_app\u0027)"},{"line_number":50,"context_line":"    @mock.patch.object(service.wsgi, \u0027Server\u0027)"},{"line_number":51,"context_line":"    def test_workers_set_correct_setting(self, wsgi_server, mock_app):"},{"line_number":52,"context_line":"        cfg.CONF.set_default(\u0027api_workers\u0027, 8, \u0027api\u0027)"},{"line_number":53,"context_line":""},{"line_number":54,"context_line":"        mock_app.return_value \u003d pecan.testing.load_test_app({"},{"line_number":55,"context_line":"            \u0027app\u0027: {"}],"source_content_type":"text/x-python","patch_set":5,"id":"bacf61ea_687d38b1","line":52,"range":{"start_line":52,"start_character":8,"end_line":52,"end_character":53},"updated":"2016-08-02 14:49:51.000000000","message":"You should mock the value in config instead of changing it. Changes of defaults are global, so if \u0027test_workers_set_correct_setting\u0027 and \u0027test_workers_set_zero_setting\u0027 changing of value can be nearly in the same time which would result in having wrong value in one of tests.\n\nYou should use safe override instead. Here\u0027s example commit from cinder that introduce and use such functionality: https://github.com/openstack/cinder/commit/e5d69cb68e7d46e7635b9a4218d603f07c50d409 or in mistral: https://github.com/openstack/mistral/blob/master/mistral/tests/unit/api/test_cors_middleware.py#L35-L39","commit_id":"04804ff76eda1ae05a9bb536957dfcbae7339321"}]}
