Skip to content

Commit 95a5cf9

Browse files
authored
fix: remove static host list provider check (#601)
1 parent 2f837ff commit 95a5cf9

2 files changed

Lines changed: 0 additions & 12 deletions

File tree

common/lib/plugins/aurora_initial_connection_strategy_plugin.ts

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,9 +51,6 @@ export class AuroraInitialConnectionStrategyPlugin extends AbstractConnectionPlu
5151
initHostProviderFunc: () => void
5252
): void {
5353
this.hostListProviderService = hostListProviderService;
54-
if (hostListProviderService.isStaticHostListProvider()) {
55-
throw new AwsWrapperError(Messages.get("AuroraInitialConnectionStrategyPlugin.requireDynamicProvider"));
56-
}
5754
initHostProviderFunc();
5855
}
5956

tests/unit/aurora_initial_connection_strategy_plugin.test.ts

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -90,15 +90,6 @@ describe("Aurora initial connection strategy plugin", () => {
9090
await expect(plugin.connect(hostInfo, props, true, mockFunc)).rejects.toThrow(Error);
9191
});
9292

93-
it("test static HostListProvider", async () => {
94-
const plugin = new AuroraInitialConnectionStrategyPlugin(instance(mockPluginService));
95-
when(mockHostListProviderService.isStaticHostListProvider()).thenReturn(true);
96-
97-
expect(() => {
98-
plugin.initHostProvider(hostInfo, props, instance(mockHostListProviderService), mockFunc);
99-
}).toThrow(AwsWrapperError);
100-
});
101-
10293
it("test writer - not found", async () => {
10394
when(mockRdsUtils.identifyRdsType(anything())).thenReturn(RdsUrlType.RDS_WRITER_CLUSTER);
10495
when(mockPluginService.getAllHosts()).thenReturn([hostInfoBuilder.withRole(HostRole.READER).build()]);

0 commit comments

Comments
 (0)