libcluster_postgres icon indicating copy to clipboard operation
libcluster_postgres copied to clipboard

The `channel_name` limitations are missing

Open jfayad opened this issue 1 year ago • 1 comments

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

  1. Either sanitize the channe_name (whether it comes from the config or from the cookie)
  2. 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

jfayad avatar May 10 '24 16:05 jfayad

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

tfwright avatar Jul 25 '24 08:07 tfwright

@jfayad Thanks for sharing.

acrolink avatar Nov 30 '24 09:11 acrolink

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.

blakedietz avatar Dec 09 '24 02:12 blakedietz