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
Copy recreated object permissions on update #3109
Copy recreated object permissions on update #3109
Conversation
Codecov Report
@@ Coverage Diff @@
## master #3109 +/- ##
==========================================
+ Coverage 90.22% 90.35% +0.12%
==========================================
Files 215 215
Lines 35360 35310 -50
==========================================
- Hits 31904 31903 -1
+ Misses 3456 3407 -49
Continue to review full report at Codecov.
|
74f7fc5
to
01e9a1e
Compare
sql/updates/1.7.5--2.0.0-rc1.sql
Outdated
@@ -264,6 +258,16 @@ DROP VIEW IF EXISTS timescaledb_information.continuous_aggregates; | |||
DROP VIEW IF EXISTS timescaledb_information.continuous_aggregate_stats; | |||
ALTER TABLE IF EXISTS _timescaledb_catalog.continuous_agg DROP COLUMN IF EXISTS job_id; | |||
|
|||
-- Save ACL for tables that are being rebuilt | |||
CREATE TABLE saved_acl(tmpoid oid, tmpns oid, tmpacl aclitem[]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could this be a temporary table?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Using a temporary table here does not offer any advantage. They are dropped at the end of the session, not at the end of the update, so they need to be explicitly removed anyway.
9f25430
to
fb93bbf
Compare
c02c471
to
cd5420c
Compare
cd5420c
to
612c187
Compare
|
||
-- For objects that are newly created, we need to set the initprivs to | ||
-- the initprivs for the "chunk" catalog table since that is created | ||
-- in the first version of TimescaleDB and should have the correct |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you rewrite the comment a bit so that it is clear 1) we choose chunk table (but it could be any other catalog table
2) The comment about first version can be misinterpreted as version 1.0, and I did. Instead reword it as, -- the first time Timescaledb extension was installed --
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated the comment
sql/updates/post-update.sql
Outdated
-- We can now update the initprivs for the objects using the saved | ||
-- privileges. | ||
-- | ||
-- For objects that existed before, We need to restore initprivs to |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This comment is a bit confusing. Shouldn't initprivs for all the catalog objects be the same as that when the extension was first created? i believe that's what the sql does.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tried to clarify the comment.
sql/updates/post-update.sql
Outdated
LEFT JOIN saved_privs ON tmpnsp = nspname AND tmpname = relname | ||
WHERE nspname IN ('_timescaledb_catalog', '_timescaledb_config') | ||
OR nspname = '_timescaledb_internal' | ||
AND relname IN ('hypertable_chunk_local_size', 'compressed_chunk_stats') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hypertable_chunk_local_size and chunk_stats are views. We should either do this for all the internal views or none.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes. These were the ones that showed up in the update tests, but I've added two more tables. However, I don't see any other views.
Ideally, we should place all these objects in some other catalog and leave _timescaledb_internal
for only objects that are created as a result of creating other TimescaleDB objects.
sql/updates/pre-update.sql
Outdated
JOIN pg_init_privs ip ON ip.objoid = cl.oid | ||
WHERE nspname IN ('_timescaledb_catalog', '_timescaledb_config') | ||
OR nspname = '_timescaledb_internal' | ||
AND relname IN ('hypertable_chunk_local_size', 'compressed_chunk_stats'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we do this for _timescaledb_internal, it should cover all the objects that we create in that schema during extension installation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since we would have to list the objects from _timescaledb_internal here, it would be worth adding a comment in the README that pre/post and need to be updated for any new catalog objects.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need to have a better solution for how to handle and differentiate between objects that are internal to timescaledb objects and objects that we use as part of the implementation. A separate schema would be the easiest solution, but I am reluctant to add this change to this PR and intend to take it separately. For now, I just handle the internal views and tables.
\z _timescaledb_catalog.* | ||
\z _timescaledb_config.* | ||
\z _timescaledb_internal.* | ||
SELECT nspname AS Schema, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should check initprivs as well? Or is that being done some other place?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good point. No, this is probably the best place. Added a check.
612c187
to
cd0122f
Compare
7ab457d
to
f753018
Compare
f0fdce3
to
57291e6
Compare
Tables, indexes, and sequences that are recreated as part of an update does not propagate permissions to the recreated object. This commit fixes that by saving away the permissions in `pg_class` temporarily and then copying them back into the `pg_class` table. If internal objects are created or re-created, they get the wrong initial privileges, which result in privileges not being dumped when using `pg_dump`. Save away the privileges before starting the update and restore them afterwards to make sure that the privileges are maintained over the update. For new objects, we use the initial privileges of the `chunk` metadata table, which should always have correct initial privileges. Fixes timescale#3078
57291e6
to
56fe04f
Compare
This maintenance release contains bugfixes since the 2.1.0 release. We deem it high priority for upgrading. This release adds support for Skip Scan on multinode by enabling the pushdown of `DISTINCT` to data nodes and also fixes a number of bugs in the implementation of Skip Scan. **Features** * timescale#3113 Pushdown "SELECT DISTINCT" in multi-node to allow use of Skip Scan **Bugfixes** * timescale#3101 Use commit date in `get_git_commit()` * timescale#3104 Fix use after free in `add_reorder_policy` * timescale#3106 Fix use after free in `chunk_api_get_chunk_stats` * timescale#3123 Fix crash while using `REINDEX TABLE CONCURRENTLY` * timescale#3135 Fix SkipScan path generation in `DISTINCT` queries with expressions * timescale#3146 Fix SkipScan for IndexPaths without pathkeys * timescale#3151 Fix `fdw_relinfo_get` assertion failure on DELETE * timescale#3155 Inherit CFLAGS from PostgreSQL * timescale#3109 Copy recreated object permissions on update * timescale#3148 Make `SELECT DISTINCT` handle non-var targetlists * timescale#3147 Skip ChunkAppend if AppendPath has no children * timescale#3102 Fix REINDEX TABLE for distributed hypertables * timescale#3118 Fix use after free in cache * timescale#3112 Use `%u` to format Oid instead of `%d` * timescale#3111 Fix `CMAKE_BUILD_TYPE` check **Thanks** * @Dead2, @dv8472 and @einsibjarni for reporting an issue with multinode queries and views * @hperez75 for reporting an issue with Skip Scan
This maintenance release contains bugfixes since the 2.1.0 release. We deem it high priority for upgrading. This release adds support for Skip Scan on multinode by enabling the pushdown of `DISTINCT` to data nodes and also fixes a number of bugs in the implementation of Skip Scan. **Features** * timescale#3113 Pushdown "SELECT DISTINCT" in multi-node to allow use of Skip Scan **Bugfixes** * timescale#3101 Use commit date in `get_git_commit()` * timescale#3104 Fix use after free in `add_reorder_policy` * timescale#3106 Fix use after free in `chunk_api_get_chunk_stats` * timescale#3123 Fix crash while using `REINDEX TABLE CONCURRENTLY` * timescale#3135 Fix SkipScan path generation in `DISTINCT` queries with expressions * timescale#3146 Fix SkipScan for IndexPaths without pathkeys * timescale#3151 Fix `fdw_relinfo_get` assertion failure on DELETE * timescale#3155 Inherit CFLAGS from PostgreSQL * timescale#3109 Copy recreated object permissions on update * timescale#3148 Make `SELECT DISTINCT` handle non-var targetlists * timescale#3147 Skip ChunkAppend if AppendPath has no children * timescale#3102 Fix REINDEX TABLE for distributed hypertables * timescale#3118 Fix use after free in cache * timescale#3112 Use `%u` to format Oid instead of `%d` * timescale#3111 Fix `CMAKE_BUILD_TYPE` check **Thanks** * @Dead2, @dv8472 and @einsibjarni for reporting an issue with multinode queries and views * @hperez75 for reporting an issue with Skip Scan
This maintenance release contains bugfixes since the 2.1.0 release. We deem it high priority for upgrading. This release adds support for Skip Scan on multinode by enabling the pushdown of `DISTINCT` to data nodes and also fixes a number of bugs in the implementation of Skip Scan. **Features** * timescale#3113 Pushdown "SELECT DISTINCT" in multi-node to allow use of Skip Scan **Bugfixes** * timescale#3101 Use commit date in `get_git_commit()` * timescale#3104 Fix use after free in `add_reorder_policy` * timescale#3106 Fix use after free in `chunk_api_get_chunk_stats` * timescale#3123 Fix crash while using `REINDEX TABLE CONCURRENTLY` * timescale#3135 Fix SkipScan path generation in `DISTINCT` queries with expressions * timescale#3146 Fix SkipScan for IndexPaths without pathkeys * timescale#3151 Fix `fdw_relinfo_get` assertion failure on DELETE * timescale#3155 Inherit CFLAGS from PostgreSQL * timescale#3109 Copy recreated object permissions on update * timescale#3148 Make `SELECT DISTINCT` handle non-var targetlists * timescale#3147 Skip ChunkAppend if AppendPath has no children * timescale#3102 Fix REINDEX TABLE for distributed hypertables * timescale#3118 Fix use after free in cache * timescale#3112 Use `%u` to format Oid instead of `%d` * timescale#3111 Fix `CMAKE_BUILD_TYPE` check **Thanks** * @Dead2, @dv8472 and @einsibjarni for reporting an issue with multinode queries and views * @hperez75 for reporting an issue with Skip Scan
This maintenance release contains bugfixes since the 2.1.0 release. We deem it high priority for upgrading. This release adds support for Skip Scan on multinode by enabling the pushdown of `DISTINCT` to data nodes and also fixes a number of bugs in the implementation of Skip Scan. **Features** * timescale#3113 Pushdown "SELECT DISTINCT" in multi-node to allow use of Skip Scan **Bugfixes** * timescale#3101 Use commit date in `get_git_commit()` * timescale#3104 Fix use after free in `add_reorder_policy` * timescale#3106 Fix use after free in `chunk_api_get_chunk_stats` * timescale#3123 Fix crash while using `REINDEX TABLE CONCURRENTLY` * timescale#3135 Fix SkipScan path generation in `DISTINCT` queries with expressions * timescale#3146 Fix SkipScan for IndexPaths without pathkeys * timescale#3151 Fix `fdw_relinfo_get` assertion failure on DELETE * timescale#3155 Inherit CFLAGS from PostgreSQL * timescale#3109 Copy recreated object permissions on update * timescale#3148 Make `SELECT DISTINCT` handle non-var targetlists * timescale#3147 Skip ChunkAppend if AppendPath has no children * timescale#3102 Fix REINDEX TABLE for distributed hypertables * timescale#3118 Fix use after free in cache * timescale#3112 Use `%u` to format Oid instead of `%d` * timescale#3111 Fix `CMAKE_BUILD_TYPE` check **Thanks** * @Dead2, @dv8472 and @einsibjarni for reporting an issue with multinode queries and views * @hperez75 for reporting an issue with Skip Scan
This maintenance release contains bugfixes since the 2.1.0 release. We deem it high priority for upgrading. This release adds support for Skip Scan on multinode by enabling the pushdown of `DISTINCT` to data nodes and also fixes a number of bugs in the implementation of Skip Scan. **Features** * timescale#3113 Pushdown "SELECT DISTINCT" in multi-node to allow use of Skip Scan **Bugfixes** * timescale#3101 Use commit date in `get_git_commit()` * timescale#3104 Fix use after free in `add_reorder_policy` * timescale#3106 Fix use after free in `chunk_api_get_chunk_stats` * timescale#3123 Fix crash while using `REINDEX TABLE CONCURRENTLY` * timescale#3135 Fix SkipScan path generation in `DISTINCT` queries with expressions * timescale#3146 Fix SkipScan for IndexPaths without pathkeys * timescale#3151 Fix `fdw_relinfo_get` assertion failure on DELETE * timescale#3155 Inherit CFLAGS from PostgreSQL * timescale#3109 Copy recreated object permissions on update * timescale#3148 Make `SELECT DISTINCT` handle non-var targetlists * timescale#3147 Skip ChunkAppend if AppendPath has no children * timescale#3102 Fix REINDEX TABLE for distributed hypertables * timescale#3118 Fix use after free in cache * timescale#3112 Use `%u` to format Oid instead of `%d` * timescale#3111 Fix `CMAKE_BUILD_TYPE` check **Thanks** * @Dead2, @dv8472 and @einsibjarni for reporting an issue with multinode queries and views * @hperez75 for reporting an issue with Skip Scan
This maintenance release contains bugfixes since the 2.1.0 release. We deem it high priority for upgrading. This release extends Skip Scan to multinode by enabling the pushdown of `DISTINCT` to data nodes. It also fixes a number of bugs in the implementation of Skip Scan. **Features** * timescale#3113 Pushdown "SELECT DISTINCT" in multi-node to allow use of Skip Scan **Bugfixes** * timescale#3101 Use commit date in `get_git_commit()` * timescale#3102 Fix `REINDEX TABLE` for distributed hypertables * timescale#3104 Fix use after free in `add_reorder_policy` * timescale#3106 Fix use after free in `chunk_api_get_chunk_stats` * timescale#3109 Copy recreated object permissions on update * timescale#3111 Fix `CMAKE_BUILD_TYPE` check * timescale#3112 Use `%u` to format Oid instead of `%d` * timescale#3118 Fix use after free in cache * timescale#3123 Fix crash while using `REINDEX TABLE CONCURRENTLY` * timescale#3135 Fix SkipScan path generation in `DISTINCT` queries with expressions * timescale#3146 Fix SkipScan for IndexPaths without pathkeys * timescale#3147 Skip ChunkAppend if AppendPath has no children * timescale#3148 Make `SELECT DISTINCT` handle non-var targetlists * timescale#3151 Fix `fdw_relinfo_get` assertion failure on `DELETE` * timescale#3155 Inherit `CFLAGS` from PostgreSQL * timescale#3169 Fix incorrect type cast in compression policy **Thanks** * @Dead2, @dv8472 and @einsibjarni for reporting an issue with multinode queries and views * @hperez75 for reporting an issue with Skip Scan * @nathanloisel for reporting an issue with compression on hypertables with integer-based timestamps * @xin-hedera for fixing an issue with compression on hypertables with integer-based timestamps
This maintenance release contains bugfixes since the 2.1.0 release. We deem it high priority for upgrading. This release extends Skip Scan to multinode by enabling the pushdown of `DISTINCT` to data nodes. It also fixes a number of bugs in the implementation of Skip Scan. **Features** * timescale#3113 Pushdown "SELECT DISTINCT" in multi-node to allow use of Skip Scan **Bugfixes** * timescale#3101 Use commit date in `get_git_commit()` * timescale#3102 Fix `REINDEX TABLE` for distributed hypertables * timescale#3104 Fix use after free in `add_reorder_policy` * timescale#3106 Fix use after free in `chunk_api_get_chunk_stats` * timescale#3109 Copy recreated object permissions on update * timescale#3111 Fix `CMAKE_BUILD_TYPE` check * timescale#3112 Use `%u` to format Oid instead of `%d` * timescale#3118 Fix use after free in cache * timescale#3123 Fix crash while using `REINDEX TABLE CONCURRENTLY` * timescale#3135 Fix SkipScan path generation in `DISTINCT` queries with expressions * timescale#3146 Fix SkipScan for IndexPaths without pathkeys * timescale#3147 Skip ChunkAppend if AppendPath has no children * timescale#3148 Make `SELECT DISTINCT` handle non-var targetlists * timescale#3151 Fix `fdw_relinfo_get` assertion failure on `DELETE` * timescale#3155 Inherit `CFLAGS` from PostgreSQL * timescale#3169 Fix incorrect type cast in compression policy **Thanks** * @Dead2, @dv8472 and @einsibjarni for reporting an issue with multinode queries and views * @hperez75 for reporting an issue with Skip Scan * @nathanloisel for reporting an issue with compression on hypertables with integer-based timestamps * @xin-hedera for fixing an issue with compression on hypertables with integer-based timestamps
This maintenance release contains bugfixes since the 2.1.0 release. We deem it high priority for upgrading. This release extends Skip Scan to multinode by enabling the pushdown of `DISTINCT` to data nodes. It also fixes a number of bugs in the implementation of Skip Scan, in distributed hypertables, in creation of indexes, in compression, and in policies. **Features** * timescale#3113 Pushdown "SELECT DISTINCT" in multi-node to allow use of Skip Scan **Bugfixes** * timescale#3101 Use commit date in `get_git_commit()` * timescale#3102 Fix `REINDEX TABLE` for distributed hypertables * timescale#3104 Fix use after free in `add_reorder_policy` * timescale#3106 Fix use after free in `chunk_api_get_chunk_stats` * timescale#3109 Copy recreated object permissions on update * timescale#3111 Fix `CMAKE_BUILD_TYPE` check * timescale#3112 Use `%u` to format Oid instead of `%d` * timescale#3118 Fix use after free in cache * timescale#3123 Fix crash while using `REINDEX TABLE CONCURRENTLY` * timescale#3135 Fix SkipScan path generation in `DISTINCT` queries with expressions * timescale#3146 Fix SkipScan for IndexPaths without pathkeys * timescale#3147 Skip ChunkAppend if AppendPath has no children * timescale#3148 Make `SELECT DISTINCT` handle non-var targetlists * timescale#3151 Fix `fdw_relinfo_get` assertion failure on `DELETE` * timescale#3155 Inherit `CFLAGS` from PostgreSQL * timescale#3169 Fix incorrect type cast in compression policy **Thanks** * @Dead2, @dv8472 and @einsibjarni for reporting an issue with multinode queries and views * @hperez75 for reporting an issue with Skip Scan * @nathanloisel for reporting an issue with compression on hypertables with integer-based timestamps * @xin-hedera for fixing an issue with compression on hypertables with integer-based timestamps
This maintenance release contains bugfixes since the 2.2.0 release. We deem it high priority for upgrading. This release extends Skip Scan to multinode by enabling the pushdown of `DISTINCT` to data nodes. It also fixes a number of bugs in the implementation of Skip Scan, in distributed hypertables, in creation of indexes, in compression, and in policies. **Features** * timescale#3113 Pushdown "SELECT DISTINCT" in multi-node to allow use of Skip Scan **Bugfixes** * timescale#3101 Use commit date in `get_git_commit()` * timescale#3102 Fix `REINDEX TABLE` for distributed hypertables * timescale#3104 Fix use after free in `add_reorder_policy` * timescale#3106 Fix use after free in `chunk_api_get_chunk_stats` * timescale#3109 Copy recreated object permissions on update * timescale#3111 Fix `CMAKE_BUILD_TYPE` check * timescale#3112 Use `%u` to format Oid instead of `%d` * timescale#3118 Fix use after free in cache * timescale#3123 Fix crash while using `REINDEX TABLE CONCURRENTLY` * timescale#3135 Fix SkipScan path generation in `DISTINCT` queries with expressions * timescale#3146 Fix SkipScan for IndexPaths without pathkeys * timescale#3147 Skip ChunkAppend if AppendPath has no children * timescale#3148 Make `SELECT DISTINCT` handle non-var targetlists * timescale#3151 Fix `fdw_relinfo_get` assertion failure on `DELETE` * timescale#3155 Inherit `CFLAGS` from PostgreSQL * timescale#3169 Fix incorrect type cast in compression policy * timescale#3183 Fix segfault in calculate_chunk_interval * timescale#3185 Fix wrong datatype in integer based retention policy **Thanks** * @Dead2, @dv8472 and @einsibjarni for reporting an issue with multinode queries and views * @hperez75 for reporting an issue with Skip Scan * @nathanloisel for reporting an issue with compression on hypertables with integer-based timestamps * @xin-hedera for fixing an issue with compression on hypertables with integer-based timestamps
This maintenance release contains bugfixes since the 2.2.0 release. We deem it high priority for upgrading. This release extends Skip Scan to multinode by enabling the pushdown of `DISTINCT` to data nodes. It also fixes a number of bugs in the implementation of Skip Scan, in distributed hypertables, in creation of indexes, in compression, and in policies. **Features** * #3113 Pushdown "SELECT DISTINCT" in multi-node to allow use of Skip Scan **Bugfixes** * #3101 Use commit date in `get_git_commit()` * #3102 Fix `REINDEX TABLE` for distributed hypertables * #3104 Fix use after free in `add_reorder_policy` * #3106 Fix use after free in `chunk_api_get_chunk_stats` * #3109 Copy recreated object permissions on update * #3111 Fix `CMAKE_BUILD_TYPE` check * #3112 Use `%u` to format Oid instead of `%d` * #3118 Fix use after free in cache * #3123 Fix crash while using `REINDEX TABLE CONCURRENTLY` * #3135 Fix SkipScan path generation in `DISTINCT` queries with expressions * #3146 Fix SkipScan for IndexPaths without pathkeys * #3147 Skip ChunkAppend if AppendPath has no children * #3148 Make `SELECT DISTINCT` handle non-var targetlists * #3151 Fix `fdw_relinfo_get` assertion failure on `DELETE` * #3155 Inherit `CFLAGS` from PostgreSQL * #3169 Fix incorrect type cast in compression policy * #3183 Fix segfault in calculate_chunk_interval * #3185 Fix wrong datatype in integer based retention policy **Thanks** * @Dead2, @dv8472 and @einsibjarni for reporting an issue with multinode queries and views * @hperez75 for reporting an issue with Skip Scan * @nathanloisel for reporting an issue with compression on hypertables with integer-based timestamps * @xin-hedera for fixing an issue with compression on hypertables with integer-based timestamps
This maintenance release contains bugfixes since the 2.2.0 release. We deem it high priority for upgrading. This release extends Skip Scan to multinode by enabling the pushdown of `DISTINCT` to data nodes. It also fixes a number of bugs in the implementation of Skip Scan, in distributed hypertables, in creation of indexes, in compression, and in policies. **Features** * timescale#3113 Pushdown "SELECT DISTINCT" in multi-node to allow use of Skip Scan **Bugfixes** * timescale#3101 Use commit date in `get_git_commit()` * timescale#3102 Fix `REINDEX TABLE` for distributed hypertables * timescale#3104 Fix use after free in `add_reorder_policy` * timescale#3106 Fix use after free in `chunk_api_get_chunk_stats` * timescale#3109 Copy recreated object permissions on update * timescale#3111 Fix `CMAKE_BUILD_TYPE` check * timescale#3112 Use `%u` to format Oid instead of `%d` * timescale#3118 Fix use after free in cache * timescale#3123 Fix crash while using `REINDEX TABLE CONCURRENTLY` * timescale#3135 Fix SkipScan path generation in `DISTINCT` queries with expressions * timescale#3146 Fix SkipScan for IndexPaths without pathkeys * timescale#3147 Skip ChunkAppend if AppendPath has no children * timescale#3148 Make `SELECT DISTINCT` handle non-var targetlists * timescale#3151 Fix `fdw_relinfo_get` assertion failure on `DELETE` * timescale#3155 Inherit `CFLAGS` from PostgreSQL * timescale#3169 Fix incorrect type cast in compression policy * timescale#3183 Fix segfault in calculate_chunk_interval * timescale#3185 Fix wrong datatype in integer based retention policy **Thanks** * @Dead2, @dv8472 and @einsibjarni for reporting an issue with multinode queries and views * @hperez75 for reporting an issue with Skip Scan * @nathanloisel for reporting an issue with compression on hypertables with integer-based timestamps * @xin-hedera for fixing an issue with compression on hypertables with integer-based timestamps
This maintenance release contains bugfixes since the 2.2.0 release. We deem it high priority for upgrading. This release extends Skip Scan to multinode by enabling the pushdown of `DISTINCT` to data nodes. It also fixes a number of bugs in the implementation of Skip Scan, in distributed hypertables, in creation of indexes, in compression, and in policies. **Features** * #3113 Pushdown "SELECT DISTINCT" in multi-node to allow use of Skip Scan **Bugfixes** * #3101 Use commit date in `get_git_commit()` * #3102 Fix `REINDEX TABLE` for distributed hypertables * #3104 Fix use after free in `add_reorder_policy` * #3106 Fix use after free in `chunk_api_get_chunk_stats` * #3109 Copy recreated object permissions on update * #3111 Fix `CMAKE_BUILD_TYPE` check * #3112 Use `%u` to format Oid instead of `%d` * #3118 Fix use after free in cache * #3123 Fix crash while using `REINDEX TABLE CONCURRENTLY` * #3135 Fix SkipScan path generation in `DISTINCT` queries with expressions * #3146 Fix SkipScan for IndexPaths without pathkeys * #3147 Skip ChunkAppend if AppendPath has no children * #3148 Make `SELECT DISTINCT` handle non-var targetlists * #3151 Fix `fdw_relinfo_get` assertion failure on `DELETE` * #3155 Inherit `CFLAGS` from PostgreSQL * #3169 Fix incorrect type cast in compression policy * #3183 Fix segfault in calculate_chunk_interval * #3185 Fix wrong datatype in integer based retention policy **Thanks** * @Dead2, @dv8472 and @einsibjarni for reporting an issue with multinode queries and views * @hperez75 for reporting an issue with Skip Scan * @nathanloisel for reporting an issue with compression on hypertables with integer-based timestamps * @xin-hedera for fixing an issue with compression on hypertables with integer-based timestamps
Tables, indexes, and sequences that are recreated as part of an update
does not propagate permissions to the recreated object. This commit
fixes that by saving away the permissions in
pg_class
temporarily andthen copying them back into the
pg_class
table.If internal objects are created or re-created, they get the wrong
initial privileges, which result in privileges not being dumped when
using
pg_dump
. Save away the privileges before starting the updateand restore them afterwards to make sure that the privileges are
maintained over the update.
For new objects, we use the initial privileges of the
chunk
metadatatable, which should always have correct initial privileges.
Fixes #3078