All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.quarkus.oidc.UserInfoCache Maven / Gradle / Ivy

Go to download

Secure your applications with OpenID Connect Adapter and IDP such as Keycloak

There is a newer version: 3.17.5
Show newest version
package io.quarkus.oidc;

import io.smallrye.mutiny.Uni;

/**
 * UserInfo cache.
 */
public interface UserInfoCache {

    /**
     * Add a new {@link UserInfo} to the cache.
     *
     * @param token the token which was used to get {@link UserInfo}
     * @param userInfo {@link UserInfo}
     * @param oidcConfig the tenant configuration
     * @param requestContext the request context which can be used to run the blocking tasks
     */
    Uni addUserInfo(String token, UserInfo userInfo, OidcTenantConfig oidcConfig,
            OidcRequestContext requestContext);

    /**
     * Get the cached {@link UserInfo}.
     *
     * @param token the token which will be used to get new {@link UserInfo} if no {@link UserInfo} is cached.
     *        Effectively this token is a cache key which has to be stored when
     *        {@link #addUserInfo(String, UserInfo, OidcTenantConfig, AddUserInfoRequestContext)}
     *        is called.
     * @param oidcConfig the tenant configuration
     * @param requestContext the request context which can be used to run the blocking tasks
     */
    Uni getUserInfo(String token, OidcTenantConfig oidcConfig, OidcRequestContext requestContext);
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy