)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"8a5c85b1215295abf49c06f1a3e4977627f93f21","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"recovery: use given session"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Don\u0027t mix given session and session created by get_admin_state."},{"line_number":10,"context_line":"Given session needs to be used consistently."},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"Change-Id: Idbda084693bd203e6baf074e1e7567eacafe9dbd"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"7ffa3b31_02179fef","line":9,"range":{"start_line":9,"start_character":57,"end_line":9,"end_character":62},"updated":"2017-04-18 09:15:40.000000000","message":"context","commit_id":"7e29d2027ea044a76d15380560582e941bda1691"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"cce584d69d7b017e7281b5a9263ca0ae5482b2f2","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"recovery: use given session"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Don\u0027t mix given session and session created by get_admin_state."},{"line_number":10,"context_line":"Given session needs to be used consistently."},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"Change-Id: Idbda084693bd203e6baf074e1e7567eacafe9dbd"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":7,"id":"df140735_310d9b3e","line":9,"range":{"start_line":9,"start_character":57,"end_line":9,"end_character":62},"updated":"2017-05-29 05:53:19.000000000","message":"context","commit_id":"8537da22d2825ac133419c96a1a9c3a6379ec45f"},{"author":{"_account_id":7921,"name":"Mike Kolesnik","email":"mkolesni@redhat.com","username":"mkolesni"},"change_message_id":"5e76453324f48fefd8be7dccb4de4178b260ed88","unresolved":false,"context_lines":[{"line_number":9,"context_line":"Don\u0027t mix given session and session created by get_admin_context."},{"line_number":10,"context_line":"Given session needs to be used consistently."},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"Change-Id: Idbda084693bd203e6baf074e1e7567eacafe9dbd"},{"line_number":13,"context_line":"Co-Authored-By: Rajiv Kumar \u003crajiv.kumar@nectechnologies.in\u003e"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":20,"id":"ff346bd7_b7a96ee0","line":12,"range":{"start_line":12,"start_character":0,"end_line":12,"end_character":52},"updated":"2017-07-24 08:47:00.000000000","message":"Missing closes bug clause","commit_id":"d1551042690c853807f25680e36edc77884946f4"},{"author":{"_account_id":333,"name":"Isaku Yamahata","email":"isaku.yamahata@gmail.com","username":"yamahata"},"change_message_id":"ac50abcf1277f498de28b65c45ad20ee5b3c2686","unresolved":false,"context_lines":[{"line_number":9,"context_line":"Don\u0027t mix given session and session created by get_admin_context."},{"line_number":10,"context_line":"Given session needs to be used consistently."},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"Change-Id: Idbda084693bd203e6baf074e1e7567eacafe9dbd"},{"line_number":13,"context_line":"Co-Authored-By: Rajiv Kumar \u003crajiv.kumar@nectechnologies.in\u003e"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":20,"id":"ff346bd7_e31283b1","line":12,"range":{"start_line":12,"start_character":0,"end_line":12,"end_character":52},"in_reply_to":"ff346bd7_b7a96ee0","updated":"2017-07-24 19:33:37.000000000","message":"Done","commit_id":"d1551042690c853807f25680e36edc77884946f4"}],"networking_odl/common/context.py":[{"author":{"_account_id":13912,"name":"rajiv","email":"thenakliman@gmail.com","username":"rajiv.kumar"},"change_message_id":"18f3580ee4aa1549d1044951a18b5fadbec0d223","unresolved":false,"context_lines":[{"line_number":19,"context_line":""},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"def get_admin_context_with_session(session):"},{"line_number":22,"context_line":"    # NOTE(yamahata): see nuetron_context.get_admin_context()"},{"line_number":23,"context_line":"    context \u003d neutron_context.get_admin_context()"},{"line_number":24,"context_line":"    context._session \u003d session"},{"line_number":25,"context_line":"    return context"}],"source_content_type":"text/x-python","patch_set":2,"id":"7ffa3b31_ae5eb8e3","line":22,"range":{"start_line":22,"start_character":25,"end_line":22,"end_character":35},"updated":"2017-04-17 07:15:51.000000000","message":"spelling mistake","commit_id":"1aaacd59df090aa2675d10db5b79c1aacccb253d"},{"author":{"_account_id":333,"name":"Isaku Yamahata","email":"isaku.yamahata@gmail.com","username":"yamahata"},"change_message_id":"b39259074935ebad6594a86e6f2dedc64ad0647d","unresolved":false,"context_lines":[{"line_number":19,"context_line":""},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"def get_admin_context_with_session(session):"},{"line_number":22,"context_line":"    # NOTE(yamahata): see nuetron_context.get_admin_context()"},{"line_number":23,"context_line":"    context \u003d neutron_context.get_admin_context()"},{"line_number":24,"context_line":"    context._session \u003d session"},{"line_number":25,"context_line":"    return context"}],"source_content_type":"text/x-python","patch_set":2,"id":"7ffa3b31_0bab5089","line":22,"range":{"start_line":22,"start_character":25,"end_line":22,"end_character":35},"in_reply_to":"7ffa3b31_ae5eb8e3","updated":"2017-04-17 17:36:33.000000000","message":"Done","commit_id":"1aaacd59df090aa2675d10db5b79c1aacccb253d"},{"author":{"_account_id":13912,"name":"rajiv","email":"thenakliman@gmail.com","username":"rajiv.kumar"},"change_message_id":"18f3580ee4aa1549d1044951a18b5fadbec0d223","unresolved":false,"context_lines":[{"line_number":20,"context_line":""},{"line_number":21,"context_line":"def get_admin_context_with_session(session):"},{"line_number":22,"context_line":"    # NOTE(yamahata): see nuetron_context.get_admin_context()"},{"line_number":23,"context_line":"    context \u003d neutron_context.get_admin_context()"},{"line_number":24,"context_line":"    context._session \u003d session"},{"line_number":25,"context_line":"    return context"}],"source_content_type":"text/x-python","patch_set":2,"id":"7ffa3b31_ae13580d","line":23,"range":{"start_line":23,"start_character":14,"end_line":23,"end_character":49},"updated":"2017-04-17 07:15:51.000000000","message":"Do you think, calling https://github.com/openstack/neutron-lib/blob/master/neutron_lib/context.py#L168 and then assigning values to context._session \u003d (given session) will be a good idea?","commit_id":"1aaacd59df090aa2675d10db5b79c1aacccb253d"},{"author":{"_account_id":333,"name":"Isaku Yamahata","email":"isaku.yamahata@gmail.com","username":"yamahata"},"change_message_id":"b39259074935ebad6594a86e6f2dedc64ad0647d","unresolved":false,"context_lines":[{"line_number":20,"context_line":""},{"line_number":21,"context_line":"def get_admin_context_with_session(session):"},{"line_number":22,"context_line":"    # NOTE(yamahata): see nuetron_context.get_admin_context()"},{"line_number":23,"context_line":"    context \u003d neutron_context.get_admin_context()"},{"line_number":24,"context_line":"    context._session \u003d session"},{"line_number":25,"context_line":"    return context"}],"source_content_type":"text/x-python","patch_set":2,"id":"7ffa3b31_2ba60cc3","line":23,"range":{"start_line":23,"start_character":14,"end_line":23,"end_character":49},"in_reply_to":"7ffa3b31_ae13580d","updated":"2017-04-17 17:36:33.000000000","message":"Unfortunately it results in error because the super class of neutron-lib context, oslo_context.context.RequestContext doesn\u0027t accept session.","commit_id":"1aaacd59df090aa2675d10db5b79c1aacccb253d"},{"author":{"_account_id":13912,"name":"rajiv","email":"thenakliman@gmail.com","username":"rajiv.kumar"},"change_message_id":"a2303fa6044a8c07d9fbd556aedc2d2750a2bf19","unresolved":false,"context_lines":[{"line_number":21,"context_line":"def get_admin_context_with_session(session):"},{"line_number":22,"context_line":"    # NOTE(yamahata): see neutron_context.get_admin_context()"},{"line_number":23,"context_line":"    context \u003d neutron_context.get_admin_context()"},{"line_number":24,"context_line":"    context._session \u003d session"},{"line_number":25,"context_line":"    return context"}],"source_content_type":"text/x-python","patch_set":3,"id":"7ffa3b31_aab3214d","line":24,"range":{"start_line":24,"start_character":0,"end_line":24,"end_character":30},"updated":"2017-04-18 10:33:40.000000000","message":"I think, the reason of failure is not that ConextBase does not have session attribute. Because even get_admin_context create object of context which has base class ContextBase. The reason of failure is, Context class has defined session property therefore our code get session attribute lower in inheritance hierarchy.\n\nIf we do following \n\ncontext.session \u003d session\n\nIt should be solve the problem. I tested it, it is working.","commit_id":"7e29d2027ea044a76d15380560582e941bda1691"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"8a5c85b1215295abf49c06f1a3e4977627f93f21","unresolved":false,"context_lines":[{"line_number":22,"context_line":"    # NOTE(yamahata): see neutron_context.get_admin_context()"},{"line_number":23,"context_line":"    context \u003d neutron_context.get_admin_context()"},{"line_number":24,"context_line":"    context._session \u003d session"},{"line_number":25,"context_line":"    return context"}],"source_content_type":"text/x-python","patch_set":3,"id":"7ffa3b31_22773b05","line":25,"updated":"2017-04-18 09:15:40.000000000","message":"this looks awkward to me.\nwhy don\u0027t you pass a context around instead?","commit_id":"7e29d2027ea044a76d15380560582e941bda1691"},{"author":{"_account_id":17120,"name":"Manjeet Singh Bhatia","email":"manjeet.s.bhatia@intel.com","username":"manjeets"},"change_message_id":"b4d3cee1106ede6045adb2b8915b151bc48debc2","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":4,"id":"1f013ff3_5513275d","updated":"2017-05-16 17:38:28.000000000","message":"this should have a unit test to make sure context returned have a given session.","commit_id":"46f1d308bc03063d9aa3712876e1b1e662e02c4d"}],"networking_odl/journal/full_sync.py":[{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"a17918859f03423d8d4e83a06d9b94960f9aa5a8","unresolved":false,"context_lines":[{"line_number":77,"context_line":""},{"line_number":78,"context_line":"    db.delete_pending_rows(session, _OPS_TO_DELETE_ON_SYNC)"},{"line_number":79,"context_line":""},{"line_number":80,"context_line":"    dbcontext \u003d neutron_context.get_admin_context()"},{"line_number":81,"context_line":"    for resource_type in _ORDERED_ODL_RESOURCES:"},{"line_number":82,"context_line":"        for plugin_alias, resource in ALL_RESOURCES.items():"},{"line_number":83,"context_line":"            collection_name \u003d resource.get(resource_type)"}],"source_content_type":"text/x-python","patch_set":22,"id":"ff346bd7_ed1ca96b","line":80,"range":{"start_line":80,"start_character":32,"end_line":80,"end_character":49},"updated":"2017-07-25 01:14:15.000000000","message":"why don\u0027t you use the given context?","commit_id":"4f43c8b767e2a6195143428bc3552b9d28dc434a"},{"author":{"_account_id":333,"name":"Isaku Yamahata","email":"isaku.yamahata@gmail.com","username":"yamahata"},"change_message_id":"d740aecc474c534ed6eb0a247566e8345b03620a","unresolved":false,"context_lines":[{"line_number":77,"context_line":""},{"line_number":78,"context_line":"    db.delete_pending_rows(session, _OPS_TO_DELETE_ON_SYNC)"},{"line_number":79,"context_line":""},{"line_number":80,"context_line":"    dbcontext \u003d neutron_context.get_admin_context()"},{"line_number":81,"context_line":"    for resource_type in _ORDERED_ODL_RESOURCES:"},{"line_number":82,"context_line":"        for plugin_alias, resource in ALL_RESOURCES.items():"},{"line_number":83,"context_line":"            collection_name \u003d resource.get(resource_type)"}],"source_content_type":"text/x-python","patch_set":22,"id":"ff346bd7_cd4fa532","line":80,"range":{"start_line":80,"start_character":32,"end_line":80,"end_character":49},"in_reply_to":"ff346bd7_ed1ca96b","updated":"2017-07-25 01:22:42.000000000","message":"full_sync will be fixed by https://review.openstack.org/#/c/455870/","commit_id":"4f43c8b767e2a6195143428bc3552b9d28dc434a"}],"networking_odl/journal/maintenance.py":[{"author":{"_account_id":333,"name":"Isaku Yamahata","email":"isaku.yamahata@gmail.com","username":"yamahata"},"change_message_id":"9e3a64b011e4f930f537af6b3bf8fb2198489552","unresolved":false,"context_lines":[{"line_number":19,"context_line":"from oslo_log import log as logging"},{"line_number":20,"context_line":"from oslo_service import loopingcall"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"from networking_odl.db import db"},{"line_number":23,"context_line":""},{"line_number":24,"context_line":"LOG \u003d logging.getLogger(__name__)"},{"line_number":25,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"7f231b9d_a3418fab","line":22,"range":{"start_line":22,"start_character":32,"end_line":22,"end_character":32},"updated":"2017-06-17 00:14:18.000000000","message":"unnecessary code churn.","commit_id":"c72537287256ac202be7ae311ea73c33406f2403"},{"author":{"_account_id":13912,"name":"rajiv","email":"thenakliman@gmail.com","username":"rajiv.kumar"},"change_message_id":"d249cac329c738cdebd2db1bbed13f2f7aa41c3d","unresolved":false,"context_lines":[{"line_number":19,"context_line":"from oslo_log import log as logging"},{"line_number":20,"context_line":"from oslo_service import loopingcall"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"from networking_odl.db import db"},{"line_number":23,"context_line":""},{"line_number":24,"context_line":"LOG \u003d logging.getLogger(__name__)"},{"line_number":25,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"3f1d235d_48086f27","line":22,"range":{"start_line":22,"start_character":32,"end_line":22,"end_character":32},"in_reply_to":"7f231b9d_a3418fab","updated":"2017-06-29 07:16:52.000000000","message":"Done","commit_id":"c72537287256ac202be7ae311ea73c33406f2403"},{"author":{"_account_id":333,"name":"Isaku Yamahata","email":"isaku.yamahata@gmail.com","username":"yamahata"},"change_message_id":"a17c7995a46076db418d7224f5c58e4055722577","unresolved":false,"context_lines":[{"line_number":53,"context_line":"            LOG.info(\"Starting maintenance operation %s.\", op_details)"},{"line_number":54,"context_line":"            db.update_maintenance_operation(context.session,"},{"line_number":55,"context_line":"                                            operation\u003doperation)"},{"line_number":56,"context_line":"            operation(session\u003dcontext.session)"},{"line_number":57,"context_line":"            LOG.info(\"Finished maintenance operation %s.\", op_details)"},{"line_number":58,"context_line":"        except Exception:"},{"line_number":59,"context_line":"            LOG.exception(\"Failed during maintenance operation %s.\","}],"source_content_type":"text/x-python","patch_set":15,"id":"3f1d235d_f005f914","line":56,"range":{"start_line":56,"start_character":22,"end_line":56,"end_character":29},"updated":"2017-07-06 23:27:52.000000000","message":"context","commit_id":"357b11c6b6e87c488f9a84e6c03841f9cd3e60a2"},{"author":{"_account_id":7921,"name":"Mike Kolesnik","email":"mkolesni@redhat.com","username":"mkolesni"},"change_message_id":"5e76453324f48fefd8be7dccb4de4178b260ed88","unresolved":false,"context_lines":[{"line_number":53,"context_line":"            LOG.info(\"Starting maintenance operation %s.\", op_details)"},{"line_number":54,"context_line":"            db.update_maintenance_operation(context.session,"},{"line_number":55,"context_line":"                                            operation\u003doperation)"},{"line_number":56,"context_line":"            operation(context\u003dcontext.session)"},{"line_number":57,"context_line":"            LOG.info(\"Finished maintenance operation %s.\", op_details)"},{"line_number":58,"context_line":"        except Exception:"},{"line_number":59,"context_line":"            LOG.exception(\"Failed during maintenance operation %s.\","}],"source_content_type":"text/x-python","patch_set":20,"id":"ff346bd7_179b9ac9","line":56,"range":{"start_line":56,"start_character":30,"end_line":56,"end_character":45},"updated":"2017-07-24 08:47:00.000000000","message":"You\u0027re still sending session here, but in recovery you expect to get a context now, I suspect this will break.\n\nProbably more test coverage is needed for this integration to catch such failures.","commit_id":"d1551042690c853807f25680e36edc77884946f4"},{"author":{"_account_id":333,"name":"Isaku Yamahata","email":"isaku.yamahata@gmail.com","username":"yamahata"},"change_message_id":"ac50abcf1277f498de28b65c45ad20ee5b3c2686","unresolved":false,"context_lines":[{"line_number":53,"context_line":"            LOG.info(\"Starting maintenance operation %s.\", op_details)"},{"line_number":54,"context_line":"            db.update_maintenance_operation(context.session,"},{"line_number":55,"context_line":"                                            operation\u003doperation)"},{"line_number":56,"context_line":"            operation(context\u003dcontext.session)"},{"line_number":57,"context_line":"            LOG.info(\"Finished maintenance operation %s.\", op_details)"},{"line_number":58,"context_line":"        except Exception:"},{"line_number":59,"context_line":"            LOG.exception(\"Failed during maintenance operation %s.\","}],"source_content_type":"text/x-python","patch_set":20,"id":"ff346bd7_c3277f12","line":56,"range":{"start_line":56,"start_character":30,"end_line":56,"end_character":45},"in_reply_to":"ff346bd7_179b9ac9","updated":"2017-07-24 19:33:37.000000000","message":"Done","commit_id":"d1551042690c853807f25680e36edc77884946f4"}],"networking_odl/journal/recovery.py":[{"author":{"_account_id":333,"name":"Isaku Yamahata","email":"isaku.yamahata@gmail.com","username":"yamahata"},"change_message_id":"49f4d9a605c36952a7639520a585698c5d2935fc","unresolved":false,"context_lines":[{"line_number":38,"context_line":"    for row in db.get_all_db_rows_by_state(context.session, odl_const.FAILED):"},{"line_number":39,"context_line":"        try:"},{"line_number":40,"context_line":"            LOG.debug(\"Attempting recovery of journal entry %s.\", row)"},{"line_number":41,"context_line":"            odl_resource \u003d _CLIENT.get_client().get_resource("},{"line_number":42,"context_line":"                row.object_type, row.object_uuid)"},{"line_number":43,"context_line":"            if odl_resource is not None:"},{"line_number":44,"context_line":"                _handle_existing_resource(context, row)"},{"line_number":45,"context_line":"            else:"}],"source_content_type":"text/x-python","patch_set":6,"id":"ff0f0b1f_f18dc331","line":42,"range":{"start_line":41,"start_character":61,"end_line":42,"end_character":49},"updated":"2017-05-26 18:57:14.000000000","message":"Can you please avoid unrelated change?","commit_id":"9610de53cb9e1609105a1f689c67c3bb99108250"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"cce584d69d7b017e7281b5a9263ca0ae5482b2f2","unresolved":false,"context_lines":[{"line_number":68,"context_line":"def _sync_resource_to_odl(context, row, operation_type, exists_on_odl):"},{"line_number":69,"context_line":"    resource \u003d None"},{"line_number":70,"context_line":"    try:"},{"line_number":71,"context_line":"        resource \u003d _get_latest_resource(context.session, row)"},{"line_number":72,"context_line":"    except nexc.NotFound:"},{"line_number":73,"context_line":"        if exists_on_odl:"},{"line_number":74,"context_line":"            journal.record(context, row.object_type,"}],"source_content_type":"text/x-python","patch_set":7,"id":"df140735_8c032a0e","line":71,"range":{"start_line":71,"start_character":40,"end_line":71,"end_character":55},"updated":"2017-05-29 05:53:19.000000000","message":"passing a session while the function takes a context?","commit_id":"8537da22d2825ac133419c96a1a9c3a6379ec45f"}],"networking_odl/ml2/pseudo_agentdb_binding.py":[{"author":{"_account_id":333,"name":"Isaku Yamahata","email":"isaku.yamahata@gmail.com","username":"yamahata"},"change_message_id":"49f4d9a605c36952a7639520a585698c5d2935fc","unresolved":false,"context_lines":[{"line_number":144,"context_line":""},{"line_number":145,"context_line":"        return hostconfigs"},{"line_number":146,"context_line":""},{"line_number":147,"context_line":"    def _get_and_update_hostconfigs(self, context\u003dNone):"},{"line_number":148,"context_line":"        LOG.info(\"REST/GET hostconfigs from ODL\")"},{"line_number":149,"context_line":""},{"line_number":150,"context_line":"        hostconfigs \u003d self._rest_get_hostconfigs()"}],"source_content_type":"text/x-python","patch_set":6,"id":"ff0f0b1f_51ab4f74","line":147,"range":{"start_line":147,"start_character":42,"end_line":147,"end_character":54},"updated":"2017-05-26 18:57:14.000000000","message":"This argument isn\u0027t used. Let\u0027s remove it.","commit_id":"9610de53cb9e1609105a1f689c67c3bb99108250"},{"author":{"_account_id":333,"name":"Isaku Yamahata","email":"isaku.yamahata@gmail.com","username":"yamahata"},"change_message_id":"9e3a64b011e4f930f537af6b3bf8fb2198489552","unresolved":false,"context_lines":[{"line_number":144,"context_line":""},{"line_number":145,"context_line":"        return hostconfigs"},{"line_number":146,"context_line":""},{"line_number":147,"context_line":"    def _get_and_update_hostconfigs(self, context\u003dNone):"},{"line_number":148,"context_line":"        LOG.info(\"REST/GET hostconfigs from ODL\")"},{"line_number":149,"context_line":""},{"line_number":150,"context_line":"        hostconfigs \u003d self._rest_get_hostconfigs()"}],"source_content_type":"text/x-python","patch_set":11,"id":"7f231b9d_6375b7f9","line":147,"range":{"start_line":147,"start_character":42,"end_line":147,"end_character":49},"updated":"2017-06-17 00:14:18.000000000","message":"This isn\u0027t used. we can drop this argument.","commit_id":"c72537287256ac202be7ae311ea73c33406f2403"},{"author":{"_account_id":13912,"name":"rajiv","email":"thenakliman@gmail.com","username":"rajiv.kumar"},"change_message_id":"d249cac329c738cdebd2db1bbed13f2f7aa41c3d","unresolved":false,"context_lines":[{"line_number":144,"context_line":""},{"line_number":145,"context_line":"        return hostconfigs"},{"line_number":146,"context_line":""},{"line_number":147,"context_line":"    def _get_and_update_hostconfigs(self, context\u003dNone):"},{"line_number":148,"context_line":"        LOG.info(\"REST/GET hostconfigs from ODL\")"},{"line_number":149,"context_line":""},{"line_number":150,"context_line":"        hostconfigs \u003d self._rest_get_hostconfigs()"}],"source_content_type":"text/x-python","patch_set":11,"id":"3f1d235d_5d1eef70","line":147,"range":{"start_line":147,"start_character":42,"end_line":147,"end_character":49},"in_reply_to":"7f231b9d_6375b7f9","updated":"2017-06-29 07:16:52.000000000","message":"it is being passed to all the operations of maintenance task https://github.com/openstack/networking-odl/blob/master/networking_odl/journal/maintenance.py#L55 . We might have to put if else at the time of calling, i can do this in separate patch if you like.","commit_id":"c72537287256ac202be7ae311ea73c33406f2403"},{"author":{"_account_id":333,"name":"Isaku Yamahata","email":"isaku.yamahata@gmail.com","username":"yamahata"},"change_message_id":"a17c7995a46076db418d7224f5c58e4055722577","unresolved":false,"context_lines":[{"line_number":137,"context_line":""},{"line_number":138,"context_line":"        return hostconfigs"},{"line_number":139,"context_line":""},{"line_number":140,"context_line":"    def _get_and_update_hostconfigs(self, context\u003dNone):"},{"line_number":141,"context_line":"        LOG.info(\"REST/GET hostconfigs from ODL\")"},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"        hostconfigs \u003d self._rest_get_hostconfigs()"}],"source_content_type":"text/x-python","patch_set":15,"id":"3f1d235d_70120964","line":140,"range":{"start_line":140,"start_character":42,"end_line":140,"end_character":54},"updated":"2017-07-06 23:27:52.000000000","message":"maintenance.MaintenanceThread.execute_ops needs fix.","commit_id":"357b11c6b6e87c488f9a84e6c03841f9cd3e60a2"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"16483c39b0d2d92290a7543f788c094954f1220f","unresolved":false,"context_lines":[{"line_number":137,"context_line":""},{"line_number":138,"context_line":"        return hostconfigs"},{"line_number":139,"context_line":""},{"line_number":140,"context_line":"    def _get_and_update_hostconfigs(self, context\u003dNone):"},{"line_number":141,"context_line":"        LOG.info(\"REST/GET hostconfigs from ODL\")"},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"        hostconfigs \u003d self._rest_get_hostconfigs()"}],"source_content_type":"text/x-python","patch_set":16,"id":"3f1d235d_8978d88f","line":140,"range":{"start_line":140,"start_character":42,"end_line":140,"end_character":49},"updated":"2017-07-07 07:28:06.000000000","message":"it takes a session, doesn\u0027t it?","commit_id":"eed117c919625937939e1e40a874b195fb0bf40a"}],"networking_odl/tests/unit/journal/test_maintenance.py":[{"author":{"_account_id":333,"name":"Isaku Yamahata","email":"isaku.yamahata@gmail.com","username":"yamahata"},"change_message_id":"49f4d9a605c36952a7639520a585698c5d2935fc","unresolved":false,"context_lines":[{"line_number":31,"context_line":""},{"line_number":32,"context_line":"        row \u003d models.OpendaylightMaintenance(state\u003dodl_const.PENDING)"},{"line_number":33,"context_line":"        self.context \u003d neutron_context.get_admin_context()"},{"line_number":34,"context_line":"        self.db_session \u003d self.context.session"},{"line_number":35,"context_line":"        self.db_session.add(row)"},{"line_number":36,"context_line":"        self.db_session.flush()"},{"line_number":37,"context_line":"        self.thread \u003d maintenance.MaintenanceThread()"}],"source_content_type":"text/x-python","patch_set":6,"id":"ff0f0b1f_91f8c77c","line":34,"range":{"start_line":34,"start_character":8,"end_line":34,"end_character":23},"updated":"2017-05-26 18:57:14.000000000","message":"Is self.db_session used somewhere? only line 35 and 36?\nIf so, let\u0027s drop self.db_session","commit_id":"9610de53cb9e1609105a1f689c67c3bb99108250"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"16483c39b0d2d92290a7543f788c094954f1220f","unresolved":false,"context_lines":[{"line_number":30,"context_line":"        super(MaintenanceThreadTestCase, self).setUp()"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":"        row \u003d models.OpendaylightMaintenance(state\u003dodl_const.PENDING)"},{"line_number":33,"context_line":"        self.context \u003d neutron_context.get_admin_context()"},{"line_number":34,"context_line":"        self.context.session.add(row)"},{"line_number":35,"context_line":"        self.context.session.flush()"},{"line_number":36,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"3f1d235d_c93370f5","line":33,"range":{"start_line":33,"start_character":0,"end_line":33,"end_character":58},"updated":"2017-07-07 07:28:06.000000000","message":"have you considered to do it in ODLBaseDbTestCase?","commit_id":"eed117c919625937939e1e40a874b195fb0bf40a"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"64c48dcd5e871c29e2114eed33482a5c0c606103","unresolved":false,"context_lines":[{"line_number":30,"context_line":"        super(MaintenanceThreadTestCase, self).setUp()"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":"        row \u003d models.OpendaylightMaintenance(state\u003dodl_const.PENDING)"},{"line_number":33,"context_line":"        self.context \u003d neutron_context.get_admin_context()"},{"line_number":34,"context_line":"        self.context.session.add(row)"},{"line_number":35,"context_line":"        self.context.session.flush()"},{"line_number":36,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"ff346bd7_2a605701","line":33,"range":{"start_line":33,"start_character":0,"end_line":33,"end_character":58},"in_reply_to":"1f1a1f67_09d00f50","updated":"2017-07-25 01:06:06.000000000","message":"having both of self.context and self.db_session seems redundant.\nif you do it in the base class, you can do:\n\n  self.context \u003d get_admin_context()\n  self.db_session \u003d context.session()","commit_id":"eed117c919625937939e1e40a874b195fb0bf40a"},{"author":{"_account_id":13912,"name":"rajiv","email":"thenakliman@gmail.com","username":"rajiv.kumar"},"change_message_id":"9c6a8f2590163c1d52994d750dfd7028c3e806f6","unresolved":false,"context_lines":[{"line_number":30,"context_line":"        super(MaintenanceThreadTestCase, self).setUp()"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":"        row \u003d models.OpendaylightMaintenance(state\u003dodl_const.PENDING)"},{"line_number":33,"context_line":"        self.context \u003d neutron_context.get_admin_context()"},{"line_number":34,"context_line":"        self.context.session.add(row)"},{"line_number":35,"context_line":"        self.context.session.flush()"},{"line_number":36,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"1f1a1f67_09d00f50","line":33,"range":{"start_line":33,"start_character":0,"end_line":33,"end_character":58},"in_reply_to":"3f1d235d_c93370f5","updated":"2017-07-21 06:50:44.000000000","message":"Do you mean, moving this statement to ODLBaseDbTestCase?\n\nI am not sure, whether it is a good idea or not. Can you elaborate more on it?","commit_id":"eed117c919625937939e1e40a874b195fb0bf40a"},{"author":{"_account_id":333,"name":"Isaku Yamahata","email":"isaku.yamahata@gmail.com","username":"yamahata"},"change_message_id":"aad8279538cab03ce6d0402e0439b8452f644b57","unresolved":false,"context_lines":[{"line_number":30,"context_line":"        super(MaintenanceThreadTestCase, self).setUp()"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":"        row \u003d models.OpendaylightMaintenance(state\u003dodl_const.PENDING)"},{"line_number":33,"context_line":"        self.context \u003d neutron_context.get_admin_context()"},{"line_number":34,"context_line":"        self.context.session.add(row)"},{"line_number":35,"context_line":"        self.context.session.flush()"},{"line_number":36,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"ff346bd7_6d0f99e1","line":33,"range":{"start_line":33,"start_character":0,"end_line":33,"end_character":58},"in_reply_to":"ff346bd7_2a605701","updated":"2017-07-25 01:22:36.000000000","message":"Done","commit_id":"eed117c919625937939e1e40a874b195fb0bf40a"},{"author":{"_account_id":6854,"name":"YAMAMOTO Takashi","email":"yamamoto@midokura.com","username":"yamamoto"},"change_message_id":"a17918859f03423d8d4e83a06d9b94960f9aa5a8","unresolved":false,"context_lines":[{"line_number":30,"context_line":"        super(MaintenanceThreadTestCase, self).setUp()"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":"        row \u003d models.OpenDaylightMaintenance(state\u003dodl_const.PENDING)"},{"line_number":33,"context_line":"        self.context \u003d neutron_context.get_admin_context()"},{"line_number":34,"context_line":"        self.context.session.add(row)"},{"line_number":35,"context_line":"        self.context.session.flush()"},{"line_number":36,"context_line":""}],"source_content_type":"text/x-python","patch_set":22,"id":"ff346bd7_ed6389db","line":33,"updated":"2017-07-25 01:14:15.000000000","message":"why do you need a new context, rather than self.db_context?","commit_id":"4f43c8b767e2a6195143428bc3552b9d28dc434a"},{"author":{"_account_id":333,"name":"Isaku Yamahata","email":"isaku.yamahata@gmail.com","username":"yamahata"},"change_message_id":"d740aecc474c534ed6eb0a247566e8345b03620a","unresolved":false,"context_lines":[{"line_number":30,"context_line":"        super(MaintenanceThreadTestCase, self).setUp()"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":"        row \u003d models.OpenDaylightMaintenance(state\u003dodl_const.PENDING)"},{"line_number":33,"context_line":"        self.context \u003d neutron_context.get_admin_context()"},{"line_number":34,"context_line":"        self.context.session.add(row)"},{"line_number":35,"context_line":"        self.context.session.flush()"},{"line_number":36,"context_line":""}],"source_content_type":"text/x-python","patch_set":22,"id":"ff346bd7_cd68c588","line":33,"in_reply_to":"ff346bd7_ed6389db","updated":"2017-07-25 01:22:42.000000000","message":"Done","commit_id":"4f43c8b767e2a6195143428bc3552b9d28dc434a"}],"networking_odl/tests/unit/journal/test_recovery.py":[{"author":{"_account_id":7921,"name":"Mike Kolesnik","email":"mkolesni@redhat.com","username":"mkolesni"},"change_message_id":"ecc13f2b427447ff76223da651b69f73db97c99c","unresolved":false,"context_lines":[{"line_number":126,"context_line":"    @mock.patch.object(recovery, \u0027_get_latest_resource\u0027)"},{"line_number":127,"context_line":"    def _test_recovery_creates_operation("},{"line_number":128,"context_line":"            self, operation, resource, odl_resource, expected_operation,"},{"line_number":129,"context_line":"            expected_state, recovery_mock):"},{"line_number":130,"context_line":"        if resource is not None:"},{"line_number":131,"context_line":"            recovery_mock.return_value \u003d resource"},{"line_number":132,"context_line":"        else:"}],"source_content_type":"text/x-python","patch_set":10,"id":"bf091321_d6a07fa8","line":129,"range":{"start_line":129,"start_character":12,"end_line":129,"end_character":27},"updated":"2017-06-08 13:48:00.000000000","message":"Please avoid this unrelated change","commit_id":"eab74eee524eb5b8d7fe29203011bc05de8ab2dc"},{"author":{"_account_id":7921,"name":"Mike Kolesnik","email":"mkolesni@redhat.com","username":"mkolesni"},"change_message_id":"ecc13f2b427447ff76223da651b69f73db97c99c","unresolved":false,"context_lines":[{"line_number":157,"context_line":"            odl_const.ODL_UPDATE, None, {}, odl_const.ODL_DELETE,"},{"line_number":158,"context_line":"            odl_const.COMPLETED)"},{"line_number":159,"context_line":""},{"line_number":160,"context_line":"    def test_recovery_deleted_resource_missing_but_exists_in_odl(self):"},{"line_number":161,"context_line":"        self._test_recovery_creates_operation("},{"line_number":162,"context_line":"            odl_const.ODL_DELETE, None, {}, odl_const.ODL_DELETE,"},{"line_number":163,"context_line":"            odl_const.PENDING)"},{"line_number":164,"context_line":""},{"line_number":165,"context_line":"    @mock.patch.object(recovery, \u0027_get_latest_resource\u0027)"},{"line_number":166,"context_line":"    def test_recovery_created_resource_missing_and_not_in_odl(self, rmock):"}],"source_content_type":"text/x-python","patch_set":10,"id":"bf091321_16c95777","line":163,"range":{"start_line":160,"start_character":4,"end_line":163,"end_character":30},"updated":"2017-06-08 13:48:00.000000000","message":"This test is meaningless to add since the existence of a resource on Neutron side is only considered in the case of UPDATE recovery.\n\nThis case is already covered by test_journal_recovery_deleted_row_exists_in_odl","commit_id":"eab74eee524eb5b8d7fe29203011bc05de8ab2dc"}]}
