Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multiple schemas via request's path /schema1/tableA, /schema2/viewB #2956

Closed
steve-chavez opened this issue Sep 18, 2023 · 2 comments
Closed
Labels
idea Needs of discussion to become an enhancement, not ready for implementation

Comments

@steve-chavez
Copy link
Member

If we really want to make working with multiple schemas easy, we should reconsider just doing that via the request's path, like /schema1/tableA, /schema2/viewB etc.

Originally posted by @wolfgangwalther in #2927 (comment)

@steve-chavez
Copy link
Member Author

Copy pasting the discussion on #2927


like /schema1/tableA, /schema2/viewB

@steve-chavez I'd be against it because:


it makes the url brittle (a schema is an implementation detail and a rename would break the url)

@wolfgangwalther That's not true. A schema is not an implementation detail as soon as you use multiple of them. Right now, you need to pass the schema in the -Profile headers. That makes it part of the API.

Whether to change a header or the path in the URL if you change the schema name - does not make a difference. You need to change it anyway.

would make impossible to do resource embedding across different schemas (if we ever want to)

Not true, either. You just need syntax. you could do /schema1/table1?select=*,schema2/table2(*), for example. That's actually quite natural and much easier to deal with name conflicts compared to the header approach.

will make custom urls harder to implement later on

And of course I don't agree here as well. If done right, this could actually be a step towards custom URLs.

@steve-chavez steve-chavez added the idea Needs of discussion to become an enhancement, not ready for implementation label Sep 18, 2023
@steve-chavez
Copy link
Member Author

@wolfgangwalther Just had an idea for implementing this on #2157 (comment). I think that's the way forward, seems pretty simple and plays along with #1086 (comment).

Will close here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
idea Needs of discussion to become an enhancement, not ready for implementation
Development

No branches or pull requests

1 participant