Open dvv opened 9 months ago
To narrow the problem.
I believe we should collect array of entities used in exposed functions (arg_types || type_oid
).
Filter them by schema usage permission.
Expose them as types and may be connections (if some function returns the setof of the entity).
Do NOT expose collection/mutation for them, effectively obey search_path instruction.
That way we won't be in need to proxy each and every piece of hidden schemas to the exposed schema.
yes, you're exactly right with the solution
One way would be to add a CTE under this to collect any tables or views referenced by functions on the search_path
where the referenced table is not on the search_path
and then updating the join here to include them
It might not actually require an update to the rust source but TBD
Describe the bug Seems a function returning a table from another schema is not exposed.
To Reproduce Steps to reproduce the behavior:
Expected behavior I would expect fully-typed return values to be exposed based on permissions and regardless of
search_path
.Versions: