citusdata / citus

Distributed PostgreSQL as an extension
https://www.citusdata.com
GNU Affero General Public License v3.0
10.65k stars 670 forks source link

PG17 compatibility: Adjust print_extension_changes function for extra type outputs in PG17 #7761

Closed naisila closed 3 days ago

naisila commented 3 days ago

In PG17, Auto-generated array types, multirange types, and relation rowtypes are treated as dependent objects, hence changing the output of the print_extension_changes function.

Relevant PG commit: e5bc9454e527b1cba97553531d8d4992892fdeef https://github.com/postgres/postgres/commit/e5bc9454e527b1cba97553531d8d4992892fdeef

Here we create a table with only the basic extension types in order to avoid printing extra ones for now. This can be removed when we drop PG16 support.

https://github.com/citusdata/citus/actions/runs/11960253650/attempts/1#summary-33343972656

                  | table pg_dist_local_group 
                  | table pg_dist_node 
                  | table pg_dist_node_metadata 
                  | table pg_dist_partition 
                  | table pg_dist_placement 
                  | table pg_dist_poolinfo 
                  | table pg_dist_rebalance_strategy 
                  | table pg_dist_shard 
                  | table pg_dist_transaction 
                  | type citus.distribution_type 
+                 | type citus.distribution_type[] 
+                 | type citus.pg_dist_object 
+                 | type citus.pg_dist_object[] 
                  | type citus.shard_transfer_mode 
+                 | type citus.shard_transfer_mode[] 
                  | type citus_copy_format 
+                 | type citus_copy_format[] 
+                 | type citus_dist_stat_activity 
+                 | type citus_dist_stat_activity[] 
+                 | type citus_lock_waits 
+                 | type citus_lock_waits[] 
+                 | type citus_shard_indexes_on_worker 
+                 | type citus_shard_indexes_on_worker[] 
+                 | type citus_shards_on_worker 
+                 | type citus_shards_on_worker[] 
+                 | type citus_stat_statements 
+                 | type citus_stat_statements[] 
+                 | type citus_worker_stat_activity 
+                 | type citus_worker_stat_activity[] 
                  | type noderole 
+                 | type noderole[] 
+                 | type pg_dist_authinfo 
+                 | type pg_dist_authinfo[] 
+                 | type pg_dist_colocation 
+                 | type pg_dist_colocation[] 
+                 | type pg_dist_local_group 
+                 | type pg_dist_local_group[] 
+                 | type pg_dist_node 
+                 | type pg_dist_node[] 
+                 | type pg_dist_node_metadata 
+                 | type pg_dist_node_metadata[] 
+                 | type pg_dist_partition 
+                 | type pg_dist_partition[] 
+                 | type pg_dist_placement 
+                 | type pg_dist_placement[] 
+                 | type pg_dist_poolinfo 
+                 | type pg_dist_poolinfo[] 
+                 | type pg_dist_rebalance_strategy 
+                 | type pg_dist_rebalance_strategy[] 
+                 | type pg_dist_shard 
+                 | type pg_dist_shard[] 
+                 | type pg_dist_shard_placement 
+                 | type pg_dist_shard_placement[] 
+                 | type pg_dist_transaction 
+                 | type pg_dist_transaction[] 
                  | view citus_dist_stat_activity 
                  | view citus_lock_waits 
                  | view citus_shard_indexes_on_worker 
                  | view citus_shards_on_worker 
                  | view citus_stat_statements 
                  | view citus_worker_stat_activity 
                  | view pg_dist_shard_placement 
-(186 rows)
+(228 rows)
codecov[bot] commented 3 days ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Please upload report for BASE (release-13.0@65dcc59). Learn more about missing BASE report.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## release-13.0 #7761 +/- ## =============================================== Coverage ? 89.64% =============================================== Files ? 274 Lines ? 59582 Branches ? 7436 =============================================== Hits ? 53413 Misses ? 4035 Partials ? 2134 ```

🚨 Try these New Features: