Skip to content

Commit

Permalink
feat(spanner): added spanner options method usePlainText for abstraction
Browse files Browse the repository at this point in the history
  • Loading branch information
sagnghos committed Jan 2, 2025
1 parent 2391971 commit 1f1ef13
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1518,6 +1518,12 @@ public Builder useClientCert(String host, String clientCertificate, String clien
return this;
}

public Builder usePlainText() {
this.setChannelConfigurator(ManagedChannelBuilder::usePlaintext);
this.setCredentials(NoCredentials.getInstance());
return this;
}

/**
* Sets OpenTelemetry object to be used for Spanner Metrics and Traces. GlobalOpenTelemetry will
* be used as fallback if this options is not set.
Expand Down

0 comments on commit 1f1ef13

Please sign in to comment.