)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"11cc45a972e9c7e585a3a1ba12b2812aea257566","unresolved":false,"context_lines":[{"line_number":10,"context_line":"Add methods to get cert expiration date from PEM server_pem and update db"},{"line_number":11,"context_line":"Use the new REST agent method to perform cycling"},{"line_number":12,"context_line":"Add process to housekeeping to facilitate rotation"},{"line_number":13,"context_line":"WIP: need more unit test"},{"line_number":14,"context_line":""},{"line_number":15,"context_line":"This patch depends on the following 2 bugs:"},{"line_number":16,"context_line":"https://bugs.launchpad.net/octavia/+bug/1496634"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":15,"id":"ba15a1d1_856617eb","line":13,"updated":"2015-09-19 01:14:11.000000000","message":"Is this still WIP or is this done?","commit_id":"6e73ec826cab50571fc7f87856ff1e06830e8ce6"},{"author":{"_account_id":10850,"name":"German Eichberger","email":"german.eichberger@gmail.com","username":"german"},"change_message_id":"f6329ec06932eb247c64499834998a8f15729b65","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Add cert tracking and rotating in Housekeeping"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"The target of this patch is to add the function that once we detect an"},{"line_number":10,"context_line":"amphora\u0027s cert will expire in 2 weeks from utcnow, we will update its"},{"line_number":11,"context_line":"cert with a new one and update its db information at the same time."},{"line_number":12,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":34,"id":"fa80f949_5e03af42","line":9,"updated":"2015-11-05 00:29:45.000000000","message":"s/target/goal/r","commit_id":"31e78f127140339eacb753db3c4b3990f9f42537"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"9744c64cad25cc1596edaa98148f8f5ff7d9389f","unresolved":false,"context_lines":[{"line_number":7,"context_line":"Add cert tracking and rotating in Housekeeping"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"The target of this patch is to add the function that once we detect an"},{"line_number":10,"context_line":"amphora\u0027s cert will expire in 2 weeks from utcnow, we will update its"},{"line_number":11,"context_line":"cert with a new one and update its db information at the same time."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"In order to achieve this target, I did the following changes:"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":34,"id":"fa80f949_189de9bb","line":10,"updated":"2015-11-07 00:54:48.000000000","message":"s/2 weeks/a configurable period from utcnow/","commit_id":"31e78f127140339eacb753db3c4b3990f9f42537"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"9744c64cad25cc1596edaa98148f8f5ff7d9389f","unresolved":false,"context_lines":[{"line_number":19,"context_line":"Add process in housekeeping to facilitate rotation"},{"line_number":20,"context_line":"Add unit tests"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"This patch depends on the following 2 bugs:"},{"line_number":23,"context_line":"https://bugs.launchpad.net/octavia/+bug/1496634"},{"line_number":24,"context_line":"https://bugs.launchpad.net/octavia/+bug/1496628"},{"line_number":25,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":34,"id":"fa80f949_b3cdde86","line":22,"updated":"2015-11-07 00:54:48.000000000","message":"Does this patch really depend on these or are these nice to have?","commit_id":"31e78f127140339eacb753db3c4b3990f9f42537"}],"octavia/amphorae/drivers/driver_base.py":[{"author":{"_account_id":15226,"name":"Bharath M","email":"bharath.stacker@gmail.com","username":"bharath"},"change_message_id":"8de2638cf7903d66048d3adf757fb13117f5adc4","unresolved":false,"context_lines":[{"line_number":192,"context_line":"        :param pem_file: a certificate file"},{"line_number":193,"context_line":"        :type pem: pem file"},{"line_number":194,"context_line":""},{"line_number":195,"context_line":"        uplaod cert file to amphora for Controller Communication"},{"line_number":196,"context_line":"        \"\"\""},{"line_number":197,"context_line":"        pass"},{"line_number":198,"context_line":""}],"source_content_type":"text/x-python","patch_set":7,"id":"da20952f_e9eea1eb","line":195,"updated":"2015-08-27 08:23:54.000000000","message":"nit: typo \u0027upload\u0027","commit_id":"a0316b696a10d66dbb1dd68bb0c30ecabb317fd8"},{"author":{"_account_id":16054,"name":"Matsumoto Yoshihide","email":"matsumoto333@gmail.com","username":"matchan"},"change_message_id":"347b5f50fed91fba9c5848b534f28be7ff561258","unresolved":false,"context_lines":[{"line_number":194,"context_line":"        :param pem_file: a certificate file"},{"line_number":195,"context_line":"        :type pem: pem file"},{"line_number":196,"context_line":""},{"line_number":197,"context_line":"        uplaad cert file to amphora for Controller Communication"},{"line_number":198,"context_line":"        \"\"\""},{"line_number":199,"context_line":"        pass"},{"line_number":200,"context_line":""}],"source_content_type":"text/x-python","patch_set":13,"id":"ba15a1d1_e5b18148","line":197,"updated":"2015-09-16 14:14:40.000000000","message":"upload?","commit_id":"65bc0670b4ac31c2e100116844019d28f0f4a605"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"c56a08727d109c9d8fcf2a1c83dc3b4e0089fdf5","unresolved":false,"context_lines":[{"line_number":194,"context_line":"        :param pem_file: a certificate file"},{"line_number":195,"context_line":"        :type pem: pem file"},{"line_number":196,"context_line":""},{"line_number":197,"context_line":"        uplaad cert file to amphora for Controller Communication"},{"line_number":198,"context_line":"        \"\"\""},{"line_number":199,"context_line":"        pass"},{"line_number":200,"context_line":""}],"source_content_type":"text/x-python","patch_set":13,"id":"ba15a1d1_48b724f5","line":197,"in_reply_to":"ba15a1d1_e5b18148","updated":"2015-09-16 14:21:12.000000000","message":"yeah, typo, thanks!","commit_id":"65bc0670b4ac31c2e100116844019d28f0f4a605"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"11cc45a972e9c7e585a3a1ba12b2812aea257566","unresolved":false,"context_lines":[{"line_number":192,"context_line":"        :param amphora: amphora object, needs id and network ip(s)"},{"line_number":193,"context_line":"        :type amphora: object"},{"line_number":194,"context_line":"        :param pem_file: a certificate file"},{"line_number":195,"context_line":"        :type pem: pem file"},{"line_number":196,"context_line":""},{"line_number":197,"context_line":"        upload cert file to amphora for Controller Communication"},{"line_number":198,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":15,"id":"ba15a1d1_05ef671e","line":195,"updated":"2015-09-19 01:14:11.000000000","message":"This should be:\n:type pem_file: file object","commit_id":"6e73ec826cab50571fc7f87856ff1e06830e8ce6"}],"octavia/amphorae/drivers/haproxy/rest_api_driver.py":[{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"9d284d669f6af7caad24731b2773d6d183aa9f91","unresolved":false,"context_lines":[{"line_number":80,"context_line":"                    self.client.start_listener(amp, listener.id)"},{"line_number":81,"context_line":""},{"line_number":82,"context_line":"    def upload_cert_amp(self, amp, pem):"},{"line_number":83,"context_line":"        LOG.debug(\"Amphora %s haproxy, updating cert in REST driver \""},{"line_number":84,"context_line":"                  \"with amphora id %s,\","},{"line_number":85,"context_line":"                  self.__class__.__name__, amp.id)"},{"line_number":86,"context_line":"        self.client.update_cert_for_rotation(amp, pem)"}],"source_content_type":"text/x-python","patch_set":45,"id":"da85f559_15e44239","line":83,"updated":"2015-11-13 17:57:08.000000000","message":"nit: remove haproxy as it is confusing.","commit_id":"ef0cfaae9f8a16494b561aa089bfecd754cd54b8"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"52588da459caccb0f7743641619a1d8a675c9770","unresolved":false,"context_lines":[{"line_number":80,"context_line":"                    self.client.start_listener(amp, listener.id)"},{"line_number":81,"context_line":""},{"line_number":82,"context_line":"    def upload_cert_amp(self, amp, pem):"},{"line_number":83,"context_line":"        LOG.debug(\"Amphora %s haproxy, updating cert in REST driver \""},{"line_number":84,"context_line":"                  \"with amphora id %s,\","},{"line_number":85,"context_line":"                  self.__class__.__name__, amp.id)"},{"line_number":86,"context_line":"        self.client.update_cert_for_rotation(amp, pem)"}],"source_content_type":"text/x-python","patch_set":45,"id":"da85f559_d08c8837","line":83,"in_reply_to":"da85f559_15e44239","updated":"2015-11-13 18:00:05.000000000","message":"ok, will change it in the next patch.","commit_id":"ef0cfaae9f8a16494b561aa089bfecd754cd54b8"},{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"07fa8246713f5e2ab5d630e8321b2195cd91f818","unresolved":false,"context_lines":[{"line_number":256,"context_line":"            data\u003dpem_file)"},{"line_number":257,"context_line":"        return exc.check_exception(r)"},{"line_number":258,"context_line":""},{"line_number":259,"context_line":"    def update_cert_for_rotation(self, amp, pem_file):"},{"line_number":260,"context_line":"        r \u003d self.put(amp, \u0027certificate\u0027, data\u003dpem_file)"},{"line_number":261,"context_line":"        return exc.check_exception(r)"},{"line_number":262,"context_line":""}],"source_content_type":"text/x-python","patch_set":48,"id":"ba8a016a_f2185620","line":259,"updated":"2015-11-18 15:46:29.000000000","message":"Why is this a separate function? It seems a bit weird to have split this out to me. Maybe there is a reason I\u0027m not seeing?","commit_id":"f952248b9b0ca32f30e29b3df668d8c4f78b0e59"},{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"e95860a10b16dc6bc941a0e02eee3062eeb7dd84","unresolved":false,"context_lines":[{"line_number":256,"context_line":"            data\u003dpem_file)"},{"line_number":257,"context_line":"        return exc.check_exception(r)"},{"line_number":258,"context_line":""},{"line_number":259,"context_line":"    def update_cert_for_rotation(self, amp, pem_file):"},{"line_number":260,"context_line":"        r \u003d self.put(amp, \u0027certificate\u0027, data\u003dpem_file)"},{"line_number":261,"context_line":"        return exc.check_exception(r)"},{"line_number":262,"context_line":""}],"source_content_type":"text/x-python","patch_set":48,"id":"ba8a016a_f1d034f8","line":259,"in_reply_to":"ba8a016a_1c1f28b8","updated":"2015-11-19 04:10:42.000000000","message":"Oh, yeah. Missed that context with all of the unchanged lines folded up in gerrit. I see now!","commit_id":"f952248b9b0ca32f30e29b3df668d8c4f78b0e59"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"2a9be7663150b71f706ae06bd528db845e083c10","unresolved":false,"context_lines":[{"line_number":256,"context_line":"            data\u003dpem_file)"},{"line_number":257,"context_line":"        return exc.check_exception(r)"},{"line_number":258,"context_line":""},{"line_number":259,"context_line":"    def update_cert_for_rotation(self, amp, pem_file):"},{"line_number":260,"context_line":"        r \u003d self.put(amp, \u0027certificate\u0027, data\u003dpem_file)"},{"line_number":261,"context_line":"        return exc.check_exception(r)"},{"line_number":262,"context_line":""}],"source_content_type":"text/x-python","patch_set":48,"id":"ba8a016a_1c1f28b8","line":259,"in_reply_to":"ba8a016a_f2185620","updated":"2015-11-18 17:50:50.000000000","message":"2 reasons:the first is the keep the coding style consistent here, if you check other methods in this file, they basically split the methods into 2 parts ; the second reason is that this method belongs to class AmphoraAPIClient, while the method on line 82 belongs to another class.","commit_id":"f952248b9b0ca32f30e29b3df668d8c4f78b0e59"}],"octavia/amphorae/drivers/noop_driver/driver.py":[{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"674c6364553fe2a02d24db2f27ad214b8160bee1","unresolved":false,"context_lines":[{"line_number":92,"context_line":"        self.amphoraconfig[(load_balancer.id, id(amphorae_network_config))] \u003d ("},{"line_number":93,"context_line":"            load_balancer.id, amphorae_network_config, \u0027post_vip_plug\u0027)"},{"line_number":94,"context_line":""},{"line_number":95,"context_line":"    def upload_cert_amp(self, amphora, pem_file):"},{"line_number":96,"context_line":"        LOG.debug(\"Amphora %s no-op, upload cert amphora %s\","},{"line_number":97,"context_line":"                  self.__class__.__name__, amphora.id)"},{"line_number":98,"context_line":"        self.amphoraconfig[amphora.id] \u003d (amphora.id, \u0027upload_cert_amp\u0027)"}],"source_content_type":"text/x-python","patch_set":37,"id":"da85f559_4b46d9c0","line":95,"updated":"2015-11-07 01:19:31.000000000","message":"Missing unit test","commit_id":"9ac96425f0cc0a72b120527af4df2c5c48a4ec5b"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"674c6364553fe2a02d24db2f27ad214b8160bee1","unresolved":false,"context_lines":[{"line_number":139,"context_line":""},{"line_number":140,"context_line":"        self.driver.post_vip_plug(load_balancer, amphorae_network_config)"},{"line_number":141,"context_line":""},{"line_number":142,"context_line":"    def upload_cert_amp(self, amphora, pem_file):"},{"line_number":143,"context_line":""},{"line_number":144,"context_line":"        self.driver.upload_cert_amp(amphora, pem_file)"}],"source_content_type":"text/x-python","patch_set":37,"id":"da85f559_0b1771a4","line":142,"updated":"2015-11-07 01:19:31.000000000","message":"Missing unit test","commit_id":"9ac96425f0cc0a72b120527af4df2c5c48a4ec5b"}],"octavia/cmd/house_keeping.py":[{"author":{"_account_id":10850,"name":"German Eichberger","email":"german.eichberger@gmail.com","username":"german"},"change_message_id":"d9273dec9c255f9d276f76f950050a9915ca1357","unresolved":false,"context_lines":[{"line_number":61,"context_line":"        time.sleep(interval)"},{"line_number":62,"context_line":""},{"line_number":63,"context_line":""},{"line_number":64,"context_line":"def cert_rotation():"},{"line_number":65,"context_line":"    \"\"\"Perform certificate rotation.\"\"\""},{"line_number":66,"context_line":"    # Read the interval from CONF"},{"line_number":67,"context_line":"    interval \u003d CONF.house_keeping.cert_interval"}],"source_content_type":"text/x-python","patch_set":2,"id":"fa1b9901_ef3833d5","line":64,"updated":"2015-08-20 23:47:40.000000000","message":"we might want a way to disable that for people having other means of cycling certs, e.g. deployment systems like chef...","commit_id":"89ecfd2f39f1eda12e605c2c607e4a1338c8ab8a"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"81a8cde830ab6c6622a21560517df10b7c94103a","unresolved":false,"context_lines":[{"line_number":61,"context_line":"        time.sleep(interval)"},{"line_number":62,"context_line":""},{"line_number":63,"context_line":""},{"line_number":64,"context_line":"def cert_rotation():"},{"line_number":65,"context_line":"    \"\"\"Perform certificate rotation.\"\"\""},{"line_number":66,"context_line":"    # Read the interval from CONF"},{"line_number":67,"context_line":"    interval \u003d CONF.house_keeping.cert_interval"}],"source_content_type":"text/x-python","patch_set":2,"id":"fa1b9901_e3c5800a","line":64,"in_reply_to":"fa1b9901_5611b302","updated":"2015-08-21 16:47:08.000000000","message":"Adam, i did not quite get you, can you explain a bit for maintaining a single  work flow here?\n\nNow we just use a process to facilitate the certificate rotation","commit_id":"89ecfd2f39f1eda12e605c2c607e4a1338c8ab8a"},{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"e8e4f7f7c9e72d07428bda9b25516bd75d5dfb2a","unresolved":false,"context_lines":[{"line_number":61,"context_line":"        time.sleep(interval)"},{"line_number":62,"context_line":""},{"line_number":63,"context_line":""},{"line_number":64,"context_line":"def cert_rotation():"},{"line_number":65,"context_line":"    \"\"\"Perform certificate rotation.\"\"\""},{"line_number":66,"context_line":"    # Read the interval from CONF"},{"line_number":67,"context_line":"    interval \u003d CONF.house_keeping.cert_interval"}],"source_content_type":"text/x-python","patch_set":2,"id":"fa1b9901_d03fd985","line":64,"in_reply_to":"fa1b9901_e3c5800a","updated":"2015-08-21 20:47:32.000000000","message":"Maintaining a single work flow, ie:\n\n* Octavia\u0027s Controller generates and deploys the initial cert.\n* Any external system jumping in to the process like Chef/Ansible/CertMonger/etc would be a second workflow for the Amphora to get a certificate.\n\nI think we want there to be only one way for an Amp to get a cert assigned, that way we guarantee that the cert was generated in the exact same way. In that case, only Octavia\u0027s Controller should generate and re-deploy certs for rotations.","commit_id":"89ecfd2f39f1eda12e605c2c607e4a1338c8ab8a"},{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"d6f84274cc93ecfa33ebe43ba3290030eaa0c7b2","unresolved":false,"context_lines":[{"line_number":61,"context_line":"        time.sleep(interval)"},{"line_number":62,"context_line":""},{"line_number":63,"context_line":""},{"line_number":64,"context_line":"def cert_rotation():"},{"line_number":65,"context_line":"    \"\"\"Perform certificate rotation.\"\"\""},{"line_number":66,"context_line":"    # Read the interval from CONF"},{"line_number":67,"context_line":"    interval \u003d CONF.house_keeping.cert_interval"}],"source_content_type":"text/x-python","patch_set":2,"id":"fa1b9901_5611b302","line":64,"in_reply_to":"fa1b9901_ef3833d5","updated":"2015-08-21 04:21:47.000000000","message":"I can\u0027t imagine people would want to use some other automation system to replace certs on *our amphorae*. They\u0027d have to do things like dig into our DB to know which machines and what certs to have generated for them, and I think we should just plan to maintain a single workflow for this (since we were also the ones who did the original certificate deployment).","commit_id":"89ecfd2f39f1eda12e605c2c607e4a1338c8ab8a"},{"author":{"_account_id":15226,"name":"Bharath M","email":"bharath.stacker@gmail.com","username":"bharath"},"change_message_id":"f38a0d413a73e6a341cfb2ae721ec4915367259d","unresolved":false,"context_lines":[{"line_number":90,"context_line":"    db_cleanup_thread_event.set()"},{"line_number":91,"context_line":"    db_cleanup_thread.start()"},{"line_number":92,"context_line":""},{"line_number":93,"context_line":"    # Thread to perform certificate rotation"},{"line_number":94,"context_line":"    processes \u003d []"},{"line_number":95,"context_line":"    cert_rotation_proc \u003d multiprocessing.Process(name\u003d\u0027Cert_rotation\u0027,"},{"line_number":96,"context_line":"                                                 target\u003dcert_rotation)"}],"source_content_type":"text/x-python","patch_set":5,"id":"fa1b9901_6d46ab7c","line":93,"updated":"2015-08-25 21:16:24.000000000","message":"\"Process\" but not Thread.","commit_id":"fee2d3a0f36d2abcb8a7f4d4079cfd790f9b0f78"},{"author":{"_account_id":15226,"name":"Bharath M","email":"bharath.stacker@gmail.com","username":"bharath"},"change_message_id":"f38a0d413a73e6a341cfb2ae721ec4915367259d","unresolved":false,"context_lines":[{"line_number":103,"context_line":"        while True:"},{"line_number":104,"context_line":"            time.sleep(1)"},{"line_number":105,"context_line":"        for process in processes:"},{"line_number":106,"context_line":"            process.join()"},{"line_number":107,"context_line":"    except KeyboardInterrupt:"},{"line_number":108,"context_line":"        LOG.info(_LI(\"Attempting to gracefully terminate House-Keeping\"))"},{"line_number":109,"context_line":"        spare_amp_thread_event.clear()"}],"source_content_type":"text/x-python","patch_set":5,"id":"fa1b9901_6d146b4c","line":106,"updated":"2015-08-25 21:16:24.000000000","message":"As we are using both threads and processes, I guess process.join() should go into the exception block because a Keyboard interrupt would result in skipping this.","commit_id":"fee2d3a0f36d2abcb8a7f4d4079cfd790f9b0f78"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"dc3a1150dd5a4a93f7fb0e989051d807d28d912a","unresolved":false,"context_lines":[{"line_number":103,"context_line":"        while True:"},{"line_number":104,"context_line":"            time.sleep(1)"},{"line_number":105,"context_line":"        for process in processes:"},{"line_number":106,"context_line":"            process.join()"},{"line_number":107,"context_line":"    except KeyboardInterrupt:"},{"line_number":108,"context_line":"        LOG.info(_LI(\"Attempting to gracefully terminate House-Keeping\"))"},{"line_number":109,"context_line":"        spare_amp_thread_event.clear()"}],"source_content_type":"text/x-python","patch_set":5,"id":"fa1b9901_1ff7165a","line":106,"in_reply_to":"fa1b9901_6d146b4c","updated":"2015-08-25 21:35:00.000000000","message":"yes.  I\u0027m not sure we need a separate process here.  The join is a problem here and should go in the handler code.","commit_id":"fee2d3a0f36d2abcb8a7f4d4079cfd790f9b0f78"},{"author":{"_account_id":15226,"name":"Bharath M","email":"bharath.stacker@gmail.com","username":"bharath"},"change_message_id":"8de2638cf7903d66048d3adf757fb13117f5adc4","unresolved":false,"context_lines":[{"line_number":65,"context_line":"    \"\"\"Perform certificate rotation.\"\"\""},{"line_number":66,"context_line":"    # Read the interval from CONF"},{"line_number":67,"context_line":"    interval \u003d CONF.house_keeping.cert_interval"},{"line_number":68,"context_line":"    LOG.info(_LI(\"Certificate expiration check\") % interval)"},{"line_number":69,"context_line":"    cert_rotate \u003d house_keeping.CertRotation()"},{"line_number":70,"context_line":"    while cert_rotate_thread_event.is_set():"},{"line_number":71,"context_line":"        LOG.info(_LI(\"Initiating certification rotation ...\"))"}],"source_content_type":"text/x-python","patch_set":7,"id":"da20952f_def9154f","line":68,"updated":"2015-08-27 08:23:54.000000000","message":"Formatter (%d) is missing. Something like:\n\nLOG.info(_LI(\"Certificate expiration interval is set to %d sec\") % interval)","commit_id":"a0316b696a10d66dbb1dd68bb0c30ecabb317fd8"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"11cc45a972e9c7e585a3a1ba12b2812aea257566","unresolved":false,"context_lines":[{"line_number":65,"context_line":"    # Read the interval from CONF"},{"line_number":66,"context_line":"    interval \u003d CONF.house_keeping.cert_interval"},{"line_number":67,"context_line":"    LOG.info("},{"line_number":68,"context_line":"        _LI(\"Certificate expiration interval is set to %d sec\") % interval)"},{"line_number":69,"context_line":"    cert_rotate \u003d house_keeping.CertRotation()"},{"line_number":70,"context_line":"    while cert_rotate_thread_event.is_set():"},{"line_number":71,"context_line":"        LOG.info(_LI(\"Initiating certification rotation ...\"))"}],"source_content_type":"text/x-python","patch_set":15,"id":"ba15a1d1_1e76cd06","line":68,"updated":"2015-09-19 01:14:11.000000000","message":"Let\u0027s change this wording:\n\"Expiring certificate check interval is set to %d sec\"","commit_id":"6e73ec826cab50571fc7f87856ff1e06830e8ce6"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"b5fd19041412fb6917376b2fda359de4536e0c4e","unresolved":false,"context_lines":[{"line_number":67,"context_line":"    LOG.info("},{"line_number":68,"context_line":"        _LI(\"Certificate expiration interval is set to %d sec\") % interval)"},{"line_number":69,"context_line":"    cert_rotate \u003d house_keeping.CertRotation()"},{"line_number":70,"context_line":"    while cert_rotate_thread_event.is_set():"},{"line_number":71,"context_line":"        LOG.info(_LI(\"Initiating certification rotation ...\"))"},{"line_number":72,"context_line":"        cert_rotate.rotate()"},{"line_number":73,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"ba15a1d1_d1cd9187","line":70,"updated":"2015-09-21 02:31:05.000000000","message":"I think we should rethink the sleep and checking this event.\nCan we move the sleep up to this level, and have it sleep only five seconds, then check the event, and sleep again up to the over all sleep interval?\n\nThis way if someone sets this sleep to 24 hours a keyboard interrupt would still gracefully shutdown the process.","commit_id":"6e73ec826cab50571fc7f87856ff1e06830e8ce6"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"6fc33d4a291337bcdc2babb1c05ac60850ef866d","unresolved":false,"context_lines":[{"line_number":70,"context_line":"        _LI(\"Expiring certificate check interval is set to %d sec\") % interval)"},{"line_number":71,"context_line":"    cert_rotate \u003d house_keeping.CertRotation()"},{"line_number":72,"context_line":"    while cert_rotate_thread_event.is_set():"},{"line_number":73,"context_line":"        LOG.info(_LI(\"Initiating certification rotation ...\"))"},{"line_number":74,"context_line":"        cert_rotate.rotate()"},{"line_number":75,"context_line":"        time.sleep(interval)"},{"line_number":76,"context_line":""}],"source_content_type":"text/x-python","patch_set":21,"id":"9a1a9d01_de6ce8d1","line":73,"updated":"2015-10-01 00:26:57.000000000","message":"This should be debug level otherwise the logs will be very large at the info level.","commit_id":"6ed6a21021da64a362c281874327f3936ff5b89c"},{"author":{"_account_id":8157,"name":"Bertrand LALLAU","email":"bertrand.lallau@gmail.com","username":"blallau"},"change_message_id":"5b6b41a64dd95d347abb75fde7a5c2c2099a83c5","unresolved":false,"context_lines":[{"line_number":64,"context_line":""},{"line_number":65,"context_line":"def cert_rotation():"},{"line_number":66,"context_line":"    \"\"\"Perform certificate rotation.\"\"\""},{"line_number":67,"context_line":"    # Read the interval from CONF"},{"line_number":68,"context_line":"    interval \u003d CONF.house_keeping.cert_interval"},{"line_number":69,"context_line":"    LOG.info("},{"line_number":70,"context_line":"        _LI(\"Expiring certificate check interval is set to %d sec\") % interval)"}],"source_content_type":"text/x-python","patch_set":38,"id":"da85f559_d0a443a7","line":67,"updated":"2015-11-10 16:55:29.000000000","message":"not useful","commit_id":"d099c9e4826fe1b54e357810bd5591e578bd73e4"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"83dfce2573f7767297eb3758fc65ce6a26397997","unresolved":false,"context_lines":[{"line_number":64,"context_line":""},{"line_number":65,"context_line":"def cert_rotation():"},{"line_number":66,"context_line":"    \"\"\"Perform certificate rotation.\"\"\""},{"line_number":67,"context_line":"    # Read the interval from CONF"},{"line_number":68,"context_line":"    interval \u003d CONF.house_keeping.cert_interval"},{"line_number":69,"context_line":"    LOG.info("},{"line_number":70,"context_line":"        _LI(\"Expiring certificate check interval is set to %d sec\") % interval)"}],"source_content_type":"text/x-python","patch_set":38,"id":"da85f559_e12736c8","line":67,"in_reply_to":"da85f559_d0a443a7","updated":"2015-11-10 18:13:04.000000000","message":"Done","commit_id":"d099c9e4826fe1b54e357810bd5591e578bd73e4"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"9d284d669f6af7caad24731b2773d6d183aa9f91","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":""},{"line_number":16,"context_line":"import datetime"},{"line_number":17,"context_line":"import sys"},{"line_number":18,"context_line":"import threading"}],"source_content_type":"text/x-python","patch_set":45,"id":"da85f559_f5bdfe02","side":"PARENT","line":15,"updated":"2015-11-13 17:57:08.000000000","message":"nit: This line should go back in","commit_id":"0878c6b81b67e4a11f5c445526a26550719373fd"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"52588da459caccb0f7743641619a1d8a675c9770","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":""},{"line_number":16,"context_line":"import datetime"},{"line_number":17,"context_line":"import sys"},{"line_number":18,"context_line":"import threading"}],"source_content_type":"text/x-python","patch_set":45,"id":"da85f559_b08ea425","side":"PARENT","line":15,"in_reply_to":"da85f559_f5bdfe02","updated":"2015-11-13 18:00:05.000000000","message":"will change it in the next patch.","commit_id":"0878c6b81b67e4a11f5c445526a26550719373fd"},{"author":{"_account_id":11685,"name":"Stephen Balukoff","email":"stephen@balukoff.com","username":"sbalukoff"},"change_message_id":"e430a0dab69edb248bb6675ad42a8fa5d965a5da","unresolved":false,"context_lines":[{"line_number":98,"context_line":"    db_cleanup_thread_event.set()"},{"line_number":99,"context_line":"    db_cleanup_thread.start()"},{"line_number":100,"context_line":""},{"line_number":101,"context_line":"    # # Thread to perform certificate rotation"},{"line_number":102,"context_line":"    cert_rotate_thread \u003d threading.Thread(target\u003dcert_rotation)"},{"line_number":103,"context_line":"    cert_rotate_thread.daemon \u003d True"},{"line_number":104,"context_line":"    cert_rotate_thread_event.set()"}],"source_content_type":"text/x-python","patch_set":49,"id":"ba8a016a_59472977","line":101,"updated":"2015-11-23 23:26:43.000000000","message":"Nit: Only need one #","commit_id":"f283d52139bfffa09e3c35a7f5406bb6c90e57f4"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"a1dcc4542154eff93d96cec9701ce86f32e73228","unresolved":false,"context_lines":[{"line_number":98,"context_line":"    db_cleanup_thread_event.set()"},{"line_number":99,"context_line":"    db_cleanup_thread.start()"},{"line_number":100,"context_line":""},{"line_number":101,"context_line":"    # # Thread to perform certificate rotation"},{"line_number":102,"context_line":"    cert_rotate_thread \u003d threading.Thread(target\u003dcert_rotation)"},{"line_number":103,"context_line":"    cert_rotate_thread.daemon \u003d True"},{"line_number":104,"context_line":"    cert_rotate_thread_event.set()"}],"source_content_type":"text/x-python","patch_set":49,"id":"ba8a016a_6a31ed0a","line":101,"in_reply_to":"ba8a016a_59472977","updated":"2015-11-24 00:40:19.000000000","message":"i can take the additional # off.","commit_id":"f283d52139bfffa09e3c35a7f5406bb6c90e57f4"}],"octavia/common/config.py":[{"author":{"_account_id":10850,"name":"German Eichberger","email":"german.eichberger@gmail.com","username":"german"},"change_message_id":"312be15b25ff86e0a6782b3302205509746bb16f","unresolved":false,"context_lines":[{"line_number":224,"context_line":"    cfg.IntOpt(\u0027cert_expired\u0027,"},{"line_number":225,"context_line":"               default\u003d1000,"},{"line_number":226,"context_line":"               help\u003d_(\u0027DB certificate rotation interval in seconds\u0027)),"},{"line_number":227,"context_line":"    cfg.IntOpt(\u0027failover_threads\u0027,"},{"line_number":228,"context_line":"               default\u003d10,"},{"line_number":229,"context_line":"               help\u003d_(\u0027Number of threads performing amphora certificate\u0027"},{"line_number":230,"context_line":"                      \u0027 rotation\u0027))"}],"source_content_type":"text/x-python","patch_set":3,"id":"fa1b9901_ab719379","line":227,"updated":"2015-08-21 22:56:28.000000000","message":"failover? you mean cert rotate?","commit_id":"143353125b8cdd9c0a6bf8fe590db6b814576b1e"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"98e1d6edd72056172848e634fa35a6296ca00ad2","unresolved":false,"context_lines":[{"line_number":224,"context_line":"    cfg.IntOpt(\u0027cert_expired\u0027,"},{"line_number":225,"context_line":"               default\u003d1000,"},{"line_number":226,"context_line":"               help\u003d_(\u0027DB certificate rotation interval in seconds\u0027)),"},{"line_number":227,"context_line":"    cfg.IntOpt(\u0027failover_threads\u0027,"},{"line_number":228,"context_line":"               default\u003d10,"},{"line_number":229,"context_line":"               help\u003d_(\u0027Number of threads performing amphora certificate\u0027"},{"line_number":230,"context_line":"                      \u0027 rotation\u0027))"}],"source_content_type":"text/x-python","patch_set":3,"id":"fa1b9901_f303c474","line":227,"in_reply_to":"fa1b9901_ab719379","updated":"2015-08-24 17:29:17.000000000","message":"have renamed it as cert_rotate_threads","commit_id":"143353125b8cdd9c0a6bf8fe590db6b814576b1e"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"11cc45a972e9c7e585a3a1ba12b2812aea257566","unresolved":false,"context_lines":[{"line_number":266,"context_line":"               help\u003d_(\u0027DB certificate check interval in seconds\u0027)),"},{"line_number":267,"context_line":"    cfg.IntOpt(\u0027cert_expired\u0027,"},{"line_number":268,"context_line":"               default\u003d1000,"},{"line_number":269,"context_line":"               help\u003d_(\u0027DB certificate rotation interval in seconds\u0027)),"},{"line_number":270,"context_line":"    cfg.IntOpt(\u0027cert_rotate_threads\u0027,"},{"line_number":271,"context_line":"               default\u003d10,"},{"line_number":272,"context_line":"               help\u003d_(\u0027Number of threads performing amphora certificate\u0027"}],"source_content_type":"text/x-python","patch_set":15,"id":"ba15a1d1_528f54cc","line":269,"updated":"2015-09-19 01:14:11.000000000","message":"We should re-word this:\n\"Seconds until certificate expiration\"","commit_id":"6e73ec826cab50571fc7f87856ff1e06830e8ce6"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"9d284d669f6af7caad24731b2773d6d183aa9f91","unresolved":false,"context_lines":[{"line_number":272,"context_line":"               default\u003d604800,"},{"line_number":273,"context_line":"               help\u003d_(\u0027Amphora expiry age in seconds\u0027)),"},{"line_number":274,"context_line":"    cfg.IntOpt(\u0027cert_interval\u0027,"},{"line_number":275,"context_line":"               default\u003d5,"},{"line_number":276,"context_line":"               help\u003d_(\u0027DB certificate check interval in seconds\u0027)),"},{"line_number":277,"context_line":"    cfg.IntOpt(\u0027cert_expiry_buffer\u0027,"},{"line_number":278,"context_line":"               default\u003d1209600,"}],"source_content_type":"text/x-python","patch_set":45,"id":"da85f559_75982e6b","line":275,"updated":"2015-11-13 17:57:08.000000000","message":"I think we should consider a one hour default here.\nWith five seconds it will put a lot of info log entries in the log and I don\u0027t know that this is time sensitive enough to run every five seconds.","commit_id":"ef0cfaae9f8a16494b561aa089bfecd754cd54b8"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"9d284d669f6af7caad24731b2773d6d183aa9f91","unresolved":false,"context_lines":[{"line_number":273,"context_line":"               help\u003d_(\u0027Amphora expiry age in seconds\u0027)),"},{"line_number":274,"context_line":"    cfg.IntOpt(\u0027cert_interval\u0027,"},{"line_number":275,"context_line":"               default\u003d5,"},{"line_number":276,"context_line":"               help\u003d_(\u0027DB certificate check interval in seconds\u0027)),"},{"line_number":277,"context_line":"    cfg.IntOpt(\u0027cert_expiry_buffer\u0027,"},{"line_number":278,"context_line":"               default\u003d1209600,"},{"line_number":279,"context_line":"               help\u003d_(\u0027Seconds until certificate expiration--2 weeks\u0027)),"}],"source_content_type":"text/x-python","patch_set":45,"id":"da85f559_3572a67d","line":276,"updated":"2015-11-13 17:57:08.000000000","message":"nit: Remove \"DB\"","commit_id":"ef0cfaae9f8a16494b561aa089bfecd754cd54b8"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"9d284d669f6af7caad24731b2773d6d183aa9f91","unresolved":false,"context_lines":[{"line_number":276,"context_line":"               help\u003d_(\u0027DB certificate check interval in seconds\u0027)),"},{"line_number":277,"context_line":"    cfg.IntOpt(\u0027cert_expiry_buffer\u0027,"},{"line_number":278,"context_line":"               default\u003d1209600,"},{"line_number":279,"context_line":"               help\u003d_(\u0027Seconds until certificate expiration--2 weeks\u0027)),"},{"line_number":280,"context_line":"    cfg.IntOpt(\u0027cert_rotate_threads\u0027,"},{"line_number":281,"context_line":"               default\u003d10,"},{"line_number":282,"context_line":"               help\u003d_(\u0027Number of threads performing amphora certificate\u0027"}],"source_content_type":"text/x-python","patch_set":45,"id":"da85f559_955cb2ee","line":279,"updated":"2015-11-13 17:57:08.000000000","message":"Remove the \"--2 weeks\" as this is configurable.","commit_id":"ef0cfaae9f8a16494b561aa089bfecd754cd54b8"},{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"07fa8246713f5e2ab5d630e8321b2195cd91f818","unresolved":false,"context_lines":[{"line_number":271,"context_line":"    cfg.IntOpt(\u0027amphora_expiry_age\u0027,"},{"line_number":272,"context_line":"               default\u003d604800,"},{"line_number":273,"context_line":"               help\u003d_(\u0027Amphora expiry age in seconds\u0027)),"},{"line_number":274,"context_line":"    cfg.IntOpt(\u0027cert_interval\u0027,"},{"line_number":275,"context_line":"               default\u003d3600,"},{"line_number":276,"context_line":"               help\u003d_(\u0027Certificate check interval in seconds\u0027)),"},{"line_number":277,"context_line":"    cfg.IntOpt(\u0027cert_expiry_buffer\u0027,"}],"source_content_type":"text/x-python","patch_set":48,"id":"ba8a016a_75dbf04f","line":274,"updated":"2015-11-18 15:46:29.000000000","message":"I almost wish this was named \"cert_check_interval\" but it is probably fine like this.","commit_id":"f952248b9b0ca32f30e29b3df668d8c4f78b0e59"},{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"07fa8246713f5e2ab5d630e8321b2195cd91f818","unresolved":false,"context_lines":[{"line_number":277,"context_line":"    cfg.IntOpt(\u0027cert_expiry_buffer\u0027,"},{"line_number":278,"context_line":"               default\u003d1209600,"},{"line_number":279,"context_line":"               help\u003d_(\u0027Seconds until certificate expiration\u0027)),"},{"line_number":280,"context_line":"    cfg.IntOpt(\u0027cert_rotate_threads\u0027,"},{"line_number":281,"context_line":"               default\u003d10,"},{"line_number":282,"context_line":"               help\u003d_(\u0027Number of threads performing amphora certificate\u0027"},{"line_number":283,"context_line":"                      \u0027 rotation\u0027))"}],"source_content_type":"text/x-python","patch_set":48,"id":"ba8a016a_55ceec82","line":280,"updated":"2015-11-18 15:46:29.000000000","message":"Does this actually control anything?","commit_id":"f952248b9b0ca32f30e29b3df668d8c4f78b0e59"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"2a9be7663150b71f706ae06bd528db845e083c10","unresolved":false,"context_lines":[{"line_number":277,"context_line":"    cfg.IntOpt(\u0027cert_expiry_buffer\u0027,"},{"line_number":278,"context_line":"               default\u003d1209600,"},{"line_number":279,"context_line":"               help\u003d_(\u0027Seconds until certificate expiration\u0027)),"},{"line_number":280,"context_line":"    cfg.IntOpt(\u0027cert_rotate_threads\u0027,"},{"line_number":281,"context_line":"               default\u003d10,"},{"line_number":282,"context_line":"               help\u003d_(\u0027Number of threads performing amphora certificate\u0027"},{"line_number":283,"context_line":"                      \u0027 rotation\u0027))"}],"source_content_type":"text/x-python","patch_set":48,"id":"ba8a016a_dc65201e","line":280,"in_reply_to":"ba8a016a_55ceec82","updated":"2015-11-18 17:50:50.000000000","message":"yes, it is used in file octavia/controller/housekeeping/house_keeping.py\n on line 87","commit_id":"f952248b9b0ca32f30e29b3df668d8c4f78b0e59"},{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"e95860a10b16dc6bc941a0e02eee3062eeb7dd84","unresolved":false,"context_lines":[{"line_number":277,"context_line":"    cfg.IntOpt(\u0027cert_expiry_buffer\u0027,"},{"line_number":278,"context_line":"               default\u003d1209600,"},{"line_number":279,"context_line":"               help\u003d_(\u0027Seconds until certificate expiration\u0027)),"},{"line_number":280,"context_line":"    cfg.IntOpt(\u0027cert_rotate_threads\u0027,"},{"line_number":281,"context_line":"               default\u003d10,"},{"line_number":282,"context_line":"               help\u003d_(\u0027Number of threads performing amphora certificate\u0027"},{"line_number":283,"context_line":"                      \u0027 rotation\u0027))"}],"source_content_type":"text/x-python","patch_set":48,"id":"ba8a016a_710be48e","line":280,"in_reply_to":"ba8a016a_dc65201e","updated":"2015-11-19 04:10:42.000000000","message":"Erk, yeah I found it later and forgot to go back and remove this comment. Sorry. T_T","commit_id":"f952248b9b0ca32f30e29b3df668d8c4f78b0e59"},{"author":{"_account_id":11685,"name":"Stephen Balukoff","email":"stephen@balukoff.com","username":"sbalukoff"},"change_message_id":"e430a0dab69edb248bb6675ad42a8fa5d965a5da","unresolved":false,"context_lines":[{"line_number":279,"context_line":"               default\u003d3600,"},{"line_number":280,"context_line":"               help\u003d_(\u0027Certificate check interval in seconds\u0027)),"},{"line_number":281,"context_line":"    cfg.IntOpt(\u0027cert_expiry_buffer\u0027,"},{"line_number":282,"context_line":"               default\u003d1209600,"},{"line_number":283,"context_line":"               help\u003d_(\u0027Seconds until certificate expiration\u0027)),"},{"line_number":284,"context_line":"    cfg.IntOpt(\u0027cert_rotate_threads\u0027,"},{"line_number":285,"context_line":"               default\u003d10,"}],"source_content_type":"text/x-python","patch_set":49,"id":"ba8a016a_39126563","line":282,"updated":"2015-11-23 23:26:43.000000000","message":"Could you add a comment here to indicate how long this is in a more easily understood metric (ie. \"1209600 seconds is 14 days\")","commit_id":"f283d52139bfffa09e3c35a7f5406bb6c90e57f4"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"a1dcc4542154eff93d96cec9701ce86f32e73228","unresolved":false,"context_lines":[{"line_number":279,"context_line":"               default\u003d3600,"},{"line_number":280,"context_line":"               help\u003d_(\u0027Certificate check interval in seconds\u0027)),"},{"line_number":281,"context_line":"    cfg.IntOpt(\u0027cert_expiry_buffer\u0027,"},{"line_number":282,"context_line":"               default\u003d1209600,"},{"line_number":283,"context_line":"               help\u003d_(\u0027Seconds until certificate expiration\u0027)),"},{"line_number":284,"context_line":"    cfg.IntOpt(\u0027cert_rotate_threads\u0027,"},{"line_number":285,"context_line":"               default\u003d10,"}],"source_content_type":"text/x-python","patch_set":49,"id":"ba8a016a_2a3be5ec","line":282,"in_reply_to":"ba8a016a_39126563","updated":"2015-11-24 00:40:19.000000000","message":"it is 2 weeks, i can add it.","commit_id":"f283d52139bfffa09e3c35a7f5406bb6c90e57f4"},{"author":{"_account_id":11685,"name":"Stephen Balukoff","email":"stephen@balukoff.com","username":"sbalukoff"},"change_message_id":"839068a398dd7b44de6065a5b828c0a20c234c48","unresolved":false,"context_lines":[{"line_number":280,"context_line":"               help\u003d_(\u0027Certificate check interval in seconds\u0027)),"},{"line_number":281,"context_line":"    cfg.IntOpt(\u0027cert_expiry_buffer\u0027,"},{"line_number":282,"context_line":"               default\u003d1209600,"},{"line_number":283,"context_line":"               help\u003d_(\u0027Seconds (14days) until certificate expiration\u0027)),"},{"line_number":284,"context_line":"    cfg.IntOpt(\u0027cert_rotate_threads\u0027,"},{"line_number":285,"context_line":"               default\u003d10,"},{"line_number":286,"context_line":"               help\u003d_(\u0027Number of threads performing amphora certificate\u0027"}],"source_content_type":"text/x-python","patch_set":50,"id":"9a8ffd7b_603cb7e2","line":283,"updated":"2015-11-26 00:11:09.000000000","message":"No, I meant a comment in the code, not in the help message. It actually makes less sense to add \"(14days)\" where you have.","commit_id":"678cc697c20cf63601258ae3cf6a81166075900c"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"b45b5b4d27b913306632ad2f8a872f06283ff50d","unresolved":false,"context_lines":[{"line_number":280,"context_line":"               help\u003d_(\u0027Certificate check interval in seconds\u0027)),"},{"line_number":281,"context_line":"    cfg.IntOpt(\u0027cert_expiry_buffer\u0027,"},{"line_number":282,"context_line":"               default\u003d1209600,"},{"line_number":283,"context_line":"               help\u003d_(\u0027Seconds (14days) until certificate expiration\u0027)),"},{"line_number":284,"context_line":"    cfg.IntOpt(\u0027cert_rotate_threads\u0027,"},{"line_number":285,"context_line":"               default\u003d10,"},{"line_number":286,"context_line":"               help\u003d_(\u0027Number of threads performing amphora certificate\u0027"}],"source_content_type":"text/x-python","patch_set":50,"id":"9a8ffd7b_f038cc3f","line":283,"in_reply_to":"9a8ffd7b_603cb7e2","updated":"2015-11-30 18:37:32.000000000","message":"ok, I can do that","commit_id":"678cc697c20cf63601258ae3cf6a81166075900c"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"f6c7ebdbcdb60215c51b317ec6d0e88d295a878d","unresolved":false,"context_lines":[{"line_number":280,"context_line":"               help\u003d_(\u0027Certificate check interval in seconds\u0027)),"},{"line_number":281,"context_line":"    cfg.IntOpt(\u0027cert_expiry_buffer\u0027,"},{"line_number":282,"context_line":"               default\u003d1209600,"},{"line_number":283,"context_line":"               help\u003d_(\u0027Seconds (14days) until certificate expiration\u0027)),"},{"line_number":284,"context_line":"    cfg.IntOpt(\u0027cert_rotate_threads\u0027,"},{"line_number":285,"context_line":"               default\u003d10,"},{"line_number":286,"context_line":"               help\u003d_(\u0027Number of threads performing amphora certificate\u0027"}],"source_content_type":"text/x-python","patch_set":50,"id":"9a8ffd7b_50e438ab","line":283,"in_reply_to":"9a8ffd7b_f038cc3f","updated":"2015-11-30 18:46:42.000000000","message":"Please remove this from the help string.  This setting lets you configure the number of days.","commit_id":"678cc697c20cf63601258ae3cf6a81166075900c"}],"octavia/common/data_models.py":[{"author":{"_account_id":10850,"name":"German Eichberger","email":"german.eichberger@gmail.com","username":"german"},"change_message_id":"d9273dec9c255f9d276f76f950050a9915ca1357","unresolved":false,"context_lines":[{"line_number":237,"context_line":"        self.ha_port_id \u003d ha_port_id"},{"line_number":238,"context_line":"        self.role \u003d role"},{"line_number":239,"context_line":"        self.load_balancer \u003d load_balancer"},{"line_number":240,"context_line":"        self.cert_expiration \u003d cert_expiration"},{"line_number":241,"context_line":""},{"line_number":242,"context_line":""},{"line_number":243,"context_line":"class AmphoraHealth(BaseDataModel):"}],"source_content_type":"text/x-python","patch_set":2,"id":"fa1b9901_efdb537a","line":240,"updated":"2015-08-20 23:47:40.000000000","message":"we probably need some way to indicate some other housekeeper is already dealing with it like the busy we have in the health table. Alternatively we can use some magic date here...","commit_id":"89ecfd2f39f1eda12e605c2c607e4a1338c8ab8a"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"81a8cde830ab6c6622a21560517df10b7c94103a","unresolved":false,"context_lines":[{"line_number":237,"context_line":"        self.ha_port_id \u003d ha_port_id"},{"line_number":238,"context_line":"        self.role \u003d role"},{"line_number":239,"context_line":"        self.load_balancer \u003d load_balancer"},{"line_number":240,"context_line":"        self.cert_expiration \u003d cert_expiration"},{"line_number":241,"context_line":""},{"line_number":242,"context_line":""},{"line_number":243,"context_line":"class AmphoraHealth(BaseDataModel):"}],"source_content_type":"text/x-python","patch_set":2,"id":"fa1b9901_43454cb1","line":240,"in_reply_to":"fa1b9901_efdb537a","updated":"2015-08-21 16:47:08.000000000","message":"how do you mean by magic date, can we use another boolean variable to mark at certain moment, can we operate on this amphora?","commit_id":"89ecfd2f39f1eda12e605c2c607e4a1338c8ab8a"}],"octavia/common/tls_utils/cert_parser.py":[{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"11cc45a972e9c7e585a3a1ba12b2812aea257566","unresolved":false,"context_lines":[{"line_number":134,"context_line":"    \"\"\"Extract the expiration date from the Pem encoded X509 certificate"},{"line_number":135,"context_line":""},{"line_number":136,"context_line":"    :param certificate: A PEM encoded certificate"},{"line_number":137,"context_line":"    :returns: An expiration date with datetime type"},{"line_number":138,"context_line":"    \"\"\""},{"line_number":139,"context_line":"    try:"},{"line_number":140,"context_line":"        certificate \u003d certificate_pem.encode(\u0027ascii\u0027)"}],"source_content_type":"text/x-python","patch_set":15,"id":"ba15a1d1_b2427067","line":137,"updated":"2015-09-19 01:14:11.000000000","message":"Add the raises docstring","commit_id":"6e73ec826cab50571fc7f87856ff1e06830e8ce6"},{"author":{"_account_id":8157,"name":"Bertrand LALLAU","email":"bertrand.lallau@gmail.com","username":"blallau"},"change_message_id":"27a90d680a4a6048485648029cb37b1b7b72e75d","unresolved":false,"context_lines":[{"line_number":142,"context_line":""},{"line_number":143,"context_line":"        cert \u003d x509.load_pem_x509_certificate(certificate,"},{"line_number":144,"context_line":"                                              backends.default_backend())"},{"line_number":145,"context_line":"        cert_expiration \u003d cert.not_valid_after"},{"line_number":146,"context_line":"        return cert_expiration"},{"line_number":147,"context_line":"    except Exception as e:"},{"line_number":148,"context_line":"        LOG.exception(e)"}],"source_content_type":"text/x-python","patch_set":34,"id":"fa80f949_a0a95b7d","line":145,"updated":"2015-11-04 21:23:52.000000000","message":"maybe cert_expiration variable not useful ?","commit_id":"31e78f127140339eacb753db3c4b3990f9f42537"},{"author":{"_account_id":8157,"name":"Bertrand LALLAU","email":"bertrand.lallau@gmail.com","username":"blallau"},"change_message_id":"27a90d680a4a6048485648029cb37b1b7b72e75d","unresolved":false,"context_lines":[{"line_number":143,"context_line":"        cert \u003d x509.load_pem_x509_certificate(certificate,"},{"line_number":144,"context_line":"                                              backends.default_backend())"},{"line_number":145,"context_line":"        cert_expiration \u003d cert.not_valid_after"},{"line_number":146,"context_line":"        return cert_expiration"},{"line_number":147,"context_line":"    except Exception as e:"},{"line_number":148,"context_line":"        LOG.exception(e)"},{"line_number":149,"context_line":"        raise exceptions.UnreadableCert"}],"source_content_type":"text/x-python","patch_set":34,"id":"fa80f949_60ba93c2","line":146,"updated":"2015-11-04 21:23:52.000000000","message":"return cert.not_valid_after","commit_id":"31e78f127140339eacb753db3c4b3990f9f42537"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"9744c64cad25cc1596edaa98148f8f5ff7d9389f","unresolved":false,"context_lines":[{"line_number":143,"context_line":"        cert \u003d x509.load_pem_x509_certificate(certificate,"},{"line_number":144,"context_line":"                                              backends.default_backend())"},{"line_number":145,"context_line":"        cert_expiration \u003d cert.not_valid_after"},{"line_number":146,"context_line":"        return cert_expiration"},{"line_number":147,"context_line":"    except Exception as e:"},{"line_number":148,"context_line":"        LOG.exception(e)"},{"line_number":149,"context_line":"        raise exceptions.UnreadableCert"}],"source_content_type":"text/x-python","patch_set":34,"id":"fa80f949_a81d6863","line":146,"in_reply_to":"fa80f949_60ba93c2","updated":"2015-11-07 00:54:48.000000000","message":"+1","commit_id":"31e78f127140339eacb753db3c4b3990f9f42537"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"0a66e5090409805ed37c48f22f9a1e5d20a6aae8","unresolved":false,"context_lines":[{"line_number":143,"context_line":"        cert \u003d x509.load_pem_x509_certificate(certificate,"},{"line_number":144,"context_line":"                                              backends.default_backend())"},{"line_number":145,"context_line":"        cert_expiration \u003d cert.not_valid_after"},{"line_number":146,"context_line":"        return cert_expiration"},{"line_number":147,"context_line":"    except Exception as e:"},{"line_number":148,"context_line":"        LOG.exception(e)"},{"line_number":149,"context_line":"        raise exceptions.UnreadableCert"}],"source_content_type":"text/x-python","patch_set":34,"id":"fa80f949_78c00b7d","line":146,"in_reply_to":"fa80f949_60ba93c2","updated":"2015-11-04 22:42:49.000000000","message":"yes, we can do it like that way.","commit_id":"31e78f127140339eacb753db3c4b3990f9f42537"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"674c6364553fe2a02d24db2f27ad214b8160bee1","unresolved":false,"context_lines":[{"line_number":131,"context_line":"        raise exceptions.UnreadableCert"},{"line_number":132,"context_line":""},{"line_number":133,"context_line":""},{"line_number":134,"context_line":"def get_cert_expiration(certificate_pem):"},{"line_number":135,"context_line":"    \"\"\"Extract the expiration date from the Pem encoded X509 certificate"},{"line_number":136,"context_line":""},{"line_number":137,"context_line":"    :param certificate_pem: Certificate in PEM format"}],"source_content_type":"text/x-python","patch_set":37,"id":"da85f559_cb5e4976","line":134,"updated":"2015-11-07 01:19:31.000000000","message":"Missing unit test","commit_id":"9ac96425f0cc0a72b120527af4df2c5c48a4ec5b"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"9230d4bf02be0e6320c81fb2d1930e2a72016f1e","unresolved":false,"context_lines":[{"line_number":131,"context_line":"        raise exceptions.UnreadableCert"},{"line_number":132,"context_line":""},{"line_number":133,"context_line":""},{"line_number":134,"context_line":"def get_cert_expiration(certificate_pem):"},{"line_number":135,"context_line":"    \"\"\"Extract the expiration date from the Pem encoded X509 certificate"},{"line_number":136,"context_line":""},{"line_number":137,"context_line":"    :param certificate_pem: Certificate in PEM format"}],"source_content_type":"text/x-python","patch_set":37,"id":"da85f559_ddca53a1","line":134,"in_reply_to":"da85f559_cb5e4976","updated":"2015-11-09 18:03:58.000000000","message":"https://review.openstack.org/#/c/215359/37/octavia/tests/unit/common/tls_utils/test_cert_parser.py","commit_id":"9ac96425f0cc0a72b120527af4df2c5c48a4ec5b"}],"octavia/controller/housekeeping/house_keeping.py":[{"author":{"_account_id":10850,"name":"German Eichberger","email":"german.eichberger@gmail.com","username":"german"},"change_message_id":"d9273dec9c255f9d276f76f950050a9915ca1357","unresolved":false,"context_lines":[{"line_number":97,"context_line":""},{"line_number":98,"context_line":"            for amp in amphora:"},{"line_number":99,"context_line":"                LOG.info(_LI(\u0027Attempting to delete Amphora whose cert is \u0027"},{"line_number":100,"context_line":"                             \u0027expired,amphora id : %s\u0027) % amp.id)"},{"line_number":101,"context_line":"                self.amp_repo.delete(session, id\u003damp.id)"},{"line_number":102,"context_line":"                LOG.info(_LI(\u0027Deleted Amphora id : %s\u0027) % amp.id)"}],"source_content_type":"text/x-python","patch_set":2,"id":"fa1b9901_0f57a7ca","line":100,"updated":"2015-08-20 23:47:40.000000000","message":"use different text :-)","commit_id":"89ecfd2f39f1eda12e605c2c607e4a1338c8ab8a"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"81a8cde830ab6c6622a21560517df10b7c94103a","unresolved":false,"context_lines":[{"line_number":97,"context_line":""},{"line_number":98,"context_line":"            for amp in amphora:"},{"line_number":99,"context_line":"                LOG.info(_LI(\u0027Attempting to delete Amphora whose cert is \u0027"},{"line_number":100,"context_line":"                             \u0027expired,amphora id : %s\u0027) % amp.id)"},{"line_number":101,"context_line":"                self.amp_repo.delete(session, id\u003damp.id)"},{"line_number":102,"context_line":"                LOG.info(_LI(\u0027Deleted Amphora id : %s\u0027) % amp.id)"}],"source_content_type":"text/x-python","patch_set":2,"id":"fa1b9901_83c60448","line":100,"in_reply_to":"fa1b9901_0f57a7ca","updated":"2015-08-21 16:47:08.000000000","message":"will do","commit_id":"89ecfd2f39f1eda12e605c2c607e4a1338c8ab8a"},{"author":{"_account_id":10850,"name":"German Eichberger","email":"german.eichberger@gmail.com","username":"german"},"change_message_id":"d9273dec9c255f9d276f76f950050a9915ca1357","unresolved":false,"context_lines":[{"line_number":98,"context_line":"            for amp in amphora:"},{"line_number":99,"context_line":"                LOG.info(_LI(\u0027Attempting to delete Amphora whose cert is \u0027"},{"line_number":100,"context_line":"                             \u0027expired,amphora id : %s\u0027) % amp.id)"},{"line_number":101,"context_line":"                self.amp_repo.delete(session, id\u003damp.id)"},{"line_number":102,"context_line":"                LOG.info(_LI(\u0027Deleted Amphora id : %s\u0027) % amp.id)"}],"source_content_type":"text/x-python","patch_set":2,"id":"fa1b9901_af66bbb8","line":101,"updated":"2015-08-20 23:47:40.000000000","message":"and again don\u0027t delete but kick off a cert rotation flow","commit_id":"89ecfd2f39f1eda12e605c2c607e4a1338c8ab8a"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"81a8cde830ab6c6622a21560517df10b7c94103a","unresolved":false,"context_lines":[{"line_number":98,"context_line":"            for amp in amphora:"},{"line_number":99,"context_line":"                LOG.info(_LI(\u0027Attempting to delete Amphora whose cert is \u0027"},{"line_number":100,"context_line":"                             \u0027expired,amphora id : %s\u0027) % amp.id)"},{"line_number":101,"context_line":"                self.amp_repo.delete(session, id\u003damp.id)"},{"line_number":102,"context_line":"                LOG.info(_LI(\u0027Deleted Amphora id : %s\u0027) % amp.id)"}],"source_content_type":"text/x-python","patch_set":2,"id":"fa1b9901_43c0ec2a","line":101,"in_reply_to":"fa1b9901_af66bbb8","updated":"2015-08-21 16:47:08.000000000","message":"ok, will work on it.","commit_id":"89ecfd2f39f1eda12e605c2c607e4a1338c8ab8a"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"281dede09aacfdc9b6e20bcc81be0640466ab9cf","unresolved":false,"context_lines":[{"line_number":86,"context_line":""},{"line_number":87,"context_line":"class CertRotation(object):"},{"line_number":88,"context_line":"    def __init__(self):"},{"line_number":89,"context_line":"        self.threads \u003d CONF.health_manager.failover_threads"},{"line_number":90,"context_line":"        self.cw \u003d cw.ControllerWorker()"},{"line_number":91,"context_line":""},{"line_number":92,"context_line":"    def rotate(self):"}],"source_content_type":"text/x-python","patch_set":3,"id":"fa1b9901_d1acb837","line":89,"updated":"2015-08-22 00:43:19.000000000","message":"failover?","commit_id":"143353125b8cdd9c0a6bf8fe590db6b814576b1e"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"98e1d6edd72056172848e634fa35a6296ca00ad2","unresolved":false,"context_lines":[{"line_number":86,"context_line":""},{"line_number":87,"context_line":"class CertRotation(object):"},{"line_number":88,"context_line":"    def __init__(self):"},{"line_number":89,"context_line":"        self.threads \u003d CONF.health_manager.failover_threads"},{"line_number":90,"context_line":"        self.cw \u003d cw.ControllerWorker()"},{"line_number":91,"context_line":""},{"line_number":92,"context_line":"    def rotate(self):"}],"source_content_type":"text/x-python","patch_set":3,"id":"fa1b9901_b3fd4c70","line":89,"in_reply_to":"fa1b9901_d1acb837","updated":"2015-08-24 17:29:17.000000000","message":"have renamed it as cert_rotate_threads","commit_id":"143353125b8cdd9c0a6bf8fe590db6b814576b1e"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"281dede09aacfdc9b6e20bcc81be0640466ab9cf","unresolved":false,"context_lines":[{"line_number":96,"context_line":"        with futures.ThreadPoolExecutor(max_workers\u003dself.threads) as executor:"},{"line_number":97,"context_line":"            try:"},{"line_number":98,"context_line":"                while True:"},{"line_number":99,"context_line":"                    time.sleep(CONF.house_keeping.cert_interval)"},{"line_number":100,"context_line":"                    session \u003d db_api.get_session()"},{"line_number":101,"context_line":"                    LOG.debug(\"Starting amphora cert rotation\")"},{"line_number":102,"context_line":"                    rotation_count \u003d 0"}],"source_content_type":"text/x-python","patch_set":3,"id":"fa1b9901_918f20cc","line":99,"updated":"2015-08-22 00:43:19.000000000","message":"Why sleep here?  The top thread in octavia/cmd/house_keeping also sleeps.  Do we need both?","commit_id":"143353125b8cdd9c0a6bf8fe590db6b814576b1e"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"98e1d6edd72056172848e634fa35a6296ca00ad2","unresolved":false,"context_lines":[{"line_number":96,"context_line":"        with futures.ThreadPoolExecutor(max_workers\u003dself.threads) as executor:"},{"line_number":97,"context_line":"            try:"},{"line_number":98,"context_line":"                while True:"},{"line_number":99,"context_line":"                    time.sleep(CONF.house_keeping.cert_interval)"},{"line_number":100,"context_line":"                    session \u003d db_api.get_session()"},{"line_number":101,"context_line":"                    LOG.debug(\"Starting amphora cert rotation\")"},{"line_number":102,"context_line":"                    rotation_count \u003d 0"}],"source_content_type":"text/x-python","patch_set":3,"id":"fa1b9901_73b0148c","line":99,"in_reply_to":"fa1b9901_918f20cc","updated":"2015-08-24 17:29:17.000000000","message":"will remove this one.","commit_id":"143353125b8cdd9c0a6bf8fe590db6b814576b1e"},{"author":{"_account_id":15226,"name":"Bharath M","email":"bharath.stacker@gmail.com","username":"bharath"},"change_message_id":"f38a0d413a73e6a341cfb2ae721ec4915367259d","unresolved":false,"context_lines":[{"line_number":94,"context_line":""},{"line_number":95,"context_line":"        with futures.ThreadPoolExecutor(max_workers\u003dself.threads) as executor:"},{"line_number":96,"context_line":"            try:"},{"line_number":97,"context_line":"                while True:"},{"line_number":98,"context_line":"                    session \u003d db_api.get_session()"},{"line_number":99,"context_line":"                    LOG.info(_LI(\"Starting amphora cert rotation\"))"},{"line_number":100,"context_line":"                    rotation_count \u003d 0"}],"source_content_type":"text/x-python","patch_set":5,"id":"fa1b9901_cd9017f0","line":97,"updated":"2015-08-25 21:16:24.000000000","message":"This one goes to infinite loop. Either you should introduce sleep command inside the loop OR let the process fork method cert_rotation() under cmd/house_keeping.py do the sleeping. In the late case, you may have to remove the outer While loop here.","commit_id":"fee2d3a0f36d2abcb8a7f4d4079cfd790f9b0f78"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"dc3a1150dd5a4a93f7fb0e989051d807d28d912a","unresolved":false,"context_lines":[{"line_number":94,"context_line":""},{"line_number":95,"context_line":"        with futures.ThreadPoolExecutor(max_workers\u003dself.threads) as executor:"},{"line_number":96,"context_line":"            try:"},{"line_number":97,"context_line":"                while True:"},{"line_number":98,"context_line":"                    session \u003d db_api.get_session()"},{"line_number":99,"context_line":"                    LOG.info(_LI(\"Starting amphora cert rotation\"))"},{"line_number":100,"context_line":"                    rotation_count \u003d 0"}],"source_content_type":"text/x-python","patch_set":5,"id":"fa1b9901_3fdd3ae0","line":97,"in_reply_to":"fa1b9901_cd9017f0","updated":"2015-08-25 21:35:00.000000000","message":"This is correct in my view.  This while loop will go until no more amphora are \"popped\" from the database to have the cert updated.  Each amphora that needs updating is added to the thread queue with submit.  The one-by-one nature of this loop assures that other controllers won\u0027t try to rotate the cert on the same amphora.  There is no need to sleep here as it is queuing the work up for the thread pool workers.","commit_id":"fee2d3a0f36d2abcb8a7f4d4079cfd790f9b0f78"},{"author":{"_account_id":15226,"name":"Bharath M","email":"bharath.stacker@gmail.com","username":"bharath"},"change_message_id":"e175eccfa3e3bdd36a3fc6393858f0e275bdeb33","unresolved":false,"context_lines":[{"line_number":94,"context_line":""},{"line_number":95,"context_line":"        with futures.ThreadPoolExecutor(max_workers\u003dself.threads) as executor:"},{"line_number":96,"context_line":"            try:"},{"line_number":97,"context_line":"                while True:"},{"line_number":98,"context_line":"                    session \u003d db_api.get_session()"},{"line_number":99,"context_line":"                    LOG.info(_LI(\"Starting amphora cert rotation\"))"},{"line_number":100,"context_line":"                    rotation_count \u003d 0"}],"source_content_type":"text/x-python","patch_set":7,"id":"da20952f_9b5e2b11","line":97,"updated":"2015-08-27 17:40:33.000000000","message":"If you want the thread to invoke this method at cert_interval timeouts, you have two options:\n\n1) (Suggested implementation) Remove this \"while True\" such that after L111, the control is returned to the thread target, which sleeps for the interval time before invoking this method again.\n\nOR\n\n2) (Not a good implementation) You can introduce the cert_interval sleep inside this loop. In that case, you don\u0027t need to spin a new thread for this process.","commit_id":"a0316b696a10d66dbb1dd68bb0c30ecabb317fd8"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"11cc45a972e9c7e585a3a1ba12b2812aea257566","unresolved":false,"context_lines":[{"line_number":108,"context_line":"                    LOG.info(_LI(\"Cert expired amphora\u0027s id is: %s\") % amp.id)"},{"line_number":109,"context_line":"                    executor.submit(self.cw.amphora_cert_rotation, amp.id)"},{"line_number":110,"context_line":"                if rotation_count \u003e 0:"},{"line_number":111,"context_line":"                    LOG.info(_LI(\"Cert rotation over %s amphora\") %"},{"line_number":112,"context_line":"                             rotation_count)"},{"line_number":113,"context_line":"            finally:"},{"line_number":114,"context_line":"                executor.shutdown(wait\u003dTrue)"}],"source_content_type":"text/x-python","patch_set":15,"id":"ba15a1d1_b210305b","line":111,"updated":"2015-09-19 01:14:11.000000000","message":"Reword:\n\"Rotated certificates for %s ampohra\"","commit_id":"6e73ec826cab50571fc7f87856ff1e06830e8ce6"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"6fc33d4a291337bcdc2babb1c05ac60850ef866d","unresolved":false,"context_lines":[{"line_number":96,"context_line":"                session \u003d db_api.get_session()"},{"line_number":97,"context_line":"                rotation_count \u003d 0"},{"line_number":98,"context_line":"                while True:"},{"line_number":99,"context_line":"                    LOG.info(_LI(\"Starting amphora cert rotation\"))"},{"line_number":100,"context_line":"                    amp \u003d amp_repo.get_cert_expiring_amphora(session)"},{"line_number":101,"context_line":"                    if not amp:"},{"line_number":102,"context_line":"                        break"}],"source_content_type":"text/x-python","patch_set":21,"id":"9a1a9d01_5ee458aa","line":99,"updated":"2015-10-01 00:26:57.000000000","message":"I would remove this log entry as it seems duplicate to the one below.","commit_id":"6ed6a21021da64a362c281874327f3936ff5b89c"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"6fc33d4a291337bcdc2babb1c05ac60850ef866d","unresolved":false,"context_lines":[{"line_number":101,"context_line":"                    if not amp:"},{"line_number":102,"context_line":"                        break"},{"line_number":103,"context_line":"                    rotation_count +\u003d 1"},{"line_number":104,"context_line":"                    LOG.info(_LI(\"Cert expired amphora\u0027s id is: %s\") % amp.id)"},{"line_number":105,"context_line":"                    executor.submit(self.cw.amphora_cert_rotation, amp.id)"},{"line_number":106,"context_line":"                if rotation_count \u003e 0:"},{"line_number":107,"context_line":"                    LOG.info(_LI(\"Rotated certificates for %s ampohra\") %"}],"source_content_type":"text/x-python","patch_set":21,"id":"9a1a9d01_1e98201b","line":104,"updated":"2015-10-01 00:26:57.000000000","message":"This should be debug level","commit_id":"6ed6a21021da64a362c281874327f3936ff5b89c"},{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"07fa8246713f5e2ab5d630e8321b2195cd91f818","unresolved":false,"context_lines":[{"line_number":93,"context_line":""},{"line_number":94,"context_line":"        with futures.ThreadPoolExecutor(max_workers\u003dself.threads) as executor:"},{"line_number":95,"context_line":"            try:"},{"line_number":96,"context_line":"                session \u003d db_api.get_session()"},{"line_number":97,"context_line":"                rotation_count \u003d 0"},{"line_number":98,"context_line":"                while True:"},{"line_number":99,"context_line":"                    amp \u003d amp_repo.get_cert_expiring_amphora(session)"}],"source_content_type":"text/x-python","patch_set":48,"id":"ba8a016a_f5fa8042","line":96,"updated":"2015-11-18 15:46:29.000000000","message":"Do you need to do a session commit anywhere here, or is that taken care of in sub-functions?","commit_id":"f952248b9b0ca32f30e29b3df668d8c4f78b0e59"},{"author":{"_account_id":11685,"name":"Stephen Balukoff","email":"stephen@balukoff.com","username":"sbalukoff"},"change_message_id":"e430a0dab69edb248bb6675ad42a8fa5d965a5da","unresolved":false,"context_lines":[{"line_number":88,"context_line":"        self.cw \u003d cw.ControllerWorker()"},{"line_number":89,"context_line":""},{"line_number":90,"context_line":"    def rotate(self):"},{"line_number":91,"context_line":"        \"\"\"Check the amphora db table for ones with expired cert.\"\"\""},{"line_number":92,"context_line":"        amp_repo \u003d repo.AmphoraRepository()"},{"line_number":93,"context_line":""},{"line_number":94,"context_line":"        with futures.ThreadPoolExecutor(max_workers\u003dself.threads) as executor:"}],"source_content_type":"text/x-python","patch_set":49,"id":"ba8a016a_7c269bbb","line":91,"updated":"2015-11-23 23:26:43.000000000","message":"Nit: awkward English.  Maybe instead: \"Check the amphora db table for expiring auth certs\"","commit_id":"f283d52139bfffa09e3c35a7f5406bb6c90e57f4"}],"octavia/controller/worker/controller_worker.py":[{"author":{"_account_id":10850,"name":"German Eichberger","email":"german.eichberger@gmail.com","username":"german"},"change_message_id":"312be15b25ff86e0a6782b3302205509746bb16f","unresolved":false,"context_lines":[{"line_number":471,"context_line":"                                     id\u003damphora_id)"},{"line_number":472,"context_line":""},{"line_number":473,"context_line":"        certrotation_amphora_tf \u003d self._taskflow_load("},{"line_number":474,"context_line":"            self._amphora_flows.get_create_amphora_flow(),"},{"line_number":475,"context_line":"            store\u003d{constants.AMPHORA: amp})"},{"line_number":476,"context_line":""},{"line_number":477,"context_line":"        with tf_logging.DynamicLoggingListener(certrotation_amphora_tf,"}],"source_content_type":"text/x-python","patch_set":3,"id":"fa1b9901_6b193b22","line":474,"updated":"2015-08-21 22:56:28.000000000","message":"cert rotation flow instead of create_amphora_flow","commit_id":"143353125b8cdd9c0a6bf8fe590db6b814576b1e"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"98e1d6edd72056172848e634fa35a6296ca00ad2","unresolved":false,"context_lines":[{"line_number":471,"context_line":"                                     id\u003damphora_id)"},{"line_number":472,"context_line":""},{"line_number":473,"context_line":"        certrotation_amphora_tf \u003d self._taskflow_load("},{"line_number":474,"context_line":"            self._amphora_flows.get_create_amphora_flow(),"},{"line_number":475,"context_line":"            store\u003d{constants.AMPHORA: amp})"},{"line_number":476,"context_line":""},{"line_number":477,"context_line":"        with tf_logging.DynamicLoggingListener(certrotation_amphora_tf,"}],"source_content_type":"text/x-python","patch_set":3,"id":"fa1b9901_d36fa0fa","line":474,"in_reply_to":"fa1b9901_6b193b22","updated":"2015-08-24 17:29:17.000000000","message":"have added a new flow named as cert_rotate_amphora_flow()","commit_id":"143353125b8cdd9c0a6bf8fe590db6b814576b1e"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"281dede09aacfdc9b6e20bcc81be0640466ab9cf","unresolved":false,"context_lines":[{"line_number":473,"context_line":"        certrotation_amphora_tf \u003d self._taskflow_load("},{"line_number":474,"context_line":"            self._amphora_flows.get_create_amphora_flow(),"},{"line_number":475,"context_line":"            store\u003d{constants.AMPHORA: amp})"},{"line_number":476,"context_line":""},{"line_number":477,"context_line":"        with tf_logging.DynamicLoggingListener(certrotation_amphora_tf,"},{"line_number":478,"context_line":"                                               log\u003dLOG):"},{"line_number":479,"context_line":"            certrotation_amphora_tf.run()"}],"source_content_type":"text/x-python","patch_set":3,"id":"fa1b9901_1cb9e7ec","line":476,"updated":"2015-08-22 00:43:19.000000000","message":"Yeah, the flow to update the cert is missing.\nDon\u0027t forget to update the busy flag in the DB to false after the rotation is complete.","commit_id":"143353125b8cdd9c0a6bf8fe590db6b814576b1e"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"98e1d6edd72056172848e634fa35a6296ca00ad2","unresolved":false,"context_lines":[{"line_number":473,"context_line":"        certrotation_amphora_tf \u003d self._taskflow_load("},{"line_number":474,"context_line":"            self._amphora_flows.get_create_amphora_flow(),"},{"line_number":475,"context_line":"            store\u003d{constants.AMPHORA: amp})"},{"line_number":476,"context_line":""},{"line_number":477,"context_line":"        with tf_logging.DynamicLoggingListener(certrotation_amphora_tf,"},{"line_number":478,"context_line":"                                               log\u003dLOG):"},{"line_number":479,"context_line":"            certrotation_amphora_tf.run()"}],"source_content_type":"text/x-python","patch_set":3,"id":"fa1b9901_966d969b","line":476,"in_reply_to":"fa1b9901_1cb9e7ec","updated":"2015-08-24 17:29:17.000000000","message":"will add  self._amphora_repo.update(db_apis.get_session(),amphora_id,\n                                  cert_busy\u003dFalse) \nhere","commit_id":"143353125b8cdd9c0a6bf8fe590db6b814576b1e"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"11cc45a972e9c7e585a3a1ba12b2812aea257566","unresolved":false,"context_lines":[{"line_number":495,"context_line":"        certrotation_amphora_tf \u003d self._taskflow_load("},{"line_number":496,"context_line":"            self._amphora_flows.cert_rotate_amphora_flow(),"},{"line_number":497,"context_line":"            store\u003d{constants.AMPHORA: amp,"},{"line_number":498,"context_line":"                   constants.AMPHORA_ID: amp.id})"},{"line_number":499,"context_line":""},{"line_number":500,"context_line":"        with tf_logging.DynamicLoggingListener(certrotation_amphora_tf,"},{"line_number":501,"context_line":"                                               log\u003dLOG):"}],"source_content_type":"text/x-python","patch_set":15,"id":"ba15a1d1_0d51c10e","line":498,"updated":"2015-09-19 01:14:11.000000000","message":"This is a duplicate as if you have the amphora you have amphora.id.\nCan we remove the amp.id storage?","commit_id":"6e73ec826cab50571fc7f87856ff1e06830e8ce6"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"6fc33d4a291337bcdc2babb1c05ac60850ef866d","unresolved":false,"context_lines":[{"line_number":495,"context_line":"        certrotation_amphora_tf \u003d self._taskflow_load("},{"line_number":496,"context_line":"            self._amphora_flows.cert_rotate_amphora_flow(),"},{"line_number":497,"context_line":"            store\u003d{constants.AMPHORA: amp,"},{"line_number":498,"context_line":"                   constants.AMPHORA_ID: amp.id})"},{"line_number":499,"context_line":""},{"line_number":500,"context_line":"        with tf_logging.DynamicLoggingListener(certrotation_amphora_tf,"},{"line_number":501,"context_line":"                                               log\u003dLOG):"}],"source_content_type":"text/x-python","patch_set":21,"id":"9a1a9d01_3ec2c4e9","line":498,"updated":"2015-10-01 00:26:57.000000000","message":"I thought we were going to eliminate the need to store both of these.","commit_id":"6ed6a21021da64a362c281874327f3936ff5b89c"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"674c6364553fe2a02d24db2f27ad214b8160bee1","unresolved":false,"context_lines":[{"line_number":488,"context_line":"                                               log\u003dLOG):"},{"line_number":489,"context_line":"            failover_amphora_tf.run()"},{"line_number":490,"context_line":""},{"line_number":491,"context_line":"    def amphora_cert_rotation(self, amphora_id):"},{"line_number":492,"context_line":"        \"\"\"Perform cert rotation for an amphora."},{"line_number":493,"context_line":""},{"line_number":494,"context_line":"        :param amphora_id: ID for amphora to rotate"}],"source_content_type":"text/x-python","patch_set":37,"id":"da85f559_0bcc5134","line":491,"updated":"2015-11-07 01:19:31.000000000","message":"Missing unit tests","commit_id":"9ac96425f0cc0a72b120527af4df2c5c48a4ec5b"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"9230d4bf02be0e6320c81fb2d1930e2a72016f1e","unresolved":false,"context_lines":[{"line_number":488,"context_line":"                                               log\u003dLOG):"},{"line_number":489,"context_line":"            failover_amphora_tf.run()"},{"line_number":490,"context_line":""},{"line_number":491,"context_line":"    def amphora_cert_rotation(self, amphora_id):"},{"line_number":492,"context_line":"        \"\"\"Perform cert rotation for an amphora."},{"line_number":493,"context_line":""},{"line_number":494,"context_line":"        :param amphora_id: ID for amphora to rotate"}],"source_content_type":"text/x-python","patch_set":37,"id":"da85f559_9d428b3d","line":491,"in_reply_to":"da85f559_0bcc5134","updated":"2015-11-09 18:03:58.000000000","message":"https://review.openstack.org/#/c/215359/37/octavia/tests/unit/controller/worker/test_controller_worker.py","commit_id":"9ac96425f0cc0a72b120527af4df2c5c48a4ec5b"},{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"07fa8246713f5e2ab5d630e8321b2195cd91f818","unresolved":false,"context_lines":[{"line_number":496,"context_line":"        :raises AmphoraNotFound: The referenced amphora was not found"},{"line_number":497,"context_line":"        \"\"\""},{"line_number":498,"context_line":""},{"line_number":499,"context_line":"        amp \u003d self._amphora_repo.get(db_apis.get_session(),"},{"line_number":500,"context_line":"                                     id\u003damphora_id)"},{"line_number":501,"context_line":"        LOG.info(_LI(\"Start amphora cert rotation, amphora\u0027s id is: %s\")"},{"line_number":502,"context_line":"                 % amp.id)"}],"source_content_type":"text/x-python","patch_set":48,"id":"ba8a016a_7b6c41d0","line":499,"updated":"2015-11-18 15:46:29.000000000","message":"I forget, do we need to use context managers / commit sessions manually, or does oslo or our db code do some magic wrapping for us?","commit_id":"f952248b9b0ca32f30e29b3df668d8c4f78b0e59"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"b5f15f59499d52ae3a2adbfa0faa46117b0d67e8","unresolved":false,"context_lines":[{"line_number":496,"context_line":"        :raises AmphoraNotFound: The referenced amphora was not found"},{"line_number":497,"context_line":"        \"\"\""},{"line_number":498,"context_line":""},{"line_number":499,"context_line":"        amp \u003d self._amphora_repo.get(db_apis.get_session(),"},{"line_number":500,"context_line":"                                     id\u003damphora_id)"},{"line_number":501,"context_line":"        LOG.info(_LI(\"Start amphora cert rotation, amphora\u0027s id is: %s\")"},{"line_number":502,"context_line":"                 % amp.id)"}],"source_content_type":"text/x-python","patch_set":48,"id":"ba8a016a_039e9c06","line":499,"in_reply_to":"ba8a016a_7b6c41d0","updated":"2015-11-19 21:09:44.000000000","message":"it will be taken care automatically.","commit_id":"f952248b9b0ca32f30e29b3df668d8c4f78b0e59"}],"octavia/controller/worker/flows/amphora_flows.py":[{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"281dede09aacfdc9b6e20bcc81be0640466ab9cf","unresolved":false,"context_lines":[{"line_number":55,"context_line":""},{"line_number":56,"context_line":"            create_amphora_flow.add("},{"line_number":57,"context_line":"                database_tasks.UpdateAmphoraDBCertExpiration("},{"line_number":58,"context_line":"                    provides\u003dconstants.SERVER_PEM))"},{"line_number":59,"context_line":""},{"line_number":60,"context_line":"            create_amphora_flow.add(compute_tasks.CertComputeCreate("},{"line_number":61,"context_line":"                requires\u003d(constants.AMPHORA_ID, constants.SERVER_PEM),"}],"source_content_type":"text/x-python","patch_set":3,"id":"fa1b9901_31309407","line":58,"updated":"2015-08-22 00:43:19.000000000","message":"Why does this provide SERVER_PEM?\nI don\u0027t think it needs to return anything.","commit_id":"143353125b8cdd9c0a6bf8fe590db6b814576b1e"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"98e1d6edd72056172848e634fa35a6296ca00ad2","unresolved":false,"context_lines":[{"line_number":55,"context_line":""},{"line_number":56,"context_line":"            create_amphora_flow.add("},{"line_number":57,"context_line":"                database_tasks.UpdateAmphoraDBCertExpiration("},{"line_number":58,"context_line":"                    provides\u003dconstants.SERVER_PEM))"},{"line_number":59,"context_line":""},{"line_number":60,"context_line":"            create_amphora_flow.add(compute_tasks.CertComputeCreate("},{"line_number":61,"context_line":"                requires\u003d(constants.AMPHORA_ID, constants.SERVER_PEM),"}],"source_content_type":"text/x-python","patch_set":3,"id":"fa1b9901_f62bb231","line":58,"in_reply_to":"fa1b9901_31309407","updated":"2015-08-24 17:29:17.000000000","message":"good point, this is a mistake, it requires SERVER_PEM instead.","commit_id":"143353125b8cdd9c0a6bf8fe590db6b814576b1e"},{"author":{"_account_id":10850,"name":"German Eichberger","email":"german.eichberger@gmail.com","username":"german"},"change_message_id":"2a76645c17944bc4210587c0f07eeda9af99d076","unresolved":false,"context_lines":[{"line_number":175,"context_line":"        rotated_amphora_flow \u003d linear_flow.Flow("},{"line_number":176,"context_line":"            constants.CERT_ROTATE_AMPHORA_FLOW)"},{"line_number":177,"context_line":""},{"line_number":178,"context_line":"        if self.REST_AMPHORA_DRIVER:"},{"line_number":179,"context_line":"            # create a new certificate, the returned value is the newly created"},{"line_number":180,"context_line":"            # certificate"},{"line_number":181,"context_line":"            rotated_amphora_flow.add(cert_task.GenerateServerPEMTask("}],"source_content_type":"text/x-python","patch_set":4,"id":"fa1b9901_8bca444e","line":178,"updated":"2015-08-24 21:40:23.000000000","message":"this is only relevant if it\u0027s the REST driver -- so the if is superfluous","commit_id":"f531a1a779ea8992b2f02db0a98780aa802d659f"},{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"4e992ebf56ec6cbd9378d7a4081975068f17d408","unresolved":false,"context_lines":[{"line_number":175,"context_line":"        rotated_amphora_flow \u003d linear_flow.Flow("},{"line_number":176,"context_line":"            constants.CERT_ROTATE_AMPHORA_FLOW)"},{"line_number":177,"context_line":""},{"line_number":178,"context_line":"        if self.REST_AMPHORA_DRIVER:"},{"line_number":179,"context_line":"            # create a new certificate, the returned value is the newly created"},{"line_number":180,"context_line":"            # certificate"},{"line_number":181,"context_line":"            rotated_amphora_flow.add(cert_task.GenerateServerPEMTask("}],"source_content_type":"text/x-python","patch_set":4,"id":"fa1b9901_9e5a8129","line":178,"in_reply_to":"fa1b9901_41e72b40","updated":"2015-08-24 23:30:52.000000000","message":"German is correct, but I wonder if we are fine with putting driver-specific flows in this general \"worker/flows/amphora_flows.py\" file... It may be a little late to be asking that though. :P","commit_id":"f531a1a779ea8992b2f02db0a98780aa802d659f"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"b320260071d488d601b4d4ec629bb825c7bc734a","unresolved":false,"context_lines":[{"line_number":175,"context_line":"        rotated_amphora_flow \u003d linear_flow.Flow("},{"line_number":176,"context_line":"            constants.CERT_ROTATE_AMPHORA_FLOW)"},{"line_number":177,"context_line":""},{"line_number":178,"context_line":"        if self.REST_AMPHORA_DRIVER:"},{"line_number":179,"context_line":"            # create a new certificate, the returned value is the newly created"},{"line_number":180,"context_line":"            # certificate"},{"line_number":181,"context_line":"            rotated_amphora_flow.add(cert_task.GenerateServerPEMTask("}],"source_content_type":"text/x-python","patch_set":4,"id":"fa1b9901_41e72b40","line":178,"in_reply_to":"fa1b9901_8bca444e","updated":"2015-08-24 22:25:48.000000000","message":"will delete this if statement","commit_id":"f531a1a779ea8992b2f02db0a98780aa802d659f"},{"author":{"_account_id":10850,"name":"German Eichberger","email":"german.eichberger@gmail.com","username":"german"},"change_message_id":"2a76645c17944bc4210587c0f07eeda9af99d076","unresolved":false,"context_lines":[{"line_number":180,"context_line":"            # certificate"},{"line_number":181,"context_line":"            rotated_amphora_flow.add(cert_task.GenerateServerPEMTask("},{"line_number":182,"context_line":"                provides\u003dconstants.SERVER_PEM))"},{"line_number":183,"context_line":"            # update the newly created certificate info to amphora"},{"line_number":184,"context_line":"            rotated_amphora_flow.add("},{"line_number":185,"context_line":"                database_tasks.UpdateAmphoraDBCertExpiration("},{"line_number":186,"context_line":"                    requires\u003d(constants.AMPHORA_ID, constants.SERVER_PEM)))"}],"source_content_type":"text/x-python","patch_set":4,"id":"fa1b9901_abcce861","line":183,"updated":"2015-08-24 21:40:23.000000000","message":"that step is missing. You need to write another amphora task and  update the REST client to support the update","commit_id":"f531a1a779ea8992b2f02db0a98780aa802d659f"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"b320260071d488d601b4d4ec629bb825c7bc734a","unresolved":false,"context_lines":[{"line_number":180,"context_line":"            # certificate"},{"line_number":181,"context_line":"            rotated_amphora_flow.add(cert_task.GenerateServerPEMTask("},{"line_number":182,"context_line":"                provides\u003dconstants.SERVER_PEM))"},{"line_number":183,"context_line":"            # update the newly created certificate info to amphora"},{"line_number":184,"context_line":"            rotated_amphora_flow.add("},{"line_number":185,"context_line":"                database_tasks.UpdateAmphoraDBCertExpiration("},{"line_number":186,"context_line":"                    requires\u003d(constants.AMPHORA_ID, constants.SERVER_PEM)))"}],"source_content_type":"text/x-python","patch_set":4,"id":"fa1b9901_c1c9fbad","line":183,"in_reply_to":"fa1b9901_abcce861","updated":"2015-08-24 22:25:48.000000000","message":"hmm, need to think a bit on how to implement","commit_id":"f531a1a779ea8992b2f02db0a98780aa802d659f"},{"author":{"_account_id":10850,"name":"German Eichberger","email":"german.eichberger@gmail.com","username":"german"},"change_message_id":"2a76645c17944bc4210587c0f07eeda9af99d076","unresolved":false,"context_lines":[{"line_number":185,"context_line":"                database_tasks.UpdateAmphoraDBCertExpiration("},{"line_number":186,"context_line":"                    requires\u003d(constants.AMPHORA_ID, constants.SERVER_PEM)))"},{"line_number":187,"context_line":""},{"line_number":188,"context_line":"        wait_flow \u003d linear_flow.Flow(\u0027wait_for_amphora\u0027,"},{"line_number":189,"context_line":"                                     retry\u003dretry.Times(CONF."},{"line_number":190,"context_line":"                                                       controller_worker."},{"line_number":191,"context_line":"                                                       amp_active_retries))"}],"source_content_type":"text/x-python","patch_set":4,"id":"fa1b9901_4bf2ec9b","line":188,"updated":"2015-08-24 21:40:23.000000000","message":"I am confused about the task below - the amphora is still ready we are just updating the cert. So it is still a fine amphora... no need for all those steps","commit_id":"f531a1a779ea8992b2f02db0a98780aa802d659f"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"b320260071d488d601b4d4ec629bb825c7bc734a","unresolved":false,"context_lines":[{"line_number":185,"context_line":"                database_tasks.UpdateAmphoraDBCertExpiration("},{"line_number":186,"context_line":"                    requires\u003d(constants.AMPHORA_ID, constants.SERVER_PEM)))"},{"line_number":187,"context_line":""},{"line_number":188,"context_line":"        wait_flow \u003d linear_flow.Flow(\u0027wait_for_amphora\u0027,"},{"line_number":189,"context_line":"                                     retry\u003dretry.Times(CONF."},{"line_number":190,"context_line":"                                                       controller_worker."},{"line_number":191,"context_line":"                                                       amp_active_retries))"}],"source_content_type":"text/x-python","patch_set":4,"id":"fa1b9901_81c46392","line":188,"in_reply_to":"fa1b9901_4bf2ec9b","updated":"2015-08-24 22:25:48.000000000","message":"so will delete all of the steps below except the last line","commit_id":"f531a1a779ea8992b2f02db0a98780aa802d659f"},{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"4e992ebf56ec6cbd9378d7a4081975068f17d408","unresolved":false,"context_lines":[{"line_number":185,"context_line":"                database_tasks.UpdateAmphoraDBCertExpiration("},{"line_number":186,"context_line":"                    requires\u003d(constants.AMPHORA_ID, constants.SERVER_PEM)))"},{"line_number":187,"context_line":""},{"line_number":188,"context_line":"        wait_flow \u003d linear_flow.Flow(\u0027wait_for_amphora\u0027,"},{"line_number":189,"context_line":"                                     retry\u003dretry.Times(CONF."},{"line_number":190,"context_line":"                                                       controller_worker."},{"line_number":191,"context_line":"                                                       amp_active_retries))"}],"source_content_type":"text/x-python","patch_set":4,"id":"fa1b9901_5e3629e8","line":188,"in_reply_to":"fa1b9901_81c46392","updated":"2015-08-24 23:30:52.000000000","message":"Yeah I don\u0027t think we need \"wait_flow\" at all, do we?","commit_id":"f531a1a779ea8992b2f02db0a98780aa802d659f"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"11cc45a972e9c7e585a3a1ba12b2812aea257566","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":"import logging"},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"from oslo_config import cfg"},{"line_number":18,"context_line":"from taskflow.patterns import linear_flow"}],"source_content_type":"text/x-python","patch_set":15,"id":"ba15a1d1_ad6c55d1","line":15,"updated":"2015-09-19 01:14:11.000000000","message":"This should be oslo_log I think.\n\nThis is also a problem in other parts of the code, but we can start here.","commit_id":"6e73ec826cab50571fc7f87856ff1e06830e8ce6"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"11cc45a972e9c7e585a3a1ba12b2812aea257566","unresolved":false,"context_lines":[{"line_number":265,"context_line":"         2. Upload the cert to amphora"},{"line_number":266,"context_line":"         3. Save new expiration date in DB for the amphora"},{"line_number":267,"context_line":""},{"line_number":268,"context_line":"        :returns: The flow for updating an amphora"},{"line_number":269,"context_line":"        \"\"\""},{"line_number":270,"context_line":"        rotated_amphora_flow \u003d linear_flow.Flow("},{"line_number":271,"context_line":"            constants.CERT_ROTATE_AMPHORA_FLOW)"}],"source_content_type":"text/x-python","patch_set":15,"id":"ba15a1d1_6dae3de9","line":268,"updated":"2015-09-19 01:14:11.000000000","message":"Great docstring.  Very clear.","commit_id":"6e73ec826cab50571fc7f87856ff1e06830e8ce6"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"11cc45a972e9c7e585a3a1ba12b2812aea257566","unresolved":false,"context_lines":[{"line_number":272,"context_line":""},{"line_number":273,"context_line":"        # create a new certificate, the returned value is the newly created"},{"line_number":274,"context_line":"        # certificate"},{"line_number":275,"context_line":"        LOG.debug(\"Create cert in cert rotate amphora flow\")"},{"line_number":276,"context_line":"        rotated_amphora_flow.add(cert_task.GenerateServerPEMTask("},{"line_number":277,"context_line":"            provides\u003dconstants.SERVER_PEM))"},{"line_number":278,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"ba15a1d1_ed800d4c","line":275,"updated":"2015-09-19 01:14:11.000000000","message":"We should move these logs into the actual task.\nHere they only get logged when the taskflow is created, not when the code is run.\nThe same with all of these log statements.","commit_id":"6e73ec826cab50571fc7f87856ff1e06830e8ce6"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"9744c64cad25cc1596edaa98148f8f5ff7d9389f","unresolved":false,"context_lines":[{"line_number":13,"context_line":"# under the License."},{"line_number":14,"context_line":"#"},{"line_number":15,"context_line":"from oslo_config import cfg"},{"line_number":16,"context_line":"from oslo_log import log"},{"line_number":17,"context_line":"from taskflow.patterns import linear_flow"},{"line_number":18,"context_line":"from taskflow import retry"},{"line_number":19,"context_line":""}],"source_content_type":"text/x-python","patch_set":34,"id":"da85f559_7748682e","line":16,"updated":"2015-11-07 00:54:48.000000000","message":"I don\u0027t think we need log here anymore.","commit_id":"31e78f127140339eacb753db3c4b3990f9f42537"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"9744c64cad25cc1596edaa98148f8f5ff7d9389f","unresolved":false,"context_lines":[{"line_number":25,"context_line":"from octavia.controller.worker.tasks import database_tasks"},{"line_number":26,"context_line":"from octavia.controller.worker.tasks import network_tasks"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"LOG \u003d log.getLogger(__name__)"},{"line_number":29,"context_line":"CONF \u003d cfg.CONF"},{"line_number":30,"context_line":"CONF.import_group(\u0027controller_worker\u0027, \u0027octavia.common.config\u0027)"},{"line_number":31,"context_line":""}],"source_content_type":"text/x-python","patch_set":34,"id":"da85f559_97406c09","line":28,"updated":"2015-11-07 00:54:48.000000000","message":"Same here.","commit_id":"31e78f127140339eacb753db3c4b3990f9f42537"},{"author":{"_account_id":8157,"name":"Bertrand LALLAU","email":"bertrand.lallau@gmail.com","username":"blallau"},"change_message_id":"5b6b41a64dd95d347abb75fde7a5c2c2099a83c5","unresolved":false,"context_lines":[{"line_number":13,"context_line":"# under the License."},{"line_number":14,"context_line":"#"},{"line_number":15,"context_line":"from oslo_config import cfg"},{"line_number":16,"context_line":"from oslo_log import log"},{"line_number":17,"context_line":"from taskflow.patterns import linear_flow"},{"line_number":18,"context_line":"from taskflow import retry"},{"line_number":19,"context_line":""}],"source_content_type":"text/x-python","patch_set":38,"id":"da85f559_90ab1b1d","line":16,"updated":"2015-11-10 16:55:29.000000000","message":"imported but unused","commit_id":"d099c9e4826fe1b54e357810bd5591e578bd73e4"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"83dfce2573f7767297eb3758fc65ce6a26397997","unresolved":false,"context_lines":[{"line_number":13,"context_line":"# under the License."},{"line_number":14,"context_line":"#"},{"line_number":15,"context_line":"from oslo_config import cfg"},{"line_number":16,"context_line":"from oslo_log import log"},{"line_number":17,"context_line":"from taskflow.patterns import linear_flow"},{"line_number":18,"context_line":"from taskflow import retry"},{"line_number":19,"context_line":""}],"source_content_type":"text/x-python","patch_set":38,"id":"da85f559_64283487","line":16,"in_reply_to":"da85f559_90ab1b1d","updated":"2015-11-10 18:13:04.000000000","message":"Done","commit_id":"d099c9e4826fe1b54e357810bd5591e578bd73e4"},{"author":{"_account_id":8157,"name":"Bertrand LALLAU","email":"bertrand.lallau@gmail.com","username":"blallau"},"change_message_id":"5b6b41a64dd95d347abb75fde7a5c2c2099a83c5","unresolved":false,"context_lines":[{"line_number":25,"context_line":"from octavia.controller.worker.tasks import database_tasks"},{"line_number":26,"context_line":"from octavia.controller.worker.tasks import network_tasks"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"LOG \u003d log.getLogger(__name__)"},{"line_number":29,"context_line":"CONF \u003d cfg.CONF"},{"line_number":30,"context_line":"CONF.import_group(\u0027controller_worker\u0027, \u0027octavia.common.config\u0027)"},{"line_number":31,"context_line":""}],"source_content_type":"text/x-python","patch_set":38,"id":"da85f559_d08a03bf","line":28,"updated":"2015-11-10 16:55:29.000000000","message":"LOG not used","commit_id":"d099c9e4826fe1b54e357810bd5591e578bd73e4"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"83dfce2573f7767297eb3758fc65ce6a26397997","unresolved":false,"context_lines":[{"line_number":25,"context_line":"from octavia.controller.worker.tasks import database_tasks"},{"line_number":26,"context_line":"from octavia.controller.worker.tasks import network_tasks"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"LOG \u003d log.getLogger(__name__)"},{"line_number":29,"context_line":"CONF \u003d cfg.CONF"},{"line_number":30,"context_line":"CONF.import_group(\u0027controller_worker\u0027, \u0027octavia.common.config\u0027)"},{"line_number":31,"context_line":""}],"source_content_type":"text/x-python","patch_set":38,"id":"da85f559_842d1897","line":28,"in_reply_to":"da85f559_d08a03bf","updated":"2015-11-10 18:13:04.000000000","message":"Done","commit_id":"d099c9e4826fe1b54e357810bd5591e578bd73e4"},{"author":{"_account_id":8157,"name":"Bertrand LALLAU","email":"bertrand.lallau@gmail.com","username":"blallau"},"change_message_id":"5b6b41a64dd95d347abb75fde7a5c2c2099a83c5","unresolved":false,"context_lines":[{"line_number":261,"context_line":""},{"line_number":262,"context_line":"         1. Create a new certificate"},{"line_number":263,"context_line":"         2. Upload the cert to amphora"},{"line_number":264,"context_line":"         3. Save new expiration date in DB for the amphora"},{"line_number":265,"context_line":""},{"line_number":266,"context_line":"        :returns: The flow for updating an amphora"},{"line_number":267,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":38,"id":"da85f559_d00d233f","line":264,"updated":"2015-11-10 16:55:29.000000000","message":"Steps not up to date","commit_id":"d099c9e4826fe1b54e357810bd5591e578bd73e4"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"83dfce2573f7767297eb3758fc65ce6a26397997","unresolved":false,"context_lines":[{"line_number":261,"context_line":""},{"line_number":262,"context_line":"         1. Create a new certificate"},{"line_number":263,"context_line":"         2. Upload the cert to amphora"},{"line_number":264,"context_line":"         3. Save new expiration date in DB for the amphora"},{"line_number":265,"context_line":""},{"line_number":266,"context_line":"        :returns: The flow for updating an amphora"},{"line_number":267,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":38,"id":"da85f559_4423b0a7","line":264,"in_reply_to":"da85f559_d00d233f","updated":"2015-11-10 18:13:04.000000000","message":"Done","commit_id":"d099c9e4826fe1b54e357810bd5591e578bd73e4"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"9d284d669f6af7caad24731b2773d6d183aa9f91","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":""},{"line_number":16,"context_line":"from oslo_config import cfg"},{"line_number":17,"context_line":"from taskflow.patterns import linear_flow"},{"line_number":18,"context_line":"from taskflow import retry"}],"source_content_type":"text/x-python","patch_set":45,"id":"da85f559_f5dade16","side":"PARENT","line":15,"updated":"2015-11-13 17:57:08.000000000","message":"nit: This should go back in.","commit_id":"0878c6b81b67e4a11f5c445526a26550719373fd"},{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"07fa8246713f5e2ab5d630e8321b2195cd91f818","unresolved":false,"context_lines":[{"line_number":55,"context_line":"            create_amphora_flow.add("},{"line_number":56,"context_line":"                database_tasks.UpdateAmphoraDBCertExpiration("},{"line_number":57,"context_line":"                    requires\u003d(constants.AMPHORA_ID, constants.SERVER_PEM)))"},{"line_number":58,"context_line":""},{"line_number":59,"context_line":"            create_amphora_flow.add(compute_tasks.CertComputeCreate("},{"line_number":60,"context_line":"                requires\u003d(constants.AMPHORA_ID, constants.SERVER_PEM),"},{"line_number":61,"context_line":"                provides\u003dconstants.COMPUTE_ID))"}],"source_content_type":"text/x-python","patch_set":48,"id":"ba8a016a_5bc4dd8f","line":58,"updated":"2015-11-18 15:46:29.000000000","message":"Do these flows also need to do \"UpdateAmphoraCertBusyToFalse\"?","commit_id":"f952248b9b0ca32f30e29b3df668d8c4f78b0e59"},{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"94b2f2d46f06aff49eef6b9a2456d6ba8c327f59","unresolved":false,"context_lines":[{"line_number":55,"context_line":"            create_amphora_flow.add("},{"line_number":56,"context_line":"                database_tasks.UpdateAmphoraDBCertExpiration("},{"line_number":57,"context_line":"                    requires\u003d(constants.AMPHORA_ID, constants.SERVER_PEM)))"},{"line_number":58,"context_line":""},{"line_number":59,"context_line":"            create_amphora_flow.add(compute_tasks.CertComputeCreate("},{"line_number":60,"context_line":"                requires\u003d(constants.AMPHORA_ID, constants.SERVER_PEM),"},{"line_number":61,"context_line":"                provides\u003dconstants.COMPUTE_ID))"}],"source_content_type":"text/x-python","patch_set":48,"id":"ba8a016a_815ad628","line":58,"in_reply_to":"ba8a016a_5bc4dd8f","updated":"2015-11-18 16:01:58.000000000","message":"Err, I meant to remove this, as I am fairly certain I see why they do not need this (because of where busy is actually set).","commit_id":"f952248b9b0ca32f30e29b3df668d8c4f78b0e59"}],"octavia/controller/worker/tasks/amphora_driver_tasks.py":[{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"11cc45a972e9c7e585a3a1ba12b2812aea257566","unresolved":false,"context_lines":[{"line_number":242,"context_line":""},{"line_number":243,"context_line":""},{"line_number":244,"context_line":"class AmphoraCertUpload(BaseAmphoraTask):"},{"line_number":245,"context_line":"    \"\"\"Update the REST client to support the cert update.\"\"\""},{"line_number":246,"context_line":""},{"line_number":247,"context_line":"    def execute(self, amphora, server_pem):"},{"line_number":248,"context_line":"        \"\"\"Execute cert_update_amphora routine.\"\"\""}],"source_content_type":"text/x-python","patch_set":15,"id":"ba15a1d1_0ded4125","line":245,"updated":"2015-09-19 01:14:11.000000000","message":"Re-word:\nUpload a certificate to the amphora","commit_id":"6e73ec826cab50571fc7f87856ff1e06830e8ce6"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"11cc45a972e9c7e585a3a1ba12b2812aea257566","unresolved":false,"context_lines":[{"line_number":247,"context_line":"    def execute(self, amphora, server_pem):"},{"line_number":248,"context_line":"        \"\"\"Execute cert_update_amphora routine.\"\"\""},{"line_number":249,"context_line":"        self.amphora_driver.upload_cert_amp(amphora, server_pem)"},{"line_number":250,"context_line":"        LOG.debug(\"Upload cert for amphora.\")"}],"source_content_type":"text/x-python","patch_set":15,"id":"ba15a1d1_2d8fe576","line":250,"updated":"2015-09-19 01:14:11.000000000","message":"Since this is after the call, we should say \"Uploaded\" instead of \"Upload\"","commit_id":"6e73ec826cab50571fc7f87856ff1e06830e8ce6"}],"octavia/controller/worker/tasks/database_tasks.py":[{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"281dede09aacfdc9b6e20bcc81be0640466ab9cf","unresolved":false,"context_lines":[{"line_number":466,"context_line":""},{"line_number":467,"context_line":"class UpdateAmphoraDBCertExpiration(BaseDatabaseTask):"},{"line_number":468,"context_line":"    \"\"\"Get the expiration date from cert file, which is pem format.\"\"\""},{"line_number":469,"context_line":"    def execute(self, amphora_id, server_pem):"},{"line_number":470,"context_line":"        cert_expiration \u003d cert_parser.get_cert_expiration(server_pem)"},{"line_number":471,"context_line":"        self.amphora_repo.update(db_apis.get_session(), amphora_id,"},{"line_number":472,"context_line":"                                 cert_expiration\u003dcert_expiration)"}],"source_content_type":"text/x-python","patch_set":3,"id":"fa1b9901_d1083830","line":469,"updated":"2015-08-22 00:43:19.000000000","message":"Needs a revert I think.","commit_id":"143353125b8cdd9c0a6bf8fe590db6b814576b1e"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"98e1d6edd72056172848e634fa35a6296ca00ad2","unresolved":false,"context_lines":[{"line_number":466,"context_line":""},{"line_number":467,"context_line":"class UpdateAmphoraDBCertExpiration(BaseDatabaseTask):"},{"line_number":468,"context_line":"    \"\"\"Get the expiration date from cert file, which is pem format.\"\"\""},{"line_number":469,"context_line":"    def execute(self, amphora_id, server_pem):"},{"line_number":470,"context_line":"        cert_expiration \u003d cert_parser.get_cert_expiration(server_pem)"},{"line_number":471,"context_line":"        self.amphora_repo.update(db_apis.get_session(), amphora_id,"},{"line_number":472,"context_line":"                                 cert_expiration\u003dcert_expiration)"}],"source_content_type":"text/x-python","patch_set":3,"id":"fa1b9901_1615069a","line":469,"in_reply_to":"fa1b9901_d1083830","updated":"2015-08-24 17:29:17.000000000","message":"i am not sure about if we need to add revert or not, i referred the 2 classes above UpdateAmphoraComputeId and UpdateAmphoraInfo, they do not have revert methods though.","commit_id":"143353125b8cdd9c0a6bf8fe590db6b814576b1e"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"281dede09aacfdc9b6e20bcc81be0640466ab9cf","unresolved":false,"context_lines":[{"line_number":470,"context_line":"        cert_expiration \u003d cert_parser.get_cert_expiration(server_pem)"},{"line_number":471,"context_line":"        self.amphora_repo.update(db_apis.get_session(), amphora_id,"},{"line_number":472,"context_line":"                                 cert_expiration\u003dcert_expiration)"},{"line_number":473,"context_line":"        return self.amphora_repo.get(db_apis.get_session(), id\u003damphora_id)"},{"line_number":474,"context_line":""},{"line_number":475,"context_line":""},{"line_number":476,"context_line":"class MarkLBActiveInDB(BaseDatabaseTask):"}],"source_content_type":"text/x-python","patch_set":3,"id":"fa1b9901_dc6ccfd2","line":473,"updated":"2015-08-22 00:43:19.000000000","message":"Why do we need to return an amphora object here?  I don\u0027 think we need to return anything.","commit_id":"143353125b8cdd9c0a6bf8fe590db6b814576b1e"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"98e1d6edd72056172848e634fa35a6296ca00ad2","unresolved":false,"context_lines":[{"line_number":470,"context_line":"        cert_expiration \u003d cert_parser.get_cert_expiration(server_pem)"},{"line_number":471,"context_line":"        self.amphora_repo.update(db_apis.get_session(), amphora_id,"},{"line_number":472,"context_line":"                                 cert_expiration\u003dcert_expiration)"},{"line_number":473,"context_line":"        return self.amphora_repo.get(db_apis.get_session(), id\u003damphora_id)"},{"line_number":474,"context_line":""},{"line_number":475,"context_line":""},{"line_number":476,"context_line":"class MarkLBActiveInDB(BaseDatabaseTask):"}],"source_content_type":"text/x-python","patch_set":3,"id":"fa1b9901_162e66fa","line":473,"in_reply_to":"fa1b9901_dc6ccfd2","updated":"2015-08-24 17:29:17.000000000","message":"yes, i agree","commit_id":"143353125b8cdd9c0a6bf8fe590db6b814576b1e"},{"author":{"_account_id":15226,"name":"Bharath M","email":"bharath.stacker@gmail.com","username":"bharath"},"change_message_id":"8de2638cf7903d66048d3adf757fb13117f5adc4","unresolved":false,"context_lines":[{"line_number":469,"context_line":"    \"\"\"Update the amphora expiration date with new cert file date.\"\"\""},{"line_number":470,"context_line":""},{"line_number":471,"context_line":"    def execute(self, amphora_id, server_pem):"},{"line_number":472,"context_line":"        LOG.info(_LI(\"Update cert expiratied amphora whose  id: %s\""},{"line_number":473,"context_line":"                     ) % amphora_id)"},{"line_number":474,"context_line":"        cert_expiration \u003d cert_parser.get_cert_expiration(server_pem)"},{"line_number":475,"context_line":"        self.amphora_repo.update(db_apis.get_session(), amphora_id,"}],"source_content_type":"text/x-python","patch_set":7,"id":"da20952f_04c5fc8c","line":472,"updated":"2015-08-27 08:23:54.000000000","message":"nit: expiratied? Is it \"Update cert expiry date of amphora ***\"?","commit_id":"a0316b696a10d66dbb1dd68bb0c30ecabb317fd8"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"11cc45a972e9c7e585a3a1ba12b2812aea257566","unresolved":false,"context_lines":[{"line_number":483,"context_line":"    \"\"\"Update the amphora expiration date with new cert file date.\"\"\""},{"line_number":484,"context_line":""},{"line_number":485,"context_line":"    def execute(self, amphora_id, server_pem):"},{"line_number":486,"context_line":"        LOG.info(_LI(\"Update cert expiry date of amphora  id: %s\""},{"line_number":487,"context_line":"                     ) % amphora_id)"},{"line_number":488,"context_line":"        cert_expiration \u003d cert_parser.get_cert_expiration(server_pem)"},{"line_number":489,"context_line":"        LOG.info(_LI(\"Certificate expiration date is %s sec\""}],"source_content_type":"text/x-python","patch_set":15,"id":"ba15a1d1_6ddcfd74","line":486,"updated":"2015-09-19 01:14:11.000000000","message":"We should clarify this:\n\"Update DB cert expiry date of amphora  id: %s\"","commit_id":"6e73ec826cab50571fc7f87856ff1e06830e8ce6"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"11cc45a972e9c7e585a3a1ba12b2812aea257566","unresolved":false,"context_lines":[{"line_number":486,"context_line":"        LOG.info(_LI(\"Update cert expiry date of amphora  id: %s\""},{"line_number":487,"context_line":"                     ) % amphora_id)"},{"line_number":488,"context_line":"        cert_expiration \u003d cert_parser.get_cert_expiration(server_pem)"},{"line_number":489,"context_line":"        LOG.info(_LI(\"Certificate expiration date is %s sec\""},{"line_number":490,"context_line":"                     ) % cert_expiration)"},{"line_number":491,"context_line":"        self.amphora_repo.update(db_apis.get_session(), amphora_id,"},{"line_number":492,"context_line":"                                 cert_expiration\u003dcert_expiration)"}],"source_content_type":"text/x-python","patch_set":15,"id":"ba15a1d1_4de33934","line":489,"updated":"2015-09-19 01:14:11.000000000","message":"This is not in seconds, so remove the \"sec\"","commit_id":"6e73ec826cab50571fc7f87856ff1e06830e8ce6"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"6fc33d4a291337bcdc2babb1c05ac60850ef866d","unresolved":false,"context_lines":[{"line_number":484,"context_line":"    \"\"\"Update the amphora expiration date with new cert file date.\"\"\""},{"line_number":485,"context_line":""},{"line_number":486,"context_line":"    def execute(self, amphora_id, server_pem):"},{"line_number":487,"context_line":"        LOG.info(_LI(\"Update DB cert expiry date of amphora id: %s\""},{"line_number":488,"context_line":"                     ) % amphora_id)"},{"line_number":489,"context_line":"        cert_expiration \u003d cert_parser.get_cert_expiration(server_pem)"},{"line_number":490,"context_line":"        LOG.info(_LI(\"Certificate expiration date is %s \""}],"source_content_type":"text/x-python","patch_set":21,"id":"9a1a9d01_be7574cb","line":487,"updated":"2015-10-01 00:26:57.000000000","message":"debug level","commit_id":"6ed6a21021da64a362c281874327f3936ff5b89c"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"6fc33d4a291337bcdc2babb1c05ac60850ef866d","unresolved":false,"context_lines":[{"line_number":487,"context_line":"        LOG.info(_LI(\"Update DB cert expiry date of amphora id: %s\""},{"line_number":488,"context_line":"                     ) % amphora_id)"},{"line_number":489,"context_line":"        cert_expiration \u003d cert_parser.get_cert_expiration(server_pem)"},{"line_number":490,"context_line":"        LOG.info(_LI(\"Certificate expiration date is %s \""},{"line_number":491,"context_line":"                     ) % cert_expiration)"},{"line_number":492,"context_line":"        LOG.debug(\"Store the new cert expiration date in amphora table\")"},{"line_number":493,"context_line":"        self.amphora_repo.update(db_apis.get_session(), amphora_id,"}],"source_content_type":"text/x-python","patch_set":21,"id":"9a1a9d01_7e7b5cbe","line":490,"updated":"2015-10-01 00:26:57.000000000","message":"debug level","commit_id":"6ed6a21021da64a362c281874327f3936ff5b89c"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"6fc33d4a291337bcdc2babb1c05ac60850ef866d","unresolved":false,"context_lines":[{"line_number":489,"context_line":"        cert_expiration \u003d cert_parser.get_cert_expiration(server_pem)"},{"line_number":490,"context_line":"        LOG.info(_LI(\"Certificate expiration date is %s \""},{"line_number":491,"context_line":"                     ) % cert_expiration)"},{"line_number":492,"context_line":"        LOG.debug(\"Store the new cert expiration date in amphora table\")"},{"line_number":493,"context_line":"        self.amphora_repo.update(db_apis.get_session(), amphora_id,"},{"line_number":494,"context_line":"                                 cert_expiration\u003dcert_expiration)"},{"line_number":495,"context_line":""}],"source_content_type":"text/x-python","patch_set":21,"id":"9a1a9d01_be5c944b","line":492,"updated":"2015-10-01 00:26:57.000000000","message":"I would remove this log entry","commit_id":"6ed6a21021da64a362c281874327f3936ff5b89c"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"674c6364553fe2a02d24db2f27ad214b8160bee1","unresolved":false,"context_lines":[{"line_number":477,"context_line":"        return self.amphora_repo.get(db_apis.get_session(), id\u003damphora_id)"},{"line_number":478,"context_line":""},{"line_number":479,"context_line":""},{"line_number":480,"context_line":"class UpdateAmphoraDBCertExpiration(BaseDatabaseTask):"},{"line_number":481,"context_line":"    \"\"\"Update the amphora expiration date with new cert file date.\"\"\""},{"line_number":482,"context_line":""},{"line_number":483,"context_line":"    def execute(self, amphora_id, server_pem):"}],"source_content_type":"text/x-python","patch_set":37,"id":"da85f559_abd0a5ca","line":480,"updated":"2015-11-07 01:19:31.000000000","message":"Missing unit test","commit_id":"9ac96425f0cc0a72b120527af4df2c5c48a4ec5b"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"674c6364553fe2a02d24db2f27ad214b8160bee1","unresolved":false,"context_lines":[{"line_number":488,"context_line":"                                 cert_expiration\u003dcert_expiration)"},{"line_number":489,"context_line":""},{"line_number":490,"context_line":""},{"line_number":491,"context_line":"class UpdateAmphoraCertBusyToFalse(BaseDatabaseTask):"},{"line_number":492,"context_line":"    \"\"\"Update the amphora cert_busy flag to be false.\"\"\""},{"line_number":493,"context_line":"    def execute(self, amphora):"},{"line_number":494,"context_line":"        self.amphora_repo.update(db_apis.get_session(), amphora.id,"}],"source_content_type":"text/x-python","patch_set":37,"id":"da85f559_cbd5e9b9","line":491,"updated":"2015-11-07 01:19:31.000000000","message":"Missing unit test","commit_id":"9ac96425f0cc0a72b120527af4df2c5c48a4ec5b"}],"octavia/db/migration/alembic.ini":[{"author":{"_account_id":10850,"name":"German Eichberger","email":"german.eichberger@gmail.com","username":"german"},"change_message_id":"d9273dec9c255f9d276f76f950050a9915ca1357","unresolved":false,"context_lines":[{"line_number":20,"context_line":"# versions/ directory"},{"line_number":21,"context_line":"# sourceless \u003d false"},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"sqlalchemy.url \u003d mysql+pymysql://root:password@127.0.0.1:3306/octavia"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"# Logging configuration"}],"source_content_type":"text/x-properties","patch_set":2,"id":"fa1b9901_8f02d7b2","line":23,"updated":"2015-08-20 23:47:40.000000000","message":"I don\u0027t like it when this file changes --","commit_id":"89ecfd2f39f1eda12e605c2c607e4a1338c8ab8a"},{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"d6f84274cc93ecfa33ebe43ba3290030eaa0c7b2","unresolved":false,"context_lines":[{"line_number":20,"context_line":"# versions/ directory"},{"line_number":21,"context_line":"# sourceless \u003d false"},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"sqlalchemy.url \u003d mysql+pymysql://root:password@127.0.0.1:3306/octavia"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"# Logging configuration"}],"source_content_type":"text/x-properties","patch_set":2,"id":"fa1b9901_96d98b59","line":23,"in_reply_to":"fa1b9901_8f02d7b2","updated":"2015-08-21 04:21:47.000000000","message":"Yeah, technically this change should be unnecessary as default hostname resolution and default SQL port settings should mean these are identical.","commit_id":"89ecfd2f39f1eda12e605c2c607e4a1338c8ab8a"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"81a8cde830ab6c6622a21560517df10b7c94103a","unresolved":false,"context_lines":[{"line_number":20,"context_line":"# versions/ directory"},{"line_number":21,"context_line":"# sourceless \u003d false"},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"sqlalchemy.url \u003d mysql+pymysql://root:password@127.0.0.1:3306/octavia"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"# Logging configuration"}],"source_content_type":"text/x-properties","patch_set":2,"id":"fa1b9901_e3b4a0d5","line":23,"in_reply_to":"fa1b9901_96d98b59","updated":"2015-08-21 16:47:08.000000000","message":"thank you for the input , i will change it back.","commit_id":"89ecfd2f39f1eda12e605c2c607e4a1338c8ab8a"}],"octavia/db/migration/alembic_migrations/versions/26500bae3db8_add_cert_busy_in_amphora.py":[{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"281dede09aacfdc9b6e20bcc81be0640466ab9cf","unresolved":false,"context_lines":[{"line_number":11,"context_line":"#    WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the"},{"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":"\"\"\"add  cert_busy in amphora"},{"line_number":15,"context_line":""},{"line_number":16,"context_line":"Revision ID: 26500bae3db8"},{"line_number":17,"context_line":"Revises: 5a3ee5472c31"}],"source_content_type":"text/x-python","patch_set":3,"id":"fa1b9901_dc7a8f77","line":14,"updated":"2015-08-22 00:43:19.000000000","message":"These two alembic changes should be merged into one.\nWe really should only have one alembic migration per patchset.","commit_id":"143353125b8cdd9c0a6bf8fe590db6b814576b1e"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"98e1d6edd72056172848e634fa35a6296ca00ad2","unresolved":false,"context_lines":[{"line_number":11,"context_line":"#    WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the"},{"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":"\"\"\"add  cert_busy in amphora"},{"line_number":15,"context_line":""},{"line_number":16,"context_line":"Revision ID: 26500bae3db8"},{"line_number":17,"context_line":"Revises: 5a3ee5472c31"}],"source_content_type":"text/x-python","patch_set":3,"id":"fa1b9901_b6821ac7","line":14,"in_reply_to":"fa1b9901_dc7a8f77","updated":"2015-08-24 17:29:17.000000000","message":"will combine 2 files into 1","commit_id":"143353125b8cdd9c0a6bf8fe590db6b814576b1e"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"281dede09aacfdc9b6e20bcc81be0640466ab9cf","unresolved":false,"context_lines":[{"line_number":32,"context_line":"                                        nullable\u003dFalse))"},{"line_number":33,"context_line":""},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"def downgrade():"},{"line_number":36,"context_line":"    pass"}],"source_content_type":"text/x-python","patch_set":3,"id":"fa1b9901_bc647be5","line":35,"updated":"2015-08-22 00:43:19.000000000","message":"remove downgrade","commit_id":"143353125b8cdd9c0a6bf8fe590db6b814576b1e"}],"octavia/db/migration/alembic_migrations/versions/5a3ee5472c31_add_cert_expiration_in_amphora_table.py":[{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"281dede09aacfdc9b6e20bcc81be0640466ab9cf","unresolved":false,"context_lines":[{"line_number":34,"context_line":"                  )"},{"line_number":35,"context_line":""},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"def downgrade():"},{"line_number":38,"context_line":"    pass"}],"source_content_type":"text/x-python","patch_set":3,"id":"fa1b9901_7c5ee313","line":37,"updated":"2015-08-22 00:43:19.000000000","message":"Remove downgrade.","commit_id":"143353125b8cdd9c0a6bf8fe590db6b814576b1e"}],"octavia/db/models.py":[{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"d6f84274cc93ecfa33ebe43ba3290030eaa0c7b2","unresolved":false,"context_lines":[{"line_number":340,"context_line":"    ha_ip \u003d sa.Column(sa.String(64), nullable\u003dTrue)"},{"line_number":341,"context_line":"    vrrp_port_id \u003d sa.Column(sa.String(36), nullable\u003dTrue)"},{"line_number":342,"context_line":"    ha_port_id \u003d sa.Column(sa.String(36), nullable\u003dTrue)"},{"line_number":343,"context_line":"    cert_expiration \u003d sa.Column(sa.DateTime(timezone\u003dTrue), default\u003dfunc.now(),"},{"line_number":344,"context_line":"                                nullable\u003dFalse)"},{"line_number":345,"context_line":"    role \u003d sa.Column("},{"line_number":346,"context_line":"        sa.String(36),"}],"source_content_type":"text/x-python","patch_set":2,"id":"fa1b9901_f6d1e723","line":343,"updated":"2015-08-21 04:21:47.000000000","message":"NOW is a strange default for this -- can we do a rough calculation based on the certificate generation settings in our conf? Or, should we actually just default this to NULL if it is not specified (IE, in the case that the SSL driver was chosen).","commit_id":"89ecfd2f39f1eda12e605c2c607e4a1338c8ab8a"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"81a8cde830ab6c6622a21560517df10b7c94103a","unresolved":false,"context_lines":[{"line_number":340,"context_line":"    ha_ip \u003d sa.Column(sa.String(64), nullable\u003dTrue)"},{"line_number":341,"context_line":"    vrrp_port_id \u003d sa.Column(sa.String(36), nullable\u003dTrue)"},{"line_number":342,"context_line":"    ha_port_id \u003d sa.Column(sa.String(36), nullable\u003dTrue)"},{"line_number":343,"context_line":"    cert_expiration \u003d sa.Column(sa.DateTime(timezone\u003dTrue), default\u003dfunc.now(),"},{"line_number":344,"context_line":"                                nullable\u003dFalse)"},{"line_number":345,"context_line":"    role \u003d sa.Column("},{"line_number":346,"context_line":"        sa.String(36),"}],"source_content_type":"text/x-python","patch_set":2,"id":"fa1b9901_63a2d09c","line":343,"in_reply_to":"fa1b9901_f6d1e723","updated":"2015-08-21 16:47:08.000000000","message":"will change it to be NULL , initially i was thinking between Null and now(), so NULL it is :)","commit_id":"89ecfd2f39f1eda12e605c2c607e4a1338c8ab8a"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"281dede09aacfdc9b6e20bcc81be0640466ab9cf","unresolved":false,"context_lines":[{"line_number":342,"context_line":"    ha_port_id \u003d sa.Column(sa.String(36), nullable\u003dTrue)"},{"line_number":343,"context_line":"    cert_expiration \u003d sa.Column(sa.DateTime(timezone\u003dTrue), default\u003dNone,"},{"line_number":344,"context_line":"                                nullable\u003dTrue)"},{"line_number":345,"context_line":"    cert_busy \u003d sa.Column(sa.Boolean(), default\u003dFalse, nullable\u003dTrue)"},{"line_number":346,"context_line":""},{"line_number":347,"context_line":"    role \u003d sa.Column("},{"line_number":348,"context_line":"        sa.String(36),"}],"source_content_type":"text/x-python","patch_set":3,"id":"fa1b9901_3c094bde","line":345,"updated":"2015-08-22 00:43:19.000000000","message":"With the default here you can set nullable to False","commit_id":"143353125b8cdd9c0a6bf8fe590db6b814576b1e"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"98e1d6edd72056172848e634fa35a6296ca00ad2","unresolved":false,"context_lines":[{"line_number":342,"context_line":"    ha_port_id \u003d sa.Column(sa.String(36), nullable\u003dTrue)"},{"line_number":343,"context_line":"    cert_expiration \u003d sa.Column(sa.DateTime(timezone\u003dTrue), default\u003dNone,"},{"line_number":344,"context_line":"                                nullable\u003dTrue)"},{"line_number":345,"context_line":"    cert_busy \u003d sa.Column(sa.Boolean(), default\u003dFalse, nullable\u003dTrue)"},{"line_number":346,"context_line":""},{"line_number":347,"context_line":"    role \u003d sa.Column("},{"line_number":348,"context_line":"        sa.String(36),"}],"source_content_type":"text/x-python","patch_set":3,"id":"fa1b9901_1663c642","line":345,"in_reply_to":"fa1b9901_3c094bde","updated":"2015-08-24 17:29:17.000000000","message":"ok","commit_id":"143353125b8cdd9c0a6bf8fe590db6b814576b1e"}],"octavia/db/repositories.py":[{"author":{"_account_id":10850,"name":"German Eichberger","email":"german.eichberger@gmail.com","username":"german"},"change_message_id":"312be15b25ff86e0a6782b3302205509746bb16f","unresolved":false,"context_lines":[{"line_number":380,"context_line":"            seconds\u003dexpired_seconds)"},{"line_number":381,"context_line":""},{"line_number":382,"context_line":"        with session.begin(subtransactions\u003dTrue):"},{"line_number":383,"context_line":"            amp \u003d session.query(self.model_class).filter("},{"line_number":384,"context_line":"                self.model_class.cert_expiration \u003e expired_date).first()"},{"line_number":385,"context_line":""},{"line_number":386,"context_line":"            if amp is None:"}],"source_content_type":"text/x-python","patch_set":3,"id":"fa1b9901_6b9e1b65","line":383,"updated":"2015-08-21 22:56:28.000000000","message":"this needs to a select for update see https://review.openstack.org/#/c/160061/41/octavia/db/repositories.py","commit_id":"143353125b8cdd9c0a6bf8fe590db6b814576b1e"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"98e1d6edd72056172848e634fa35a6296ca00ad2","unresolved":false,"context_lines":[{"line_number":380,"context_line":"            seconds\u003dexpired_seconds)"},{"line_number":381,"context_line":""},{"line_number":382,"context_line":"        with session.begin(subtransactions\u003dTrue):"},{"line_number":383,"context_line":"            amp \u003d session.query(self.model_class).filter("},{"line_number":384,"context_line":"                self.model_class.cert_expiration \u003e expired_date).first()"},{"line_number":385,"context_line":""},{"line_number":386,"context_line":"            if amp is None:"}],"source_content_type":"text/x-python","patch_set":3,"id":"fa1b9901_71612cd3","line":383,"in_reply_to":"fa1b9901_6b9e1b65","updated":"2015-08-24 17:29:17.000000000","message":"thanks！","commit_id":"143353125b8cdd9c0a6bf8fe590db6b814576b1e"},{"author":{"_account_id":15226,"name":"Bharath M","email":"bharath.stacker@gmail.com","username":"bharath"},"change_message_id":"8de2638cf7903d66048d3adf757fb13117f5adc4","unresolved":false,"context_lines":[{"line_number":27,"context_line":"from octavia.common import exceptions"},{"line_number":28,"context_line":"from octavia.db import models"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"LOG \u003d logging.getLogger(__name__)"},{"line_number":31,"context_line":"CONF_house_keeping \u003d cfg.CONF"},{"line_number":32,"context_line":"CONF_house_keeping.import_group(\u0027house_keeping\u0027, \u0027octavia.common.config\u0027)"},{"line_number":33,"context_line":""}],"source_content_type":"text/x-python","patch_set":7,"id":"da20952f_0fe8b5e1","line":30,"updated":"2015-08-27 08:23:54.000000000","message":"Currently LOG is not used. Is it WIP ?","commit_id":"a0316b696a10d66dbb1dd68bb0c30ecabb317fd8"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"11cc45a972e9c7e585a3a1ba12b2812aea257566","unresolved":false,"context_lines":[{"line_number":32,"context_line":"LOG \u003d logging.getLogger(__name__)"},{"line_number":33,"context_line":"CONF.import_group(\u0027health_manager\u0027, \u0027octavia.common.config\u0027)"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"CONF_house_keeping \u003d cfg.CONF"},{"line_number":36,"context_line":"CONF_house_keeping.import_group(\u0027house_keeping\u0027, \u0027octavia.common.config\u0027)"},{"line_number":37,"context_line":""},{"line_number":38,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"ba15a1d1_0d3b019e","line":35,"updated":"2015-09-19 01:14:11.000000000","message":"We don\u0027t need this.  You can import the house_keeping group into the above CONF object.","commit_id":"6e73ec826cab50571fc7f87856ff1e06830e8ce6"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"11cc45a972e9c7e585a3a1ba12b2812aea257566","unresolved":false,"context_lines":[{"line_number":396,"context_line":"        return count"},{"line_number":397,"context_line":""},{"line_number":398,"context_line":"    def get_cert_expired_amphora(self, session):"},{"line_number":399,"context_line":"        \"\"\"Retrieves an amphora whose cert is expired."},{"line_number":400,"context_line":""},{"line_number":401,"context_line":"        :param session: A Sql Alchemy database session."},{"line_number":402,"context_line":"        :returns: one amphora with expired certificate"}],"source_content_type":"text/x-python","patch_set":15,"id":"ba15a1d1_2d54c5c8","line":399,"updated":"2015-09-19 01:14:11.000000000","message":"Reword:\n\"Retrieves an amphora whose cert is close to expiring.\"","commit_id":"6e73ec826cab50571fc7f87856ff1e06830e8ce6"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"11cc45a972e9c7e585a3a1ba12b2812aea257566","unresolved":false,"context_lines":[{"line_number":399,"context_line":"        \"\"\"Retrieves an amphora whose cert is expired."},{"line_number":400,"context_line":""},{"line_number":401,"context_line":"        :param session: A Sql Alchemy database session."},{"line_number":402,"context_line":"        :returns: one amphora with expired certificate"},{"line_number":403,"context_line":"        \"\"\""},{"line_number":404,"context_line":"        expired_seconds \u003d CONF_house_keeping.house_keeping.cert_expired"},{"line_number":405,"context_line":"        expired_date \u003d datetime.datetime.now() - datetime.timedelta("}],"source_content_type":"text/x-python","patch_set":15,"id":"ba15a1d1_ed5c8df2","line":402,"updated":"2015-09-19 01:14:11.000000000","message":"expired -\u003e expiring","commit_id":"6e73ec826cab50571fc7f87856ff1e06830e8ce6"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"11cc45a972e9c7e585a3a1ba12b2812aea257566","unresolved":false,"context_lines":[{"line_number":402,"context_line":"        :returns: one amphora with expired certificate"},{"line_number":403,"context_line":"        \"\"\""},{"line_number":404,"context_line":"        expired_seconds \u003d CONF_house_keeping.house_keeping.cert_expired"},{"line_number":405,"context_line":"        expired_date \u003d datetime.datetime.now() - datetime.timedelta("},{"line_number":406,"context_line":"            seconds\u003dexpired_seconds)"},{"line_number":407,"context_line":""},{"line_number":408,"context_line":"        with session.begin(subtransactions\u003dTrue):"}],"source_content_type":"text/x-python","patch_set":15,"id":"ba15a1d1_72aff82b","line":405,"updated":"2015-09-19 01:14:11.000000000","message":"Shouldn\u0027t this be +?\nWe want to rotate the certificate before it expires, right?","commit_id":"6e73ec826cab50571fc7f87856ff1e06830e8ce6"},{"author":{"_account_id":10850,"name":"German Eichberger","email":"german.eichberger@gmail.com","username":"german"},"change_message_id":"83c6bdcfa863fd5ee9c751166bc26b05b6d7b76e","unresolved":false,"context_lines":[{"line_number":411,"context_line":"        :returns: one amphora with expiring certificate"},{"line_number":412,"context_line":"        \"\"\""},{"line_number":413,"context_line":"        expired_seconds \u003d CONF.house_keeping.cert_expired"},{"line_number":414,"context_line":"        expired_date \u003d datetime.datetime.utcnow() + datetime.timedelta("},{"line_number":415,"context_line":"            seconds\u003dexpired_seconds)"},{"line_number":416,"context_line":""},{"line_number":417,"context_line":"        with session.begin(subtransactions\u003dTrue):"}],"source_content_type":"text/x-python","patch_set":18,"id":"9a1a9d01_b0150ee6","line":414,"updated":"2015-09-28 22:30:15.000000000","message":"needs to be -","commit_id":"9374c96c3cc10c268a2d7c23ff2d227c62a71648"},{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"98a57e6110a68992122c978fd3df949388b4d3a4","unresolved":false,"context_lines":[{"line_number":411,"context_line":"        :returns: one amphora with expiring certificate"},{"line_number":412,"context_line":"        \"\"\""},{"line_number":413,"context_line":"        expired_seconds \u003d CONF.house_keeping.cert_expired"},{"line_number":414,"context_line":"        expired_date \u003d datetime.datetime.utcnow() + datetime.timedelta("},{"line_number":415,"context_line":"            seconds\u003dexpired_seconds)"},{"line_number":416,"context_line":""},{"line_number":417,"context_line":"        with session.begin(subtransactions\u003dTrue):"}],"source_content_type":"text/x-python","patch_set":18,"id":"9a1a9d01_b08e6ece","line":414,"in_reply_to":"9a1a9d01_b0150ee6","updated":"2015-09-28 22:49:38.000000000","message":"I had to have this explained in IRC because this calculation made no sense to me -- primarily because the config variable \"cert_expired\" has a name that is actively misleading. Possibly \"cert_expiry_buffer\" or something like that would be more apt.\n\nAnd no, it does need to be +. It was already corrected from - in a previous review.","commit_id":"9374c96c3cc10c268a2d7c23ff2d227c62a71648"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"a0b04761d1c223bbafdc7488f70308b9d3bdcccd","unresolved":false,"context_lines":[{"line_number":411,"context_line":"        :returns: one amphora with expiring certificate"},{"line_number":412,"context_line":"        \"\"\""},{"line_number":413,"context_line":"        expired_seconds \u003d CONF.house_keeping.cert_expired"},{"line_number":414,"context_line":"        expired_date \u003d datetime.datetime.utcnow() + datetime.timedelta("},{"line_number":415,"context_line":"            seconds\u003dexpired_seconds)"},{"line_number":416,"context_line":""},{"line_number":417,"context_line":"        with session.begin(subtransactions\u003dTrue):"}],"source_content_type":"text/x-python","patch_set":18,"id":"9a1a9d01_fb7b6726","line":414,"in_reply_to":"9a1a9d01_b08e6ece","updated":"2015-09-28 23:10:57.000000000","message":"Done","commit_id":"9374c96c3cc10c268a2d7c23ff2d227c62a71648"},{"author":{"_account_id":10850,"name":"German Eichberger","email":"german.eichberger@gmail.com","username":"german"},"change_message_id":"83c6bdcfa863fd5ee9c751166bc26b05b6d7b76e","unresolved":false,"context_lines":[{"line_number":417,"context_line":"        with session.begin(subtransactions\u003dTrue):"},{"line_number":418,"context_line":"            amp \u003d session.query(self.model_class).with_for_update().filter_by("},{"line_number":419,"context_line":"                cert_busy\u003dFalse).filter("},{"line_number":420,"context_line":"                self.model_class.cert_expiration \u003c expired_date).first()"},{"line_number":421,"context_line":""},{"line_number":422,"context_line":"            if amp is None:"},{"line_number":423,"context_line":"                return None"}],"source_content_type":"text/x-python","patch_set":18,"id":"9a1a9d01_f01f0606","line":420,"updated":"2015-09-28 22:30:15.000000000","message":"and this needs to be \u003e -- we are looking for the ones which are expired. if you keep the + above you need to add some not at the beginning","commit_id":"9374c96c3cc10c268a2d7c23ff2d227c62a71648"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"a0b04761d1c223bbafdc7488f70308b9d3bdcccd","unresolved":false,"context_lines":[{"line_number":417,"context_line":"        with session.begin(subtransactions\u003dTrue):"},{"line_number":418,"context_line":"            amp \u003d session.query(self.model_class).with_for_update().filter_by("},{"line_number":419,"context_line":"                cert_busy\u003dFalse).filter("},{"line_number":420,"context_line":"                self.model_class.cert_expiration \u003c expired_date).first()"},{"line_number":421,"context_line":""},{"line_number":422,"context_line":"            if amp is None:"},{"line_number":423,"context_line":"                return None"}],"source_content_type":"text/x-python","patch_set":18,"id":"9a1a9d01_db7ea318","line":420,"in_reply_to":"9a1a9d01_504cb29d","updated":"2015-09-28 23:10:57.000000000","message":"Done","commit_id":"9374c96c3cc10c268a2d7c23ff2d227c62a71648"},{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"98a57e6110a68992122c978fd3df949388b4d3a4","unresolved":false,"context_lines":[{"line_number":417,"context_line":"        with session.begin(subtransactions\u003dTrue):"},{"line_number":418,"context_line":"            amp \u003d session.query(self.model_class).with_for_update().filter_by("},{"line_number":419,"context_line":"                cert_busy\u003dFalse).filter("},{"line_number":420,"context_line":"                self.model_class.cert_expiration \u003c expired_date).first()"},{"line_number":421,"context_line":""},{"line_number":422,"context_line":"            if amp is None:"},{"line_number":423,"context_line":"                return None"}],"source_content_type":"text/x-python","patch_set":18,"id":"9a1a9d01_504cb29d","line":420,"in_reply_to":"9a1a9d01_f01f0606","updated":"2015-09-28 22:49:38.000000000","message":"I believe this is also already correct -- with + used above, the date that is returned is some period in the future, so we want to find certs whose expiration time is BEFORE that future date, not after.","commit_id":"9374c96c3cc10c268a2d7c23ff2d227c62a71648"},{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"145b699e02e3696e3b250c357fb9c49219c4b839","unresolved":false,"context_lines":[{"line_number":404,"context_line":""},{"line_number":405,"context_line":"        return count"},{"line_number":406,"context_line":""},{"line_number":407,"context_line":"    def get_cert_expired_amphora(self, session):"},{"line_number":408,"context_line":"        \"\"\"Retrieves an amphora whose cert is close to expiring.."},{"line_number":409,"context_line":""},{"line_number":410,"context_line":"        :param session: A Sql Alchemy database session."}],"source_content_type":"text/x-python","patch_set":19,"id":"9a1a9d01_2158d289","line":407,"updated":"2015-09-29 00:38:38.000000000","message":"I would consider calling this \"get_cert_expiring_amphora\" as the current name is no longer accurate.","commit_id":"e805e21f11175584ce2c5b1c1639a210449beee5"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"865e1ffa49656aae12bde2ca82c834c7443cb47a","unresolved":false,"context_lines":[{"line_number":404,"context_line":""},{"line_number":405,"context_line":"        return count"},{"line_number":406,"context_line":""},{"line_number":407,"context_line":"    def get_cert_expired_amphora(self, session):"},{"line_number":408,"context_line":"        \"\"\"Retrieves an amphora whose cert is close to expiring.."},{"line_number":409,"context_line":""},{"line_number":410,"context_line":"        :param session: A Sql Alchemy database session."}],"source_content_type":"text/x-python","patch_set":19,"id":"9a1a9d01_29e514db","line":407,"in_reply_to":"9a1a9d01_2158d289","updated":"2015-09-29 04:48:15.000000000","message":"thanks for taking care of the details, will update it in the next patch","commit_id":"e805e21f11175584ce2c5b1c1639a210449beee5"},{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"145b699e02e3696e3b250c357fb9c49219c4b839","unresolved":false,"context_lines":[{"line_number":411,"context_line":"        :returns: one amphora with expiring certificate"},{"line_number":412,"context_line":"        \"\"\""},{"line_number":413,"context_line":"        # certification will expire in expired_seconds from now, and we need"},{"line_number":414,"context_line":"        # to update those amphorae whose certs is before the expiration date"},{"line_number":415,"context_line":"        expired_seconds \u003d CONF.house_keeping.cert_expiry_buffer"},{"line_number":416,"context_line":"        expired_date \u003d datetime.datetime.utcnow() + datetime.timedelta("},{"line_number":417,"context_line":"            seconds\u003dexpired_seconds)"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a1a9d01_21cf722a","line":414,"updated":"2015-09-29 00:38:38.000000000","message":"This wording is a little bit confusing... Maybe say:\n\nFind amphorae with certs that will expire within the configured buffer period, so we can rotate their certs ahead of time","commit_id":"e805e21f11175584ce2c5b1c1639a210449beee5"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"865e1ffa49656aae12bde2ca82c834c7443cb47a","unresolved":false,"context_lines":[{"line_number":411,"context_line":"        :returns: one amphora with expiring certificate"},{"line_number":412,"context_line":"        \"\"\""},{"line_number":413,"context_line":"        # certification will expire in expired_seconds from now, and we need"},{"line_number":414,"context_line":"        # to update those amphorae whose certs is before the expiration date"},{"line_number":415,"context_line":"        expired_seconds \u003d CONF.house_keeping.cert_expiry_buffer"},{"line_number":416,"context_line":"        expired_date \u003d datetime.datetime.utcnow() + datetime.timedelta("},{"line_number":417,"context_line":"            seconds\u003dexpired_seconds)"}],"source_content_type":"text/x-python","patch_set":19,"id":"9a1a9d01_c9bfb8a8","line":414,"in_reply_to":"9a1a9d01_21cf722a","updated":"2015-09-29 04:48:15.000000000","message":"good idea, thanks for the input","commit_id":"e805e21f11175584ce2c5b1c1639a210449beee5"},{"author":{"_account_id":10850,"name":"German Eichberger","email":"german.eichberger@gmail.com","username":"german"},"change_message_id":"8df71ab49093fb8cbe832ef569f0f4aa23ad64b6","unresolved":false,"context_lines":[{"line_number":410,"context_line":"        :param session: A Sql Alchemy database session."},{"line_number":411,"context_line":"        :returns: one amphora with expiring certificate"},{"line_number":412,"context_line":"        \"\"\""},{"line_number":413,"context_line":"        # ind amphorae with certs that will expire within the"},{"line_number":414,"context_line":"        # configured buffer period, so we can rotate their certs ahead of time"},{"line_number":415,"context_line":"        expired_seconds \u003d CONF.house_keeping.cert_expiry_buffer"},{"line_number":416,"context_line":"        expired_date \u003d datetime.datetime.utcnow() + datetime.timedelta("}],"source_content_type":"text/x-python","patch_set":25,"id":"9a1a9d01_77c35139","line":413,"updated":"2015-10-01 23:51:02.000000000","message":"ind - what word is that?","commit_id":"6c58fc9997f7879d44be6b892f71af8f7f57a656"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"9744c64cad25cc1596edaa98148f8f5ff7d9389f","unresolved":false,"context_lines":[{"line_number":410,"context_line":"        :param session: A Sql Alchemy database session."},{"line_number":411,"context_line":"        :returns: one amphora with expiring certificate"},{"line_number":412,"context_line":"        \"\"\""},{"line_number":413,"context_line":"        # ind amphorae with certs that will expire within the"},{"line_number":414,"context_line":"        # configured buffer period, so we can rotate their certs ahead of time"},{"line_number":415,"context_line":"        expired_seconds \u003d CONF.house_keeping.cert_expiry_buffer"},{"line_number":416,"context_line":"        expired_date \u003d datetime.datetime.utcnow() + datetime.timedelta("}],"source_content_type":"text/x-python","patch_set":34,"id":"da85f559_b713300d","line":413,"updated":"2015-11-07 00:54:48.000000000","message":"nit: ind -\u003e find?","commit_id":"31e78f127140339eacb753db3c4b3990f9f42537"},{"author":{"_account_id":8157,"name":"Bertrand LALLAU","email":"bertrand.lallau@gmail.com","username":"blallau"},"change_message_id":"5b6b41a64dd95d347abb75fde7a5c2c2099a83c5","unresolved":false,"context_lines":[{"line_number":410,"context_line":"        :param session: A Sql Alchemy database session."},{"line_number":411,"context_line":"        :returns: one amphora with expiring certificate"},{"line_number":412,"context_line":"        \"\"\""},{"line_number":413,"context_line":"        # ind amphorae with certs that will expire within the"},{"line_number":414,"context_line":"        # configured buffer period, so we can rotate their certs ahead of time"},{"line_number":415,"context_line":"        expired_seconds \u003d CONF.house_keeping.cert_expiry_buffer"},{"line_number":416,"context_line":"        expired_date \u003d datetime.datetime.utcnow() + datetime.timedelta("}],"source_content_type":"text/x-python","patch_set":38,"id":"da85f559_4b750296","line":413,"updated":"2015-11-10 16:55:29.000000000","message":"ind ?","commit_id":"d099c9e4826fe1b54e357810bd5591e578bd73e4"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"83dfce2573f7767297eb3758fc65ce6a26397997","unresolved":false,"context_lines":[{"line_number":410,"context_line":"        :param session: A Sql Alchemy database session."},{"line_number":411,"context_line":"        :returns: one amphora with expiring certificate"},{"line_number":412,"context_line":"        \"\"\""},{"line_number":413,"context_line":"        # ind amphorae with certs that will expire within the"},{"line_number":414,"context_line":"        # configured buffer period, so we can rotate their certs ahead of time"},{"line_number":415,"context_line":"        expired_seconds \u003d CONF.house_keeping.cert_expiry_buffer"},{"line_number":416,"context_line":"        expired_date \u003d datetime.datetime.utcnow() + datetime.timedelta("}],"source_content_type":"text/x-python","patch_set":38,"id":"da85f559_4412d00a","line":413,"in_reply_to":"da85f559_4b750296","updated":"2015-11-10 18:13:04.000000000","message":"Done","commit_id":"d099c9e4826fe1b54e357810bd5591e578bd73e4"},{"author":{"_account_id":11685,"name":"Stephen Balukoff","email":"stephen@balukoff.com","username":"sbalukoff"},"change_message_id":"e430a0dab69edb248bb6675ad42a8fa5d965a5da","unresolved":false,"context_lines":[{"line_number":424,"context_line":"            if amp is None:"},{"line_number":425,"context_line":"                return None"},{"line_number":426,"context_line":""},{"line_number":427,"context_line":"            amp.cert_busy \u003d True"},{"line_number":428,"context_line":""},{"line_number":429,"context_line":"        return amp.to_data_model()"},{"line_number":430,"context_line":""}],"source_content_type":"text/x-python","patch_set":49,"id":"ba8a016a_5cf637fa","line":427,"updated":"2015-11-23 23:26:43.000000000","message":"Shouldn\u0027t we actually write this to the database in case there is more than one housekeeping process running? (Or better yet, don\u0027t alter the data from the database, but add a method (and call it) for setting the cert_busy flag to true once the the housekeeper actually starts to update the cert?)","commit_id":"f283d52139bfffa09e3c35a7f5406bb6c90e57f4"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"a1dcc4542154eff93d96cec9701ce86f32e73228","unresolved":false,"context_lines":[{"line_number":424,"context_line":"            if amp is None:"},{"line_number":425,"context_line":"                return None"},{"line_number":426,"context_line":""},{"line_number":427,"context_line":"            amp.cert_busy \u003d True"},{"line_number":428,"context_line":""},{"line_number":429,"context_line":"        return amp.to_data_model()"},{"line_number":430,"context_line":""}],"source_content_type":"text/x-python","patch_set":49,"id":"ba8a016a_aa811591","line":427,"in_reply_to":"ba8a016a_5cf637fa","updated":"2015-11-24 00:40:19.000000000","message":"when cert_busy becomes true, you can actually see that in db, its value will become true too. Also,this method is called in house_keeping where we use multiprocessing to handle it, by which we make sure the data will not become dirty.","commit_id":"f283d52139bfffa09e3c35a7f5406bb6c90e57f4"},{"author":{"_account_id":11685,"name":"Stephen Balukoff","email":"stephen@balukoff.com","username":"sbalukoff"},"change_message_id":"839068a398dd7b44de6065a5b828c0a20c234c48","unresolved":false,"context_lines":[{"line_number":424,"context_line":"            if amp is None:"},{"line_number":425,"context_line":"                return None"},{"line_number":426,"context_line":""},{"line_number":427,"context_line":"            amp.cert_busy \u003d True"},{"line_number":428,"context_line":""},{"line_number":429,"context_line":"        return amp.to_data_model()"},{"line_number":430,"context_line":""}],"source_content_type":"text/x-python","patch_set":50,"id":"9a8ffd7b_40097330","line":427,"updated":"2015-11-26 00:11:09.000000000","message":"Ok, maybe I\u0027m just missing it, then? where in this code are we setting cert_busy to true in the database?","commit_id":"678cc697c20cf63601258ae3cf6a81166075900c"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"f6c7ebdbcdb60215c51b317ec6d0e88d295a878d","unresolved":false,"context_lines":[{"line_number":424,"context_line":"            if amp is None:"},{"line_number":425,"context_line":"                return None"},{"line_number":426,"context_line":""},{"line_number":427,"context_line":"            amp.cert_busy \u003d True"},{"line_number":428,"context_line":""},{"line_number":429,"context_line":"        return amp.to_data_model()"},{"line_number":430,"context_line":""}],"source_content_type":"text/x-python","patch_set":50,"id":"9a8ffd7b_50c3d838","line":427,"in_reply_to":"9a8ffd7b_40097330","updated":"2015-11-30 18:46:42.000000000","message":"The line above your comment, line 427, sets it to True in the database.","commit_id":"678cc697c20cf63601258ae3cf6a81166075900c"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"b45b5b4d27b913306632ad2f8a872f06283ff50d","unresolved":false,"context_lines":[{"line_number":424,"context_line":"            if amp is None:"},{"line_number":425,"context_line":"                return None"},{"line_number":426,"context_line":""},{"line_number":427,"context_line":"            amp.cert_busy \u003d True"},{"line_number":428,"context_line":""},{"line_number":429,"context_line":"        return amp.to_data_model()"},{"line_number":430,"context_line":""}],"source_content_type":"text/x-python","patch_set":50,"id":"9a8ffd7b_90f7008c","line":427,"in_reply_to":"9a8ffd7b_40097330","updated":"2015-11-30 18:37:32.000000000","message":"amp is a database object, setting it to True right there sets it in the database","commit_id":"678cc697c20cf63601258ae3cf6a81166075900c"}],"octavia/tests/functional/db/test_models.py":[{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"11cc45a972e9c7e585a3a1ba12b2812aea257566","unresolved":false,"context_lines":[{"line_number":15,"context_line":"import datetime"},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"from oslo_utils import uuidutils"},{"line_number":18,"context_line":"from sqlalchemy.sql import func"},{"line_number":19,"context_line":""},{"line_number":20,"context_line":"from octavia.common import constants"},{"line_number":21,"context_line":"from octavia.common import data_models"}],"source_content_type":"text/x-python","patch_set":15,"id":"ba15a1d1_2d6b6587","line":18,"updated":"2015-09-19 01:14:11.000000000","message":"Remove this","commit_id":"6e73ec826cab50571fc7f87856ff1e06830e8ce6"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"11cc45a972e9c7e585a3a1ba12b2812aea257566","unresolved":false,"context_lines":[{"line_number":125,"context_line":"                  \u0027vrrp_port_id\u0027: self.FAKE_UUID_1,"},{"line_number":126,"context_line":"                  \u0027ha_port_id\u0027: self.FAKE_UUID_2,"},{"line_number":127,"context_line":"                  \u0027lb_network_ip\u0027: self.FAKE_IP,"},{"line_number":128,"context_line":"                  \u0027cert_expiration\u0027: func.now(),"},{"line_number":129,"context_line":"                  \u0027cert_busy\u0027: False}"},{"line_number":130,"context_line":"        kwargs.update(overrides)"},{"line_number":131,"context_line":"        return self._insert(session, models.Amphora, kwargs)"}],"source_content_type":"text/x-python","patch_set":15,"id":"ba15a1d1_ad0d35ea","line":128,"updated":"2015-09-19 01:14:11.000000000","message":"Switch this to datetime.utcnow()\n\nsqlalchemy.sql.now() get the date and time from the database.  We can remove a round trip to the database by just using the local time.","commit_id":"6e73ec826cab50571fc7f87856ff1e06830e8ce6"}],"octavia/tests/functional/db/test_repositories.py":[{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"11cc45a972e9c7e585a3a1ba12b2812aea257566","unresolved":false,"context_lines":[{"line_number":16,"context_line":"import random"},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"from oslo_utils import uuidutils"},{"line_number":19,"context_line":"from sqlalchemy.sql import func"},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"from octavia.common import constants"},{"line_number":22,"context_line":"from octavia.common import data_models as models"}],"source_content_type":"text/x-python","patch_set":15,"id":"ba15a1d1_ed2a4d2f","line":19,"updated":"2015-09-19 01:14:11.000000000","message":"Remove this","commit_id":"6e73ec826cab50571fc7f87856ff1e06830e8ce6"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"11cc45a972e9c7e585a3a1ba12b2812aea257566","unresolved":false,"context_lines":[{"line_number":1116,"context_line":"                                           vrrp_ip\u003dself.FAKE_IP,"},{"line_number":1117,"context_line":"                                           ha_ip\u003dself.FAKE_IP,"},{"line_number":1118,"context_line":"                                           role\u003dconstants.ROLE_MASTER,"},{"line_number":1119,"context_line":"                                           cert_expiration\u003dfunc.now(),"},{"line_number":1120,"context_line":"                                           cert_busy\u003dFalse)"},{"line_number":1121,"context_line":"        return amphora"},{"line_number":1122,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"ba15a1d1_8df5d1cc","line":1119,"updated":"2015-09-19 01:14:11.000000000","message":"Switch this to datetime.utcnow()","commit_id":"6e73ec826cab50571fc7f87856ff1e06830e8ce6"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"11cc45a972e9c7e585a3a1ba12b2812aea257566","unresolved":false,"context_lines":[{"line_number":1223,"context_line":""},{"line_number":1224,"context_line":"        # test with expired amphora"},{"line_number":1225,"context_line":"        amphora2 \u003d self.create_amphora(self.FAKE_UUID_2)"},{"line_number":1226,"context_line":"        expiration \u003d datetime.datetime.now() - datetime.timedelta(seconds\u003d5000)"},{"line_number":1227,"context_line":"        self.amphora_repo.update(self.session, amphora2.id,"},{"line_number":1228,"context_line":"                                 cert_expiration\u003dexpiration)"},{"line_number":1229,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"ba15a1d1_ad245560","line":1226,"updated":"2015-09-19 01:14:11.000000000","message":"I think this should be +","commit_id":"6e73ec826cab50571fc7f87856ff1e06830e8ce6"}],"octavia/tests/unit/amphorae/drivers/haproxy/test_rest_api_driver.py":[{"author":{"_account_id":10850,"name":"German Eichberger","email":"german.eichberger@gmail.com","username":"german"},"change_message_id":"f6329ec06932eb247c64499834998a8f15729b65","unresolved":false,"context_lines":[{"line_number":112,"context_line":"            self.amp, self.sl.id)"},{"line_number":113,"context_line":""},{"line_number":114,"context_line":"    def test_upload_cert_amp(self):"},{"line_number":115,"context_line":"        self.driver.upload_cert_amp(self.amp, six.b(\u0027\u0027))"},{"line_number":116,"context_line":"        self.driver.client.update_cert_for_rotation.assert_called_once_with("},{"line_number":117,"context_line":"            self.amp, six.b(\u0027\u0027))"},{"line_number":118,"context_line":""}],"source_content_type":"text/x-python","patch_set":34,"id":"fa80f949_1ec5273b","line":115,"updated":"2015-11-05 00:29:45.000000000","message":"I like not to use empty string for tests do something like b(\u0027test\u0027)","commit_id":"31e78f127140339eacb753db3c4b3990f9f42537"},{"author":{"_account_id":10850,"name":"German Eichberger","email":"german.eichberger@gmail.com","username":"german"},"change_message_id":"f6329ec06932eb247c64499834998a8f15729b65","unresolved":false,"context_lines":[{"line_number":453,"context_line":"    def test_update_cert_for_rotation(self, m):"},{"line_number":454,"context_line":"        m.put(\"{base}/certificate\".format(base\u003dself.base_url))"},{"line_number":455,"context_line":"        self.driver.update_cert_for_rotation(self.amp, \"some_file\")"},{"line_number":456,"context_line":"        self.assertTrue(m.called)"},{"line_number":457,"context_line":""},{"line_number":458,"context_line":"    @requests_mock.mock()"},{"line_number":459,"context_line":"    def test_upload_invalid_cert_pem(self, m):"}],"source_content_type":"text/x-python","patch_set":34,"id":"fa80f949_9ee7d7e3","line":456,"updated":"2015-11-05 00:29:45.000000000","message":"I think we can also check if the payload matches","commit_id":"31e78f127140339eacb753db3c4b3990f9f42537"}],"octavia/tests/unit/cmd/test_house_keeping.py":[{"author":{"_account_id":8157,"name":"Bertrand LALLAU","email":"bertrand.lallau@gmail.com","username":"blallau"},"change_message_id":"9ac297b67efef94a10f7b08e59569c49a865d449","unresolved":false,"context_lines":[{"line_number":50,"context_line":"                                house_keeping.cert_rotation)"},{"line_number":51,"context_line":""},{"line_number":52,"context_line":"        mock_CertRotation.assert_called_once_with()"},{"line_number":53,"context_line":"        self.assertEqual(cert_rotate_mock.rotate.call_count, 1)"},{"line_number":54,"context_line":""},{"line_number":55,"context_line":"    @mock.patch(\u0027octavia.cmd.house_keeping.spare_amp_thread_event\u0027)"},{"line_number":56,"context_line":"    @mock.patch(\u0027octavia.controller.housekeeping.\u0027"}],"source_content_type":"text/x-python","patch_set":31,"id":"1a26ad4f_cb94a7e3","line":53,"updated":"2015-10-30 13:43:26.000000000","message":"prefer: assertEqual(Expected, observed)\n\nself.assertEqual(1, cert_rotate_mock.rotate.call_count)","commit_id":"6934ef1d98faa319999e304085c4abb010cacd10"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"ab407408d146a33b597c2cfdecee1474ef19741f","unresolved":false,"context_lines":[{"line_number":50,"context_line":"                                house_keeping.cert_rotation)"},{"line_number":51,"context_line":""},{"line_number":52,"context_line":"        mock_CertRotation.assert_called_once_with()"},{"line_number":53,"context_line":"        self.assertEqual(cert_rotate_mock.rotate.call_count, 1)"},{"line_number":54,"context_line":""},{"line_number":55,"context_line":"    @mock.patch(\u0027octavia.cmd.house_keeping.spare_amp_thread_event\u0027)"},{"line_number":56,"context_line":"    @mock.patch(\u0027octavia.controller.housekeeping.\u0027"}],"source_content_type":"text/x-python","patch_set":31,"id":"1a26ad4f_442ac12d","line":53,"in_reply_to":"1a26ad4f_cb94a7e3","updated":"2015-10-30 19:12:34.000000000","message":"will change it in the next patch.","commit_id":"6934ef1d98faa319999e304085c4abb010cacd10"},{"author":{"_account_id":8157,"name":"Bertrand LALLAU","email":"bertrand.lallau@gmail.com","username":"blallau"},"change_message_id":"9ac297b67efef94a10f7b08e59569c49a865d449","unresolved":false,"context_lines":[{"line_number":72,"context_line":"                                house_keeping.spare_amphora_check)"},{"line_number":73,"context_line":""},{"line_number":74,"context_line":"        mock_SpareAmphora.assert_called_once_with()"},{"line_number":75,"context_line":"        self.assertEqual(spare_amp_mock.spare_check.call_count, 1)"},{"line_number":76,"context_line":""},{"line_number":77,"context_line":"    @mock.patch(\u0027octavia.cmd.house_keeping.db_cleanup_thread_event\u0027)"},{"line_number":78,"context_line":"    @mock.patch(\u0027octavia.controller.housekeeping.\u0027"}],"source_content_type":"text/x-python","patch_set":31,"id":"1a26ad4f_abc04be1","line":75,"updated":"2015-10-30 13:43:26.000000000","message":"itto","commit_id":"6934ef1d98faa319999e304085c4abb010cacd10"},{"author":{"_account_id":8157,"name":"Bertrand LALLAU","email":"bertrand.lallau@gmail.com","username":"blallau"},"change_message_id":"9ac297b67efef94a10f7b08e59569c49a865d449","unresolved":false,"context_lines":[{"line_number":92,"context_line":"        self.assertRaisesRegexp(Exception, \u0027break\u0027, house_keeping.db_cleanup)"},{"line_number":93,"context_line":""},{"line_number":94,"context_line":"        mock_DatabaseCleanup.assert_called_once_with()"},{"line_number":95,"context_line":"        self.assertEqual(db_cleanup.delete_old_amphorae.call_count, 1)"},{"line_number":96,"context_line":""},{"line_number":97,"context_line":"    @mock.patch(\u0027time.sleep\u0027)"},{"line_number":98,"context_line":"    @mock.patch(\u0027octavia.cmd.house_keeping.cert_rotate_thread_event\u0027)"}],"source_content_type":"text/x-python","patch_set":31,"id":"1a26ad4f_0bb29f94","line":95,"updated":"2015-10-30 13:43:26.000000000","message":"itto","commit_id":"6934ef1d98faa319999e304085c4abb010cacd10"},{"author":{"_account_id":10850,"name":"German Eichberger","email":"german.eichberger@gmail.com","username":"german"},"change_message_id":"f6329ec06932eb247c64499834998a8f15729b65","unresolved":false,"context_lines":[{"line_number":55,"context_line":"    @mock.patch(\u0027octavia.cmd.house_keeping.spare_amp_thread_event\u0027)"},{"line_number":56,"context_line":"    @mock.patch(\u0027octavia.controller.housekeeping.\u0027"},{"line_number":57,"context_line":"                \u0027house_keeping.SpareAmphora\u0027)"},{"line_number":58,"context_line":"    @mock.patch(\u0027time.sleep\u0027)"},{"line_number":59,"context_line":"    def test_spare_amphora_check(self, sleep_mock, mock_SpareAmphora,"},{"line_number":60,"context_line":"                                 spare_amp_thread_event_mock):"},{"line_number":61,"context_line":"        spare_amp_mock \u003d mock.MagicMock()"}],"source_content_type":"text/x-python","patch_set":34,"id":"fa80f949_be389b3e","line":58,"updated":"2015-11-05 00:29:45.000000000","message":"that might have been better submitted in it\u0027s own patch since it doesn\u0027t test cert rotation","commit_id":"31e78f127140339eacb753db3c4b3990f9f42537"},{"author":{"_account_id":10850,"name":"German Eichberger","email":"german.eichberger@gmail.com","username":"german"},"change_message_id":"f6329ec06932eb247c64499834998a8f15729b65","unresolved":false,"context_lines":[{"line_number":66,"context_line":"        # mock spare_amp_thread_event.is_set() in the while loop"},{"line_number":67,"context_line":"        spare_amp_thread_event_mock.is_set \u003d mock.MagicMock()"},{"line_number":68,"context_line":"        spare_amp_thread_event_mock.is_set.side_effect \u003d [True,"},{"line_number":69,"context_line":"                                                          Exception(\u0027break\u0027)]"},{"line_number":70,"context_line":""},{"line_number":71,"context_line":"        self.assertRaisesRegexp(Exception, \u0027break\u0027,"},{"line_number":72,"context_line":"                                house_keeping.spare_amphora_check)"}],"source_content_type":"text/x-python","patch_set":34,"id":"fa80f949_9e5a7782","line":69,"updated":"2015-11-05 00:29:45.000000000","message":"also I think we need to test the happy case without exception","commit_id":"31e78f127140339eacb753db3c4b3990f9f42537"}],"octavia/tests/unit/common/tls_utils/test_cert_parser.py":[{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"07fa8246713f5e2ab5d630e8321b2195cd91f818","unresolved":false,"context_lines":[{"line_number":323,"context_line":"        self.assertEqual(datetime.datetime(2025, 5, 18, 20, 33, 23), exp_date)"},{"line_number":324,"context_line":""},{"line_number":325,"context_line":"        # test the exception"},{"line_number":326,"context_line":"        with mock.patch(\u0027cryptography.x509.load_pem_x509_certificate\u0027)as cp:"},{"line_number":327,"context_line":"            cp.side_effect \u003d [Exception(\u0027test\u0027)]"},{"line_number":328,"context_line":"            self.assertRaises(exceptions.UnreadableCert,"},{"line_number":329,"context_line":"                              cert_parser.get_cert_expiration, ALT_EXT_CRT)"}],"source_content_type":"text/x-python","patch_set":48,"id":"ba8a016a_5b54dd51","line":326,"updated":"2015-11-18 15:46:29.000000000","message":"Instead of testing this by mocking crypto, couldn\u0027t you literally just pass in a bad cert? Passing in a bad cert is super easy, because almost every string is an invalid cert. :P","commit_id":"f952248b9b0ca32f30e29b3df668d8c4f78b0e59"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"2a9be7663150b71f706ae06bd528db845e083c10","unresolved":false,"context_lines":[{"line_number":323,"context_line":"        self.assertEqual(datetime.datetime(2025, 5, 18, 20, 33, 23), exp_date)"},{"line_number":324,"context_line":""},{"line_number":325,"context_line":"        # test the exception"},{"line_number":326,"context_line":"        with mock.patch(\u0027cryptography.x509.load_pem_x509_certificate\u0027)as cp:"},{"line_number":327,"context_line":"            cp.side_effect \u003d [Exception(\u0027test\u0027)]"},{"line_number":328,"context_line":"            self.assertRaises(exceptions.UnreadableCert,"},{"line_number":329,"context_line":"                              cert_parser.get_cert_expiration, ALT_EXT_CRT)"}],"source_content_type":"text/x-python","patch_set":48,"id":"ba8a016a_cf76c4a3","line":326,"in_reply_to":"ba8a016a_5b54dd51","updated":"2015-11-18 17:50:50.000000000","message":"dont you think using mock is more fancy:)","commit_id":"f952248b9b0ca32f30e29b3df668d8c4f78b0e59"},{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"e95860a10b16dc6bc941a0e02eee3062eeb7dd84","unresolved":false,"context_lines":[{"line_number":323,"context_line":"        self.assertEqual(datetime.datetime(2025, 5, 18, 20, 33, 23), exp_date)"},{"line_number":324,"context_line":""},{"line_number":325,"context_line":"        # test the exception"},{"line_number":326,"context_line":"        with mock.patch(\u0027cryptography.x509.load_pem_x509_certificate\u0027)as cp:"},{"line_number":327,"context_line":"            cp.side_effect \u003d [Exception(\u0027test\u0027)]"},{"line_number":328,"context_line":"            self.assertRaises(exceptions.UnreadableCert,"},{"line_number":329,"context_line":"                              cert_parser.get_cert_expiration, ALT_EXT_CRT)"}],"source_content_type":"text/x-python","patch_set":48,"id":"ba8a016a_d1fad074","line":326,"in_reply_to":"ba8a016a_cf76c4a3","updated":"2015-11-19 04:10:42.000000000","message":"lol, admittedly CPU/RAM constraints aren\u0027t that high anymore, but it just seems like a waste to do all of this when you could just pass a string. :P","commit_id":"f952248b9b0ca32f30e29b3df668d8c4f78b0e59"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"0d768acffc813bff2e32d301882ae032f2052901","unresolved":false,"context_lines":[{"line_number":323,"context_line":"        self.assertEqual(datetime.datetime(2025, 5, 18, 20, 33, 23), exp_date)"},{"line_number":324,"context_line":""},{"line_number":325,"context_line":"        # test the exception"},{"line_number":326,"context_line":"        with mock.patch(\u0027cryptography.x509.load_pem_x509_certificate\u0027)as cp:"},{"line_number":327,"context_line":"            cp.side_effect \u003d [Exception(\u0027test\u0027)]"},{"line_number":328,"context_line":"            self.assertRaises(exceptions.UnreadableCert,"},{"line_number":329,"context_line":"                              cert_parser.get_cert_expiration, ALT_EXT_CRT)"}],"source_content_type":"text/x-python","patch_set":48,"id":"ba8a016a_33a54746","line":326,"in_reply_to":"ba8a016a_d1fad074","updated":"2015-11-19 14:15:33.000000000","message":"i can use the string to pass","commit_id":"f952248b9b0ca32f30e29b3df668d8c4f78b0e59"}],"octavia/tests/unit/controller/housekeeping/test_house_keeping.py":[{"author":{"_account_id":10850,"name":"German Eichberger","email":"german.eichberger@gmail.com","username":"german"},"change_message_id":"f6329ec06932eb247c64499834998a8f15729b65","unresolved":false,"context_lines":[{"line_number":150,"context_line":"        amphora.id \u003d AMPHORA_ID"},{"line_number":151,"context_line":""},{"line_number":152,"context_line":"        session.return_value \u003d session"},{"line_number":153,"context_line":"        cert_expired_amp_mock.side_effect \u003d [amphora, TestException("},{"line_number":154,"context_line":"            \u0027break_while\u0027)]"},{"line_number":155,"context_line":""},{"line_number":156,"context_line":"        cr \u003d house_keeping.CertRotation()"}],"source_content_type":"text/x-python","patch_set":34,"id":"fa80f949_7e50f35e","line":153,"updated":"2015-11-05 00:29:45.000000000","message":"we should also have a test of the happy case: [amphora, None]","commit_id":"31e78f127140339eacb753db3c4b3990f9f42537"},{"author":{"_account_id":10850,"name":"German Eichberger","email":"german.eichberger@gmail.com","username":"german"},"change_message_id":"f6329ec06932eb247c64499834998a8f15729b65","unresolved":false,"context_lines":[{"line_number":166,"context_line":"                                               cert_expired_amp_mock,"},{"line_number":167,"context_line":"                                               amp_cert_mock):"},{"line_number":168,"context_line":"        amphora \u003d mock.MagicMock()"},{"line_number":169,"context_line":"        amphora.id \u003d AMPHORA_ID"},{"line_number":170,"context_line":""},{"line_number":171,"context_line":"        session.return_value \u003d session"},{"line_number":172,"context_line":"        cert_expired_amp_mock.return_value \u003d None"}],"source_content_type":"text/x-python","patch_set":34,"id":"fa80f949_3e4a6bad","line":169,"updated":"2015-11-05 00:29:45.000000000","message":"amphora and amphora.id are never used in that test code","commit_id":"31e78f127140339eacb753db3c4b3990f9f42537"}],"octavia/tests/unit/controller/worker/flows/test_amphora_flows.py":[{"author":{"_account_id":8157,"name":"Bertrand LALLAU","email":"bertrand.lallau@gmail.com","username":"blallau"},"change_message_id":"9ac297b67efef94a10f7b08e59569c49a865d449","unresolved":false,"context_lines":[{"line_number":145,"context_line":"        self.assertIn(constants.SERVER_PEM, amp_rotate_flow.provides)"},{"line_number":146,"context_line":"        self.assertIn(constants.AMPHORA, amp_rotate_flow.requires)"},{"line_number":147,"context_line":""},{"line_number":148,"context_line":"        self.assertEqual(len(amp_rotate_flow.provides), 1)"},{"line_number":149,"context_line":"        self.assertEqual(len(amp_rotate_flow.requires), 2)"}],"source_content_type":"text/x-python","patch_set":31,"id":"1a26ad4f_4b45f76d","line":148,"updated":"2015-10-30 13:43:26.000000000","message":"self.assertEqual(1, len(amp_rotate_flow.provides))","commit_id":"6934ef1d98faa319999e304085c4abb010cacd10"},{"author":{"_account_id":8157,"name":"Bertrand LALLAU","email":"bertrand.lallau@gmail.com","username":"blallau"},"change_message_id":"9ac297b67efef94a10f7b08e59569c49a865d449","unresolved":false,"context_lines":[{"line_number":146,"context_line":"        self.assertIn(constants.AMPHORA, amp_rotate_flow.requires)"},{"line_number":147,"context_line":""},{"line_number":148,"context_line":"        self.assertEqual(len(amp_rotate_flow.provides), 1)"},{"line_number":149,"context_line":"        self.assertEqual(len(amp_rotate_flow.requires), 2)"}],"source_content_type":"text/x-python","patch_set":31,"id":"1a26ad4f_6b48f387","line":149,"updated":"2015-10-30 13:43:26.000000000","message":"itto","commit_id":"6934ef1d98faa319999e304085c4abb010cacd10"}],"octavia/tests/unit/controller/worker/tasks/test_amphora_driver_tasks.py":[{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"07fa8246713f5e2ab5d630e8321b2195cd91f818","unresolved":false,"context_lines":[{"line_number":278,"context_line":"                                 mock_get_session,"},{"line_number":279,"context_line":"                                 mock_listener_repo_update,"},{"line_number":280,"context_line":"                                 mock_amphora_repo_update):"},{"line_number":281,"context_line":"        pem_file_mock \u003d mock.Mock()"},{"line_number":282,"context_line":"        amphora_cert_upload_mock \u003d (amphora_driver_tasks.AmphoraCertUpload())"},{"line_number":283,"context_line":"        amphora_cert_upload_mock.execute(_amphora_mock, pem_file_mock)"},{"line_number":284,"context_line":""}],"source_content_type":"text/x-python","patch_set":48,"id":"ba8a016a_1bf89548","line":281,"updated":"2015-11-18 15:46:29.000000000","message":"This doesn\u0027t have to be a mock, this can literally just be a string, right?","commit_id":"f952248b9b0ca32f30e29b3df668d8c4f78b0e59"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"2a9be7663150b71f706ae06bd528db845e083c10","unresolved":false,"context_lines":[{"line_number":278,"context_line":"                                 mock_get_session,"},{"line_number":279,"context_line":"                                 mock_listener_repo_update,"},{"line_number":280,"context_line":"                                 mock_amphora_repo_update):"},{"line_number":281,"context_line":"        pem_file_mock \u003d mock.Mock()"},{"line_number":282,"context_line":"        amphora_cert_upload_mock \u003d (amphora_driver_tasks.AmphoraCertUpload())"},{"line_number":283,"context_line":"        amphora_cert_upload_mock.execute(_amphora_mock, pem_file_mock)"},{"line_number":284,"context_line":""}],"source_content_type":"text/x-python","patch_set":48,"id":"ba8a016a_d2f0a769","line":281,"in_reply_to":"ba8a016a_1bf89548","updated":"2015-11-18 17:50:50.000000000","message":"yes, it can be.","commit_id":"f952248b9b0ca32f30e29b3df668d8c4f78b0e59"},{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"07fa8246713f5e2ab5d630e8321b2195cd91f818","unresolved":false,"context_lines":[{"line_number":279,"context_line":"                                 mock_listener_repo_update,"},{"line_number":280,"context_line":"                                 mock_amphora_repo_update):"},{"line_number":281,"context_line":"        pem_file_mock \u003d mock.Mock()"},{"line_number":282,"context_line":"        amphora_cert_upload_mock \u003d (amphora_driver_tasks.AmphoraCertUpload())"},{"line_number":283,"context_line":"        amphora_cert_upload_mock.execute(_amphora_mock, pem_file_mock)"},{"line_number":284,"context_line":""},{"line_number":285,"context_line":"        mock_driver.upload_cert_amp.assert_called_once_with("}],"source_content_type":"text/x-python","patch_set":48,"id":"ba8a016a_1be1759a","line":282,"updated":"2015-11-18 15:46:29.000000000","message":"Why are there parenthesis around this?","commit_id":"f952248b9b0ca32f30e29b3df668d8c4f78b0e59"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"2a9be7663150b71f706ae06bd528db845e083c10","unresolved":false,"context_lines":[{"line_number":279,"context_line":"                                 mock_listener_repo_update,"},{"line_number":280,"context_line":"                                 mock_amphora_repo_update):"},{"line_number":281,"context_line":"        pem_file_mock \u003d mock.Mock()"},{"line_number":282,"context_line":"        amphora_cert_upload_mock \u003d (amphora_driver_tasks.AmphoraCertUpload())"},{"line_number":283,"context_line":"        amphora_cert_upload_mock.execute(_amphora_mock, pem_file_mock)"},{"line_number":284,"context_line":""},{"line_number":285,"context_line":"        mock_driver.upload_cert_amp.assert_called_once_with("}],"source_content_type":"text/x-python","patch_set":48,"id":"ba8a016a_6f68f8b9","line":282,"in_reply_to":"ba8a016a_1be1759a","updated":"2015-11-18 17:50:50.000000000","message":"I can take off these parenthesis.","commit_id":"f952248b9b0ca32f30e29b3df668d8c4f78b0e59"}],"octavia/tests/unit/controller/worker/tasks/test_database_tasks.py":[{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"07fa8246713f5e2ab5d630e8321b2195cd91f818","unresolved":false,"context_lines":[{"line_number":672,"context_line":"        repo.AmphoraRepository.update.assert_called_once_with("},{"line_number":673,"context_line":"            \u0027TEST\u0027,"},{"line_number":674,"context_line":"            AMP_ID,"},{"line_number":675,"context_line":"            cert_expiration\u003d_cert_mock)"},{"line_number":676,"context_line":""},{"line_number":677,"context_line":"    def test_update_amphora_cert_busy_to_false(self,"},{"line_number":678,"context_line":"                                               mock_generate_uuid,"}],"source_content_type":"text/x-python","patch_set":48,"id":"ba8a016a_1ba65553","line":675,"updated":"2015-11-18 15:46:29.000000000","message":"Wait, is this right? Why is the cert_mock being passed as cert_expiration?","commit_id":"f952248b9b0ca32f30e29b3df668d8c4f78b0e59"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"2a9be7663150b71f706ae06bd528db845e083c10","unresolved":false,"context_lines":[{"line_number":672,"context_line":"        repo.AmphoraRepository.update.assert_called_once_with("},{"line_number":673,"context_line":"            \u0027TEST\u0027,"},{"line_number":674,"context_line":"            AMP_ID,"},{"line_number":675,"context_line":"            cert_expiration\u003d_cert_mock)"},{"line_number":676,"context_line":""},{"line_number":677,"context_line":"    def test_update_amphora_cert_busy_to_false(self,"},{"line_number":678,"context_line":"                                               mock_generate_uuid,"}],"source_content_type":"text/x-python","patch_set":48,"id":"ba8a016a_cdd24c5c","line":675,"in_reply_to":"ba8a016a_1ba65553","updated":"2015-11-18 17:50:50.000000000","message":"when you check the execute method of UpdateAmphoraDBCertExpiration, \ninside :\n        cert_expiration \u003d cert_parser.get_cert_expiration(server_pem)\n        self.amphora_repo.update(db_apis.get_session(), amphora_id,\n                                 cert_expiration\u003dcert_expiration)\nhere to check if the update has been called, we need to pass in the cert_expiration property, and it is a method, so we mock this method and pass in.","commit_id":"f952248b9b0ca32f30e29b3df668d8c4f78b0e59"},{"author":{"_account_id":10477,"name":"min wang","email":"swiftwangster@gmail.com","username":"minwang"},"change_message_id":"0d768acffc813bff2e32d301882ae032f2052901","unresolved":false,"context_lines":[{"line_number":672,"context_line":"        repo.AmphoraRepository.update.assert_called_once_with("},{"line_number":673,"context_line":"            \u0027TEST\u0027,"},{"line_number":674,"context_line":"            AMP_ID,"},{"line_number":675,"context_line":"            cert_expiration\u003d_cert_mock)"},{"line_number":676,"context_line":""},{"line_number":677,"context_line":"    def test_update_amphora_cert_busy_to_false(self,"},{"line_number":678,"context_line":"                                               mock_generate_uuid,"}],"source_content_type":"text/x-python","patch_set":48,"id":"ba8a016a_332a2791","line":675,"in_reply_to":"ba8a016a_b144ecb6","updated":"2015-11-19 14:15:33.000000000","message":"yes please, I see this kind of method before in other tests of octavia.","commit_id":"f952248b9b0ca32f30e29b3df668d8c4f78b0e59"},{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"e95860a10b16dc6bc941a0e02eee3062eeb7dd84","unresolved":false,"context_lines":[{"line_number":672,"context_line":"        repo.AmphoraRepository.update.assert_called_once_with("},{"line_number":673,"context_line":"            \u0027TEST\u0027,"},{"line_number":674,"context_line":"            AMP_ID,"},{"line_number":675,"context_line":"            cert_expiration\u003d_cert_mock)"},{"line_number":676,"context_line":""},{"line_number":677,"context_line":"    def test_update_amphora_cert_busy_to_false(self,"},{"line_number":678,"context_line":"                                               mock_generate_uuid,"}],"source_content_type":"text/x-python","patch_set":48,"id":"ba8a016a_b144ecb6","line":675,"in_reply_to":"ba8a016a_cdd24c5c","updated":"2015-11-19 04:10:42.000000000","message":"Ah yes, I missed that you had actually mocked the function directly, not the class. I guess I\u0027ve not seen this mock syntax, as I was paying attention to \"_cert_mock \u003d mock.MagicMock()\" above, but it is something different in this function due to the way you patched? I\u0027ll have to research this syntax.","commit_id":"f952248b9b0ca32f30e29b3df668d8c4f78b0e59"}],"octavia/tests/unit/controller/worker/test_controller_worker.py":[{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"f6c7ebdbcdb60215c51b317ec6d0e88d295a878d","unresolved":false,"context_lines":[{"line_number":141,"context_line":""},{"line_number":142,"context_line":"        (base_taskflow.BaseTaskFlowEngine._taskflow_load."},{"line_number":143,"context_line":"            assert_called_once_with(\u0027TEST\u0027,"},{"line_number":144,"context_line":"                                    store\u003d{constants.AMPHORA: _amphora_mock}))"},{"line_number":145,"context_line":""},{"line_number":146,"context_line":"        _flow_mock.run.assert_called_once_with()"},{"line_number":147,"context_line":""}],"source_content_type":"text/x-python","patch_set":50,"id":"9a8ffd7b_db1e095f","line":144,"range":{"start_line":144,"start_character":43,"end_line":144,"end_character":52},"updated":"2015-11-30 18:46:42.000000000","message":"The changes in this file are un-related to the patch.","commit_id":"678cc697c20cf63601258ae3cf6a81166075900c"}]}
