4 ms·
I really love PostgREST. This was my early approach to realtime, using PostgREST for CRUD operations: https://paul.copplest.one/blog/nimbus-tech-2019-04.html#te
by kiwicopple 7y ago
I really love PostgREST. This was my early approach to realtime, using PostgREST for CRUD operations: https://paul.copplest.one/blog/nimbus-tech-2019-04.html#tech-stack https://paul.copplest.one/blog/nimbus-tech-2019-04.html#tech...
Not much is different now except I don't use NOTIFY anymore due to the 8000 byte payload limitation (and the reason why I made the elixir server)
- numtel 7y agoI got around the 8000 byte limit by sending multiple notifications in this NPM package: https://github.com/numtel/pg-live-select/blob/master/lib/trigger.tpl.sql#L42 https://github.com/numtel/pg-live-select/blob/master/lib/tri... Reading the replication log is probably faster though. MySQL has row-based replication too and there's clients in most languages if you want to support it on your saas. Do you have plans to support changes to specific SELECT queries or keep it at the row level?
- kiwicopple 7y agoThat's quite clever, I never actually thought of that. Guessing from your username, this is your package? It's very cool Yes, we will allow filtering on the listener, just shipping early. Next steps, we will only filter on the Primary keys - something like supabase.from('users:id.eq.1') - but eventually we will support advanced filtering like this: https://supabase.io/docs/library/get#filtering https://supabase.io/docs/library/get#filtering