Something worth knowing if you add monitoring or tracing to an app that uses Supabase.
If your server talks to Supabase through supabase-js, those calls go over HTTP (PostgREST). Most APM and tracing tools therefore record them as outgoing HTTP requests, not as database queries. You see something like GET https://<project>.supabase.co/rest/v1/orders with a duration, but not the query behind it.
If you connect with a Postgres driver directly (pg in Node, psycopg or SQLAlchemy in Python), the same tools record real database spans with timings.
What helps:
GET /rest/v1/orders shows up as a pattern instead of scattered requests.Question: how do you watch query performance in production when everything goes through supabase-js? Has anyone traced through PostgREST in a way that keeps the SQL?
(Disclosure: I'm building Relia, a monitoring tool, and this is a gap I'm working on. Curious how others handle it.)
Viraj Rakholiya discusses the challenge of monitoring Supabase apps where supabase-js calls are recorded as HTTP requests rather than database queries by APM tools. He seeks advice on tracing query performance in production when using supabase-js, highlighting the gap in current monitoring solutions. Viraj is developing a tool called Relia to address this issue.