)]}'
{"neutron/server/__init__.py":[{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"5e1b8ee8c31eac10d952df7b8e9037c345dc9457","unresolved":false,"context_lines":[{"line_number":45,"context_line":"        except NotImplementedError:"},{"line_number":46,"context_line":"            LOG.info(_LI(\"RPC was already started in parent process by \""},{"line_number":47,"context_line":"                         \"plugin.\"))"},{"line_number":48,"context_line":"        launcher.wait()"},{"line_number":49,"context_line":"    except KeyboardInterrupt:"},{"line_number":50,"context_line":"        pass"},{"line_number":51,"context_line":"    except RuntimeError as e:"}],"source_content_type":"text/x-python","patch_set":28,"id":"9a41bdd9_0c3188ec","line":48,"updated":"2015-07-17 13:46:30.000000000","message":"So, the launcher variable on line 41 never has its wait() method called, since the launcher variable on line 44 shadows it. Is this intended?","commit_id":"ef5320c442ca01a2d4cf493f9e935c150bfc607c"}],"neutron/service.py":[{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"71cff200c569b01b38df1999ea2cc7c3187936e0","unresolved":false,"context_lines":[{"line_number":59,"context_line":""},{"line_number":60,"context_line":"# Instances of ServiceLauncher and ProcessLauncher used to start api and rpc"},{"line_number":61,"context_line":"# workers."},{"line_number":62,"context_line":"SERVICE_LAUNCHER \u003d common_service.ServiceLauncher()"},{"line_number":63,"context_line":"PROCESS_LAUNCHER \u003d common_service.ProcessLauncher(wait_interval\u003d1.0)"},{"line_number":64,"context_line":""},{"line_number":65,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"7a016987_d4d2a8d0","line":62,"updated":"2015-05-29 13:49:52.000000000","message":"If you put it in global for the module, any import would result in lots of side-effects, like eventlet backdoor opening attempt, or pipe creation, or signal handler reset. And I suspect if e.g. backdoor port is not available, the whole import would blow.\n\nI prefer it when a simple import does not execute a bunch of irrelevant code. Can you think of a way to avoid it?","commit_id":"75038be49919f59613f83d622869e80d14437cc6"},{"author":{"_account_id":7293,"name":"Elena Ezhova","email":"ezhovaelena19@gmail.com","username":"elena"},"change_message_id":"13acd31081dddd4436b4060f8c05927793df3147","unresolved":false,"context_lines":[{"line_number":59,"context_line":""},{"line_number":60,"context_line":"# Instances of ServiceLauncher and ProcessLauncher used to start api and rpc"},{"line_number":61,"context_line":"# workers."},{"line_number":62,"context_line":"SERVICE_LAUNCHER \u003d common_service.ServiceLauncher()"},{"line_number":63,"context_line":"PROCESS_LAUNCHER \u003d common_service.ProcessLauncher(wait_interval\u003d1.0)"},{"line_number":64,"context_line":""},{"line_number":65,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"7a016987_a4e817b4","line":62,"in_reply_to":"7a016987_2499c779","updated":"2015-05-29 14:45:36.000000000","message":"Oh, thank you for a suggestion","commit_id":"75038be49919f59613f83d622869e80d14437cc6"},{"author":{"_account_id":7293,"name":"Elena Ezhova","email":"ezhovaelena19@gmail.com","username":"elena"},"change_message_id":"49f75afea8b74a52c4882a9a136ec1b3750399d3","unresolved":false,"context_lines":[{"line_number":59,"context_line":""},{"line_number":60,"context_line":"# Instances of ServiceLauncher and ProcessLauncher used to start api and rpc"},{"line_number":61,"context_line":"# workers."},{"line_number":62,"context_line":"SERVICE_LAUNCHER \u003d common_service.ServiceLauncher()"},{"line_number":63,"context_line":"PROCESS_LAUNCHER \u003d common_service.ProcessLauncher(wait_interval\u003d1.0)"},{"line_number":64,"context_line":""},{"line_number":65,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"7a016987_b2ea72d6","line":62,"in_reply_to":"7a016987_a4e817b4","updated":"2015-06-01 08:45:56.000000000","message":"Done","commit_id":"75038be49919f59613f83d622869e80d14437cc6"},{"author":{"_account_id":7293,"name":"Elena Ezhova","email":"ezhovaelena19@gmail.com","username":"elena"},"change_message_id":"6d863766bae5674a540d858f6ca0ccb17fa1effe","unresolved":false,"context_lines":[{"line_number":59,"context_line":""},{"line_number":60,"context_line":"# Instances of ServiceLauncher and ProcessLauncher used to start api and rpc"},{"line_number":61,"context_line":"# workers."},{"line_number":62,"context_line":"SERVICE_LAUNCHER \u003d common_service.ServiceLauncher()"},{"line_number":63,"context_line":"PROCESS_LAUNCHER \u003d common_service.ProcessLauncher(wait_interval\u003d1.0)"},{"line_number":64,"context_line":""},{"line_number":65,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"7a016987_e4316fa3","line":62,"in_reply_to":"7a016987_d4d2a8d0","updated":"2015-05-29 14:39:12.000000000","message":"I understand your concern and I would\u0027ve also preferred something better, but I\u0027m not sure I can come up with any good way to avoid it right now.\n\nI\u0027ve experimented with inheriting  wsgi and rpc services from a single base class so that service and process launchers can be class attributes instead of global variables, but it turned out to be really ugly. \n\nBut I\u0027ll try to think of something better.","commit_id":"75038be49919f59613f83d622869e80d14437cc6"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"c6a27366fbaf0fb082f0ce765fc7a33e3bb7b28e","unresolved":false,"context_lines":[{"line_number":59,"context_line":""},{"line_number":60,"context_line":"# Instances of ServiceLauncher and ProcessLauncher used to start api and rpc"},{"line_number":61,"context_line":"# workers."},{"line_number":62,"context_line":"SERVICE_LAUNCHER \u003d common_service.ServiceLauncher()"},{"line_number":63,"context_line":"PROCESS_LAUNCHER \u003d common_service.ProcessLauncher(wait_interval\u003d1.0)"},{"line_number":64,"context_line":""},{"line_number":65,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"7a016987_2499c779","line":62,"in_reply_to":"7a016987_e4316fa3","updated":"2015-05-29 14:43:05.000000000","message":"You can always make a function that initializes a global variable once and then just returns it if it\u0027s already initialized (not None?). Then use the function to access your launchers.","commit_id":"75038be49919f59613f83d622869e80d14437cc6"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"71cff200c569b01b38df1999ea2cc7c3187936e0","unresolved":false,"context_lines":[{"line_number":96,"context_line":"        # Log the options used when starting if we\u0027re in debug mode..."},{"line_number":97,"context_line":""},{"line_number":98,"context_line":"        config.setup_logging()"},{"line_number":99,"context_line":"        # Dump the initial option values"},{"line_number":100,"context_line":"        cfg.CONF.log_opt_values(LOG, std_logging.DEBUG)"},{"line_number":101,"context_line":"        service \u003d cls(app_name)"},{"line_number":102,"context_line":"        return service"}],"source_content_type":"text/x-python","patch_set":16,"id":"7a016987_2fd4051e","line":99,"updated":"2015-05-29 13:49:52.000000000","message":"Now that we switched to ServiceLauncher, do we need to log options here? It seems the new parent does it for us (I see duplicate logs in the server log).\n\nNote that this may be fixed in a separate patch, no need to update the review just for that.","commit_id":"75038be49919f59613f83d622869e80d14437cc6"},{"author":{"_account_id":7293,"name":"Elena Ezhova","email":"ezhovaelena19@gmail.com","username":"elena"},"change_message_id":"0bc3a20ef71e4b408082725bb7d79239aa08986e","unresolved":false,"context_lines":[{"line_number":96,"context_line":"        # Log the options used when starting if we\u0027re in debug mode..."},{"line_number":97,"context_line":""},{"line_number":98,"context_line":"        config.setup_logging()"},{"line_number":99,"context_line":"        # Dump the initial option values"},{"line_number":100,"context_line":"        cfg.CONF.log_opt_values(LOG, std_logging.DEBUG)"},{"line_number":101,"context_line":"        service \u003d cls(app_name)"},{"line_number":102,"context_line":"        return service"}],"source_content_type":"text/x-python","patch_set":16,"id":"7a016987_a4b137e2","line":99,"in_reply_to":"7a016987_2fd4051e","updated":"2015-05-29 14:44:17.000000000","message":"That\u0027s a good catch, thank you","commit_id":"75038be49919f59613f83d622869e80d14437cc6"},{"author":{"_account_id":7293,"name":"Elena Ezhova","email":"ezhovaelena19@gmail.com","username":"elena"},"change_message_id":"49f75afea8b74a52c4882a9a136ec1b3750399d3","unresolved":false,"context_lines":[{"line_number":96,"context_line":"        # Log the options used when starting if we\u0027re in debug mode..."},{"line_number":97,"context_line":""},{"line_number":98,"context_line":"        config.setup_logging()"},{"line_number":99,"context_line":"        # Dump the initial option values"},{"line_number":100,"context_line":"        cfg.CONF.log_opt_values(LOG, std_logging.DEBUG)"},{"line_number":101,"context_line":"        service \u003d cls(app_name)"},{"line_number":102,"context_line":"        return service"}],"source_content_type":"text/x-python","patch_set":16,"id":"7a016987_12d14623","line":99,"in_reply_to":"7a016987_a4b137e2","updated":"2015-06-01 08:45:56.000000000","message":"Done","commit_id":"75038be49919f59613f83d622869e80d14437cc6"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"fefcfccc97b54b95a4ceb1ee029872abffc80df9","unresolved":false,"context_lines":[{"line_number":59,"context_line":""},{"line_number":60,"context_line":""},{"line_number":61,"context_line":"# Instances of ServiceLauncher and ProcessLauncher used to start api and rpc"},{"line_number":62,"context_line":"# workers."},{"line_number":63,"context_line":"SERVICE_LAUNCHER \u003d None"},{"line_number":64,"context_line":"PROCESS_LAUNCHER \u003d None"},{"line_number":65,"context_line":""}],"source_content_type":"text/x-python","patch_set":18,"id":"7a016987_b34cb19e","line":62,"updated":"2015-06-01 12:33:32.000000000","message":"You could usefully add a note that we use global objects since those classes are not supposed to be spawned multiple times, as per [reference-to-oslo-doc].","commit_id":"97bca980d7539281809f41c1d5fc6fb49cf3ad21"},{"author":{"_account_id":7293,"name":"Elena Ezhova","email":"ezhovaelena19@gmail.com","username":"elena"},"change_message_id":"6c7f858654612c9c327214bdafa314c9e9bc1c0f","unresolved":false,"context_lines":[{"line_number":59,"context_line":""},{"line_number":60,"context_line":""},{"line_number":61,"context_line":"# Instances of ServiceLauncher and ProcessLauncher used to start api and rpc"},{"line_number":62,"context_line":"# workers."},{"line_number":63,"context_line":"SERVICE_LAUNCHER \u003d None"},{"line_number":64,"context_line":"PROCESS_LAUNCHER \u003d None"},{"line_number":65,"context_line":""}],"source_content_type":"text/x-python","patch_set":18,"id":"7a016987_29ea90db","line":62,"in_reply_to":"7a016987_96bbe3c3","updated":"2015-06-01 13:07:10.000000000","message":"Though a bug report [1] is the only reference I can provide for now. This part of oslo.service is poorly documented yet\n\n[1] https://bugs.launchpad.net/oslo-incubator/+bug/1447965","commit_id":"97bca980d7539281809f41c1d5fc6fb49cf3ad21"},{"author":{"_account_id":7293,"name":"Elena Ezhova","email":"ezhovaelena19@gmail.com","username":"elena"},"change_message_id":"4a66fe876d3e35ab3fd6de0224d3e67ee7873a37","unresolved":false,"context_lines":[{"line_number":59,"context_line":""},{"line_number":60,"context_line":""},{"line_number":61,"context_line":"# Instances of ServiceLauncher and ProcessLauncher used to start api and rpc"},{"line_number":62,"context_line":"# workers."},{"line_number":63,"context_line":"SERVICE_LAUNCHER \u003d None"},{"line_number":64,"context_line":"PROCESS_LAUNCHER \u003d None"},{"line_number":65,"context_line":""}],"source_content_type":"text/x-python","patch_set":18,"id":"7a016987_96bbe3c3","line":62,"in_reply_to":"7a016987_b34cb19e","updated":"2015-06-01 12:44:06.000000000","message":"Sure, I\u0027ll add a note in a next PS","commit_id":"97bca980d7539281809f41c1d5fc6fb49cf3ad21"},{"author":{"_account_id":7787,"name":"Kevin Benton","email":"kevin@benton.pub","username":"blak111"},"change_message_id":"d946400349f6450c2b5719d7a42b9c40e5ce77b3","unresolved":false,"context_lines":[{"line_number":90,"context_line":"        # Log the options used when starting if we\u0027re in debug mode..."},{"line_number":91,"context_line":""},{"line_number":92,"context_line":"        config.setup_logging()"},{"line_number":93,"context_line":"        # Dump the initial option values"},{"line_number":94,"context_line":"        cfg.CONF.log_opt_values(LOG, std_logging.DEBUG)"},{"line_number":95,"context_line":"        service \u003d cls(app_name)"},{"line_number":96,"context_line":"        return service"}],"source_content_type":"text/x-python","patch_set":27,"id":"ba3cc151_2ec24d34","side":"PARENT","line":93,"updated":"2015-06-29 23:18:43.000000000","message":"why is this being removed?","commit_id":"6fe424bfffb82fd90aa386b1fe689995b9a9da21"},{"author":{"_account_id":7293,"name":"Elena Ezhova","email":"ezhovaelena19@gmail.com","username":"elena"},"change_message_id":"c1245c147055467ab66d31be7c45b3ddd805e60b","unresolved":false,"context_lines":[{"line_number":90,"context_line":"        # Log the options used when starting if we\u0027re in debug mode..."},{"line_number":91,"context_line":""},{"line_number":92,"context_line":"        config.setup_logging()"},{"line_number":93,"context_line":"        # Dump the initial option values"},{"line_number":94,"context_line":"        cfg.CONF.log_opt_values(LOG, std_logging.DEBUG)"},{"line_number":95,"context_line":"        service \u003d cls(app_name)"},{"line_number":96,"context_line":"        return service"}],"source_content_type":"text/x-python","patch_set":27,"id":"ba3cc151_535f1be5","side":"PARENT","line":93,"in_reply_to":"ba3cc151_2ec24d34","updated":"2015-06-30 13:58:03.000000000","message":"Because options are being logged in oslo.service code (https://github.com/openstack/oslo.service/blob/master/oslo_service/service.py#L230), so this was removed to avoid them being logged twice.","commit_id":"6fe424bfffb82fd90aa386b1fe689995b9a9da21"},{"author":{"_account_id":7787,"name":"Kevin Benton","email":"kevin@benton.pub","username":"blak111"},"change_message_id":"d946400349f6450c2b5719d7a42b9c40e5ce77b3","unresolved":false,"context_lines":[{"line_number":65,"context_line":"PROCESS_LAUNCHER \u003d None"},{"line_number":66,"context_line":""},{"line_number":67,"context_line":""},{"line_number":68,"context_line":"def get_service_launcher():"},{"line_number":69,"context_line":"    \"\"\"Returns an instance of ServiceLauncher.\"\"\""},{"line_number":70,"context_line":"    global SERVICE_LAUNCHER"},{"line_number":71,"context_line":"    if SERVICE_LAUNCHER is None:"}],"source_content_type":"text/x-python","patch_set":27,"id":"ba3cc151_0ec5093b","line":68,"updated":"2015-06-29 23:18:43.000000000","message":"do these need to be protected by a semaphore, or are we guarunteed to only have one caller?","commit_id":"97653ee6ea6956b0cb93ef5424ea9a6b5e55adb0"},{"author":{"_account_id":7293,"name":"Elena Ezhova","email":"ezhovaelena19@gmail.com","username":"elena"},"change_message_id":"c1245c147055467ab66d31be7c45b3ddd805e60b","unresolved":false,"context_lines":[{"line_number":65,"context_line":"PROCESS_LAUNCHER \u003d None"},{"line_number":66,"context_line":""},{"line_number":67,"context_line":""},{"line_number":68,"context_line":"def get_service_launcher():"},{"line_number":69,"context_line":"    \"\"\"Returns an instance of ServiceLauncher.\"\"\""},{"line_number":70,"context_line":"    global SERVICE_LAUNCHER"},{"line_number":71,"context_line":"    if SERVICE_LAUNCHER is None:"}],"source_content_type":"text/x-python","patch_set":27,"id":"ba3cc151_b3c0e72b","line":68,"in_reply_to":"ba3cc151_0ec5093b","updated":"2015-06-30 13:58:03.000000000","message":"These are called only for starting wsgi and rpc services which are started consequently (see neutron/server/__init__). So I guess that a semaphore is not required here.","commit_id":"97653ee6ea6956b0cb93ef5424ea9a6b5e55adb0"}],"neutron/tests/functional/test_server.py":[{"author":{"_account_id":4395,"name":"Aaron Rosen","email":"aaronorosen@gmail.com","username":"arosen"},"change_message_id":"bf630e089acbc708693975fee7bf1f7fc8ae6057","unresolved":false,"context_lines":[{"line_number":86,"context_line":"            return workers"},{"line_number":87,"context_line":""},{"line_number":88,"context_line":"        # Wait for a service to start."},{"line_number":89,"context_line":"        time.sleep(5)"},{"line_number":90,"context_line":""},{"line_number":91,"context_line":"        return [self.service_pid]"},{"line_number":92,"context_line":""}],"source_content_type":"text/x-python","patch_set":13,"id":"7ad32947_21b497f0","line":89,"updated":"2015-04-28 03:51:16.000000000","message":"why wasn\u0027t this needed before or more so why was is this added?","commit_id":"b4671394a2820395a5517285aeeeb8507c2c3ae1"},{"author":{"_account_id":7293,"name":"Elena Ezhova","email":"ezhovaelena19@gmail.com","username":"elena"},"change_message_id":"38bafba1cba158cf0b7d4e13b0fa4513f3b8b2e6","unresolved":false,"context_lines":[{"line_number":86,"context_line":"            return workers"},{"line_number":87,"context_line":""},{"line_number":88,"context_line":"        # Wait for a service to start."},{"line_number":89,"context_line":"        time.sleep(5)"},{"line_number":90,"context_line":""},{"line_number":91,"context_line":"        return [self.service_pid]"},{"line_number":92,"context_line":""}],"source_content_type":"text/x-python","patch_set":13,"id":"7ad32947_5dcad3a2","line":89,"in_reply_to":"7ad32947_21b497f0","updated":"2015-04-28 09:09:44.000000000","message":"It wasn\u0027t added in the previous patch because it didn\u0027t test single process case, when there are no worker processes. In that case, waiting for workers to spawn in enough.\n\nWhen I added tests for single process mode, it turned out that it is required to wait for a service to start, so I added this sleep.","commit_id":"b4671394a2820395a5517285aeeeb8507c2c3ae1"},{"author":{"_account_id":7293,"name":"Elena Ezhova","email":"ezhovaelena19@gmail.com","username":"elena"},"change_message_id":"faffc95385d7840647eff287563585f6ca207bcd","unresolved":false,"context_lines":[{"line_number":86,"context_line":"            return workers"},{"line_number":87,"context_line":""},{"line_number":88,"context_line":"        # Wait for a service to start."},{"line_number":89,"context_line":"        time.sleep(5)"},{"line_number":90,"context_line":""},{"line_number":91,"context_line":"        return [self.service_pid]"},{"line_number":92,"context_line":""}],"source_content_type":"text/x-python","patch_set":13,"id":"9a0c5dc1_883ee1b6","line":89,"in_reply_to":"7ad32947_5dcad3a2","updated":"2015-05-12 12:35:21.000000000","message":"@Aaron, I moved this line to the previous patch where it belongs better","commit_id":"b4671394a2820395a5517285aeeeb8507c2c3ae1"},{"author":{"_account_id":7787,"name":"Kevin Benton","email":"kevin@benton.pub","username":"blak111"},"change_message_id":"d946400349f6450c2b5719d7a42b9c40e5ce77b3","unresolved":false,"context_lines":[{"line_number":229,"context_line":"        # Read port number from a pipe"},{"line_number":230,"context_line":"        port \u003d int(os.read(self.pipein, 5))"},{"line_number":231,"context_line":"        sock \u003d socket.socket(socket.AF_INET, socket.SOCK_STREAM)"},{"line_number":232,"context_line":"        result \u003d sock.connect_ex((\u0027127.0.0.1\u0027, port))"},{"line_number":233,"context_line":""},{"line_number":234,"context_line":"        return result !\u003d 0"},{"line_number":235,"context_line":""}],"source_content_type":"text/x-python","patch_set":27,"id":"ba3cc151_cedde115","line":232,"updated":"2015-06-29 23:18:43.000000000","message":"do we have to worry about the service only running on IPv6 here? or is this only to work with the fake_start below?","commit_id":"97653ee6ea6956b0cb93ef5424ea9a6b5e55adb0"},{"author":{"_account_id":7293,"name":"Elena Ezhova","email":"ezhovaelena19@gmail.com","username":"elena"},"change_message_id":"c1245c147055467ab66d31be7c45b3ddd805e60b","unresolved":false,"context_lines":[{"line_number":229,"context_line":"        # Read port number from a pipe"},{"line_number":230,"context_line":"        port \u003d int(os.read(self.pipein, 5))"},{"line_number":231,"context_line":"        sock \u003d socket.socket(socket.AF_INET, socket.SOCK_STREAM)"},{"line_number":232,"context_line":"        result \u003d sock.connect_ex((\u0027127.0.0.1\u0027, port))"},{"line_number":233,"context_line":""},{"line_number":234,"context_line":"        return result !\u003d 0"},{"line_number":235,"context_line":""}],"source_content_type":"text/x-python","patch_set":27,"id":"ba3cc151_f33bcf36","line":232,"in_reply_to":"ba3cc151_cedde115","updated":"2015-06-30 13:58:03.000000000","message":"You are correct, it is needed only for testing a fake rpc service","commit_id":"97653ee6ea6956b0cb93ef5424ea9a6b5e55adb0"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"5e1b8ee8c31eac10d952df7b8e9037c345dc9457","unresolved":false,"context_lines":[{"line_number":222,"context_line":"        self.health_checker \u003d self._check_active"},{"line_number":223,"context_line":""},{"line_number":224,"context_line":"    def _check_active(self):"},{"line_number":225,"context_line":"        time.sleep(5)"},{"line_number":226,"context_line":"        return True"},{"line_number":227,"context_line":""},{"line_number":228,"context_line":"    def _serve_rpc(self, workers\u003d0):"}],"source_content_type":"text/x-python","patch_set":28,"id":"9a41bdd9_2cf9ecc8","side":"PARENT","line":225,"updated":"2015-07-17 13:46:30.000000000","message":"LOL. Interesting. :)","commit_id":"49774afdc111d65cd8c9e73c1c1dee04d9c9f1a8"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"5e1b8ee8c31eac10d952df7b8e9037c345dc9457","unresolved":false,"context_lines":[{"line_number":254,"context_line":"            ) as get_plugin:"},{"line_number":255,"context_line":"                if workers \u003d\u003d 0:"},{"line_number":256,"context_line":"                    self.plugin.start_rpc_listeners \u003d ("},{"line_number":257,"context_line":"                        self._fake_start_rpc_listeners)"},{"line_number":258,"context_line":"                reset_method.side_effect \u003d self._fake_reset"},{"line_number":259,"context_line":"                get_plugin.return_value \u003d self.plugin"},{"line_number":260,"context_line":""}],"source_content_type":"text/x-python","patch_set":28,"id":"9a41bdd9_4cff9034","line":257,"updated":"2015-07-17 13:46:30.000000000","message":"Instead of adding this conditional, you could just set self.plugin.return_value.start_rpc_listeners \u003d self._fake_start_rpc_listeners in the setUp() method, where the plugin mock is created...","commit_id":"ef5320c442ca01a2d4cf493f9e935c150bfc607c"},{"author":{"_account_id":7293,"name":"Elena Ezhova","email":"ezhovaelena19@gmail.com","username":"elena"},"change_message_id":"587ff9242c987ab4548169e3739c8d302edbef54","unresolved":false,"context_lines":[{"line_number":254,"context_line":"            ) as get_plugin:"},{"line_number":255,"context_line":"                if workers \u003d\u003d 0:"},{"line_number":256,"context_line":"                    self.plugin.start_rpc_listeners \u003d ("},{"line_number":257,"context_line":"                        self._fake_start_rpc_listeners)"},{"line_number":258,"context_line":"                reset_method.side_effect \u003d self._fake_reset"},{"line_number":259,"context_line":"                get_plugin.return_value \u003d self.plugin"},{"line_number":260,"context_line":""}],"source_content_type":"text/x-python","patch_set":28,"id":"1a4dcd0f_d17e9418","line":257,"in_reply_to":"9a41bdd9_4cff9034","updated":"2015-08-06 07:51:03.000000000","message":"self.plugin.return_value.start_rpc_listeners should be set only in case we have 0 workers so that we can check that our fake rpc is running. There is no need to override it when we have several workers, because it is enough to check that children processes have spawned.","commit_id":"ef5320c442ca01a2d4cf493f9e935c150bfc607c"}],"neutron/wsgi.py":[{"author":{"_account_id":7787,"name":"Kevin Benton","email":"kevin@benton.pub","username":"blak111"},"change_message_id":"d946400349f6450c2b5719d7a42b9c40e5ce77b3","unresolved":false,"context_lines":[{"line_number":251,"context_line":"            # The API service runs in a number of child processes."},{"line_number":252,"context_line":"            # Minimize the cost of checking for child exit by extending the"},{"line_number":253,"context_line":"            # wait interval past the default of 0.01s."},{"line_number":254,"context_line":"            if not self.process_launcher:"},{"line_number":255,"context_line":"                self.process_launcher \u003d common_service.ProcessLauncher("},{"line_number":256,"context_line":"                    wait_interval\u003d1.0)"},{"line_number":257,"context_line":"            self._server \u003d self.process_launcher"}],"source_content_type":"text/x-python","patch_set":27,"id":"ba3cc151_eee225d5","line":254,"updated":"2015-06-29 23:18:43.000000000","message":"why not have the logic to setup the launchers in the init method? do they have side effects?","commit_id":"97653ee6ea6956b0cb93ef5424ea9a6b5e55adb0"},{"author":{"_account_id":7293,"name":"Elena Ezhova","email":"ezhovaelena19@gmail.com","username":"elena"},"change_message_id":"c1245c147055467ab66d31be7c45b3ddd805e60b","unresolved":false,"context_lines":[{"line_number":251,"context_line":"            # The API service runs in a number of child processes."},{"line_number":252,"context_line":"            # Minimize the cost of checking for child exit by extending the"},{"line_number":253,"context_line":"            # wait interval past the default of 0.01s."},{"line_number":254,"context_line":"            if not self.process_launcher:"},{"line_number":255,"context_line":"                self.process_launcher \u003d common_service.ProcessLauncher("},{"line_number":256,"context_line":"                    wait_interval\u003d1.0)"},{"line_number":257,"context_line":"            self._server \u003d self.process_launcher"}],"source_content_type":"text/x-python","patch_set":27,"id":"ba3cc151_9394c3e2","line":254,"in_reply_to":"ba3cc151_eee225d5","updated":"2015-06-30 13:58:03.000000000","message":"This way we can avoid initializing an unneeded launcher unnecessary. Except that there were no other reasons","commit_id":"97653ee6ea6956b0cb93ef5424ea9a6b5e55adb0"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"5e1b8ee8c31eac10d952df7b8e9037c345dc9457","unresolved":false,"context_lines":[{"line_number":241,"context_line":"            # The API service should run in the current process."},{"line_number":242,"context_line":"            if not self.service_launcher:"},{"line_number":243,"context_line":"                self.service_launcher \u003d common_service.ServiceLauncher("},{"line_number":244,"context_line":"                    cfg.CONF)"},{"line_number":245,"context_line":"            self._server \u003d self.service_launcher"},{"line_number":246,"context_line":"            self._server.launch_service(service)"},{"line_number":247,"context_line":"        else:"}],"source_content_type":"text/x-python","patch_set":28,"id":"9a41bdd9_0ca74850","line":244,"updated":"2015-07-17 13:46:30.000000000","message":"This block of code from 242-244 should go in __init__() instead of being hidden down here, since it is initialization logic.","commit_id":"ef5320c442ca01a2d4cf493f9e935c150bfc607c"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"5e1b8ee8c31eac10d952df7b8e9037c345dc9457","unresolved":false,"context_lines":[{"line_number":254,"context_line":"            # wait interval past the default of 0.01s."},{"line_number":255,"context_line":"            if not self.process_launcher:"},{"line_number":256,"context_line":"                self.process_launcher \u003d common_service.ProcessLauncher("},{"line_number":257,"context_line":"                    cfg.CONF, wait_interval\u003d1.0)"},{"line_number":258,"context_line":"            self._server \u003d self.process_launcher"},{"line_number":259,"context_line":"            self._server.launch_service(service, workers\u003dworkers)"},{"line_number":260,"context_line":""}],"source_content_type":"text/x-python","patch_set":28,"id":"9a41bdd9_ac62dc14","line":257,"updated":"2015-07-17 13:46:30.000000000","message":"Ditto.","commit_id":"ef5320c442ca01a2d4cf493f9e935c150bfc607c"}]}
