Skip to content

Commit d0d3755

Browse files
authored
feat(spanner): make leader aware routing default enabled for supported RPC requests. (#7912)
1 parent 151908a commit d0d3755

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

spanner/client.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,7 @@ func contextWithOutgoingMetadata(ctx context.Context, md metadata.MD, disableRou
178178
// form projects/PROJECT_ID/instances/INSTANCE_ID/databases/DATABASE_ID. It uses
179179
// a default configuration.
180180
func NewClient(ctx context.Context, database string, opts ...option.ClientOption) (*Client, error) {
181-
return NewClientWithConfig(ctx, database, ClientConfig{SessionPoolConfig: DefaultSessionPoolConfig, DisableRouteToLeader: true}, opts...)
181+
return NewClientWithConfig(ctx, database, ClientConfig{SessionPoolConfig: DefaultSessionPoolConfig, DisableRouteToLeader: false}, opts...)
182182
}
183183

184184
// NewClientWithConfig creates a client to a database. A valid database name has

0 commit comments

Comments
 (0)