invalidate(roleId) {
    if (!roleId) {
      this.roles.clear();
    } else {
      this.roles.delete(roleId);
    }
  }
Invalidate the cache entries for the given role. If none is provided,
the entire cache is emptied.
@param {string} [roleId]