roob
DTDrizzle Team
•Created by roob on 8/28/2023 in #help
JSON with PostgreSQL not serializing correctly
All right, I can see that its a bug :/ https://github.com/drizzle-team/drizzle-orm/issues/724
3 replies
DTDrizzle Team
•Created by roob on 8/7/2023 in #help
Do I need to close the DB connection after running a script using drizzle?
as you can see, I'm importing the 'raw' connection variable from my connection setup, and at the end of my script, I'm calling
connect.end()
25 replies
DTDrizzle Team
•Created by roob on 8/7/2023 in #help
Do I need to close the DB connection after running a script using drizzle?
@spiritanand I'm currently closing at the end of my script. I'm doing it like this:
25 replies
DTDrizzle Team
•Created by roob on 8/7/2023 in #help
Do I need to close the DB connection after running a script using drizzle?
thanks for your help!
25 replies
DTDrizzle Team
•Created by roob on 8/7/2023 in #help
Do I need to close the DB connection after running a script using drizzle?
but for local dev I will end the connection now manually in my scripts
25 replies
DTDrizzle Team
•Created by roob on 8/7/2023 in #help
Do I need to close the DB connection after running a script using drizzle?
I'm not executing it yet on lambda, was just wondering how this hanging promise/open connection is handled
25 replies
DTDrizzle Team
•Created by roob on 8/7/2023 in #help
Do I need to close the DB connection after running a script using drizzle?
or is the hanging promise only related to the whole execution environment and not the handle function itself
25 replies
DTDrizzle Team
•Created by roob on 8/7/2023 in #help
Do I need to close the DB connection after running a script using drizzle?
but will this result in my lambda invocation time beeing as long as the connection is open?
25 replies
DTDrizzle Team
•Created by roob on 8/7/2023 in #help
Do I need to close the DB connection after running a script using drizzle?
@pandareaper you mean because of the lambda beeing held 'warm' for example? so the connection is still alive?
25 replies
DTDrizzle Team
•Created by roob on 8/7/2023 in #help
Do I need to close the DB connection after running a script using drizzle?
@pandareaper yeah exporting the
connection
and calling .end()
works. How is this handled in serverless context? Do I need to take care of this manually?25 replies
DTDrizzle Team
•Created by roob on 8/7/2023 in #help
Do I need to close the DB connection after running a script using drizzle?
I can export my
connection
(the raw postgres.js connection object) and then call connection.end()
at the end of each script. is that intended? How does it work in serverless environments?25 replies
DTDrizzle Team
•Created by roob on 8/7/2023 in #help
Do I need to close the DB connection after running a script using drizzle?
but script still hanging, meh
25 replies
DTDrizzle Team
•Created by roob on 8/7/2023 in #help
Do I need to close the DB connection after running a script using drizzle?
25 replies
DTDrizzle Team
•Created by roob on 8/7/2023 in #help
Do I need to close the DB connection after running a script using drizzle?
It looks a bit like this one: https://github.com/drizzle-team/drizzle-orm/issues/619
25 replies
DTDrizzle Team
•Created by roob on 3/16/2023 in #help
Example failed to run: `pg` does not provide an export named `Pool`
thanks, will do this!
9 replies
DTDrizzle Team
•Created by roob on 3/16/2023 in #help
Example failed to run: `pg` does not provide an export named `Pool`
Do you have a link or keyword I can google to understand this behaviour?
9 replies
DTDrizzle Team
•Created by roob on 3/16/2023 in #help
Example failed to run: `pg` does not provide an export named `Pool`
However I do not understand why this error occured because of this
9 replies
DTDrizzle Team
•Created by roob on 3/16/2023 in #help
Example failed to run: `pg` does not provide an export named `Pool`
@bloberenober I removed the
"type": "module"
now from my package.json and it seems to solve this, thanks!9 replies