dbos-inc / dbos-transact-ts

The TypeScript framework for backends that scale
https://docs.dbos.dev
MIT License
373 stars 28 forks source link

Access Database Connection From Handler #627

Open kraftp opened 2 months ago

kraftp commented 2 months ago

From jansommer on Discord:

I've asked in ⁠Custom connection to Postgres why I have to decorate calls to pg with @Transaction. Would be nice to access the client from a HandlerContext when I'm doing things a @Transaction cant handle, where a stored procedure is overkill, and where I'd like to do more such as starting a workflow (the response from signup is needed, while the email can be sent in the background)