cant connect to postgres db
smithmanny
HOBBYOP

a month ago

I'm getting an error when using the pg internal url

received direct SSL connection request without ALPN protocol negotiation extension

$10 Bounty

6 Replies

Railway
BOT

a month ago

Hey there! We've found the following might help you get unblocked faster:

If you find the answer from one of these, please let us know by solving the thread!


Can you share the error that you are getting from your application?


Status changed to Awaiting User Response Railway 27 days ago


smithmanny
HOBBYOP

25 days ago

sorry just seeing this.
(node:11) [DEP0060] DeprecationWarning: The util._extend API is deprecated. Please use Object.assign() instead.

consumer start: (Use node --trace-deprecation ... to show where the warning was created)

consumer start: Error: Failed query: insert into "waitlist" ("id", "created_at", "updated_at", "email") values (default, default, default, $1) on conflict do nothing

consumer start: params: shakhorsmith@gmail.com

consumer start: at o.queryWithCache (.next/server/chunks/ssr/_ef94ec34._.js:236:41231)

consumer start: at async Object.handler (.next/server/chunks/ssr/_632353c2._.js:13:630)

consumer start: at async f (.next/server/chunks/ssr/_ac79848f._.js:1:5434)

consumer start: at async next (.next/server/chunks/ssr/_ac79848f._.js:1:5379)

consumer start: at async (.next/server/chunks/ssr/_ac79848f._.js:5:2034)

consumer start: at async (.next/server/chunks/ssr/_ac79848f._.js:1:5299)

consumer start: at async f (.next/server/chunks/ssr/_ac79848f._.js:1:5138)

consumer start: at async next (.next/server/chunks/ssr/_ac79848f._.js:1:5379)

consumer start: at async (.next/server/chunks/ssr/_ac79848f._.js:5:1094) {

consumer start: query: 'insert into "waitlist" ("id", "created_at", "updated_at", "email") values (default, default, default, $1) on conflict do nothing',

consumer start: params: [Array],

consumer start: [cause]: AggregateError:

consumer start: at async (.next/server/chunks/ssr/_ef94ec34._.js:236:44756)

consumer start: at async o.queryWithCache (.next/server/chunks/ssr/_ef94ec34._.js:236:41206)

consumer start: at async Object.handler (.next/server/chunks/ssr/_632353c2._.js:13:630)

consumer start: at async f (.next/server/chunks/ssr/_ac79848f._.js:1:5434)

consumer start: at async next (.next/server/chunks/ssr/_ac79848f._.js:1:5379)

consumer start: at async (.next/server/chunks/ssr/_ac79848f._.js:5:2034)

consumer start: at async (.next/server/chunks/ssr/_ac79848f._.js:1:5299)

consumer start: at async f (.next/server/chunks/ssr/_ac79848f._.js:1:5138) {

consumer start: code: 'ECONNREFUSED'

consumer start: }

consumer start: }


Status changed to Awaiting Railway Response Railway 25 days ago


smithmanny

sorry just seeing this. (node:11) [DEP0060] DeprecationWarning: The util._extend API is deprecated. Please use Object.assign() instead.consumer start: (Use node --trace-deprecation ... to show where the warning was created)consumer start: Error: Failed query: insert into "waitlist" ("id", "created_at", "updated_at", "email") values (default, default, default, $1) on conflict do nothingconsumer start: params: shakhorsmith@gmail.comconsumer start: at o.queryWithCache (.next/server/chunks/ssr/_ef94ec34._.js:236:41231)consumer start: at async Object.handler (.next/server/chunks/ssr/_632353c2._.js:13:630)consumer start: at async f (.next/server/chunks/ssr/_ac79848f._.js:1:5434)consumer start: at async next (.next/server/chunks/ssr/_ac79848f._.js:1:5379)consumer start: at async (.next/server/chunks/ssr/_ac79848f._.js:5:2034)consumer start: at async (.next/server/chunks/ssr/_ac79848f._.js:1:5299)consumer start: at async f (.next/server/chunks/ssr/_ac79848f._.js:1:5138)consumer start: at async next (.next/server/chunks/ssr/_ac79848f._.js:1:5379)consumer start: at async (.next/server/chunks/ssr/_ac79848f._.js:5:1094) {consumer start: query: 'insert into "waitlist" ("id", "created_at", "updated_at", "email") values (default, default, default, $1) on conflict do nothing',consumer start: params: [Array],consumer start: [cause]: AggregateError:consumer start: at async (.next/server/chunks/ssr/_ef94ec34._.js:236:44756)consumer start: at async o.queryWithCache (.next/server/chunks/ssr/_ef94ec34._.js:236:41206)consumer start: at async Object.handler (.next/server/chunks/ssr/_632353c2._.js:13:630)consumer start: at async f (.next/server/chunks/ssr/_ac79848f._.js:1:5434)consumer start: at async next (.next/server/chunks/ssr/_ac79848f._.js:1:5379)consumer start: at async (.next/server/chunks/ssr/_ac79848f._.js:5:2034)consumer start: at async (.next/server/chunks/ssr/_ac79848f._.js:1:5299)consumer start: at async f (.next/server/chunks/ssr/_ac79848f._.js:1:5138) {consumer start: code: 'ECONNREFUSED'consumer start: }consumer start: }

passos
MODERATOR

24 days ago

Hey, I see that the error you're getting is different from what you told us. It appears your NodeJS application is experiencing connection refused errors when attempting to connect. Please ensure your credentials are correct and that the database is operational.

As a last resort, try connecting to your database via a database viewer or using the data tab.


smithmanny
HOBBYOP

24 days ago

I'm using the env variable provided by Railway to connect to my db. I can access the db viewer and inspect tables with no problems


smithmanny

I'm using the env variable provided by Railway to connect to my db. I can access the db viewer and inspect tables with no problems

passos
MODERATOR

23 days ago

If you're able to connect to your database through the DB viewer, then I would start examining your code. Additionally, I see mentions of query cache, which might require a Redis instance or similar caching system that may not currently exist.


Loading...