supavisor
pg_net
supavisor | pg_net | |
---|---|---|
15 | 4 | |
1,591 | 171 | |
1.8% | 6.4% | |
8.9 | 7.2 | |
2 days ago | about 2 months ago | |
Elixir | PLpgSQL | |
Apache License 2.0 | Apache License 2.0 |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
supavisor
-
PostgreSQL Is Enough
WalEx instead of pub/sub (listen/subscribe): https://github.com/cpursley/walex
Supavisor connection pooler: https://github.com/supabase/supavisor
-
Introducing Read Replicas
To make use of your read replicas, copy your connection string for the read replica, update your apps to use the new read replica and you are done! A unique connection pool is also provisioned for each read replica via Supavisor.
-
Supavisor 1.0: a scalable connection pooler for Postgres
[I'm on the supabase team]
You can find the code/docs here: https://github.com/supabase/supavisor
This release adds support for
- SQL Parsing
- Load balancing
- support for named prepared statement
- query cancellation
It's also now available on all new databases in Supabase. For some more background on scalability, we have some benchmarks available here:
https://supabase.com/blog/supavisor-1-million
-
PgBouncer 1.21.0 released with prepared statement support
PgBouncer maintainer here, so obviously biased. But I think currently PgBouncer should still be the default connection pooler that you choose. There's a few newer options: Odyssey, pgcat, and supavisor. But all focus on a solving 1 or 2 specific problems that PgBouncer did not solve well, while not solving many of the other problems that PgBouncer does solve. So if you have the exact same requirements as the authors of those tools, then switching might be good. But otherwise you should probably continue using PgBouncer.
Supavisor specifically is really immature. It's missing some really core functionality like query cancellations: https://github.com/supabase/supavisor/issues/174
I did a talk on this exact topic at PGConf NYC recently. My slides are here: https://github.com/JelteF/slides/raw/main/2023-10-05-future-...
-
Supavisor: Scaling Postgres to 1 Million Connections
If you are interested in exploring Supavisor's potential or want to implement its scalability in your upcoming project, check out the GitHub repository to know more.
-
How to Listen to Database Changes Using Postgres Triggers in Elixir
Phoenix.PubSub is basically a noop service. It really just works. You should try it!
If discovering nodes is difficult in your env, try using a listen/notify libcluster strategy:
https://github.com/supabase/supavisor/blob/main/lib/cluster/...
-
The Database Package Manager for PostgreSQL Trusted Language Extensions
[2] https://github.com/supabase/supavisor
-
Supabase Logs: open source logging server
Supavisor
- Supavisor - Postgres connection pooler written in Elixir
- Supavisor - a Postgres connection pooler written in Elixir
pg_net
- PostgreSQL Is Enough
-
Supabase Wrappers: A Framework for Building Postgres Foreign Data Wrappers
> speaks a particular API over the network
it's a interesting idea, and one of the things that we were toying with in our pg_net extension (https://github.com/supabase/pg_net). This is a "generic" async network extension, so you can fetch/put/post. It works well for APIs.
I think the generic approach works for some things where the data is less "fixed" - for example, an OpenAI API endpoint.
But for "fixed" data (data warehouses), the wrapper usually needs some custom work for security, protocols, and "push down". I'll be interested to get HN's take on this - they might have some suggestions for us for this framework
-
Show HN: Multiplayer Demo Built with Elixir
> finding the building blocks of modern applications (database, auth, functions, presence, realtime subscriptions), making them easy to use, and then sharing the source code.
Great observation!
> I’ve learned a ton just from cruising around supabase GitHub.
Glad to hear it!
> Can you say which of these new components will be open sourced?
All of these components are open source and licensed under Apache License v2.0.
> There are some other features (e.g. function hooks) that are also closed-source at the moment.
I actually worked on the initial implementation of function hooks. We've actually already open sourced both the client (see: https://github.com/supabase/supabase/tree/88bcef911669595428...) and the pg_net extension it requires (see: https://github.com/supabase/pg_net).
> Is Supabase heading for an “open core” model?
I don't think so. We want to continue to open source our projects under either MIT (client libs) and Apache License v2.0 (server libs).
-
Supabase Edge Functions
> The dream would be to have a great DX experience around using insert/update triggers to call Supabase functions to run background tasks
We have something for this: Function Hooks (soon to be renamed "Async Triggers")[0]. They are still in alpha, but the extension [1] is getting close. It was important to build something which works with PG background workers so that it's non-blocking. We'll make quick progress on this now that we've released Edge Functions.
> sending notifications or updating related rows
Tune in for tomorrow's announcement - it's related.
[0] Function Hooks / Async Triggers: https://supabase.com/blog/2021/07/30/supabase-functions-upda...
[1] https://github.com/supabase/pg_net
What are some alternatives?
pgcat - PostgreSQL pooler with sharding, load balancing and failover support.
pgsentinel - postgresql extension providing Active session history
pg_tle - Framework for building trusted language extensions for PostgreSQL
pg_hexedit - Open PostgreSQL relation files in a hex editor with tags and annotations
mssql-changefeed
Multicorn - Data Access Library
debezium - Change data capture for a variety of databases. Please log issues at https://issues.redhat.com/browse/DBZ.
pgsql-http - HTTP client for PostgreSQL, retrieve a web page from inside the database.
sql-examples - Curated list of SQL to help you find useful script easily 🚀
supabase - The open source Firebase alternative.
walex - Postgres change events (CDC) in Elixir
wal2json - JSON output plugin for changeset extraction