libcluster_postgres
libcluster_postgres copied to clipboard
The `channel_name` limitations are missing
Describe the problem
The documentation provides no hint about the necessity to supply a valid channel_name (the Pg NOTIFY command requires no dashes and it didn't work with big caps channels --> so even using the cookie did not work)
Describe the improvement
- Either sanitize the channe_name (whether it comes from the config or from the cookie)
- Update the doc. to indicate the limitations (only small caps, no dashes etc...) I'm not aware of all constraints here and could only share what did NOT work for me
Bit by this as well. It appears that this line silently fails with no log? https://github.com/supabase/libcluster_postgres/blob/3d6511d8247471a2fb307df23f942ed09a5fce7c/lib/strategy.ex#L80C5-L80C20
@jfayad Thanks for sharing.
Not sure what the best way to recommend an improvement for this is (outside of submitting a pr myself), but I too ran into this problem.