Skip to content

Commit 3720091

Browse files
authored
redshift: fix notebook connection wizard prompter order (#1077)
redshift: fix notebook connection wizard prompter order (#1077) Problem Temporary credentials authentication is not supported for serverless workgroups. In notebook connection wizard, connection type selection is before the cluster/workgroup selection. So it's possible for customers to select temporary credentials for serverless workgroups. Customers will get an error while executing queries. Solution Move the connection type selection after the cluster/warehouse selection. So temporary credentials is not available to pick for serverless workgroups.
1 parent b097b36 commit 3720091

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/redshift/wizards/connectionWizard.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ export class NotebookConnectionWizard extends Wizard<ConnectionParams> {
122122
}
123123
})
124124
this.form.connectionType.bindPrompter(state => getConnectionTypePrompterNB(state?.warehouseType), {
125-
relativeOrder: 1,
125+
relativeOrder: 3,
126126
})
127127

128128
this.form.database.bindPrompter(getDatabasePrompter, { relativeOrder: 4 })

src/test/redshift/wizards/connectionWizard.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ describe('NotebookConnectionWizard', async () => {
8181
const testWizard = createWizardTester(new NotebookConnectionWizard(mockRegionProvider))
8282
testWizard.region.assertShowFirst()
8383
testWizard.region.applyInput({ id: 'US East - 1', name: 'us-east-1' })
84-
testWizard.warehouseIdentifier.assertShowSecond()
84+
testWizard.warehouseIdentifier.assertShowFirst()
8585
testWizard.warehouseIdentifier.applyInput('testCluster')
8686
testWizard.connectionType.assertShowFirst()
8787
testWizard.connectionType.applyInput(ConnectionType.TempCreds)
@@ -96,7 +96,7 @@ describe('NotebookConnectionWizard', async () => {
9696
const testWizard = createWizardTester(new NotebookConnectionWizard(mockRegionProvider))
9797
testWizard.region.assertShowFirst()
9898
testWizard.region.applyInput({ id: 'US East - 1', name: 'us-east-1' })
99-
testWizard.warehouseIdentifier.assertShowSecond()
99+
testWizard.warehouseIdentifier.assertShowFirst()
100100
testWizard.warehouseIdentifier.applyInput('testCluster')
101101
testWizard.connectionType.assertShowFirst()
102102
testWizard.connectionType.applyInput(ConnectionType.SecretsManager)

0 commit comments

Comments
 (0)