Allow partial pipelining within a transaction
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 8.7k
- Forks
- 374
- Avg merge
- 11d 16h
- Merged PRs (30d)
- 1
Description
Allow pipelining the some requests in a transaction without requiring that all the requests are pipelined. This would allow selecting to get the id of a row, then issuing multiple statements based on the id of the row in a pipelined fashion.
For example:
await sql.begin(async sql => {
const [movie] = await sql`
SELECT * FROM Movie
WHERE name = 'Star Wars'
`;
return [
sql`
INSERT INTO MovieActor
-- some statement using ${movie.id}
`,
sql`
INSERT INTO MovieReleases
-- some statement using ${movie.id}
`,
// etc
]
})
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the transaction entry point shown in the issue, sql.begin, and trace how tagged sql requests are currently grouped and executed. Compare the existing all-pipelined behavior with the requested mix of an awaited result followed by pipelined statements; done means both sequential and pipelined requests work within one transaction.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, postgresql
- Domain
- database
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100