Class SpannerCredentials
java.lang.Object
io.github.flink.gcp.connector.spanner.SpannerCredentials
Loads credentials shared by every direction of this connector: the sink writer, the bounded
source's planner and readers, the Change Streams coordinator and query clients, and the table
lookup path.
-
Method Summary
-
Method Details
-
load
@Nullable public static com.google.auth.oauth2.GoogleCredentials load(@Nullable String serviceAccountKeyFile) throws IOException Loads a service-account key file, or returnsnullto preserve application-default credentials.The path and parser failure are deliberately absent from the exception. A path can expose a mounted secret's name, and parser exceptions can echo credential material.
- Parameters:
serviceAccountKeyFile- the configured key-file path, ornullfor ADC- Returns:
- scoped service-account credentials, or
nullfor ADC - Throws:
IOException- if the configured file cannot be read as a service-account key
-