Skip to content

Commit 1ddd53e

Browse files
committed
correct read function perms
1 parent e9e13d5 commit 1ddd53e

File tree

2 files changed

+6
-7
lines changed

2 files changed

+6
-7
lines changed

nix/tests/expected/pgmq_data_api_wrapper.out

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
/*
2-
This test is to validate the SQL for the Supabase Queues integration that
1+
/*
2+
This test is to validate the SQL for the Supabase Queues integration that
33
will be triggered in the FE and documented for how to manually expose
44
queues over supabase client libs by wrapping `pgmq`'s functions into a
55
separate schema that we can add to PostgREST's 'exposed_schemas' setting
@@ -194,8 +194,7 @@ grant execute on function pgmq.archive(text, bigint) to postgres, service_role,
194194
grant execute on function queues_public.queue_delete(text, bigint) to postgres, service_role, anon, authenticated;
195195
grant execute on function pgmq.delete(text, bigint) to postgres, service_role, anon, authenticated;
196196
grant execute on function queues_public.queue_read(text, integer, integer) to postgres, service_role, anon, authenticated;
197-
grant execute on function pgmq.read(text, integer, integer, jsonb) to postgres, service_role, anon, authenticated;
198-
ERROR: function pgmq.read(text, integer, integer, jsonb) does not exist
197+
grant execute on function pgmq.read(text, integer, integer) to postgres, service_role, anon, authenticated;
199198
-- For the service role, we want full access
200199
-- Grant permissions on existing tables
201200
grant all privileges on all tables in schema pgmq to postgres, service_role;

nix/tests/sql/pgmq_data_api_wrapper.sql

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
/*
2-
This test is to validate the SQL for the Supabase Queues integration that
1+
/*
2+
This test is to validate the SQL for the Supabase Queues integration that
33
will be triggered in the FE and documented for how to manually expose
44
queues over supabase client libs by wrapping `pgmq`'s functions into a
55
separate schema that we can add to PostgREST's 'exposed_schemas' setting
@@ -231,7 +231,7 @@ grant execute on function queues_public.queue_delete(text, bigint) to postgres,
231231
grant execute on function pgmq.delete(text, bigint) to postgres, service_role, anon, authenticated;
232232

233233
grant execute on function queues_public.queue_read(text, integer, integer) to postgres, service_role, anon, authenticated;
234-
grant execute on function pgmq.read(text, integer, integer, jsonb) to postgres, service_role, anon, authenticated;
234+
grant execute on function pgmq.read(text, integer, integer) to postgres, service_role, anon, authenticated;
235235

236236
-- For the service role, we want full access
237237
-- Grant permissions on existing tables

0 commit comments

Comments
 (0)