Skip to content

Commit 4c40d8e

Browse files
authored
refactor: Remove unnecessary pre-fetching from R2DBC. (#2107)
When the java connector was refactored to use ConnectorConfig and ConnectionConfig value objects, it was no longer necessary to pre-fetch the connection configuration to ensure that enableIamAuth was set correctly. Also, this is inconsistent behavior compared to the JDBC socket factory.
1 parent bcd8f93 commit 4c40d8e

File tree

1 file changed

+0
-3
lines changed

1 file changed

+0
-3
lines changed

r2dbc/core/src/main/java/com/google/cloud/sql/core/GcpConnectionFactoryProvider.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -144,9 +144,6 @@ public ConnectionFactory create(ConnectionFactoryOptions connectionFactoryOption
144144
.withRefreshStrategy(refreshStrategy)
145145
.build())
146146
.build();
147-
// Precompute SSL Data to trigger the initial refresh to happen immediately,
148-
// and ensure enableIAMAuth is set correctly.
149-
InternalConnectorRegistry.getInstance().getConnectionMetadata(config);
150147

151148
String socket = (String) connectionFactoryOptions.getValue(UNIX_SOCKET);
152149
if (socket != null) {

0 commit comments

Comments
 (0)