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
feat: add way to distinguish base and partitioned tables in PgDatabaseMetaData.getTables #1708
feat: add way to distinguish base and partitioned tables in PgDatabaseMetaData.getTables #1708
Conversation
…eMetaData.getTables There is currently no way to distinguish between base tables and partitioned tables in the response from PgDatabadeMetaData.getTables. Fix this by adding PARTITIONED TABLE to the tableTypeClauses map and thus the TABLE_TYPE field in the query in getTables. Also update a test (testPartitionedTables) that was using TABLE_TYPE of TABLE to grab partitioned tables. This should close pgjdbc#1590. However, perhaps this could be considered a breaking change for anyone using getTables and expecting partitioned tables to show up for .getTables(s, s1, s2, new String[]{"TABLE"})?
We would also need to update
pgjdbc/pgjdbc/src/test/java/org/postgresql/test/jdbc2/ResultSetMetaDataTest.java Line 186 in d0453b7
|
I am saddened that I missed these, thank you for letting me know! I improved Unfortunately, I am unsure what there is to change about As far as If there's anything I'm misunderstanding and should fix up then please let me know! |
Codecov Report
@@ Coverage Diff @@
## master #1708 +/- ##
============================================
+ Coverage 69.26% 69.31% +0.04%
- Complexity 4189 4195 +6
============================================
Files 187 187
Lines 17262 17266 +4
Branches 2870 2870
============================================
+ Hits 11957 11968 +11
+ Misses 4017 4015 -2
+ Partials 1288 1283 -5 |
ah, I missed where you added it to tabletypes. Cool. Thx |
So the only question now is regarding the breaking change. I would agree this should be a breaking change. Anyone else? |
The driver upgrade mitigates some issues with using this connector with Postgres on Azure. It comes with some behavioural changes, though: * column metadata for DECIMAL without scale is returned differently by the (see pgjdbc/pgjdbc#1767): while it used to be returned as 0, it's now returned as null. This should be transparent to DBZ consumers * snapshots for partitioned tables only export change events on the partition topics now due to pgjdbc/pgjdbc#1708; this has an impact on consumers, but I think it's more reasonable than exporting all change events twice, one partition table and main table topics
The driver upgrade mitigates some issues with using this connector with Postgres on Azure. It comes with some behavioural changes, though: * column metadata for DECIMAL without scale is returned differently by the (see pgjdbc/pgjdbc#1767): while it used to be returned as 0, it's now returned as null. This should be transparent to DBZ consumers * snapshots for partitioned tables only export change events on the partition topics now due to pgjdbc/pgjdbc#1708; this has an impact on consumers, but I think it's more reasonable than exporting all change events twice, one partition table and main table topics
….12"; The driver upgrade mitigates some issues with using this connector with Postgres on Azure. It comes with some behavioural changes, though: * column metadata for DECIMAL without scale is returned differently by the (see pgjdbc/pgjdbc#1767): while it used to be returned as 0, it's now returned as null. This should be transparent to DBZ consumers * snapshots for partitioned tables only export change events on the partition topics now due to pgjdbc/pgjdbc#1708; this has an impact on consumers, but I think it's more reasonable than exporting all change events twice, one partition table and main table topics
….12"; The driver upgrade mitigates some issues with using this connector with Postgres on Azure. It comes with some behavioural changes, though: * column metadata for DECIMAL without scale is returned differently by the (see pgjdbc/pgjdbc#1767): while it used to be returned as 0, it's now returned as null. This should be transparent to DBZ consumers * snapshots for partitioned tables only export change events on the partition topics now due to pgjdbc/pgjdbc#1708; this has an impact on consumers, but I think it's more reasonable than exporting all change events twice, one partition table and main table topics
…gDatabaseMetaData.getTables (pgjdbc#1708)" This reverts commit 25eb32c
Add handling for detecting existence of partitioned tables explicitly. PostgreSQL JDBC Driver update from 42.2.10 to 42.2.25 in #113 caused partitioned tables to broke due upstream change of separating types of normal table and partitioned table as explained in pgjdbc/pgjdbc#1708
Add handling for detecting existence of partitioned tables explicitly. PostgreSQL JDBC Driver update from 42.2.10 to 42.2.25 in #113 caused partitioned tables to broke due upstream change of separating types of normal table and partitioned table as explained in pgjdbc/pgjdbc#1708
The driver upgrade mitigates some issues with using this connector with Postgres on Azure. It comes with some behavioural changes, though: * column metadata for DECIMAL without scale is returned differently by the (see pgjdbc/pgjdbc#1767): while it used to be returned as 0, it's now returned as null. This should be transparent to DBZ consumers * snapshots for partitioned tables only export change events on the partition topics now due to pgjdbc/pgjdbc#1708; this has an impact on consumers, but I think it's more reasonable than exporting all change events twice, one partition table and main table topics
PostgreSQL JDBC Driver introduced separating type for partitioned table from 40.2.12 pgjdbc/pgjdbc#1708
* Fix regression with partitioned tables in PostgreSQL PostgreSQL JDBC Driver introduced separating type for partitioned table from 40.2.12 pgjdbc/pgjdbc#1708 * Add subscreensItem.menuInclude to menu data (moqui#600) * Fixed the problem that moqui cannot be deployed as non-root webapp in Tomcat * Fixed a runtime error if Currency is BTC * Fixed a runtime error if Currency is BTC * Fixed the retries of Elastic Client * Add subscreensItem.menuInclude to menu data * Docker-Image-Pull Feature (moqui#553) * Improvement: In Moqui-Multi-Instance added a Async-Pull-Image-Feature which pulls the image by Using Docker-Engine-Api from multiple registry like AWS, Azure, Docker-Hub * Update AUTHORS * Added: added the generic way to process cmd , by adding an extra field(authTokenPass) inside the entity InstanceImage , now user has separate field for cmd and password so all types of registries is easily configurable * Update ServerEntities.xml by adding description * Library updates, including Jetty 10.0.13 to 10.015 which had reported vulnerabilities; there are lots of dependencies updated in this set, see diff for full details * In ScreenRenderImpl change addFormFieldValue() and related methods to handle first, second, and last rows, for qvt and other client rendered output that needs full data for a form in a map/object * In root build.gradle change gitStatusAll task to be more tolerant of repos with no master branch * Add text-area.@autogrow attribute, supported only in qvt for now * Update various libraries including Groovy to 3.0.19 (which has some minor non-backward compatible changes single 3.0.10 with odd boolean behavior in rare cases, adjusted for in the framework long ago but should be watched for in custom code), Jetty to 10.0.16, H2 database, SLF4J, SnakeYAML, Apache Commons Lang3 * In build.gradle gitStatusAll task also handle upstream remotes with no master branch * Currency (moqui#614) * Use moqui.basic.Uom entity to determine currency formatting and rounding details * Add currency-hide-symbol attribute as a complement to currency-unit-field, displaying the value without the currency symbol * Update authors file * Add and Handle Hmac Sha256 with timestamp * A couple of minor bug fixes in the EntityAutoServiceRunner and ContextJavaUtil (moqui#618) * In EntityAutoServiceRunner, remove unwanted break statement to ensure support for multiple PK fields with wildcard (*). * In ContextJavaUtil, add missing future keyword. * Updated authors file. * Allow for 10 second threshold in nowTimestamp * In L10nFacadeImpl.formatCurrency() use disableAuthz() for entity find on Uom; small change to currency formatting test to pass with current OOTB settings * In addons.xml, added new moqui-sso component. --------- Co-authored-by: Yao Chunlin <chunlinyao@gmail.com> Co-authored-by: David E. Jones <dej@dejc.com> Co-authored-by: Wei Zhang <zhangw@shinetechsoftware.com> Co-authored-by: Rohit pawar <72196393+rohitpawar2811@users.noreply.github.com> Co-authored-by: Jens Hardings <jhp@moit.cl> Co-authored-by: acetousk <acetousk@users.noreply.github.com> Co-authored-by: Ayman Abi Abdallah <aabiabdallah@gmail.com>
* Fix regression with partitioned tables in PostgreSQL PostgreSQL JDBC Driver introduced separating type for partitioned table from 40.2.12 pgjdbc/pgjdbc#1708 * Add subscreensItem.menuInclude to menu data (moqui#600) * Fixed the problem that moqui cannot be deployed as non-root webapp in Tomcat * Fixed a runtime error if Currency is BTC * Fixed a runtime error if Currency is BTC * Fixed the retries of Elastic Client * Add subscreensItem.menuInclude to menu data * Docker-Image-Pull Feature (moqui#553) * Improvement: In Moqui-Multi-Instance added a Async-Pull-Image-Feature which pulls the image by Using Docker-Engine-Api from multiple registry like AWS, Azure, Docker-Hub * Update AUTHORS * Added: added the generic way to process cmd , by adding an extra field(authTokenPass) inside the entity InstanceImage , now user has separate field for cmd and password so all types of registries is easily configurable * Update ServerEntities.xml by adding description * Library updates, including Jetty 10.0.13 to 10.015 which had reported vulnerabilities; there are lots of dependencies updated in this set, see diff for full details * In ScreenRenderImpl change addFormFieldValue() and related methods to handle first, second, and last rows, for qvt and other client rendered output that needs full data for a form in a map/object * In root build.gradle change gitStatusAll task to be more tolerant of repos with no master branch * Add text-area.@autogrow attribute, supported only in qvt for now * Update various libraries including Groovy to 3.0.19 (which has some minor non-backward compatible changes single 3.0.10 with odd boolean behavior in rare cases, adjusted for in the framework long ago but should be watched for in custom code), Jetty to 10.0.16, H2 database, SLF4J, SnakeYAML, Apache Commons Lang3 * In build.gradle gitStatusAll task also handle upstream remotes with no master branch * Currency (moqui#614) * Use moqui.basic.Uom entity to determine currency formatting and rounding details * Add currency-hide-symbol attribute as a complement to currency-unit-field, displaying the value without the currency symbol * Update authors file * Add and Handle Hmac Sha256 with timestamp * A couple of minor bug fixes in the EntityAutoServiceRunner and ContextJavaUtil (moqui#618) * In EntityAutoServiceRunner, remove unwanted break statement to ensure support for multiple PK fields with wildcard (*). * In ContextJavaUtil, add missing future keyword. * Updated authors file. * Allow for 10 second threshold in nowTimestamp * In L10nFacadeImpl.formatCurrency() use disableAuthz() for entity find on Uom; small change to currency formatting test to pass with current OOTB settings * In addons.xml, added new moqui-sso component. * Add AutoCloseable extension to EntityListIterator for use with try with resources, thanks to Deepak Dixit for the suggestion * BugFix EntityListIterator not closed in NotificationMessageImpl#getNotifyUserIds --------- Co-authored-by: Yao Chunlin <chunlinyao@gmail.com> Co-authored-by: David E. Jones <dej@dejc.com> Co-authored-by: Wei Zhang <zhangw@shinetechsoftware.com> Co-authored-by: Rohit pawar <72196393+rohitpawar2811@users.noreply.github.com> Co-authored-by: Jens Hardings <jhp@moit.cl> Co-authored-by: acetousk <acetousk@users.noreply.github.com> Co-authored-by: Ayman Abi Abdallah <aabiabdallah@gmail.com>
* Fix regression with partitioned tables in PostgreSQL PostgreSQL JDBC Driver introduced separating type for partitioned table from 40.2.12 pgjdbc/pgjdbc#1708 * Add subscreensItem.menuInclude to menu data (moqui#600) * Fixed the problem that moqui cannot be deployed as non-root webapp in Tomcat * Fixed a runtime error if Currency is BTC * Fixed a runtime error if Currency is BTC * Fixed the retries of Elastic Client * Add subscreensItem.menuInclude to menu data * Docker-Image-Pull Feature (moqui#553) * Improvement: In Moqui-Multi-Instance added a Async-Pull-Image-Feature which pulls the image by Using Docker-Engine-Api from multiple registry like AWS, Azure, Docker-Hub * Update AUTHORS * Added: added the generic way to process cmd , by adding an extra field(authTokenPass) inside the entity InstanceImage , now user has separate field for cmd and password so all types of registries is easily configurable * Update ServerEntities.xml by adding description * Library updates, including Jetty 10.0.13 to 10.015 which had reported vulnerabilities; there are lots of dependencies updated in this set, see diff for full details * In ScreenRenderImpl change addFormFieldValue() and related methods to handle first, second, and last rows, for qvt and other client rendered output that needs full data for a form in a map/object * In root build.gradle change gitStatusAll task to be more tolerant of repos with no master branch * Add text-area.@autogrow attribute, supported only in qvt for now * Update various libraries including Groovy to 3.0.19 (which has some minor non-backward compatible changes single 3.0.10 with odd boolean behavior in rare cases, adjusted for in the framework long ago but should be watched for in custom code), Jetty to 10.0.16, H2 database, SLF4J, SnakeYAML, Apache Commons Lang3 * In build.gradle gitStatusAll task also handle upstream remotes with no master branch * Currency (moqui#614) * Use moqui.basic.Uom entity to determine currency formatting and rounding details * Add currency-hide-symbol attribute as a complement to currency-unit-field, displaying the value without the currency symbol * Update authors file * Add and Handle Hmac Sha256 with timestamp * A couple of minor bug fixes in the EntityAutoServiceRunner and ContextJavaUtil (moqui#618) * In EntityAutoServiceRunner, remove unwanted break statement to ensure support for multiple PK fields with wildcard (*). * In ContextJavaUtil, add missing future keyword. * Updated authors file. * Allow for 10 second threshold in nowTimestamp * In L10nFacadeImpl.formatCurrency() use disableAuthz() for entity find on Uom; small change to currency formatting test to pass with current OOTB settings * In addons.xml, added new moqui-sso component. * Add AutoCloseable extension to EntityListIterator for use with try with resources, thanks to Deepak Dixit for the suggestion * BugFix EntityListIterator not closed in NotificationMessageImpl#getNotifyUserIds * Implemented withCloseable/try-with-resources where needed in the code… (moqui#625) * Implemented withCloseable/try-with-resources where needed in the code to ensure proper closure of the entity list iterator resource * Fixed withCloseable syntax --------- Co-authored-by: David E. Jones <dej@dejc.com> * Change EntityDataWriterImpl to use groovy CompileStatic, without this a compile error was missed in the changes for PR moqui#625, fix small issues from this --------- Co-authored-by: Yao Chunlin <chunlinyao@gmail.com> Co-authored-by: David E. Jones <dej@dejc.com> Co-authored-by: Wei Zhang <zhangw@shinetechsoftware.com> Co-authored-by: Rohit pawar <72196393+rohitpawar2811@users.noreply.github.com> Co-authored-by: Jens Hardings <jhp@moit.cl> Co-authored-by: acetousk <acetousk@users.noreply.github.com> Co-authored-by: Ayman Abi Abdallah <aabiabdallah@gmail.com>
* Fix regression with partitioned tables in PostgreSQL PostgreSQL JDBC Driver introduced separating type for partitioned table from 40.2.12 pgjdbc/pgjdbc#1708 * Add subscreensItem.menuInclude to menu data (moqui#600) * Fixed the problem that moqui cannot be deployed as non-root webapp in Tomcat * Fixed a runtime error if Currency is BTC * Fixed a runtime error if Currency is BTC * Fixed the retries of Elastic Client * Add subscreensItem.menuInclude to menu data * Docker-Image-Pull Feature (moqui#553) * Improvement: In Moqui-Multi-Instance added a Async-Pull-Image-Feature which pulls the image by Using Docker-Engine-Api from multiple registry like AWS, Azure, Docker-Hub * Update AUTHORS * Added: added the generic way to process cmd , by adding an extra field(authTokenPass) inside the entity InstanceImage , now user has separate field for cmd and password so all types of registries is easily configurable * Update ServerEntities.xml by adding description * Library updates, including Jetty 10.0.13 to 10.015 which had reported vulnerabilities; there are lots of dependencies updated in this set, see diff for full details * In ScreenRenderImpl change addFormFieldValue() and related methods to handle first, second, and last rows, for qvt and other client rendered output that needs full data for a form in a map/object * In root build.gradle change gitStatusAll task to be more tolerant of repos with no master branch * Add text-area.@autogrow attribute, supported only in qvt for now * Update various libraries including Groovy to 3.0.19 (which has some minor non-backward compatible changes single 3.0.10 with odd boolean behavior in rare cases, adjusted for in the framework long ago but should be watched for in custom code), Jetty to 10.0.16, H2 database, SLF4J, SnakeYAML, Apache Commons Lang3 * In build.gradle gitStatusAll task also handle upstream remotes with no master branch * Currency (moqui#614) * Use moqui.basic.Uom entity to determine currency formatting and rounding details * Add currency-hide-symbol attribute as a complement to currency-unit-field, displaying the value without the currency symbol * Update authors file * Add and Handle Hmac Sha256 with timestamp * A couple of minor bug fixes in the EntityAutoServiceRunner and ContextJavaUtil (moqui#618) * In EntityAutoServiceRunner, remove unwanted break statement to ensure support for multiple PK fields with wildcard (*). * In ContextJavaUtil, add missing future keyword. * Updated authors file. * Allow for 10 second threshold in nowTimestamp * In L10nFacadeImpl.formatCurrency() use disableAuthz() for entity find on Uom; small change to currency formatting test to pass with current OOTB settings * In addons.xml, added new moqui-sso component. * Add AutoCloseable extension to EntityListIterator for use with try with resources, thanks to Deepak Dixit for the suggestion * BugFix EntityListIterator not closed in NotificationMessageImpl#getNotifyUserIds * Implemented withCloseable/try-with-resources where needed in the code… (moqui#625) * Implemented withCloseable/try-with-resources where needed in the code to ensure proper closure of the entity list iterator resource * Fixed withCloseable syntax --------- * Change EntityDataWriterImpl to use groovy CompileStatic, without this a compile error was missed in the changes for PR moqui#625, fix small issues from this --------- Co-authored-by: Yao Chunlin <chunlinyao@gmail.com> Co-authored-by: David E. Jones <dej@dejc.com> Co-authored-by: Wei Zhang <zhangw@shinetechsoftware.com> Co-authored-by: Rohit pawar <72196393+rohitpawar2811@users.noreply.github.com> Co-authored-by: Jens Hardings <jhp@moit.cl> Co-authored-by: acetousk <acetousk@users.noreply.github.com> Co-authored-by: Ayman Abi Abdallah <aabiabdallah@gmail.com>
* Master (#11) (#12) * Fix regression with partitioned tables in PostgreSQL PostgreSQL JDBC Driver introduced separating type for partitioned table from 40.2.12 pgjdbc/pgjdbc#1708 * Add subscreensItem.menuInclude to menu data (moqui#600) * Fixed the problem that moqui cannot be deployed as non-root webapp in Tomcat * Fixed a runtime error if Currency is BTC * Fixed a runtime error if Currency is BTC * Fixed the retries of Elastic Client * Add subscreensItem.menuInclude to menu data * Docker-Image-Pull Feature (moqui#553) * Improvement: In Moqui-Multi-Instance added a Async-Pull-Image-Feature which pulls the image by Using Docker-Engine-Api from multiple registry like AWS, Azure, Docker-Hub * Update AUTHORS * Added: added the generic way to process cmd , by adding an extra field(authTokenPass) inside the entity InstanceImage , now user has separate field for cmd and password so all types of registries is easily configurable * Update ServerEntities.xml by adding description * Library updates, including Jetty 10.0.13 to 10.015 which had reported vulnerabilities; there are lots of dependencies updated in this set, see diff for full details * In ScreenRenderImpl change addFormFieldValue() and related methods to handle first, second, and last rows, for qvt and other client rendered output that needs full data for a form in a map/object * In root build.gradle change gitStatusAll task to be more tolerant of repos with no master branch * Add text-area.@autogrow attribute, supported only in qvt for now * Update various libraries including Groovy to 3.0.19 (which has some minor non-backward compatible changes single 3.0.10 with odd boolean behavior in rare cases, adjusted for in the framework long ago but should be watched for in custom code), Jetty to 10.0.16, H2 database, SLF4J, SnakeYAML, Apache Commons Lang3 * In build.gradle gitStatusAll task also handle upstream remotes with no master branch * Currency (moqui#614) * Use moqui.basic.Uom entity to determine currency formatting and rounding details * Add currency-hide-symbol attribute as a complement to currency-unit-field, displaying the value without the currency symbol * Update authors file * Add and Handle Hmac Sha256 with timestamp * A couple of minor bug fixes in the EntityAutoServiceRunner and ContextJavaUtil (moqui#618) * In EntityAutoServiceRunner, remove unwanted break statement to ensure support for multiple PK fields with wildcard (*). * In ContextJavaUtil, add missing future keyword. * Updated authors file. * Allow for 10 second threshold in nowTimestamp * In L10nFacadeImpl.formatCurrency() use disableAuthz() for entity find on Uom; small change to currency formatting test to pass with current OOTB settings * In addons.xml, added new moqui-sso component. * Add AutoCloseable extension to EntityListIterator for use with try with resources, thanks to Deepak Dixit for the suggestion * BugFix EntityListIterator not closed in NotificationMessageImpl#getNotifyUserIds * Implemented withCloseable/try-with-resources where needed in the code… (moqui#625) * Implemented withCloseable/try-with-resources where needed in the code to ensure proper closure of the entity list iterator resource * Fixed withCloseable syntax --------- * Change EntityDataWriterImpl to use groovy CompileStatic, without this a compile error was missed in the changes for PR moqui#625, fix small issues from this --------- Co-authored-by: Yao Chunlin <chunlinyao@gmail.com> Co-authored-by: David E. Jones <dej@dejc.com> Co-authored-by: Wei Zhang <zhangw@shinetechsoftware.com> Co-authored-by: Rohit pawar <72196393+rohitpawar2811@users.noreply.github.com> Co-authored-by: Jens Hardings <jhp@moit.cl> Co-authored-by: acetousk <acetousk@users.noreply.github.com> Co-authored-by: Ayman Abi Abdallah <aabiabdallah@gmail.com> * Add sentDate field to WikiBlogCategory entity --------- Co-authored-by: Yao Chunlin <chunlinyao@gmail.com> Co-authored-by: David E. Jones <dej@dejc.com> Co-authored-by: Wei Zhang <zhangw@shinetechsoftware.com> Co-authored-by: Rohit pawar <72196393+rohitpawar2811@users.noreply.github.com> Co-authored-by: Jens Hardings <jhp@moit.cl> Co-authored-by: acetousk <acetousk@users.noreply.github.com> Co-authored-by: Ayman Abi Abdallah <aabiabdallah@gmail.com>
There is currently no way to distinguish between base tables and
partitioned tables in the response from
PgDatabadeMetaData.getTables
.Fix this by adding
PARTITIONED TABLE
to thetableTypeClauses
map andthus the
TABLE_TYPE
field in the query ingetTables
. Also update a test(
testPartitionedTables
) that was usingTABLE_TYPE
ofTABLE
to grabpartitioned tables.
This should close #1590. However, perhaps this could be considered a
breaking change for anyone using
getTables
and expecting partitionedtables to show up for
.getTables(s, s1, s2, new String[]{"TABLE"})
?All Submissions:
New Feature Submissions:
Changes to Existing Features:
As above: