)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":6537,"name":"gordon chung","email":"gord@live.ca","username":"chungg"},"change_message_id":"f7ea5535f50cc3cad357a712a0f78f023fe814cc","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Currently, if the endpoint id does not exist, pycadf will break."},{"line_number":10,"context_line":"This patch will attempt to find the id of the endpoint and if not"},{"line_number":11,"context_line":"found, set it to unknown."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"Closes-Bug: #1347868"},{"line_number":14,"context_line":"Change-Id: Ief7facfca79f4f4e7c550c8f2317745e0c8e41ea"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"da86d52c_bd34c0fb","line":11,"updated":"2015-02-10 18:30:29.000000000","message":"this is wrong but i get the point.","commit_id":"a568c12219db0390d90843274b07a97af6a6743b"}],"pycadf/audit/api.py":[{"author":{"_account_id":6537,"name":"gordon chung","email":"gord@live.ca","username":"chungg"},"change_message_id":"07c839c6727fb0c38ffe26535db1da4029ebfd52","unresolved":false,"context_lines":[{"line_number":184,"context_line":"    def _get_service_info(self, endp):"},{"line_number":185,"context_line":"        # NOTE(stevemar): an endpoint id is not guaranteed since the catalogs"},{"line_number":186,"context_line":"        # have a different format in v2.0 and v3 Keystone."},{"line_number":187,"context_line":"        endpoint_id \u003d endp[\u0027endpoints\u0027][0].get(\u0027id\u0027, taxonomy.UNKNOWN)"},{"line_number":188,"context_line":"        service \u003d self.Service("},{"line_number":189,"context_line":"            type\u003dself._MAP.service_endpoints.get("},{"line_number":190,"context_line":"                endp[\u0027type\u0027],"}],"source_content_type":"text/x-python","patch_set":1,"id":"baada198_61ca1e1b","line":187,"updated":"2014-07-28 18:56:33.000000000","message":"personally, i think it\u0027s better if we have a real id from keystone... if that ain\u0027t possible, is there something else we can use that isn\u0027t Unknown? ie. \u0027name\u0027 could be an option..\n\nthe main reason for having a valid id is when you query the data, if you want to get all audit records targeting a specific service it all falls apart if the id is some random/non-specific/unknown value.","commit_id":"d47497b8287c461d349d0a531770b6922fa65583"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"c914ca64d30bdb5a8a4d6f46830f3d2531073f66","unresolved":false,"context_lines":[{"line_number":184,"context_line":"    def _get_service_info(self, endp):"},{"line_number":185,"context_line":"        # NOTE(stevemar): an endpoint id is not guaranteed since the catalogs"},{"line_number":186,"context_line":"        # have a different format in v2.0 and v3 Keystone."},{"line_number":187,"context_line":"        endpoint_id \u003d endp[\u0027endpoints\u0027][0].get(\u0027id\u0027, taxonomy.UNKNOWN)"},{"line_number":188,"context_line":"        service \u003d self.Service("},{"line_number":189,"context_line":"            type\u003dself._MAP.service_endpoints.get("},{"line_number":190,"context_line":"                endp[\u0027type\u0027],"}],"source_content_type":"text/x-python","patch_set":1,"id":"baada198_64bf8c60","line":187,"in_reply_to":"baada198_044a50ac","updated":"2014-07-28 19:28:18.000000000","message":"Good call. Unknown it is, as a last resort.","commit_id":"d47497b8287c461d349d0a531770b6922fa65583"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"cd21a2d4a26b18a14c2209dbe37783ed28608281","unresolved":false,"context_lines":[{"line_number":184,"context_line":"    def _get_service_info(self, endp):"},{"line_number":185,"context_line":"        # NOTE(stevemar): an endpoint id is not guaranteed since the catalogs"},{"line_number":186,"context_line":"        # have a different format in v2.0 and v3 Keystone."},{"line_number":187,"context_line":"        endpoint_id \u003d endp[\u0027endpoints\u0027][0].get(\u0027id\u0027, taxonomy.UNKNOWN)"},{"line_number":188,"context_line":"        service \u003d self.Service("},{"line_number":189,"context_line":"            type\u003dself._MAP.service_endpoints.get("},{"line_number":190,"context_line":"                endp[\u0027type\u0027],"}],"source_content_type":"text/x-python","patch_set":1,"id":"baada198_643a2c99","line":187,"in_reply_to":"baada198_61ca1e1b","updated":"2014-07-28 19:09:48.000000000","message":"@gordon name should exist in all cases... \n\nhttps://github.com/openstack/python-keystoneclient/blob/master/keystoneclient/middleware/auth_token.py#L396\n\nhow about we try \u0027id\u0027 first, if that fails, then try \u0027name\u0027?\nif that fails, then toss up a KeyError? or something nicer?","commit_id":"d47497b8287c461d349d0a531770b6922fa65583"},{"author":{"_account_id":6537,"name":"gordon chung","email":"gord@live.ca","username":"chungg"},"change_message_id":"35bf9b68af00b501a4670bddaf8a6fd8230c9d38","unresolved":false,"context_lines":[{"line_number":184,"context_line":"    def _get_service_info(self, endp):"},{"line_number":185,"context_line":"        # NOTE(stevemar): an endpoint id is not guaranteed since the catalogs"},{"line_number":186,"context_line":"        # have a different format in v2.0 and v3 Keystone."},{"line_number":187,"context_line":"        endpoint_id \u003d endp[\u0027endpoints\u0027][0].get(\u0027id\u0027, taxonomy.UNKNOWN)"},{"line_number":188,"context_line":"        service \u003d self.Service("},{"line_number":189,"context_line":"            type\u003dself._MAP.service_endpoints.get("},{"line_number":190,"context_line":"                endp[\u0027type\u0027],"}],"source_content_type":"text/x-python","patch_set":1,"id":"baada198_044a50ac","line":187,"in_reply_to":"baada198_643a2c99","updated":"2014-07-28 19:25:29.000000000","message":"that seems fine to me.\n\ni\u0027d suggest avoiding a keyerror, the audit eventing was meant to be a secondary/background task that doesn\u0027t affect main process... maybe default to unknown and let users query data to discover failures?\n\ni\u0027d be interested in Matt/Bruce/auditing guru opinion as well","commit_id":"d47497b8287c461d349d0a531770b6922fa65583"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"7bb4b85fc2e03497c8e2aa51fc2e81e227e43b9b","unresolved":false,"context_lines":[{"line_number":184,"context_line":"    def _get_service_info(self, endp):"},{"line_number":185,"context_line":"        # NOTE(stevemar): An endpoint id is not guaranteed since the catalogs"},{"line_number":186,"context_line":"        # may be templated, so try ID first, if that fails, get the name."},{"line_number":187,"context_line":"        endpoint_id \u003d endp[\u0027endpoints\u0027][0].get(\u0027id\u0027, endp[\u0027name\u0027])"},{"line_number":188,"context_line":"        service \u003d self.Service("},{"line_number":189,"context_line":"            type\u003dself._MAP.service_endpoints.get("},{"line_number":190,"context_line":"                endp[\u0027type\u0027],"}],"source_content_type":"text/x-python","patch_set":2,"id":"9ab29df4_17ffd402","line":187,"updated":"2014-08-13 18:43:01.000000000","message":"the commit message says this will be set to \u0027unknown\u0027. also, endpoints don\u0027t have names..? patchset 1 looks correct","commit_id":"a9b2484784ecb5b1aa7de233b9b0f0710947108c"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"7bb4b85fc2e03497c8e2aa51fc2e81e227e43b9b","unresolved":false,"context_lines":[{"line_number":201,"context_line":"                name\u003d\u0027public\u0027,"},{"line_number":202,"context_line":"                url\u003dendp[\u0027endpoints\u0027][0][\u0027publicURL\u0027]))"},{"line_number":203,"context_line":""},{"line_number":204,"context_line":"        return service"},{"line_number":205,"context_line":""},{"line_number":206,"context_line":"    def _build_typeURI(self, req, service_type):"},{"line_number":207,"context_line":"        type_uri \u003d \u0027\u0027"}],"source_content_type":"text/x-python","patch_set":2,"id":"9ab29df4_5726ac69","line":204,"updated":"2014-08-13 18:43:01.000000000","message":"pretty much everything about this method looks entirely broken\n\n* a service ID is NOT an endpoint ID.\n* internal endpoints are not \"private\" by any means - they are internal service endpoints, as opposed to public service endpoints or private admin endpoints.\n* endpoints don\u0027t have names\n* services will always have types","commit_id":"a9b2484784ecb5b1aa7de233b9b0f0710947108c"}],"pycadf/tests/audit/test_api.py":[{"author":{"_account_id":6537,"name":"gordon chung","email":"gord@live.ca","username":"chungg"},"change_message_id":"55ab712b841e89d8fbd7b5310f3101bd3ce3ac48","unresolved":false,"context_lines":[{"line_number":41,"context_line":"                   \u0027HTTP_X_PROJECT_ID\u0027: \u0027tenant_id\u0027,"},{"line_number":42,"context_line":"                   \u0027HTTP_X_IDENTITY_STATUS\u0027: \u0027Confirmed\u0027}"},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"    ENV_HEADERS_TEMPLATE \u003d copy.deepcopy(ENV_HEADERS)"},{"line_number":45,"context_line":"    ENV_HEADERS_TEMPLATE[\u0027HTTP_X_SERVICE_CATALOG\u0027] \u003d \u0027\u0027\u0027[{\"endpoints_links\": [],"},{"line_number":46,"context_line":"            \"endpoints\": [{\"adminURL\": \"http://admin_host:8774\","},{"line_number":47,"context_line":"                           \"region\": \"RegionOne\","}],"source_content_type":"text/x-python","patch_set":4,"id":"da86d52c_ca74c8d0","line":44,"updated":"2015-02-06 14:41:51.000000000","message":"ENV_HEADERS doesn\u0027t have any object related info so we don\u0027t need this copy","commit_id":"3eabdea8f4033287f498137c55aa517c9a75fdd4"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"f1182186d717e9ed61628257e92df65ba11e6529","unresolved":false,"context_lines":[{"line_number":41,"context_line":"                   \u0027HTTP_X_PROJECT_ID\u0027: \u0027tenant_id\u0027,"},{"line_number":42,"context_line":"                   \u0027HTTP_X_IDENTITY_STATUS\u0027: \u0027Confirmed\u0027}"},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"    ENV_HEADERS_TEMPLATE \u003d copy.deepcopy(ENV_HEADERS)"},{"line_number":45,"context_line":"    ENV_HEADERS_TEMPLATE[\u0027HTTP_X_SERVICE_CATALOG\u0027] \u003d \u0027\u0027\u0027[{\"endpoints_links\": [],"},{"line_number":46,"context_line":"            \"endpoints\": [{\"adminURL\": \"http://admin_host:8774\","},{"line_number":47,"context_line":"                           \"region\": \"RegionOne\","}],"source_content_type":"text/x-python","patch_set":4,"id":"da86d52c_e6d8d781","line":44,"in_reply_to":"da86d52c_ca74c8d0","updated":"2015-02-06 22:46:59.000000000","message":"Done","commit_id":"3eabdea8f4033287f498137c55aa517c9a75fdd4"}]}
