@@ -149,12 +149,53 @@ static final class ClosedException extends RuntimeException {
149149 this .dbAdminClient = new DatabaseAdminClientImpl (options .getProjectId (), gapicRpc );
150150 this .instanceClient =
151151 new InstanceAdminClientImpl (options .getProjectId (), gapicRpc , dbAdminClient );
152+ logSpannerOptions (options );
152153 }
153154
154155 SpannerImpl (SpannerOptions options ) {
155156 this (options .getSpannerRpcV1 (), options );
156157 }
157158
159+ private void logSpannerOptions (SpannerOptions options ) {
160+ if (logger .isLoggable (Level .CONFIG )) {
161+ logger .log (
162+ Level .CONFIG ,
163+ "Spanner options: "
164+ + "\n Project ID: "
165+ + options .getProjectId ()
166+ + "\n Host: "
167+ + options .getHost ()
168+ + "\n Num gRPC channels: "
169+ + options .getNumChannels ()
170+ + "\n Leader aware routing enabled: "
171+ + options .isLeaderAwareRoutingEnabled ()
172+ + "\n Direct access enabled: "
173+ + options .isEnableDirectAccess ()
174+ + "\n Active Tracing Framework: "
175+ + SpannerOptions .getActiveTracingFramework ()
176+ + "\n API tracing enabled: "
177+ + options .isEnableApiTracing ()
178+ + "\n Extended tracing enabled: "
179+ + options .isEnableExtendedTracing ()
180+ + "\n End to end tracing enabled: "
181+ + options .isEndToEndTracingEnabled ()
182+ + "\n Built-in metrics enabled: "
183+ + options .isEnableBuiltInMetrics ()
184+ + "\n Session pool min sessions: "
185+ + options .getSessionPoolOptions ().getMinSessions ()
186+ + "\n Session pool max sessions: "
187+ + options .getSessionPoolOptions ().getMaxSessions ()
188+ + "\n Multiplexed sessions enabled: "
189+ + options .getSessionPoolOptions ().getUseMultiplexedSession ()
190+ + "\n Multiplexed sessions enabled for RW: "
191+ + options .getSessionPoolOptions ().getUseMultiplexedSessionForRW ()
192+ + "\n Multiplexed sessions enabled for blind write: "
193+ + options .getSessionPoolOptions ().getUseMultiplexedSessionBlindWrite ()
194+ + "\n Multiplexed sessions enabled for partitioned ops: "
195+ + options .getSessionPoolOptions ().getUseMultiplexedSessionPartitionedOps ());
196+ }
197+ }
198+
158199 /** Returns the {@link SpannerRpc} of this {@link SpannerImpl} instance. */
159200 SpannerRpc getRpc () {
160201 return gapicRpc ;
0 commit comments