-
-
Notifications
You must be signed in to change notification settings - Fork 568
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
Postgres 11 partitions support #1160
Comments
In general, features like this are added to PostGraphile in the following ways:
Option 4 is how most things get done, but it takes a long time because my sponsored time also covers a lot of other duties, and because I have my own perceived priorities on which tasks or features should be built first. Excitingly, as my sponsorship levels grow, the rate of change in option 4 is increasing 🙂 The demand for this feature is not (yet) particularly high. People who are interested in this feature should use the 👍 emoji response on the above comment. |
@ lskrajny you could always use smart comments + a view to force postgraphile to do the right thing – in this case it would be:
|
Hi @lskrajny, I plan to work on #387 to introduce interfaces. While table inheritance is imo not the best way of representing shared fields between types in postgres, I do plan to cover it (or at least prepare for it). Aren't declarative partitions a very similar thing? |
I'd love partitions to become first class citizens. |
I am actually running into a similar issue with timescale Hypertables. This is chunking the table in multiple different partitions dynamically and this seems to awry with wal2json and live queries. Since the chance is reported for the chunk (child) instead of the hypertable itself. (parent) |
Hey @wesselvdv I'm also using timescale for my project and I'm thinking about migrating from prisma to graphile. Did you solve this issue, and have you ran into other problems with graphile+timescale? |
Yes, I did solve this issue for subscriptions, and I didn’t run into any issues with queries or mutations with timescale. You can query hypertables perfectly fine. |
Nice. When you said subscriptions did you mean live queries too? |
Yes, that's what I mean. :-) |
The issue is that where we filter on we're explicitly excluding partitioned tables ( We should explicitly include the We also need to reflect the indexes. |
There is some perspective to support partitions in postgraphile? Here locally I patched the introspectionQuery.js to include the partitioned table ( I would send a PR with this change. |
V5 supports partitions out of the box; here's a test for it: https://github.com/graphile/crystal/blob/main/postgraphile/postgraphile/__tests__/queries/v4/partitions.test.graphql |
I am raising one question addressing why Postraphile isn't exposing the parent table instead of the partition tables. |
ref the identical question #1991 |
Are there any work/plans to support declarative partitioning introduced in PostgreSQL 11?
Current behaviour is lets say i have got "fruit" table partitioned by type with separate partitions for each type ("apple", "banana", etc.)
Postgraphile generates schema for child tables and not for parent one :/
The text was updated successfully, but these errors were encountered: