Closed chpicone closed 3 years ago
We need to perform an investigation for implementing this since apparently this is needed to simulate subtypes as they exist in the ESRI world. @chpicone can you explain further?
@aaime I just need an estimate and an implementation plan.
Subtypes? Hum... GeoTools would understand a partitioned table as a normal table and deliver just a single type out of it. If we are dealing with inheritance, then it seems to me we are talking about app-schema, and the rest of the response does not make sense.
I've seen usage of partitioned tables in a different context, as a way to speed up queries, if the filter manages to exclude entire partitions and possibly match only one or a handful. If that's the case, and PostgreSQL does not need any special way to query the partitioned table, then it's a matter of:
getDesiredTablesType
, and make it include in the result list PARTITIONED TABLE
as well.PostGISCitextOnlineTest
as a template).Estimate wise, I'd guess between half a day and a day, depending on what experience the developers in charge has with the JDBCTestSupport
/JDBCTestSetup
testing framework.
@aaime can you liaise with @chpicone to make sure the scenario is clear as this is going to be part of next webinar I guess.
Chatted with @chpicone, the subtypes have the same structure as the parent table, but different check constraints to maintain integrity, something that would pop up only when using WFS-T (and even in that case, would not prevent it, it's just checks for valid values on insert). So the estimate I've made above is all we need.
@aaime thake into account that we would need to backport this to 2.17.x for this project as we are using GeoNode.
Do you think it would be acceptable?
Yes, the actual code change is a line, it's just the test will take some effort.
Being a fix, we would need this to go as back as possible, until 2.17 I'd say. This will have to be tested on GeoNode's GeoServer.
When yout get here, let me know.
Changes merged on master and backported on 24.x and 23.x. Will be available starting with the January releases, onwards.
@aaime is it possible to isolate the JARs involved in this fix?
@chpicone this is for you...
Yes, only gt-jdbc-postgis-<version>.jar
has been affected. It can be picked from a GeoServer nightly build (starting tomorrow, but I can force the nightlies to run sooner if needs be).
@aaime is this fix part of 2.17.4? I think so, right?
No, the backport missed the release by a couple of days. As per my previous comment: "Changes merged on master and backported on 24.x and 23.x. Will be available starting with the January releases, onwards."
ouch, @chpicone did you read this message from @aaime ?
This means we have discuss a little on how to upgrade Krihs GeoNode (separately from this issue).
Can we update just the gt-jdbc-postgis-
I believe so, yes, it's the only one that has been changed, and I see no other changes after the partitioned table fix in gt-jdbc-postgis (nor in gt-jdbc). So it should work. We can only make sure testing it out.
If we have a (parent) partitioned table in postGIS (example TAB_A) we can see just the child tables (eg TAB_A_1, TAB_A_2, etc).
Tested on GeoServer 2.18.0.
Here the JIRA ticket