)]}'
{"/PATCHSET_LEVEL":[{"author":{"_account_id":31664,"name":"Omer Schwartz","email":"oschwart@redhat.com","username":"oschwart"},"change_message_id":"6b744a6728b207cf678df4d9644f75550d0ddc9d","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"520a581c_bf56bfda","updated":"2023-08-09 12:58:16.000000000","message":"I am not sure where to test it, as on octavia/test/unit/api/v2 there is no controllers directory. Should we create one, with a test_amphora.py file? Any other suggestions?","commit_id":"6e56dfac7851605f0a7af520d552ec322479d331"},{"author":{"_account_id":31664,"name":"Omer Schwartz","email":"oschwart@redhat.com","username":"oschwart"},"change_message_id":"c117bb9f6b85898eb85958132938c4a5bf7060be","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":6,"id":"515e716b_dc81da43","updated":"2023-09-01 15:22:51.000000000","message":"I am still getting amp stats not found, even with the patch","commit_id":"092042b7c9c1163bdcd5fadf435a1152f3f5e1e2"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"ab895f4e0320ea5207db912cc7579f1c894e5738","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":9,"id":"f7338935_81b95d7b","updated":"2024-01-10 17:36:21.000000000","message":"LGTM, thanks!","commit_id":"0c367b4fedecbc0242d6bd3c217bc33e92ab5a1d"}],"octavia/amphorae/drivers/noop_driver/driver.py":[{"author":{"_account_id":34429,"name":"Tom Weininger","email":"dienste@weinimo.de","username":"tweining"},"change_message_id":"3cf3eded749ec37b40969437c8fc096119c01ea6","unresolved":true,"context_lines":[{"line_number":47,"context_line":"                bytes_out\u003drandom.randrange(1000000000),"},{"line_number":48,"context_line":"                active_connections\u003drandom.randrange(1000000000),"},{"line_number":49,"context_line":"                total_connections\u003drandom.randrange(1000000000),"},{"line_number":50,"context_line":"                request_errors\u003drandom.randrange(1000000000),"},{"line_number":51,"context_line":"            )"},{"line_number":52,"context_line":"            listener_stats_repo.replace(session\u003ddb_apis.get_session(),"},{"line_number":53,"context_line":"                                        stats_obj\u003dstats_obj)"}],"source_content_type":"text/x-python","patch_set":7,"id":"f2c8d156_1fa1a995","line":50,"updated":"2023-10-31 08:05:36.000000000","message":"Why is the `received_time` argument not set?","commit_id":"73270b6fbad126a5fffb0d5fc49f6c471480710d"},{"author":{"_account_id":31664,"name":"Omer Schwartz","email":"oschwart@redhat.com","username":"oschwart"},"change_message_id":"07f7632a9541a49c0c67eea2fc6a70053529f62f","unresolved":false,"context_lines":[{"line_number":47,"context_line":"                bytes_out\u003drandom.randrange(1000000000),"},{"line_number":48,"context_line":"                active_connections\u003drandom.randrange(1000000000),"},{"line_number":49,"context_line":"                total_connections\u003drandom.randrange(1000000000),"},{"line_number":50,"context_line":"                request_errors\u003drandom.randrange(1000000000),"},{"line_number":51,"context_line":"            )"},{"line_number":52,"context_line":"            listener_stats_repo.replace(session\u003ddb_apis.get_session(),"},{"line_number":53,"context_line":"                                        stats_obj\u003dstats_obj)"}],"source_content_type":"text/x-python","patch_set":7,"id":"14187ca4_f9582f5a","line":50,"in_reply_to":"f2c8d156_1fa1a995","updated":"2023-10-31 09:39:56.000000000","message":"I missed it, and now it is added, thanks.","commit_id":"73270b6fbad126a5fffb0d5fc49f6c471480710d"}],"octavia/api/v2/controllers/amphora.py":[{"author":{"_account_id":29244,"name":"Gregory Thiemonge","email":"gthiemon@redhat.com","username":"gthiemonge"},"change_message_id":"eb9b94da2e92cf39f5bcbef8d495432971e00e68","unresolved":true,"context_lines":[{"line_number":213,"context_line":"                                   constants.RBAC_GET_STATS)"},{"line_number":214,"context_line":""},{"line_number":215,"context_line":"        # Fake Amphora stats if noop"},{"line_number":216,"context_line":"        if (constants.AMPHORAV2 in"},{"line_number":217,"context_line":"                CONF.api_settings.enabled_provider_drivers and"},{"line_number":218,"context_line":"                constants.VOLUME_NOOP_DRIVER in"},{"line_number":219,"context_line":"                CONF.controller_worker.volume_driver):"},{"line_number":220,"context_line":"            stats \u003d {"},{"line_number":221,"context_line":"                \u0027active_connections\u0027: 0,"},{"line_number":222,"context_line":"                \u0027bytes_in\u0027: 0,"}],"source_content_type":"text/x-python","patch_set":3,"id":"281a230c_86f960ae","line":219,"range":{"start_line":216,"start_character":12,"end_line":219,"end_character":52},"updated":"2023-08-21 08:37:07.000000000","message":"that doesn\u0027t make sense\n* amphorav2 may not be in enabled_provider_drivers because people may use the alias amphora\n* with volume_noop_driver, it\u0027s perfectly fine to use it, it doesn\u0027t mean that we have fake amphorae","commit_id":"34a44c80bfa0341f12b9435aeb9607661f4a05d4"},{"author":{"_account_id":31664,"name":"Omer Schwartz","email":"oschwart@redhat.com","username":"oschwart"},"change_message_id":"6eb6e722c5817b23f622caec3ad9e4ab1dcc26c3","unresolved":true,"context_lines":[{"line_number":213,"context_line":"                                   constants.RBAC_GET_STATS)"},{"line_number":214,"context_line":""},{"line_number":215,"context_line":"        # Fake Amphora stats if noop"},{"line_number":216,"context_line":"        if (constants.AMPHORAV2 in"},{"line_number":217,"context_line":"                CONF.api_settings.enabled_provider_drivers and"},{"line_number":218,"context_line":"                constants.VOLUME_NOOP_DRIVER in"},{"line_number":219,"context_line":"                CONF.controller_worker.volume_driver):"},{"line_number":220,"context_line":"            stats \u003d {"},{"line_number":221,"context_line":"                \u0027active_connections\u0027: 0,"},{"line_number":222,"context_line":"                \u0027bytes_in\u0027: 0,"}],"source_content_type":"text/x-python","patch_set":3,"id":"d3230712_f2e02504","line":219,"range":{"start_line":216,"start_character":12,"end_line":219,"end_character":52},"in_reply_to":"281a230c_86f960ae","updated":"2023-08-21 10:41:19.000000000","message":"ok, I think I know how to implement this check correctly.\nif not, feel free to make any suggestions.","commit_id":"34a44c80bfa0341f12b9435aeb9607661f4a05d4"},{"author":{"_account_id":29244,"name":"Gregory Thiemonge","email":"gthiemon@redhat.com","username":"gthiemonge"},"change_message_id":"d6f97cd6e18b8e9b2972bf6fa2f47012dd8bbd85","unresolved":true,"context_lines":[{"line_number":213,"context_line":"                                   constants.RBAC_GET_STATS)"},{"line_number":214,"context_line":""},{"line_number":215,"context_line":"        # Fake Amphora stats if noop"},{"line_number":216,"context_line":"        if (constants.AMPHORAV2 in"},{"line_number":217,"context_line":"                CONF.api_settings.enabled_provider_drivers and"},{"line_number":218,"context_line":"                constants.VOLUME_NOOP_DRIVER in"},{"line_number":219,"context_line":"                CONF.controller_worker.volume_driver):"},{"line_number":220,"context_line":"            stats \u003d {"},{"line_number":221,"context_line":"                \u0027active_connections\u0027: 0,"},{"line_number":222,"context_line":"                \u0027bytes_in\u0027: 0,"}],"source_content_type":"text/x-python","patch_set":3,"id":"f8ecb005_b199a165","line":219,"range":{"start_line":216,"start_character":12,"end_line":219,"end_character":52},"in_reply_to":"d3230712_f2e02504","updated":"2023-08-21 11:54:16.000000000","message":"an alternative method would be (pseudo-code):\n\n```\nstats \u003d get_stats(amp_id)\nif not stats:\n    if amp_exist(amp_id):\n        stats \u003d [{ empty_stats }]\n    else:\n        raise exceptions.NotFound(\"blah\")\n```\n\na few benefits:\n1. it doesn\u0027t need to check the driver\n2. it would also work with a \u0027get\u0027 on a amphora that doesn\u0027t have a listener (currently an amphora on a LB without a listener returns an error)\n\nwhat do you think about that?","commit_id":"34a44c80bfa0341f12b9435aeb9607661f4a05d4"},{"author":{"_account_id":31664,"name":"Omer Schwartz","email":"oschwart@redhat.com","username":"oschwart"},"change_message_id":"228462c65cf2b1d5478c5b6865fec712f6bbaa2f","unresolved":false,"context_lines":[{"line_number":213,"context_line":"                                   constants.RBAC_GET_STATS)"},{"line_number":214,"context_line":""},{"line_number":215,"context_line":"        # Fake Amphora stats if noop"},{"line_number":216,"context_line":"        if (constants.AMPHORAV2 in"},{"line_number":217,"context_line":"                CONF.api_settings.enabled_provider_drivers and"},{"line_number":218,"context_line":"                constants.VOLUME_NOOP_DRIVER in"},{"line_number":219,"context_line":"                CONF.controller_worker.volume_driver):"},{"line_number":220,"context_line":"            stats \u003d {"},{"line_number":221,"context_line":"                \u0027active_connections\u0027: 0,"},{"line_number":222,"context_line":"                \u0027bytes_in\u0027: 0,"}],"source_content_type":"text/x-python","patch_set":3,"id":"5da5436b_db6968ea","line":219,"range":{"start_line":216,"start_character":12,"end_line":219,"end_character":52},"in_reply_to":"f8ecb005_b199a165","updated":"2023-08-22 10:43:57.000000000","message":"Done, I also tested it on my devstack and as you mentioned, now it also works when amphora is on a LB without a listener.","commit_id":"34a44c80bfa0341f12b9435aeb9607661f4a05d4"},{"author":{"_account_id":29244,"name":"Gregory Thiemonge","email":"gthiemon@redhat.com","username":"gthiemonge"},"change_message_id":"eb9b94da2e92cf39f5bcbef8d495432971e00e68","unresolved":true,"context_lines":[{"line_number":217,"context_line":"                CONF.api_settings.enabled_provider_drivers and"},{"line_number":218,"context_line":"                constants.VOLUME_NOOP_DRIVER in"},{"line_number":219,"context_line":"                CONF.controller_worker.volume_driver):"},{"line_number":220,"context_line":"            stats \u003d {"},{"line_number":221,"context_line":"                \u0027active_connections\u0027: 0,"},{"line_number":222,"context_line":"                \u0027bytes_in\u0027: 0,"},{"line_number":223,"context_line":"                \u0027bytes_out\u0027: 0,"}],"source_content_type":"text/x-python","patch_set":3,"id":"5aab009c_8e9e1f4a","line":220,"range":{"start_line":220,"start_character":12,"end_line":220,"end_character":17},"updated":"2023-08-21 08:37:07.000000000","message":"at line 235 it is expected that stats is an array but it is a dict here","commit_id":"34a44c80bfa0341f12b9435aeb9607661f4a05d4"},{"author":{"_account_id":31664,"name":"Omer Schwartz","email":"oschwart@redhat.com","username":"oschwart"},"change_message_id":"6eb6e722c5817b23f622caec3ad9e4ab1dcc26c3","unresolved":false,"context_lines":[{"line_number":217,"context_line":"                CONF.api_settings.enabled_provider_drivers and"},{"line_number":218,"context_line":"                constants.VOLUME_NOOP_DRIVER in"},{"line_number":219,"context_line":"                CONF.controller_worker.volume_driver):"},{"line_number":220,"context_line":"            stats \u003d {"},{"line_number":221,"context_line":"                \u0027active_connections\u0027: 0,"},{"line_number":222,"context_line":"                \u0027bytes_in\u0027: 0,"},{"line_number":223,"context_line":"                \u0027bytes_out\u0027: 0,"}],"source_content_type":"text/x-python","patch_set":3,"id":"9bf09d55_b098ce2b","line":220,"range":{"start_line":220,"start_character":12,"end_line":220,"end_character":17},"in_reply_to":"5aab009c_8e9e1f4a","updated":"2023-08-21 10:41:19.000000000","message":"Thanks, I will change it to a list of dictionaries.","commit_id":"34a44c80bfa0341f12b9435aeb9607661f4a05d4"},{"author":{"_account_id":11628,"name":"Michael Johnson","email":"johnsomor@gmail.com","username":"johnsom"},"change_message_id":"08ae738388af1454defb83389a98809c6d225e6b","unresolved":true,"context_lines":[{"line_number":215,"context_line":"        stats \u003d self.repositories.get_amphora_stats(context.session,"},{"line_number":216,"context_line":"                                                    self.amp_id)"},{"line_number":217,"context_line":"        if not stats:"},{"line_number":218,"context_line":"            # if amphora exists and stats object doesn\u0027t: there is no listener."},{"line_number":219,"context_line":"            # return empty stats"},{"line_number":220,"context_line":"            self._get_db_amp(context.session, self.amp_id, show_deleted\u003dFalse)"},{"line_number":221,"context_line":"            stats \u003d [{"}],"source_content_type":"text/x-python","patch_set":5,"id":"da20d473_ae944e7c","line":218,"updated":"2023-08-23 20:57:33.000000000","message":"Hmm, this is an API behavior change. If someone is using this programmatically the behavior changes on them. Where they got a 404 before, they now get an empty dict.\nThis is one reason I limited it to the no-op driver.","commit_id":"832552544ce5ec8566b1170339236d00249e932c"},{"author":{"_account_id":31664,"name":"Omer Schwartz","email":"oschwart@redhat.com","username":"oschwart"},"change_message_id":"01ffe53de3f4d2cfbc99f225609aa6f475e14753","unresolved":true,"context_lines":[{"line_number":215,"context_line":"        stats \u003d self.repositories.get_amphora_stats(context.session,"},{"line_number":216,"context_line":"                                                    self.amp_id)"},{"line_number":217,"context_line":"        if not stats:"},{"line_number":218,"context_line":"            # if amphora exists and stats object doesn\u0027t: there is no listener."},{"line_number":219,"context_line":"            # return empty stats"},{"line_number":220,"context_line":"            self._get_db_amp(context.session, self.amp_id, show_deleted\u003dFalse)"},{"line_number":221,"context_line":"            stats \u003d [{"}],"source_content_type":"text/x-python","patch_set":5,"id":"17a960af_c30e61b2","line":218,"in_reply_to":"da20d473_ae944e7c","updated":"2023-09-01 13:30:08.000000000","message":"I added some dummy amphora stats to the amphorae noop driver","commit_id":"832552544ce5ec8566b1170339236d00249e932c"}],"releasenotes/notes/add-noop-amphora-stats-2cc64717f85eb9a8.yaml":[{"author":{"_account_id":34429,"name":"Tom Weininger","email":"dienste@weinimo.de","username":"tweining"},"change_message_id":"3cf3eded749ec37b40969437c8fc096119c01ea6","unresolved":true,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"fixes:"},{"line_number":3,"context_line":"  - |"},{"line_number":4,"context_line":"    Add fake Amphora stats for when Octavia runs in noop mode / using"},{"line_number":5,"context_line":"    noop drivers."}],"source_content_type":"text/x-yaml","patch_set":7,"id":"f3a46acf_df193963","line":2,"range":{"start_line":2,"start_character":0,"end_line":2,"end_character":5},"updated":"2023-10-31 08:05:36.000000000","message":"Yes, this fixes a testing issue, but it is not really a bug fix. Hence, I think other is not suitable.","commit_id":"73270b6fbad126a5fffb0d5fc49f6c471480710d"},{"author":{"_account_id":31664,"name":"Omer Schwartz","email":"oschwart@redhat.com","username":"oschwart"},"change_message_id":"07f7632a9541a49c0c67eea2fc6a70053529f62f","unresolved":false,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"fixes:"},{"line_number":3,"context_line":"  - |"},{"line_number":4,"context_line":"    Add fake Amphora stats for when Octavia runs in noop mode / using"},{"line_number":5,"context_line":"    noop drivers."}],"source_content_type":"text/x-yaml","patch_set":7,"id":"307e84f1_b805201a","line":2,"range":{"start_line":2,"start_character":0,"end_line":2,"end_character":5},"in_reply_to":"442a0b22_819fc895","updated":"2023-10-31 09:39:56.000000000","message":"Done","commit_id":"73270b6fbad126a5fffb0d5fc49f6c471480710d"},{"author":{"_account_id":34429,"name":"Tom Weininger","email":"dienste@weinimo.de","username":"tweining"},"change_message_id":"e7abf3674bf7d51e5341cb988b537eeae6b73679","unresolved":true,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"fixes:"},{"line_number":3,"context_line":"  - |"},{"line_number":4,"context_line":"    Add fake Amphora stats for when Octavia runs in noop mode / using"},{"line_number":5,"context_line":"    noop drivers."}],"source_content_type":"text/x-yaml","patch_set":7,"id":"442a0b22_819fc895","line":2,"range":{"start_line":2,"start_character":0,"end_line":2,"end_character":5},"in_reply_to":"f3a46acf_df193963","updated":"2023-10-31 08:06:34.000000000","message":"s/not suitable/more suitable/","commit_id":"73270b6fbad126a5fffb0d5fc49f6c471480710d"}]}
