)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":31857,"name":"Ayumu Ueha","email":"ueha.ayumu@fujitsu.com","username":"ueha"},"change_message_id":"4eeb1636bfe6777e3dceb201312018cf63d82a10","unresolved":true,"context_lines":[{"line_number":13,"context_line":"1.Fix the error when the database virtual field extracts"},{"line_number":14,"context_line":"the value from json in table `vnf_lcm_filters`."},{"line_number":15,"context_line":"2.Fix the error of sql query statement when querying subscription."},{"line_number":16,"context_line":"3.Fix type unmatch, request data format error, etc."},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"Closes-Bug: #1933169"},{"line_number":19,"context_line":"Change-Id: I51c198d60001dba94dd369f495cecef526e79800"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":4,"id":"1a19a5ff_7707a2b3","line":16,"range":{"start_line":16,"start_character":47,"end_line":16,"end_character":50},"updated":"2021-08-04 00:41:08.000000000","message":"Could you clearly describe the changes in this part?\nI think the description of the changes should be clear.","commit_id":"673df1b890e18bebc95ec3f82ec7545ab95020f2"},{"author":{"_account_id":33492,"name":"Yi Feng","email":"fengyi@fujitsu.com","username":"YiFeng"},"change_message_id":"e1e4778c8f4d35cb3605cc2c093f77207691cd87","unresolved":true,"context_lines":[{"line_number":13,"context_line":"1.Fix the error when the database virtual field extracts"},{"line_number":14,"context_line":"the value from json in table `vnf_lcm_filters`."},{"line_number":15,"context_line":"2.Fix the error of sql query statement when querying subscription."},{"line_number":16,"context_line":"3.Fix type unmatch, request data format error, etc."},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"Closes-Bug: #1933169"},{"line_number":19,"context_line":"Change-Id: I51c198d60001dba94dd369f495cecef526e79800"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":4,"id":"23f72818_8506c17e","line":16,"range":{"start_line":16,"start_character":47,"end_line":16,"end_character":50},"in_reply_to":"1a19a5ff_7707a2b3","updated":"2021-08-04 06:12:36.000000000","message":"Thank you for your comment, I modified the description.","commit_id":"673df1b890e18bebc95ec3f82ec7545ab95020f2"}],"tacker/api/vnflcm/v1/controller.py":[{"author":{"_account_id":25701,"name":"Yasufumi Ogawa","email":"yasufum.o@gmail.com","username":"yasufum"},"change_message_id":"2f3cc3b97627d1a9abac1f5a089d195aff0ae1aa","unresolved":true,"context_lines":[{"line_number":962,"context_line":"            LOG.debug(\"vnf_lcm_subscription %s\" % vnf_lcm_subscription)"},{"line_number":963,"context_line":"        except exceptions.SeeOther as e:"},{"line_number":964,"context_line":"            res \u003d webob.Response(content_type\u003d\u0027application/json\u0027)"},{"line_number":965,"context_line":"            res.status_int \u003d 303"},{"line_number":966,"context_line":"            location \u003d ("},{"line_number":967,"context_line":"                \u0027Location\u0027,"},{"line_number":968,"context_line":"                CONF.vnf_lcm.endpoint_url.rstrip(\"/\") +"}],"source_content_type":"text/x-python","patch_set":5,"id":"e70c858d_83262497","line":965,"range":{"start_line":965,"start_character":29,"end_line":965,"end_character":32},"updated":"2021-09-15 10:06:34.000000000","message":"You should better to use `http_client.SEE_OTHER.value` instead.","commit_id":"c0ded58ddf39c433f2b18779321f75ccd1445ff6"},{"author":{"_account_id":33492,"name":"Yi Feng","email":"fengyi@fujitsu.com","username":"YiFeng"},"change_message_id":"a7ddff8f0d1957670a47d07bb8a97dce00d5bb98","unresolved":true,"context_lines":[{"line_number":962,"context_line":"            LOG.debug(\"vnf_lcm_subscription %s\" % vnf_lcm_subscription)"},{"line_number":963,"context_line":"        except exceptions.SeeOther as e:"},{"line_number":964,"context_line":"            res \u003d webob.Response(content_type\u003d\u0027application/json\u0027)"},{"line_number":965,"context_line":"            res.status_int \u003d 303"},{"line_number":966,"context_line":"            location \u003d ("},{"line_number":967,"context_line":"                \u0027Location\u0027,"},{"line_number":968,"context_line":"                CONF.vnf_lcm.endpoint_url.rstrip(\"/\") +"}],"source_content_type":"text/x-python","patch_set":5,"id":"c97df03c_41d70933","line":965,"range":{"start_line":965,"start_character":29,"end_line":965,"end_character":32},"in_reply_to":"e70c858d_83262497","updated":"2021-09-20 08:17:12.000000000","message":"I have fixed it in PS 6.","commit_id":"c0ded58ddf39c433f2b18779321f75ccd1445ff6"}],"tacker/objects/vnf_lcm_subscriptions.py":[{"author":{"_account_id":33455,"name":"Hiromu Asahina","email":"hiromu.a5a@gmail.com","username":"h_asahina"},"change_message_id":"68ccdd47392ee1de31be48a3d867defd36cb8f1d","unresolved":true,"context_lines":[{"line_number":242,"context_line":"                if key in VNF_INSTANCE_SUBSCRIPTION_FILTER:"},{"line_number":243,"context_line":"                    value \u003d column[key]"},{"line_number":244,"context_line":"                    if key in VNF_INSTANCE_SUBSCRIPTION_FILTER_LISTS:"},{"line_number":245,"context_line":"                        if value:"},{"line_number":246,"context_line":"                            value \u003d _make_list(value)"},{"line_number":247,"context_line":"                            sql \u003d \\"},{"line_number":248,"context_line":"                                (sql + \" JSON_CONTAINS({}, \u0027{}\u0027) and \".format("}],"source_content_type":"text/x-python","patch_set":1,"id":"a79ccc32_840c1710","line":245,"updated":"2021-07-05 01:31:24.000000000","message":"I think it\u0027s too nested and hard to imagine the final result of a SQL query string created here, It might be better to refactor it and flatten it. Also, + operator is too slow, how about `join`ing all parts of a SQL query at the end instead of concating a part of a query for each step?","commit_id":"210de432a17649f72c153dc86b1082afa7450a9c"},{"author":{"_account_id":33492,"name":"Yi Feng","email":"fengyi@fujitsu.com","username":"YiFeng"},"change_message_id":"a45b53a3ec4c1658a13bdf07097cce642232b643","unresolved":true,"context_lines":[{"line_number":242,"context_line":"                if key in VNF_INSTANCE_SUBSCRIPTION_FILTER:"},{"line_number":243,"context_line":"                    value \u003d column[key]"},{"line_number":244,"context_line":"                    if key in VNF_INSTANCE_SUBSCRIPTION_FILTER_LISTS:"},{"line_number":245,"context_line":"                        if value:"},{"line_number":246,"context_line":"                            value \u003d _make_list(value)"},{"line_number":247,"context_line":"                            sql \u003d \\"},{"line_number":248,"context_line":"                                (sql + \" JSON_CONTAINS({}, \u0027{}\u0027) and \".format("}],"source_content_type":"text/x-python","patch_set":1,"id":"b9ab01de_2ad8db1e","line":245,"in_reply_to":"a79ccc32_840c1710","updated":"2021-07-12 08:30:24.000000000","message":"I think it`s hard to imagine the final result of a SQL query string created here too. Before running the old code, I spent a long time without figuring out what SQL query string it will generate. But from the perspective of respecting the old code, I did not rewrite this code, but only corrected the errors. And I agree that `join`ing all parts of a SQL query at the end is better than + operator for each step. I will adopt your suggestion in patch 2.","commit_id":"210de432a17649f72c153dc86b1082afa7450a9c"},{"author":{"_account_id":33455,"name":"Hiromu Asahina","email":"hiromu.a5a@gmail.com","username":"h_asahina"},"change_message_id":"a6e5234d1ccce4913f1c3dfa875aa8c53b935b24","unresolved":false,"context_lines":[{"line_number":242,"context_line":"                if key in VNF_INSTANCE_SUBSCRIPTION_FILTER:"},{"line_number":243,"context_line":"                    value \u003d column[key]"},{"line_number":244,"context_line":"                    if key in VNF_INSTANCE_SUBSCRIPTION_FILTER_LISTS:"},{"line_number":245,"context_line":"                        if value:"},{"line_number":246,"context_line":"                            value \u003d _make_list(value)"},{"line_number":247,"context_line":"                            sql \u003d \\"},{"line_number":248,"context_line":"                                (sql + \" JSON_CONTAINS({}, \u0027{}\u0027) and \".format("}],"source_content_type":"text/x-python","patch_set":1,"id":"3b15124e_20b741d2","line":245,"in_reply_to":"b9ab01de_2ad8db1e","updated":"2021-07-26 02:25:48.000000000","message":"Thank you :) \nLGTM.","commit_id":"210de432a17649f72c153dc86b1082afa7450a9c"},{"author":{"_account_id":25701,"name":"Yasufumi Ogawa","email":"yasufum.o@gmail.com","username":"yasufum"},"change_message_id":"2f3cc3b97627d1a9abac1f5a089d195aff0ae1aa","unresolved":true,"context_lines":[{"line_number":238,"context_line":"        column_list \u003d _get_vnf_subscription_filter_values("},{"line_number":239,"context_line":"            vnf_instance_subscription_filter)"},{"line_number":240,"context_line":""},{"line_number":241,"context_line":"        sql_lst \u003d [sql]"},{"line_number":242,"context_line":"        for column in column_list:"},{"line_number":243,"context_line":"            for key in column:"},{"line_number":244,"context_line":"                if key in VNF_INSTANCE_SUBSCRIPTION_FILTER:"},{"line_number":245,"context_line":"                    value \u003d column[key]"},{"line_number":246,"context_line":"                    if key in VNF_INSTANCE_SUBSCRIPTION_FILTER_LISTS:"},{"line_number":247,"context_line":"                        if value:"},{"line_number":248,"context_line":"                            value \u003d _make_list(value)"},{"line_number":249,"context_line":"                            sql_lst.append("},{"line_number":250,"context_line":"                                \" JSON_CONTAINS({}, \u0027{}\u0027) and \".format("},{"line_number":251,"context_line":"                                    convert_string_to_snakecase(key), value))"},{"line_number":252,"context_line":"                        else:"},{"line_number":253,"context_line":"                            sql_lst.append(\" {}_len\u003d0 and \".format("},{"line_number":254,"context_line":"                                convert_string_to_snakecase(key)))"},{"line_number":255,"context_line":"                    else:"},{"line_number":256,"context_line":"                        sql_lst.append(\" {}\u003d\u0027{}\u0027 and \".format("},{"line_number":257,"context_line":"                            convert_string_to_snakecase(key), value))"},{"line_number":258,"context_line":""},{"line_number":259,"context_line":"                    included_in_filter.append(key)"},{"line_number":260,"context_line":"        sql \u003d \u0027\u0027.join(sql_lst)"},{"line_number":261,"context_line":""},{"line_number":262,"context_line":"        not_included_in_filter \u003d list("},{"line_number":263,"context_line":"            set(VNF_INSTANCE_SUBSCRIPTION_FILTER_LISTS) -"}],"source_content_type":"text/x-python","patch_set":5,"id":"119389f6_3633f4bf","line":260,"range":{"start_line":241,"start_character":0,"end_line":260,"end_character":30},"updated":"2021-09-15 10:06:34.000000000","message":"I don\u0027t understand why you assign `sql_lst`, stands for a list of SQL? Is there any reason to have a list at once and join later which looks something make it complex a bit?","commit_id":"c0ded58ddf39c433f2b18779321f75ccd1445ff6"},{"author":{"_account_id":33492,"name":"Yi Feng","email":"fengyi@fujitsu.com","username":"YiFeng"},"change_message_id":"a7ddff8f0d1957670a47d07bb8a97dce00d5bb98","unresolved":true,"context_lines":[{"line_number":238,"context_line":"        column_list \u003d _get_vnf_subscription_filter_values("},{"line_number":239,"context_line":"            vnf_instance_subscription_filter)"},{"line_number":240,"context_line":""},{"line_number":241,"context_line":"        sql_lst \u003d [sql]"},{"line_number":242,"context_line":"        for column in column_list:"},{"line_number":243,"context_line":"            for key in column:"},{"line_number":244,"context_line":"                if key in VNF_INSTANCE_SUBSCRIPTION_FILTER:"},{"line_number":245,"context_line":"                    value \u003d column[key]"},{"line_number":246,"context_line":"                    if key in VNF_INSTANCE_SUBSCRIPTION_FILTER_LISTS:"},{"line_number":247,"context_line":"                        if value:"},{"line_number":248,"context_line":"                            value \u003d _make_list(value)"},{"line_number":249,"context_line":"                            sql_lst.append("},{"line_number":250,"context_line":"                                \" JSON_CONTAINS({}, \u0027{}\u0027) and \".format("},{"line_number":251,"context_line":"                                    convert_string_to_snakecase(key), value))"},{"line_number":252,"context_line":"                        else:"},{"line_number":253,"context_line":"                            sql_lst.append(\" {}_len\u003d0 and \".format("},{"line_number":254,"context_line":"                                convert_string_to_snakecase(key)))"},{"line_number":255,"context_line":"                    else:"},{"line_number":256,"context_line":"                        sql_lst.append(\" {}\u003d\u0027{}\u0027 and \".format("},{"line_number":257,"context_line":"                            convert_string_to_snakecase(key), value))"},{"line_number":258,"context_line":""},{"line_number":259,"context_line":"                    included_in_filter.append(key)"},{"line_number":260,"context_line":"        sql \u003d \u0027\u0027.join(sql_lst)"},{"line_number":261,"context_line":""},{"line_number":262,"context_line":"        not_included_in_filter \u003d list("},{"line_number":263,"context_line":"            set(VNF_INSTANCE_SUBSCRIPTION_FILTER_LISTS) -"}],"source_content_type":"text/x-python","patch_set":5,"id":"cf33b50c_d5ea1546","line":260,"range":{"start_line":241,"start_character":0,"end_line":260,"end_character":30},"in_reply_to":"119389f6_3633f4bf","updated":"2021-09-20 08:17:12.000000000","message":"Hiromu Asahina san commented in the previous code. The efficiency is too slow if you directly use the `+` operator, so the `join` method improves the efficiency. The detailed content can be viewed in this comment\u0027s point 3.\nhttps://review.opendev.org/c/openstack/tacker/+/797804/1..5#message-a45b53a3ec4c1658a13bdf07097cce642232b643","commit_id":"c0ded58ddf39c433f2b18779321f75ccd1445ff6"}]}
