/
githubmirror
/
ydb-java-sdk
Обзор
Документация
Войти
/
githubmirror
/
ydb-java-sdk
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
auth-providers/oauth2-provider/src/main/java/tech/ydb/auth/OAuth2AuthHelper.java
20 строк
446 B
Alexandr Gorshenin
Added environment auth provider with runtime class loading
27 окт 2024, 13:20
Не верифицирован
27 окт 2024, 13:20
e6bc656
Код
Авторство
О чём код?
package tech.ydb.auth; import java.nio.file.Path; import tech.ydb.core.impl.auth.GrpcAuthRpc; /** * * @author Aleksandr Gorshenin */ public class OAuth2AuthHelper { private OAuth2AuthHelper() { } public static AuthIdentity configFileIdentity(Path file, GrpcAuthRpc rpc) { return OAuth2TokenExchangeProvider .fromFile(file.toFile()) .build() .createAuthIdentity(rpc); } }