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

supabase / realtime / 40666509681
94%

Build:
DEFAULT BRANCH: main
Ran 28 Oct 2026 09:52AM UTC
Jobs 1
Files 133
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

28 Oct 2026 09:43AM UTC coverage: 92.895% (+0.1%) from 92.764%
40666509681

push

github

web-flow
feat: RLS evaluation application side experiment (#2384)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: Sean Geoghegan <sean@seangeo.me>

This is an experiment to see if we can make in particular joining a channel more efficient. Particularly relevant in events of mass reconnects (f.ex. deploys).

Basically, joining a channel requires a database query as of right now to check the RLS permissions of a given user. In practice, many of these policies do not require the database at all as they check the channel against the JWT the user provided.

So, this will run an experiment trying to see if we can evaluate some RLS policies application side (in elixir) without needing to go to the database [1].
The main directive here is: We're only evaluating it if we're absolutely sure we can evaluate it.

It will also not be deciding yet - for now it's running in "shadow" mode where its results are compared against the answers of the real RLS policy and we log out any mismatches. We also report and log the reasons we couldn't evaluate something to get an estimate of the coverage we can achieve and so to see the positive impact. The fallback reason given and logged does not include details on the policy.

Even this experiment is behind a feature flag, and the check itself runs in a separate task (after the original/real check completed) to avoid interference - we also run with queue: false to minimize resource contention.

Fair warning, these are a lot of changes. Commits should give a better view of the story.
The bulk of the logic for this lives in a new sub library sql_logex that is tested extensively as well as including integration tests inside real time that compare its output values to the real SQL output from the versions we're running it against.

We intend to deploy it to staging.

This was a day-shift x night-shift collaboration with @seangeo 🤜 🤛

og[1] Naturally we first need to grab the RLS policy and some other goodies from th... (continued)

114 of 117 new or added lines in 7 files covered. (97.44%)

2 existing lines in 2 files now uncovered.

4432 of 4771 relevant lines covered (92.89%)

5183.65 hits per line

Uncovered Changes

Lines Coverage ∆ File
2
96.43
lib/realtime/tenants/sql_logex_shadow.ex
1
90.91
lib/realtime/tenants/sql_logex_cache.ex

Coverage Regressions

Lines Coverage ∆ File
1
97.83
-2.17% lib/realtime/telemetry/logger.ex
1
83.33
-8.33% lib/realtime/tenants/reconnector.ex
Jobs
ID Job ID Ran Files Coverage
1 40666509681.1 28 Oct 2026 09:52AM UTC 532
61.39
GitHub Action Run
Source Files on build 40666509681
  • Tree
  • List 133
  • Changed 106
  • Source Changed 3
  • Coverage Changed 106
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #40666509681
  • 820726d0 on github
  • Prev Build on main (#40604611140)
  • Next Build on main (#40676149656)
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