Skip to content

Commit a70eea0

Browse files
authored
Fix connect UI host param (supabase#31084)
1 parent 972eba3 commit a70eea0

File tree

2 files changed

+5
-25
lines changed

2 files changed

+5
-25
lines changed

apps/studio/components/interfaces/Connect/ConnectionParameters.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ import {
1414
interface Parameter {
1515
key: string
1616
value: string
17-
description?: string
1817
}
1918

2019
interface ConnectionParametersProps {

apps/studio/components/interfaces/Connect/DatabaseConnectionString.tsx

Lines changed: 5 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -306,22 +306,14 @@ export const DatabaseConnectionString = () => {
306306
}}
307307
notice={['Does not support PREPARE statements']}
308308
parameters={[
309-
{
310-
...CONNECTION_PARAMETERS.host,
311-
value: `${projectRef}.pooler.supabase.${poolerTld}`,
312-
},
309+
{ ...CONNECTION_PARAMETERS.host, value: poolingConfiguration?.db_host ?? '' },
313310
{
314311
...CONNECTION_PARAMETERS.port,
315312
value: poolingConfiguration?.db_port.toString() ?? '6543',
316-
description: 'Port number for transaction pooler',
317313
},
318314
{ ...CONNECTION_PARAMETERS.database, value: connectionInfo.db_name },
319315
{ ...CONNECTION_PARAMETERS.user, value: connectionInfo.db_user },
320-
{
321-
...CONNECTION_PARAMETERS.pool_mode,
322-
value: 'transaction',
323-
description: 'Each transaction uses a different connection',
324-
},
316+
{ ...CONNECTION_PARAMETERS.pool_mode, value: 'transaction' },
325317
]}
326318
onCopyCallback={() => handleCopy(selectedTab)}
327319
/>
@@ -351,22 +343,11 @@ export const DatabaseConnectionString = () => {
351343
description: 'Session pooler connections are IPv4 proxied for free.',
352344
}}
353345
parameters={[
354-
{
355-
...CONNECTION_PARAMETERS.host,
356-
value: `${projectRef}.pooler.supabase.${poolerTld}`,
357-
},
358-
{
359-
...CONNECTION_PARAMETERS.port,
360-
value: '5432',
361-
description: 'Port number for session pooler',
362-
},
346+
{ ...CONNECTION_PARAMETERS.host, value: poolingConfiguration?.db_host ?? '' },
347+
{ ...CONNECTION_PARAMETERS.port, value: '5432' },
363348
{ ...CONNECTION_PARAMETERS.database, value: connectionInfo.db_name },
364349
{ ...CONNECTION_PARAMETERS.user, value: connectionInfo.db_user },
365-
{
366-
...CONNECTION_PARAMETERS.pool_mode,
367-
value: 'session',
368-
description: 'Connection is reserved for the entire session',
369-
},
350+
{ ...CONNECTION_PARAMETERS.pool_mode, value: 'session' },
370351
]}
371352
onCopyCallback={() => handleCopy(selectedTab)}
372353
/>

0 commit comments

Comments
 (0)