package credentials
import "github.com/ydb-platform/ydb-go-sdk/v3/credentials"
Index ¶
- func NewAccessTokenCredentials( accessToken string, opts ...credentials.AccessTokenCredentialsOption, ) *credentials.AccessToken
- func NewAnonymousCredentials( opts ...credentials.AnonymousCredentialsOption, ) *credentials.Anonymous
- func NewStaticCredentials( user, password, authEndpoint string, opts ...credentials.StaticCredentialsOption, ) *credentials.Static
- func WithGrpcDialOptions(opts ...grpc.DialOption) credentials.StaticCredentialsOption
- func WithSourceInfo(sourceInfo string) credentials.SourceInfoOption
- type Credentials
Functions ¶
func NewAccessTokenCredentials ¶
func NewAccessTokenCredentials( accessToken string, opts ...credentials.AccessTokenCredentialsOption, ) *credentials.AccessToken
NewAccessTokenCredentials makes access token credentials object Passed options redefines default values of credentials object internal fields
func NewAnonymousCredentials ¶
func NewAnonymousCredentials( opts ...credentials.AnonymousCredentialsOption, ) *credentials.Anonymous
NewAnonymousCredentials makes anonymous credentials object Passed options redefines default values of credentials object internal fields
func NewStaticCredentials ¶
func NewStaticCredentials( user, password, authEndpoint string, opts ...credentials.StaticCredentialsOption, ) *credentials.Static
NewStaticCredentials makes static credentials object
func WithGrpcDialOptions ¶
func WithGrpcDialOptions(opts ...grpc.DialOption) credentials.StaticCredentialsOption
WithGrpcDialOptions option append to static credentials object GRPC dial options
func WithSourceInfo ¶
func WithSourceInfo(sourceInfo string) credentials.SourceInfoOption
WithSourceInfo option append to credentials object the source info for reporting source info details on error case
Types ¶
type Credentials ¶
type Credentials interface { // Token must return actual token or error Token(context.Context) (string, error) }
Credentials is an interface of YDB credentials required for connect with YDB
Source Files ¶
- Version
- v3.54.3
- Published
- Dec 28, 2023
- Platform
- linux/amd64
- Imports
- 3 packages
- Last checked
- 9 minutes ago –
Tools for package owners.