• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

supabase / supavisor / 17412897580
83%

Build:
DEFAULT BRANCH: main
Ran 02 Sep 2025 06:51PM UTC
Jobs 2
Files 67
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

02 Sep 2025 06:42PM UTC coverage: 61.848% (+3.5%) from 58.388%
17412897580

push

github

web-flow
feat: improved named prepared statements support (#694)

Adds support for Prepared Statements through the Extended Query
Protocol.

### Concept
This PR implements the following architecture:
- ClientHandlers keep track of the prepared statements sent on them
- ClientHandlers update the prepared statement packets changing the
statement names to "internal names" (this is necessary because clients
may reuse the names in different connections)
- Prepared statement packets aren't sent directly to the db socket, but
instead are sent to the DbHandler. Whenever the ClientHandler sends a
`bind` packet to the DbHandler, it should also send the respective
`parse` (which it has stored)
- DbHandler decides whether it needs to run "parse" or just "bind"
- DbHandler must intercept "parse" responses when the client didn't
request them/it was made due to necessity
- DbHandler injects "parse" responses when the client requested a parse
but it's not necessary

### Parsing/decoding
- To be able to handle the prepared statement packets, ClientHandlers
need to peek at every client packet (at least on transaction mode)
- To be able to intercept parse responses, DbHandler needs to peek at
every server packet.
- For both ClientHandler and DbHandler, we can avoid decoding the whole
payload/decode only what's necessary (generally, we only need tagging,
except for the prepared statement payloads from which we need more
data).
- The decoding means more CPU usage, and it could also mean that we will
need to optimize the decoding routines a bit further.

### Limits
- ClientHandlers and DbHandler have separate limits
- If trespassing a ClientHandler limit, an error is returned and the
connection is closed
- If trespassing the DbHandler limit, a clean-up is triggered and a
random set of prepared statements is dropped. This is transparent to the
client. The only consequence for them is that some of their queries may
need to be re-prepared.
- ClientHandler has a memory limit. Every cli... (continued)

356 of 438 new or added lines in 17 files covered. (81.28%)

14 existing lines in 4 files now uncovered.

1553 of 2511 relevant lines covered (61.85%)

5472.08 hits per line

Jobs
ID Job ID Ran Files Coverage
1 run-tests - 17412897580.1 02 Sep 2025 06:51PM UTC 0
58.22
GitHub Action Run
2 run-integration - 17412897580.2 02 Sep 2025 06:56PM UTC 0
44.01
GitHub Action Run
Source Files on build 17412897580
Detailed source file information is not available for this build.
  • Back to Repo
  • Github Actions Build #17412897580
  • c75ca58f on github
  • Prev Build on main (#17307760804)
  • Next Build on main (#17443898625)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc