)]}'
{"keystone/assignment/core.py":[{"author":{"_account_id":7725,"name":"David Stanek","email":"dstanek@dstanek.com","username":"dstanek"},"change_message_id":"cf280577040dbbf37b05d7726259ec8eee5d7cde","unresolved":false,"context_lines":[{"line_number":521,"context_line":"            self.resource_api.get_domain(domain_id)"},{"line_number":522,"context_line":"        if project_id:"},{"line_number":523,"context_line":"            self.resource_api.get_project(project_id)"},{"line_number":524,"context_line":"        if user_id and domain_id:"},{"line_number":525,"context_line":"            self.get_roles_for_user_and_domain.invalidate(self, user_id,"},{"line_number":526,"context_line":"                                                          domain_id)"},{"line_number":527,"context_line":"        if user_id and project_id:"}],"source_content_type":"text/x-python","patch_set":1,"id":"ba15a1d1_16bf30fc","line":524,"updated":"2015-09-22 14:40:35.000000000","message":"Is it possible that get_roles_for_user_and_domain is called with a None value as one of its arguments?","commit_id":"9fedda4d322e8d73c4d1d64a3839a18a3ff4c35b"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"6f95b3f605d5903a7103a7fb73815f02b305507d","unresolved":false,"context_lines":[{"line_number":521,"context_line":"            self.resource_api.get_domain(domain_id)"},{"line_number":522,"context_line":"        if project_id:"},{"line_number":523,"context_line":"            self.resource_api.get_project(project_id)"},{"line_number":524,"context_line":"        if user_id and domain_id:"},{"line_number":525,"context_line":"            self.get_roles_for_user_and_domain.invalidate(self, user_id,"},{"line_number":526,"context_line":"                                                          domain_id)"},{"line_number":527,"context_line":"        if user_id and project_id:"}],"source_content_type":"text/x-python","patch_set":1,"id":"9a1a9d01_7f72087e","line":524,"in_reply_to":"ba15a1d1_16bf30fc","updated":"2015-10-04 19:11:51.000000000","message":"I think we actually can\u0027t cache in those methods this way.\n\nSuppose we are deleting all the grants in a given domain_id. After that, querying for user_id and domain_id would return the cached values for the pair (user_id; domain_id).\n\nI suppose that\u0027s where your question come from, because that way we should check \u0027if user_id or domain_id:\u0027 instead of with an AND. However, how to know the other value (user or domain) to invalidate the cache, since the cache key is a pair user/domain ?\n\nThis can be solved if it\u0027s possible to invalidate all the cached valus where the keys match (*, domain_id), for example. I don\u0027t know if this library supports this.","commit_id":"9fedda4d322e8d73c4d1d64a3839a18a3ff4c35b"},{"author":{"_account_id":7725,"name":"David Stanek","email":"dstanek@dstanek.com","username":"dstanek"},"change_message_id":"cf280577040dbbf37b05d7726259ec8eee5d7cde","unresolved":false,"context_lines":[{"line_number":524,"context_line":"        if user_id and domain_id:"},{"line_number":525,"context_line":"            self.get_roles_for_user_and_domain.invalidate(self, user_id,"},{"line_number":526,"context_line":"                                                          domain_id)"},{"line_number":527,"context_line":"        if user_id and project_id:"},{"line_number":528,"context_line":"            self.get_roles_for_user_and_project.invalidate(self, user_id,"},{"line_number":529,"context_line":"                                                           project_id)"},{"line_number":530,"context_line":"        self.driver.delete_grant(role_id, user_id, group_id, domain_id,"}],"source_content_type":"text/x-python","patch_set":1,"id":"ba15a1d1_9641000e","line":527,"updated":"2015-09-22 14:40:35.000000000","message":"Same question here.","commit_id":"9fedda4d322e8d73c4d1d64a3839a18a3ff4c35b"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"6f95b3f605d5903a7103a7fb73815f02b305507d","unresolved":false,"context_lines":[{"line_number":524,"context_line":"        if user_id and domain_id:"},{"line_number":525,"context_line":"            self.get_roles_for_user_and_domain.invalidate(self, user_id,"},{"line_number":526,"context_line":"                                                          domain_id)"},{"line_number":527,"context_line":"        if user_id and project_id:"},{"line_number":528,"context_line":"            self.get_roles_for_user_and_project.invalidate(self, user_id,"},{"line_number":529,"context_line":"                                                           project_id)"},{"line_number":530,"context_line":"        self.driver.delete_grant(role_id, user_id, group_id, domain_id,"}],"source_content_type":"text/x-python","patch_set":1,"id":"9a1a9d01_9f6d9c9b","line":527,"in_reply_to":"ba15a1d1_9641000e","updated":"2015-10-04 19:11:51.000000000","message":"Same as above :)","commit_id":"9fedda4d322e8d73c4d1d64a3839a18a3ff4c35b"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"7ae92cad3c291d24a913cb85baa52d75a6affbcb","unresolved":false,"context_lines":[{"line_number":285,"context_line":"                                                project_id\u003dtenant_id)"},{"line_number":286,"context_line":""},{"line_number":287,"context_line":"            except exception.RoleNotFound:"},{"line_number":288,"context_line":"                LOG.debug(\"Removing role %s failed because it does not exist.\","},{"line_number":289,"context_line":"                          role_id)"},{"line_number":290,"context_line":""},{"line_number":291,"context_line":"    # TODO(henry-nash): We might want to consider list limiting this at some"}],"source_content_type":"text/x-python","patch_set":8,"id":"5a2ca52d_4d6c949c","line":288,"updated":"2015-10-13 13:47:04.000000000","message":"Similarly to add_user_to_project, we need to invalidate the cache here too.","commit_id":"0daf67cb756aad1792f2329895fe8d83974617da"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"10ebacd308bb984e0ef1bbf0ca9f7d314ad95166","unresolved":false,"context_lines":[{"line_number":283,"context_line":"                                                              role_id)"},{"line_number":284,"context_line":"                self.revoke_api.revoke_by_grant(role_id, user_id\u003duser_id,"},{"line_number":285,"context_line":"                                                project_id\u003dtenant_id)"},{"line_number":286,"context_line":""},{"line_number":287,"context_line":"            except exception.RoleNotFound:"},{"line_number":288,"context_line":"                LOG.debug(\"Removing role %s failed because it does not exist.\","},{"line_number":289,"context_line":"                          role_id)"}],"source_content_type":"text/x-python","patch_set":9,"id":"fa80f949_e58503ad","line":286,"updated":"2015-11-05 21:54:37.000000000","message":"As per my comment in the previous patch, I think we need to invalidate it here too.\n\nassignment.COMPUTED_ASSIGNMENTS_REGION.invalidate()","commit_id":"14f899864247c29a69dfec5d63b6fb79dda77bdb"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"cbae9c01723ebeecde07549337057bb63bf80bdd","unresolved":false,"context_lines":[{"line_number":283,"context_line":"                                                              role_id)"},{"line_number":284,"context_line":"                self.revoke_api.revoke_by_grant(role_id, user_id\u003duser_id,"},{"line_number":285,"context_line":"                                                project_id\u003dtenant_id)"},{"line_number":286,"context_line":""},{"line_number":287,"context_line":"            except exception.RoleNotFound:"},{"line_number":288,"context_line":"                LOG.debug(\"Removing role %s failed because it does not exist.\","},{"line_number":289,"context_line":"                          role_id)"}],"source_content_type":"text/x-python","patch_set":9,"id":"fa80f949_82c3caec","line":286,"in_reply_to":"fa80f949_e58503ad","updated":"2015-11-05 22:53:44.000000000","message":"Done","commit_id":"14f899864247c29a69dfec5d63b6fb79dda77bdb"},{"author":{"_account_id":7725,"name":"David Stanek","email":"dstanek@dstanek.com","username":"dstanek"},"change_message_id":"5e77bbad310633429b13a1a92beba4bb54659686","unresolved":false,"context_lines":[{"line_number":1211,"context_line":"        ret \u003d self.driver.create_role(role_id, role)"},{"line_number":1212,"context_line":"        notifications.Audit.created(self._ROLE, role_id, initiator)"},{"line_number":1213,"context_line":"        if MEMOIZE.should_cache(ret):"},{"line_number":1214,"context_line":"            self.get_role.set(ret, self, role_id)"},{"line_number":1215,"context_line":"        return ret"},{"line_number":1216,"context_line":""},{"line_number":1217,"context_line":"    @manager.response_truncated"}],"source_content_type":"text/x-python","patch_set":9,"id":"fa80f949_65935350","line":1214,"updated":"2015-11-05 21:30:43.000000000","message":"Do you need to invalidate here and on role update too?","commit_id":"14f899864247c29a69dfec5d63b6fb79dda77bdb"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"10ebacd308bb984e0ef1bbf0ca9f7d314ad95166","unresolved":false,"context_lines":[{"line_number":1211,"context_line":"        ret \u003d self.driver.create_role(role_id, role)"},{"line_number":1212,"context_line":"        notifications.Audit.created(self._ROLE, role_id, initiator)"},{"line_number":1213,"context_line":"        if MEMOIZE.should_cache(ret):"},{"line_number":1214,"context_line":"            self.get_role.set(ret, self, role_id)"},{"line_number":1215,"context_line":"        return ret"},{"line_number":1216,"context_line":""},{"line_number":1217,"context_line":"    @manager.response_truncated"}],"source_content_type":"text/x-python","patch_set":9,"id":"fa80f949_80bae521","line":1214,"in_reply_to":"fa80f949_65935350","updated":"2015-11-05 21:54:37.000000000","message":"I don\u0027t think so. For create, there is no role assignment with the new role yet. For update, we can\u0027t change the role id, so the assignments are still fine.","commit_id":"14f899864247c29a69dfec5d63b6fb79dda77bdb"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"70e1ad97b51b556fccd617755f94e95e5a8c185b","unresolved":false,"context_lines":[{"line_number":83,"context_line":"        # instead of the more expensive to_dict() call for each record."},{"line_number":84,"context_line":"        return [x[\u0027id\u0027] for"},{"line_number":85,"context_line":"                x in self.identity_api.list_groups_for_user(user_id)]"},{"line_number":86,"context_line":""},{"line_number":87,"context_line":"    def list_user_ids_for_project(self, tenant_id):"},{"line_number":88,"context_line":"        self.resource_api.get_project(tenant_id)"},{"line_number":89,"context_line":"        return self.driver.list_user_ids_for_project(tenant_id)"}],"source_content_type":"text/x-python","patch_set":12,"id":"ba8a016a_0506e485","line":86,"updated":"2015-11-18 20:33:15.000000000","message":"This can also be cached ? Since it depends on user roles on the given project.","commit_id":"96e2dae796ff661cf377bffadcfa26e63c7845b9"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"938e0a4652755cbd50a234168e45c5e4b7f6804e","unresolved":false,"context_lines":[{"line_number":83,"context_line":"        # instead of the more expensive to_dict() call for each record."},{"line_number":84,"context_line":"        return [x[\u0027id\u0027] for"},{"line_number":85,"context_line":"                x in self.identity_api.list_groups_for_user(user_id)]"},{"line_number":86,"context_line":""},{"line_number":87,"context_line":"    def list_user_ids_for_project(self, tenant_id):"},{"line_number":88,"context_line":"        self.resource_api.get_project(tenant_id)"},{"line_number":89,"context_line":"        return self.driver.list_user_ids_for_project(tenant_id)"}],"source_content_type":"text/x-python","patch_set":12,"id":"ba8a016a_d923b554","line":86,"in_reply_to":"ba8a016a_0506e485","updated":"2015-11-19 16:06:21.000000000","message":"For this patch, I think we originally just wanted to target optimizing get_token_data(), specifically _populate_scope(). \n\nhttps://github.com/openstack/keystone/blob/40453931a907da7f169f7b60323cfbe8b6bbb0c8/keystone/token/providers/common.py#L268-L273\n\nMaybe something else could be open to continue optimizing the assignment api in the future?","commit_id":"96e2dae796ff661cf377bffadcfa26e63c7845b9"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"07bdb2d21346f4e531498e50b74010a7068cd468","unresolved":false,"context_lines":[{"line_number":83,"context_line":"        # instead of the more expensive to_dict() call for each record."},{"line_number":84,"context_line":"        return [x[\u0027id\u0027] for"},{"line_number":85,"context_line":"                x in self.identity_api.list_groups_for_user(user_id)]"},{"line_number":86,"context_line":""},{"line_number":87,"context_line":"    def list_user_ids_for_project(self, tenant_id):"},{"line_number":88,"context_line":"        self.resource_api.get_project(tenant_id)"},{"line_number":89,"context_line":"        return self.driver.list_user_ids_for_project(tenant_id)"}],"source_content_type":"text/x-python","patch_set":12,"id":"ba8a016a_25987d1b","line":86,"in_reply_to":"ba8a016a_d923b554","updated":"2015-11-20 00:46:21.000000000","message":"Okay, makes sense to me","commit_id":"96e2dae796ff661cf377bffadcfa26e63c7845b9"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"70e1ad97b51b556fccd617755f94e95e5a8c185b","unresolved":false,"context_lines":[{"line_number":281,"context_line":"                                                              role_id)"},{"line_number":282,"context_line":"                self.revoke_api.revoke_by_grant(role_id, user_id\u003duser_id,"},{"line_number":283,"context_line":"                                                project_id\u003dtenant_id)"},{"line_number":284,"context_line":"                COMPUTED_ASSIGNMENTS_REGION.invalidate()"},{"line_number":285,"context_line":""},{"line_number":286,"context_line":"            except exception.RoleNotFound:"},{"line_number":287,"context_line":"                LOG.debug(\"Removing role %s failed because it does not exist.\","}],"source_content_type":"text/x-python","patch_set":12,"id":"ba8a016a_a53ef825","line":284,"updated":"2015-11-18 20:33:15.000000000","message":"No need to do this inside the for loop for each role. Just do it once outside the for statement.","commit_id":"96e2dae796ff661cf377bffadcfa26e63c7845b9"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"938e0a4652755cbd50a234168e45c5e4b7f6804e","unresolved":false,"context_lines":[{"line_number":281,"context_line":"                                                              role_id)"},{"line_number":282,"context_line":"                self.revoke_api.revoke_by_grant(role_id, user_id\u003duser_id,"},{"line_number":283,"context_line":"                                                project_id\u003dtenant_id)"},{"line_number":284,"context_line":"                COMPUTED_ASSIGNMENTS_REGION.invalidate()"},{"line_number":285,"context_line":""},{"line_number":286,"context_line":"            except exception.RoleNotFound:"},{"line_number":287,"context_line":"                LOG.debug(\"Removing role %s failed because it does not exist.\","}],"source_content_type":"text/x-python","patch_set":12,"id":"ba8a016a_d3df14d4","line":284,"in_reply_to":"ba8a016a_a53ef825","updated":"2015-11-19 16:06:21.000000000","message":"Done","commit_id":"96e2dae796ff661cf377bffadcfa26e63c7845b9"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"70e1ad97b51b556fccd617755f94e95e5a8c185b","unresolved":false,"context_lines":[{"line_number":289,"context_line":""},{"line_number":290,"context_line":"    # TODO(henry-nash): We might want to consider list limiting this at some"},{"line_number":291,"context_line":"    # point in the future."},{"line_number":292,"context_line":"    def list_projects_for_user(self, user_id, hints\u003dNone):"},{"line_number":293,"context_line":"        # NOTE(henry-nash): In order to get a complete list of user projects,"},{"line_number":294,"context_line":"        # the driver will need to look at group assignments.  To avoid cross"},{"line_number":295,"context_line":"        # calling between the assignment and identity driver we get the group"}],"source_content_type":"text/x-python","patch_set":12,"id":"ba8a016a_a5259809","line":292,"updated":"2015-11-18 20:33:15.000000000","message":"This can also be cached ? Since it depends on user roles on the given project.","commit_id":"96e2dae796ff661cf377bffadcfa26e63c7845b9"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"938e0a4652755cbd50a234168e45c5e4b7f6804e","unresolved":false,"context_lines":[{"line_number":289,"context_line":""},{"line_number":290,"context_line":"    # TODO(henry-nash): We might want to consider list limiting this at some"},{"line_number":291,"context_line":"    # point in the future."},{"line_number":292,"context_line":"    def list_projects_for_user(self, user_id, hints\u003dNone):"},{"line_number":293,"context_line":"        # NOTE(henry-nash): In order to get a complete list of user projects,"},{"line_number":294,"context_line":"        # the driver will need to look at group assignments.  To avoid cross"},{"line_number":295,"context_line":"        # calling between the assignment and identity driver we get the group"}],"source_content_type":"text/x-python","patch_set":12,"id":"ba8a016a_79d96956","line":292,"in_reply_to":"ba8a016a_a5259809","updated":"2015-11-19 16:06:21.000000000","message":"Same comment as above.","commit_id":"96e2dae796ff661cf377bffadcfa26e63c7845b9"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"70e1ad97b51b556fccd617755f94e95e5a8c185b","unresolved":false,"context_lines":[{"line_number":325,"context_line":"        return self.resource_api.list_projects_from_ids(list(project_ids))"},{"line_number":326,"context_line":""},{"line_number":327,"context_line":"    # TODO(henry-nash): We might want to consider list limiting this at some"},{"line_number":328,"context_line":"    # point in the future."},{"line_number":329,"context_line":"    def list_domains_for_user(self, user_id, hints\u003dNone):"},{"line_number":330,"context_line":"        # NOTE(henry-nash): In order to get a complete list of user domains,"},{"line_number":331,"context_line":"        # the driver will need to look at group assignments.  To avoid cross"}],"source_content_type":"text/x-python","patch_set":12,"id":"ba8a016a_057b44f6","line":328,"updated":"2015-11-18 20:33:15.000000000","message":"This can also be cached ? Since it depends on user roles on the given project.","commit_id":"96e2dae796ff661cf377bffadcfa26e63c7845b9"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"938e0a4652755cbd50a234168e45c5e4b7f6804e","unresolved":false,"context_lines":[{"line_number":325,"context_line":"        return self.resource_api.list_projects_from_ids(list(project_ids))"},{"line_number":326,"context_line":""},{"line_number":327,"context_line":"    # TODO(henry-nash): We might want to consider list limiting this at some"},{"line_number":328,"context_line":"    # point in the future."},{"line_number":329,"context_line":"    def list_domains_for_user(self, user_id, hints\u003dNone):"},{"line_number":330,"context_line":"        # NOTE(henry-nash): In order to get a complete list of user domains,"},{"line_number":331,"context_line":"        # the driver will need to look at group assignments.  To avoid cross"}],"source_content_type":"text/x-python","patch_set":12,"id":"ba8a016a_39df613b","line":328,"in_reply_to":"ba8a016a_057b44f6","updated":"2015-11-19 16:06:21.000000000","message":"Same comment as above.","commit_id":"96e2dae796ff661cf377bffadcfa26e63c7845b9"},{"author":{"_account_id":13063,"name":"WEI CHEN","email":"dave.jungler@gmail.com","username":"wei.d.chen"},"change_message_id":"45105f64b83a760d61229853cd6ca6fe62ecce07","unresolved":false,"context_lines":[{"line_number":426,"context_line":"            self.resource_api.get_project(project_id)"},{"line_number":427,"context_line":"        self.driver.delete_grant(role_id, user_id, group_id, domain_id,"},{"line_number":428,"context_line":"                                 project_id, inherited_to_projects)"},{"line_number":429,"context_line":"        COMPUTED_ASSIGNMENTS_REGION.invalidate()"},{"line_number":430,"context_line":""},{"line_number":431,"context_line":"    # The methods _expand_indirect_assignment, _list_direct_role_assignments"},{"line_number":432,"context_line":"    # and _list_effective_role_assignments below are only used on"}],"source_content_type":"text/x-python","patch_set":14,"id":"7a740942_40caac4f","line":429,"updated":"2015-12-07 17:20:25.000000000","message":"I do think we need the testcases to test that the cache will be invalidated after the assignment has been deleted.\n\nThis will help to avoid the issue which similar with this, https://review.openstack.org/#/c/215212/14/keystone/contrib/endpoint_filter/core.py\n\nThis also apply to the other changes like this.","commit_id":"c1b8682ee9f3cee78a4ef752d1f9b3a96bbe5aa4"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"af8f8049690731da5f3d125bce8b485f935defa1","unresolved":false,"context_lines":[{"line_number":426,"context_line":"            self.resource_api.get_project(project_id)"},{"line_number":427,"context_line":"        self.driver.delete_grant(role_id, user_id, group_id, domain_id,"},{"line_number":428,"context_line":"                                 project_id, inherited_to_projects)"},{"line_number":429,"context_line":"        COMPUTED_ASSIGNMENTS_REGION.invalidate()"},{"line_number":430,"context_line":""},{"line_number":431,"context_line":"    # The methods _expand_indirect_assignment, _list_direct_role_assignments"},{"line_number":432,"context_line":"    # and _list_effective_role_assignments below are only used on"}],"source_content_type":"text/x-python","patch_set":14,"id":"7a740942_e8b8efea","line":429,"in_reply_to":"7a740942_40caac4f","updated":"2015-12-09 13:08:59.000000000","message":"Unit tests? Or in tempest?","commit_id":"c1b8682ee9f3cee78a4ef752d1f9b3a96bbe5aa4"},{"author":{"_account_id":13063,"name":"WEI CHEN","email":"dave.jungler@gmail.com","username":"wei.d.chen"},"change_message_id":"40b60740faaa10b1478eda83a548371a3ed08cdc","unresolved":false,"context_lines":[{"line_number":426,"context_line":"            self.resource_api.get_project(project_id)"},{"line_number":427,"context_line":"        self.driver.delete_grant(role_id, user_id, group_id, domain_id,"},{"line_number":428,"context_line":"                                 project_id, inherited_to_projects)"},{"line_number":429,"context_line":"        COMPUTED_ASSIGNMENTS_REGION.invalidate()"},{"line_number":430,"context_line":""},{"line_number":431,"context_line":"    # The methods _expand_indirect_assignment, _list_direct_role_assignments"},{"line_number":432,"context_line":"    # and _list_effective_role_assignments below are only used on"}],"source_content_type":"text/x-python","patch_set":14,"id":"7a740942_dab9327b","line":429,"in_reply_to":"7a740942_e8b8efea","updated":"2015-12-09 15:34:50.000000000","message":"Dolph - I must provide some testcases to verify that the cache does take effetcive - https://review.openstack.org/#/c/245633/\n\nSo, I think we need to provide testcases to verify this as well.","commit_id":"c1b8682ee9f3cee78a4ef752d1f9b3a96bbe5aa4"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"96c0de3a93b102c6d3960b502b41580f6f3ed880","unresolved":false,"context_lines":[{"line_number":173,"context_line":"                user_id,"},{"line_number":174,"context_line":"                tenant_id,"},{"line_number":175,"context_line":"                CONF.member_role_id)"},{"line_number":176,"context_line":"        COMPUTED_ASSIGNMENTS_REGION.invalidate()"},{"line_number":177,"context_line":""},{"line_number":178,"context_line":"    @notifications.role_assignment(\u0027created\u0027)"},{"line_number":179,"context_line":"    def _add_role_to_user_and_project_adapter(self, role_id, user_id\u003dNone,"}],"source_content_type":"text/x-python","patch_set":17,"id":"9a68dd71_28b51030","line":176,"updated":"2016-01-22 19:20:28.000000000","message":"Invalidate is a region/in-memory construct. This means we cannot use this invalidation across multiple processes.\n\nsee https://bitbucket.org/zzzeek/dogpile.cache/src/c6913eb143b24b4a886124ff0da5c935ea34e3ac/dogpile/cache/region.py?at\u003dmaster\u0026fileviewer\u003dfile-view-default#region.py-304:347\n\nI think I have a way to work around this issue, but i\u0027ll need a few minutes and it will involve a dogpile proxy. Doable but this it not the right way unfortunately.","commit_id":"aa3e0b2083492a800516bda4c8356cbd75093723"},{"author":{"_account_id":5707,"name":"Henry Nash","email":"henryn@linux.vnet.ibm.com","username":"henry-nash"},"change_message_id":"c2819f7540b7fe50eb7f1e4b3542bd70060e83f8","unresolved":false,"context_lines":[{"line_number":100,"context_line":"        else:"},{"line_number":101,"context_line":"            return []"},{"line_number":102,"context_line":""},{"line_number":103,"context_line":"    @MEMOIZE_COMPUTED_ASSIGNMENTS"},{"line_number":104,"context_line":"    def get_roles_for_user_and_project(self, user_id, tenant_id):"},{"line_number":105,"context_line":"        \"\"\"Get the roles associated with a user within given project."},{"line_number":106,"context_line":""}],"source_content_type":"text/x-python","patch_set":19,"id":"7a5de9d1_293cb392","line":103,"range":{"start_line":103,"start_character":5,"end_line":103,"end_character":33},"updated":"2016-01-27 16:10:46.000000000","message":"We could, instead, cache on list_role_assignments(). This would increase cache size (since this returns more data), but nearly all out role assignment reads end up calling this method (including a direct API)","commit_id":"91442edfdddaa812be1b17459e872de9c689547e"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"333eab44a29c258d53f99b7495d7ec030a9f11a9","unresolved":false,"context_lines":[{"line_number":41,"context_line":"MEMOIZE \u003d cache.get_memoization_decorator(group\u003d\u0027role\u0027)"},{"line_number":42,"context_line":""},{"line_number":43,"context_line":"# A Dogpile Proxy that will handle complete invalidation(s) for the entire"},{"line_number":44,"context_line":"# region by storing a key in the backend that is based upon the python"},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"# This builds a discrete cache region dedicated to role assignments computed"},{"line_number":47,"context_line":"# for a given user + project/domain pair. Any write operation to add or remove"}],"source_content_type":"text/x-python","patch_set":23,"id":"9a68dd71_1f294537","line":44,"updated":"2016-01-24 00:07:03.000000000","message":"This needs to be removed [comment[]","commit_id":"e43053827d8cb032d71448ad5570b99d39fb591f"},{"author":{"_account_id":5707,"name":"Henry Nash","email":"henryn@linux.vnet.ibm.com","username":"henry-nash"},"change_message_id":"c14651134f81a4f17af2573c451558225ff38b17","unresolved":false,"context_lines":[{"line_number":97,"context_line":"        else:"},{"line_number":98,"context_line":"            return []"},{"line_number":99,"context_line":""},{"line_number":100,"context_line":"    @MEMOIZE_COMPUTED_ASSIGNMENTS"},{"line_number":101,"context_line":"    def get_roles_for_user_and_project(self, user_id, tenant_id):"},{"line_number":102,"context_line":"        \"\"\"Get the roles associated with a user within given project."},{"line_number":103,"context_line":""}],"source_content_type":"text/x-python","patch_set":24,"id":"7a5de9d1_0f5c5424","line":100,"range":{"start_line":100,"start_character":4,"end_line":100,"end_character":33},"updated":"2016-01-27 17:27:41.000000000","message":"as per my comment on the previous patch - doing caching on list_role_assignments() would catch more calls (although would result in a larger cache size)","commit_id":"cd906266e67c8a8a8ae9676d2fa6dd1bd2f59bd8"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"e155d68f0056df6ccfdd81dbbf8b876a8b601f77","unresolved":false,"context_lines":[{"line_number":97,"context_line":"        else:"},{"line_number":98,"context_line":"            return []"},{"line_number":99,"context_line":""},{"line_number":100,"context_line":"    @MEMOIZE_COMPUTED_ASSIGNMENTS"},{"line_number":101,"context_line":"    def get_roles_for_user_and_project(self, user_id, tenant_id):"},{"line_number":102,"context_line":"        \"\"\"Get the roles associated with a user within given project."},{"line_number":103,"context_line":""}],"source_content_type":"text/x-python","patch_set":24,"id":"7a5de9d1_348879e7","line":100,"range":{"start_line":100,"start_character":4,"end_line":100,"end_character":33},"in_reply_to":"7a5de9d1_0f5c5424","updated":"2016-01-27 23:12:24.000000000","message":"Can be added.","commit_id":"cd906266e67c8a8a8ae9676d2fa6dd1bd2f59bd8"}],"keystone/common/cache/core.py":[{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"1028de4de9f28f309dc5247e3eb51af19b92d3bf","unresolved":false,"context_lines":[{"line_number":78,"context_line":"        # use `apply_invalidation_proxy()`."},{"line_number":79,"context_line":"        raise NotImplementedError()"},{"line_number":80,"context_line":""},{"line_number":81,"context_line":"    @@property"},{"line_number":82,"context_line":"    def _region(self):"},{"line_number":83,"context_line":"        # NOTE(morganfainberg): we need the region to be set, since"},{"line_number":84,"context_line":"        # invalidate needs to set a key, rather than re-implementing"}],"source_content_type":"text/x-python","patch_set":19,"id":"7a5de9d1_85e4a33b","line":81,"range":{"start_line":81,"start_character":5,"end_line":81,"end_character":6},"updated":"2016-01-27 18:16:37.000000000","message":"is this normal?","commit_id":"91442edfdddaa812be1b17459e872de9c689547e"},{"author":{"_account_id":2218,"name":"Adam Young","email":"adam@younglogic.com","username":"ayoung"},"change_message_id":"2876911004aadda1639384e54a244da80e34843f","unresolved":false,"context_lines":[{"line_number":76,"context_line":"        return None"},{"line_number":77,"context_line":""},{"line_number":78,"context_line":"    @hard_invalidated.setter"},{"line_number":79,"context_line":"    def hard_invalidated(self, value):"},{"line_number":80,"context_line":"        self.region.set(self.hard_region_key, value)"},{"line_number":81,"context_line":""},{"line_number":82,"context_line":"    @hard_invalidated.deleter"}],"source_content_type":"text/x-python","patch_set":24,"id":"7a5de9d1_2e94b935","line":79,"updated":"2016-01-27 16:01:52.000000000","message":"why return above but not here?","commit_id":"cd906266e67c8a8a8ae9676d2fa6dd1bd2f59bd8"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"e155d68f0056df6ccfdd81dbbf8b876a8b601f77","unresolved":false,"context_lines":[{"line_number":76,"context_line":"        return None"},{"line_number":77,"context_line":""},{"line_number":78,"context_line":"    @hard_invalidated.setter"},{"line_number":79,"context_line":"    def hard_invalidated(self, value):"},{"line_number":80,"context_line":"        self.region.set(self.hard_region_key, value)"},{"line_number":81,"context_line":""},{"line_number":82,"context_line":"    @hard_invalidated.deleter"}],"source_content_type":"text/x-python","patch_set":24,"id":"7a5de9d1_5412d5b5","line":79,"in_reply_to":"7a5de9d1_2e94b935","updated":"2016-01-27 23:12:24.000000000","message":"instance.attr \u003d \u003cvalue\u003e  does not return a value\n\n_hard_invalidated is explicitly set to None and we don\u0027t want api.NO_VALUE to be passed so we can be sure \"is not None\" works.","commit_id":"cd906266e67c8a8a8ae9676d2fa6dd1bd2f59bd8"},{"author":{"_account_id":2218,"name":"Adam Young","email":"adam@younglogic.com","username":"ayoung"},"change_message_id":"2876911004aadda1639384e54a244da80e34843f","unresolved":false,"context_lines":[{"line_number":92,"context_line":""},{"line_number":93,"context_line":"    @soft_invalidated.setter"},{"line_number":94,"context_line":"    def soft_invalidated(self, value):"},{"line_number":95,"context_line":"        self.region.set(self.soft_region_key, value)"},{"line_number":96,"context_line":""},{"line_number":97,"context_line":"    @soft_invalidated.deleter"},{"line_number":98,"context_line":"    def soft_invalidated(self):"}],"source_content_type":"text/x-python","patch_set":24,"id":"7a5de9d1_6eaab172","line":95,"updated":"2016-01-27 16:01:52.000000000","message":"why return above but not here?","commit_id":"cd906266e67c8a8a8ae9676d2fa6dd1bd2f59bd8"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"e155d68f0056df6ccfdd81dbbf8b876a8b601f77","unresolved":false,"context_lines":[{"line_number":92,"context_line":""},{"line_number":93,"context_line":"    @soft_invalidated.setter"},{"line_number":94,"context_line":"    def soft_invalidated(self, value):"},{"line_number":95,"context_line":"        self.region.set(self.soft_region_key, value)"},{"line_number":96,"context_line":""},{"line_number":97,"context_line":"    @soft_invalidated.deleter"},{"line_number":98,"context_line":"    def soft_invalidated(self):"}],"source_content_type":"text/x-python","patch_set":24,"id":"7a5de9d1_f423c103","line":95,"in_reply_to":"7a5de9d1_6eaab172","updated":"2016-01-27 23:12:24.000000000","message":"same as above.","commit_id":"cd906266e67c8a8a8ae9676d2fa6dd1bd2f59bd8"}],"keystone/identity/core.py":[{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"7ae92cad3c291d24a913cb85baa52d75a6affbcb","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":8,"id":"5a2ca52d_082c4a49","updated":"2015-10-13 13:47:04.000000000","message":"Why don\u0027t we cache every GET/LIST operation in this module ? (including list_role_assignments) as they all depend on the same logic (they all depend on target/role/actor) for invalidation.","commit_id":"0daf67cb756aad1792f2329895fe8d83974617da"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"dc392fd46f01e495a50f39b17af00d964fae4acb","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":8,"id":"5a2ca52d_fa8b8f1c","in_reply_to":"5a2ca52d_082c4a49","updated":"2015-10-14 21:58:47.000000000","message":"I guess that was because we start with caching the get_catalog path and this seemed like the next logic step...","commit_id":"0daf67cb756aad1792f2329895fe8d83974617da"},{"author":{"_account_id":220,"name":"Haneef Ali","email":"haneef.ali@hp.com","username":"haneef"},"change_message_id":"76ae147e11bbe42697da0d78a2de2b81b114e0de","unresolved":false,"context_lines":[{"line_number":23,"context_line":"from oslo_log import log"},{"line_number":24,"context_line":"import six"},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"from keystone import assignment"},{"line_number":27,"context_line":"from keystone.common import cache"},{"line_number":28,"context_line":"from keystone.common import clean"},{"line_number":29,"context_line":"from keystone.common import dependency"}],"source_content_type":"text/x-python","patch_set":8,"id":"7a2fa921_c1729549","line":26,"updated":"2015-10-12 20:50:02.000000000","message":"Do you really need identity module depend on assignment?  If we plan to separate identity, then we have unnecessary coupling","commit_id":"0daf67cb756aad1792f2329895fe8d83974617da"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"b0012ae62dc015c2f5692778b9f8b0e04b4cb6b2","unresolved":false,"context_lines":[{"line_number":23,"context_line":"from oslo_log import log"},{"line_number":24,"context_line":"import six"},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"from keystone import assignment"},{"line_number":27,"context_line":"from keystone.common import cache"},{"line_number":28,"context_line":"from keystone.common import clean"},{"line_number":29,"context_line":"from keystone.common import dependency"}],"source_content_type":"text/x-python","patch_set":8,"id":"7a2fa921_04097b31","line":26,"in_reply_to":"7a2fa921_c1729549","updated":"2015-10-12 21:13:19.000000000","message":"Yes, because the assignment module is where the assignment cache is. If we need to invalidate it because of a changed group or user entity, we need to use the assignment module to do so.","commit_id":"0daf67cb756aad1792f2329895fe8d83974617da"},{"author":{"_account_id":220,"name":"Haneef Ali","email":"haneef.ali@hp.com","username":"haneef"},"change_message_id":"76ae147e11bbe42697da0d78a2de2b81b114e0de","unresolved":false,"context_lines":[{"line_number":1008,"context_line":"        self.id_mapping_api.delete_id_mapping(group_id)"},{"line_number":1009,"context_line":"        self.assignment_api.delete_group_assignments(group_id)"},{"line_number":1010,"context_line":""},{"line_number":1011,"context_line":"        notifications.Audit.deleted(self._GROUP, group_id, initiator)"},{"line_number":1012,"context_line":""},{"line_number":1013,"context_line":"        for uid in user_ids:"},{"line_number":1014,"context_line":"            self.emit_invalidate_user_token_persistence(uid)"}],"source_content_type":"text/x-python","patch_set":8,"id":"7a2fa921_a1f19997","line":1011,"updated":"2015-10-12 20:50:02.000000000","message":"Don\u0027t we need to invalidate when we disable/delete/ groups and users?","commit_id":"0daf67cb756aad1792f2329895fe8d83974617da"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"b0012ae62dc015c2f5692778b9f8b0e04b4cb6b2","unresolved":false,"context_lines":[{"line_number":1008,"context_line":"        self.id_mapping_api.delete_id_mapping(group_id)"},{"line_number":1009,"context_line":"        self.assignment_api.delete_group_assignments(group_id)"},{"line_number":1010,"context_line":""},{"line_number":1011,"context_line":"        notifications.Audit.deleted(self._GROUP, group_id, initiator)"},{"line_number":1012,"context_line":""},{"line_number":1013,"context_line":"        for uid in user_ids:"},{"line_number":1014,"context_line":"            self.emit_invalidate_user_token_persistence(uid)"}],"source_content_type":"text/x-python","patch_set":8,"id":"7a2fa921_24b5977d","line":1011,"in_reply_to":"7a2fa921_a1f19997","updated":"2015-10-12 21:13:19.000000000","message":"yes, that\u0027s done at line 939 and 1007","commit_id":"0daf67cb756aad1792f2329895fe8d83974617da"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"7ae92cad3c291d24a913cb85baa52d75a6affbcb","unresolved":false,"context_lines":[{"line_number":1276,"context_line":"        \"\"\""},{"line_number":1277,"context_line":"        raise exception.NotImplemented()  # pragma: no cover"},{"line_number":1278,"context_line":""},{"line_number":1279,"context_line":"    @abc.abstractmethod"},{"line_number":1280,"context_line":"    def delete_user(self, user_id):"},{"line_number":1281,"context_line":"        \"\"\"Deletes an existing user."},{"line_number":1282,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"5a2ca52d_88961a93","line":1279,"updated":"2015-10-13 13:47:04.000000000","message":"What about if we delete a user ? We need to define this method in the manager itself and invalidate the cache in this case too.","commit_id":"0daf67cb756aad1792f2329895fe8d83974617da"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"dc392fd46f01e495a50f39b17af00d964fae4acb","unresolved":false,"context_lines":[{"line_number":1276,"context_line":"        \"\"\""},{"line_number":1277,"context_line":"        raise exception.NotImplemented()  # pragma: no cover"},{"line_number":1278,"context_line":""},{"line_number":1279,"context_line":"    @abc.abstractmethod"},{"line_number":1280,"context_line":"    def delete_user(self, user_id):"},{"line_number":1281,"context_line":"        \"\"\"Deletes an existing user."},{"line_number":1282,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"5a2ca52d_ff662128","line":1279,"in_reply_to":"5a2ca52d_88961a93","updated":"2015-10-14 21:58:47.000000000","message":"This method is defined in the manager are line 931, and we also invalidate the cache in that method.","commit_id":"0daf67cb756aad1792f2329895fe8d83974617da"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"7ae92cad3c291d24a913cb85baa52d75a6affbcb","unresolved":false,"context_lines":[{"line_number":1361,"context_line":"        \"\"\""},{"line_number":1362,"context_line":"        raise exception.NotImplemented()  # pragma: no cover"},{"line_number":1363,"context_line":""},{"line_number":1364,"context_line":"    @abc.abstractmethod"},{"line_number":1365,"context_line":"    def delete_group(self, group_id):"},{"line_number":1366,"context_line":"        \"\"\"Deletes an existing group."},{"line_number":1367,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"5a2ca52d_48e7a240","line":1364,"updated":"2015-10-13 13:47:04.000000000","message":"What about if we delete a group ? We need to define this method in the manager itself and invalidate the cache in this case too.","commit_id":"0daf67cb756aad1792f2329895fe8d83974617da"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"dc392fd46f01e495a50f39b17af00d964fae4acb","unresolved":false,"context_lines":[{"line_number":1361,"context_line":"        \"\"\""},{"line_number":1362,"context_line":"        raise exception.NotImplemented()  # pragma: no cover"},{"line_number":1363,"context_line":""},{"line_number":1364,"context_line":"    @abc.abstractmethod"},{"line_number":1365,"context_line":"    def delete_group(self, group_id):"},{"line_number":1366,"context_line":"        \"\"\"Deletes an existing group."},{"line_number":1367,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"5a2ca52d_5f7875c4","line":1364,"in_reply_to":"5a2ca52d_48e7a240","updated":"2015-10-14 21:58:47.000000000","message":"ditto to the same response above, but at line 1002.","commit_id":"0daf67cb756aad1792f2329895fe8d83974617da"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"10ebacd308bb984e0ef1bbf0ca9f7d314ad95166","unresolved":false,"context_lines":[{"line_number":927,"context_line":"            ref, domain_id, driver, mapping.EntityType.USER)"},{"line_number":928,"context_line":""},{"line_number":929,"context_line":"    @domains_configured"},{"line_number":930,"context_line":"    @exception_translated(\u0027user\u0027)"},{"line_number":931,"context_line":"    def delete_user(self, user_id, initiator\u003dNone):"},{"line_number":932,"context_line":"        domain_id, driver, entity_id \u003d ("},{"line_number":933,"context_line":"            self._get_domain_driver_and_entity_id(user_id))"}],"source_content_type":"text/x-python","patch_set":9,"id":"fa80f949_6567d325","line":930,"updated":"2015-11-05 21:54:37.000000000","message":"Don\u0027t we need to invalidate all the region create on assignment manager here too ?\n\nassignment.COMPUTED_ASSIGNMENTS_REGION.invalidate()","commit_id":"14f899864247c29a69dfec5d63b6fb79dda77bdb"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"c3bdb67f88f89720a6c45c288119696fa514ab7b","unresolved":false,"context_lines":[{"line_number":927,"context_line":"            ref, domain_id, driver, mapping.EntityType.USER)"},{"line_number":928,"context_line":""},{"line_number":929,"context_line":"    @domains_configured"},{"line_number":930,"context_line":"    @exception_translated(\u0027user\u0027)"},{"line_number":931,"context_line":"    def delete_user(self, user_id, initiator\u003dNone):"},{"line_number":932,"context_line":"        domain_id, driver, entity_id \u003d ("},{"line_number":933,"context_line":"            self._get_domain_driver_and_entity_id(user_id))"}],"source_content_type":"text/x-python","patch_set":9,"id":"fa80f949_a518581f","line":930,"in_reply_to":"fa80f949_226bfef2","updated":"2015-11-05 23:02:54.000000000","message":"Yes, when deleting a user.","commit_id":"14f899864247c29a69dfec5d63b6fb79dda77bdb"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"cbae9c01723ebeecde07549337057bb63bf80bdd","unresolved":false,"context_lines":[{"line_number":927,"context_line":"            ref, domain_id, driver, mapping.EntityType.USER)"},{"line_number":928,"context_line":""},{"line_number":929,"context_line":"    @domains_configured"},{"line_number":930,"context_line":"    @exception_translated(\u0027user\u0027)"},{"line_number":931,"context_line":"    def delete_user(self, user_id, initiator\u003dNone):"},{"line_number":932,"context_line":"        domain_id, driver, entity_id \u003d ("},{"line_number":933,"context_line":"            self._get_domain_driver_and_entity_id(user_id))"}],"source_content_type":"text/x-python","patch_set":9,"id":"fa80f949_226bfef2","line":930,"in_reply_to":"fa80f949_6567d325","updated":"2015-11-05 22:53:44.000000000","message":"Invalidating the cache when deleting a user you mean?","commit_id":"14f899864247c29a69dfec5d63b6fb79dda77bdb"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"10ebacd308bb984e0ef1bbf0ca9f7d314ad95166","unresolved":false,"context_lines":[{"line_number":1004,"context_line":"            self._get_domain_driver_and_entity_id(group_id))"},{"line_number":1005,"context_line":"        user_ids \u003d (u[\u0027id\u0027] for u in self.list_users_in_group(group_id))"},{"line_number":1006,"context_line":"        driver.delete_group(entity_id)"},{"line_number":1007,"context_line":"        self.get_group.invalidate(self, group_id)"},{"line_number":1008,"context_line":"        self.id_mapping_api.delete_id_mapping(group_id)"},{"line_number":1009,"context_line":"        self.assignment_api.delete_group_assignments(group_id)"},{"line_number":1010,"context_line":""}],"source_content_type":"text/x-python","patch_set":9,"id":"fa80f949_053cc7e0","line":1007,"updated":"2015-11-05 21:54:37.000000000","message":"Note that here we are just invalidating the cache of the method get_group, and not the cache region created at the assignment manager.","commit_id":"14f899864247c29a69dfec5d63b6fb79dda77bdb"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"cbae9c01723ebeecde07549337057bb63bf80bdd","unresolved":false,"context_lines":[{"line_number":1004,"context_line":"            self._get_domain_driver_and_entity_id(group_id))"},{"line_number":1005,"context_line":"        user_ids \u003d (u[\u0027id\u0027] for u in self.list_users_in_group(group_id))"},{"line_number":1006,"context_line":"        driver.delete_group(entity_id)"},{"line_number":1007,"context_line":"        self.get_group.invalidate(self, group_id)"},{"line_number":1008,"context_line":"        self.id_mapping_api.delete_id_mapping(group_id)"},{"line_number":1009,"context_line":"        self.assignment_api.delete_group_assignments(group_id)"},{"line_number":1010,"context_line":""}],"source_content_type":"text/x-python","patch_set":9,"id":"fa80f949_65011005","line":1007,"in_reply_to":"fa80f949_053cc7e0","updated":"2015-11-05 22:53:44.000000000","message":"The cache introduced in this patch is specific to user + project/domain pairs.","commit_id":"14f899864247c29a69dfec5d63b6fb79dda77bdb"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"c3bdb67f88f89720a6c45c288119696fa514ab7b","unresolved":false,"context_lines":[{"line_number":1004,"context_line":"            self._get_domain_driver_and_entity_id(group_id))"},{"line_number":1005,"context_line":"        user_ids \u003d (u[\u0027id\u0027] for u in self.list_users_in_group(group_id))"},{"line_number":1006,"context_line":"        driver.delete_group(entity_id)"},{"line_number":1007,"context_line":"        self.get_group.invalidate(self, group_id)"},{"line_number":1008,"context_line":"        self.id_mapping_api.delete_id_mapping(group_id)"},{"line_number":1009,"context_line":"        self.assignment_api.delete_group_assignments(group_id)"},{"line_number":1010,"context_line":""}],"source_content_type":"text/x-python","patch_set":9,"id":"fa80f949_c5ec7cf5","line":1007,"in_reply_to":"fa80f949_65011005","updated":"2015-11-05 23:02:54.000000000","message":"Yeah, it was just to support my comment below.","commit_id":"14f899864247c29a69dfec5d63b6fb79dda77bdb"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"10ebacd308bb984e0ef1bbf0ca9f7d314ad95166","unresolved":false,"context_lines":[{"line_number":1011,"context_line":"        notifications.Audit.deleted(self._GROUP, group_id, initiator)"},{"line_number":1012,"context_line":""},{"line_number":1013,"context_line":"        for uid in user_ids:"},{"line_number":1014,"context_line":"            self.emit_invalidate_user_token_persistence(uid)"},{"line_number":1015,"context_line":""},{"line_number":1016,"context_line":"    @domains_configured"},{"line_number":1017,"context_line":"    @exception_translated(\u0027group\u0027)"}],"source_content_type":"text/x-python","patch_set":9,"id":"fa80f949_c578ffc6","line":1014,"updated":"2015-11-05 21:54:37.000000000","message":"Don\u0027t we need to invalidate all the cache region created in assignment manager here too ?\n\nassignment.COMPUTED_ASSIGNMENTS_REGION.invalidate()","commit_id":"14f899864247c29a69dfec5d63b6fb79dda77bdb"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"cbae9c01723ebeecde07549337057bb63bf80bdd","unresolved":false,"context_lines":[{"line_number":1011,"context_line":"        notifications.Audit.deleted(self._GROUP, group_id, initiator)"},{"line_number":1012,"context_line":""},{"line_number":1013,"context_line":"        for uid in user_ids:"},{"line_number":1014,"context_line":"            self.emit_invalidate_user_token_persistence(uid)"},{"line_number":1015,"context_line":""},{"line_number":1016,"context_line":"    @domains_configured"},{"line_number":1017,"context_line":"    @exception_translated(\u0027group\u0027)"}],"source_content_type":"text/x-python","patch_set":9,"id":"fa80f949_45f64cfa","line":1014,"in_reply_to":"fa80f949_c578ffc6","updated":"2015-11-05 22:53:44.000000000","message":"Done","commit_id":"14f899864247c29a69dfec5d63b6fb79dda77bdb"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"a6f8a02735b75b9ad1cfde9e6d9cea6203d41b6b","unresolved":false,"context_lines":[{"line_number":1000,"context_line":""},{"line_number":1001,"context_line":"        for uid in user_ids:"},{"line_number":1002,"context_line":"            self.emit_invalidate_user_token_persistence(uid)"},{"line_number":1003,"context_line":"            assignment.COMPUTED_ASSIGNMENTS_REGION.invalidate()"},{"line_number":1004,"context_line":""},{"line_number":1005,"context_line":"    @domains_configured"},{"line_number":1006,"context_line":"    @exception_translated(\u0027group\u0027)"}],"source_content_type":"text/x-python","patch_set":10,"id":"fa80f949_e5e980e7","line":1003,"updated":"2015-11-05 23:02:44.000000000","message":"We don\u0027t need to invalidate inside the for; just once :)","commit_id":"65bc620437ce3619084860f90d58e9b28dc776d8"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"96f108a9d51b70b97cc2a2e774e403c93735550e","unresolved":false,"context_lines":[{"line_number":1000,"context_line":""},{"line_number":1001,"context_line":"        for uid in user_ids:"},{"line_number":1002,"context_line":"            self.emit_invalidate_user_token_persistence(uid)"},{"line_number":1003,"context_line":"            assignment.COMPUTED_ASSIGNMENTS_REGION.invalidate()"},{"line_number":1004,"context_line":""},{"line_number":1005,"context_line":"    @domains_configured"},{"line_number":1006,"context_line":"    @exception_translated(\u0027group\u0027)"}],"source_content_type":"text/x-python","patch_set":10,"id":"fa80f949_fc182020","line":1003,"in_reply_to":"fa80f949_e5e980e7","updated":"2015-11-06 14:37:19.000000000","message":"Done","commit_id":"65bc620437ce3619084860f90d58e9b28dc776d8"},{"author":{"_account_id":7725,"name":"David Stanek","email":"dstanek@dstanek.com","username":"dstanek"},"change_message_id":"2f1a08cb03b2762fb810e489c58ff46395f0fb12","unresolved":false,"context_lines":[{"line_number":23,"context_line":"from oslo_log import log"},{"line_number":24,"context_line":"import six"},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"from keystone import assignment"},{"line_number":27,"context_line":"from keystone.common import cache"},{"line_number":28,"context_line":"from keystone.common import clean"},{"line_number":29,"context_line":"from keystone.common import config"}],"source_content_type":"text/x-python","patch_set":16,"id":"fa69d971_ac7fc0dd","line":26,"updated":"2016-01-11 14:37:32.000000000","message":"Could we get rid of this using notifications? We keep getting rid of cross subsystem dependencies, but they keep sneaking back in.","commit_id":"73208e4fc034281e742dcadbae8f04ffe452ddf8"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"f7db07d4e476c7c8ba660259f2190204abf062ee","unresolved":false,"context_lines":[{"line_number":23,"context_line":"from oslo_log import log"},{"line_number":24,"context_line":"import six"},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"from keystone import assignment"},{"line_number":27,"context_line":"from keystone.common import cache"},{"line_number":28,"context_line":"from keystone.common import clean"},{"line_number":29,"context_line":"from keystone.common import config"}],"source_content_type":"text/x-python","patch_set":16,"id":"da6ed579_5735dcd7","line":26,"in_reply_to":"da6ed579_3435c6f6","updated":"2016-01-12 22:33:44.000000000","message":"I didn\u0027t think cross system dependencies were bad at the manager layers?","commit_id":"73208e4fc034281e742dcadbae8f04ffe452ddf8"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"0db7ae84e11eadc2706028e44030f42b01298f65","unresolved":false,"context_lines":[{"line_number":23,"context_line":"from oslo_log import log"},{"line_number":24,"context_line":"import six"},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"from keystone import assignment"},{"line_number":27,"context_line":"from keystone.common import cache"},{"line_number":28,"context_line":"from keystone.common import clean"},{"line_number":29,"context_line":"from keystone.common import config"}],"source_content_type":"text/x-python","patch_set":16,"id":"da6ed579_3435c6f6","line":26,"in_reply_to":"fa69d971_ac7fc0dd","updated":"2016-01-12 22:32:13.000000000","message":"Using notifications or using assignment?","commit_id":"73208e4fc034281e742dcadbae8f04ffe452ddf8"}],"keystone/resource/core.py":[{"author":{"_account_id":13055,"name":"Alexander Makarov","email":"ajiekcahdp.makapob@gmail.com","username":"amakarov"},"change_message_id":"54a0750dd80abb9e00676bf259618c55de3d100d","unresolved":false,"context_lines":[{"line_number":224,"context_line":"                                            original_tenant[\u0027domain_id\u0027])"},{"line_number":225,"context_line":""},{"line_number":226,"context_line":"        if (\u0027domain_id\u0027 in tenant and"},{"line_number":227,"context_line":"           tenant[\u0027domain_id\u0027] !\u003d original_tenant[\u0027domain_id\u0027]):"},{"line_number":228,"context_line":"            # If the project\u0027s domain_id has been updated, invalidate user"},{"line_number":229,"context_line":"            # role assignments cache region, as it may be caching inherited"},{"line_number":230,"context_line":"            # assignments from the old domain to the specified project"}],"source_content_type":"text/x-python","patch_set":14,"id":"7a740942_fc5aeb29","line":227,"updated":"2015-12-09 15:38:43.000000000","message":"btw, is there any real need to move project between domains?","commit_id":"c1b8682ee9f3cee78a4ef752d1f9b3a96bbe5aa4"},{"author":{"_account_id":7725,"name":"David Stanek","email":"dstanek@dstanek.com","username":"dstanek"},"change_message_id":"2f1a08cb03b2762fb810e489c58ff46395f0fb12","unresolved":false,"context_lines":[{"line_number":18,"context_line":"from oslo_log import log"},{"line_number":19,"context_line":"import six"},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"from keystone import assignment"},{"line_number":22,"context_line":"from keystone.common import cache"},{"line_number":23,"context_line":"from keystone.common import clean"},{"line_number":24,"context_line":"from keystone.common import dependency"}],"source_content_type":"text/x-python","patch_set":16,"id":"fa69d971_0cf4cc58","line":21,"updated":"2016-01-11 14:37:32.000000000","message":"Same as before.","commit_id":"73208e4fc034281e742dcadbae8f04ffe452ddf8"},{"author":{"_account_id":7725,"name":"David Stanek","email":"dstanek@dstanek.com","username":"dstanek"},"change_message_id":"2f1a08cb03b2762fb810e489c58ff46395f0fb12","unresolved":false,"context_lines":[{"line_number":223,"context_line":"        self.get_project_by_name.invalidate(self, original_tenant[\u0027name\u0027],"},{"line_number":224,"context_line":"                                            original_tenant[\u0027domain_id\u0027])"},{"line_number":225,"context_line":""},{"line_number":226,"context_line":"        if (\u0027domain_id\u0027 in tenant and"},{"line_number":227,"context_line":"           tenant[\u0027domain_id\u0027] !\u003d original_tenant[\u0027domain_id\u0027]):"},{"line_number":228,"context_line":"            # If the project\u0027s domain_id has been updated, invalidate user"},{"line_number":229,"context_line":"            # role assignments cache region, as it may be caching inherited"}],"source_content_type":"text/x-python","patch_set":16,"id":"fa69d971_2ce2f0a0","line":226,"updated":"2016-01-11 14:37:32.000000000","message":"This is unfortunate because it makes using notifications a little more messy. Is update project used so much that always invalidating would be bad?","commit_id":"73208e4fc034281e742dcadbae8f04ffe452ddf8"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"0db7ae84e11eadc2706028e44030f42b01298f65","unresolved":false,"context_lines":[{"line_number":223,"context_line":"        self.get_project_by_name.invalidate(self, original_tenant[\u0027name\u0027],"},{"line_number":224,"context_line":"                                            original_tenant[\u0027domain_id\u0027])"},{"line_number":225,"context_line":""},{"line_number":226,"context_line":"        if (\u0027domain_id\u0027 in tenant and"},{"line_number":227,"context_line":"           tenant[\u0027domain_id\u0027] !\u003d original_tenant[\u0027domain_id\u0027]):"},{"line_number":228,"context_line":"            # If the project\u0027s domain_id has been updated, invalidate user"},{"line_number":229,"context_line":"            # role assignments cache region, as it may be caching inherited"}],"source_content_type":"text/x-python","patch_set":16,"id":"da6ed579_f415ee48","line":226,"in_reply_to":"fa69d971_2ce2f0a0","updated":"2016-01-12 22:32:13.000000000","message":"We only care if the project id is updated, right? Because that would affect assignments.","commit_id":"73208e4fc034281e742dcadbae8f04ffe452ddf8"}],"keystone/tests/unit/test_backend.py":[{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"7ae92cad3c291d24a913cb85baa52d75a6affbcb","unresolved":false,"context_lines":[{"line_number":1012,"context_line":""},{"line_number":1013,"context_line":"        role_list \u003d self.assignment_api.get_roles_for_user_and_project("},{"line_number":1014,"context_line":"            user_ref[\u0027id\u0027],"},{"line_number":1015,"context_line":"            project_ref[\u0027id\u0027])"},{"line_number":1016,"context_line":""},{"line_number":1017,"context_line":"        self.assertEqual(set([r[\u0027id\u0027] for r in role_ref_list]),"},{"line_number":1018,"context_line":"                         set(role_list))"}],"source_content_type":"text/x-python","patch_set":8,"id":"5a2ca52d_884b7a2b","line":1015,"updated":"2015-10-13 13:47:04.000000000","message":"Unrelated change ?","commit_id":"0daf67cb756aad1792f2329895fe8d83974617da"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"dc392fd46f01e495a50f39b17af00d964fae4acb","unresolved":false,"context_lines":[{"line_number":1012,"context_line":""},{"line_number":1013,"context_line":"        role_list \u003d self.assignment_api.get_roles_for_user_and_project("},{"line_number":1014,"context_line":"            user_ref[\u0027id\u0027],"},{"line_number":1015,"context_line":"            project_ref[\u0027id\u0027])"},{"line_number":1016,"context_line":""},{"line_number":1017,"context_line":"        self.assertEqual(set([r[\u0027id\u0027] for r in role_ref_list]),"},{"line_number":1018,"context_line":"                         set(role_list))"}],"source_content_type":"text/x-python","patch_set":8,"id":"5a2ca52d_c31cc215","line":1015,"in_reply_to":"5a2ca52d_884b7a2b","updated":"2015-10-14 21:58:47.000000000","message":"Nope, we have to do this because dogpile doesn\u0027t take keyword arguments when building a key.","commit_id":"0daf67cb756aad1792f2329895fe8d83974617da"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"10ebacd308bb984e0ef1bbf0ca9f7d314ad95166","unresolved":false,"context_lines":[{"line_number":1018,"context_line":""},{"line_number":1019,"context_line":"        role_list \u003d self.assignment_api.get_roles_for_user_and_project("},{"line_number":1020,"context_line":"            user_ref[\u0027id\u0027],"},{"line_number":1021,"context_line":"            project_ref[\u0027id\u0027])"},{"line_number":1022,"context_line":""},{"line_number":1023,"context_line":"        self.assertEqual(set([r[\u0027id\u0027] for r in role_ref_list]),"},{"line_number":1024,"context_line":"                         set(role_list))"}],"source_content_type":"text/x-python","patch_set":9,"id":"fa80f949_007d956d","line":1021,"updated":"2015-11-05 21:54:37.000000000","message":"Unrelated change?","commit_id":"14f899864247c29a69dfec5d63b6fb79dda77bdb"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"cbae9c01723ebeecde07549337057bb63bf80bdd","unresolved":false,"context_lines":[{"line_number":1018,"context_line":""},{"line_number":1019,"context_line":"        role_list \u003d self.assignment_api.get_roles_for_user_and_project("},{"line_number":1020,"context_line":"            user_ref[\u0027id\u0027],"},{"line_number":1021,"context_line":"            project_ref[\u0027id\u0027])"},{"line_number":1022,"context_line":""},{"line_number":1023,"context_line":"        self.assertEqual(set([r[\u0027id\u0027] for r in role_ref_list]),"},{"line_number":1024,"context_line":"                         set(role_list))"}],"source_content_type":"text/x-python","patch_set":9,"id":"fa80f949_45cdecb5","line":1021,"in_reply_to":"fa80f949_007d956d","updated":"2015-11-05 22:53:44.000000000","message":"Nope, we need to do this because memcache doesn\u0027t take kwargs when creating keys.","commit_id":"14f899864247c29a69dfec5d63b6fb79dda77bdb"},{"author":{"_account_id":17860,"name":"Samuel de Medeiros Queiroz","email":"samueldmq@gmail.com","username":"samueldmq"},"change_message_id":"c3bdb67f88f89720a6c45c288119696fa514ab7b","unresolved":false,"context_lines":[{"line_number":1018,"context_line":""},{"line_number":1019,"context_line":"        role_list \u003d self.assignment_api.get_roles_for_user_and_project("},{"line_number":1020,"context_line":"            user_ref[\u0027id\u0027],"},{"line_number":1021,"context_line":"            project_ref[\u0027id\u0027])"},{"line_number":1022,"context_line":""},{"line_number":1023,"context_line":"        self.assertEqual(set([r[\u0027id\u0027] for r in role_ref_list]),"},{"line_number":1024,"context_line":"                         set(role_list))"}],"source_content_type":"text/x-python","patch_set":9,"id":"fa80f949_85a8b48e","line":1021,"in_reply_to":"fa80f949_45cdecb5","updated":"2015-11-05 23:02:54.000000000","message":"Really ? That\u0027s bad, because we don\u0027t know if the method is cached when we\u0027re calling it, in order to decide if providing named params or not :(","commit_id":"14f899864247c29a69dfec5d63b6fb79dda77bdb"},{"author":{"_account_id":13055,"name":"Alexander Makarov","email":"ajiekcahdp.makapob@gmail.com","username":"amakarov"},"change_message_id":"54a0750dd80abb9e00676bf259618c55de3d100d","unresolved":false,"context_lines":[{"line_number":952,"context_line":"                role_id\u003drole_ref[\u0027id\u0027])"},{"line_number":953,"context_line":""},{"line_number":954,"context_line":"        role_list \u003d self.assignment_api.get_roles_for_user_and_project("},{"line_number":955,"context_line":"            user_ref[\u0027id\u0027],"},{"line_number":956,"context_line":"            project_ref[\u0027id\u0027])"},{"line_number":957,"context_line":""},{"line_number":958,"context_line":"        self.assertEqual(set([r[\u0027id\u0027] for r in role_ref_list]),"}],"source_content_type":"text/x-python","patch_set":14,"id":"7a740942_5cbd3f01","line":955,"updated":"2015-12-09 15:38:43.000000000","message":"questionable. As for me, passing kwargs is more explicit","commit_id":"c1b8682ee9f3cee78a4ef752d1f9b3a96bbe5aa4"},{"author":{"_account_id":5046,"name":"Lance Bragstad","email":"lbragstad@redhat.com","username":"ldbragst"},"change_message_id":"9b93f6c0f76ab85b739df29704315743595ba27c","unresolved":false,"context_lines":[{"line_number":952,"context_line":"                role_id\u003drole_ref[\u0027id\u0027])"},{"line_number":953,"context_line":""},{"line_number":954,"context_line":"        role_list \u003d self.assignment_api.get_roles_for_user_and_project("},{"line_number":955,"context_line":"            user_ref[\u0027id\u0027],"},{"line_number":956,"context_line":"            project_ref[\u0027id\u0027])"},{"line_number":957,"context_line":""},{"line_number":958,"context_line":"        self.assertEqual(set([r[\u0027id\u0027] for r in role_ref_list]),"}],"source_content_type":"text/x-python","patch_set":14,"id":"fa69d971_76d0c41f","line":955,"in_reply_to":"7a740942_5cbd3f01","updated":"2016-01-05 14:13:42.000000000","message":"We can\u0027t pass kwargs here because it makes the caching operation fail. If you pull down the patch locally, revert the changes made to these two lines and run the tests, you should get an invalid key/signature error when caching. We had to do similar changes in the previous patch [0].\n\n[0] https://review.openstack.org/#/c/215212/14/keystone/tests/unit/test_v3_catalog.py","commit_id":"c1b8682ee9f3cee78a4ef752d1f9b3a96bbe5aa4"}]}
