EDB Postgres Distributed 4.3.6 release notes v4

Released: 15 October 2024

EDB Postgres Distributed 4.3.6 is a minor release that includes several bug fixes and enhancements.

Highlights

  • HARP proxy settings patches to reduced bloat on consensus request and response journals.
  • Fix for accidental drop of autopartition rule when a column of the autopartitioned table is dropped.

Enhancements

ComponentVersionRelease NoteAddresses
BDR4.3.6
Add bdr.bdr_show_all_file_settings() and bdr.bdr_file_settings view

Fix: Correct privileges for bdr_superuser. Creating wrapper SECURITY DEFINER functions in the bdr schema and granting access to bdr_superuser to use those:

  • bdr.bdr_show_all_file_settings
  • bdr.bdr_file_settings

Bug Fixes

ComponentVersionRelease NoteAddresses
BDR4.3.6
bdr consensus: Add GUCs to control automatic Raft vacuum

Aggressive HARP proxy settings may face issues due to increased bloat on consensus request and response journals. This patch adds GUCs to control frequency of automatic vacuum on said catalogs. The bdr.raft_vacuum_interval GUC controls how frequently the tables are checked for VACUUM and ANALYZE. The Autovacuum GUCs and table reloptions are used to determine whether VACUUM/ANALYZE is needed or not. The bdr.raft_vacuum_full_interval triggers VACUUM FULL on the tables. The user can disable VACUUM FULL if normal VACUUM is sufficient to keep the bloat in control.

40412
BDR4.3.6
Do not accidentally drop the autopartition rule when a column of the autopartitioned table is dropped.

When ALTER TABLE .. DROP COLUMN is used, the object_access_hook is fired with classId set to RelationRelationId, but the subId is set to the attribute number to differentiate it from the DROP TABLE command. Therefore, we need to check the subId field to make sure that we are not performing actions that should only be triggered when a table is dropped.

40258
BDR4.3.6
Cleanup unwanted data with drop_node

When we drop the local node we cleanup all the catalog tables internally.

BDR4.3.6
Delete older logs if we get a snapshot that's already applied

The follower doesn't need the older logs once a snapshot is applied. If we keep those around, the duplicate request id issue may keep happening. So clear the logs a bit more aggressively once we know they are not needed.

BDR4.3.6
Handling duplicate requests in RAFT preventing protocol breakage

When processing RAFT entries, it's crucial to handle duplicate requests properly to prevent Raft protocol issues. Duplicate requests can occur when a client retries a request that has already been accepted and applied by the Raft leader. The problem arose when the leader failed to detect the duplicate request due to historical evidence being pruned.

37725
BDR4.3.6
Handling Raft Snapshots: Consensus Log

When installing or importing a Raft snapshot, discard the consensus log unless it contains an entry matching the snapshot's last included entry and term.

37725
BDR4.3.6
Allow ANALYZE on temp tables

The ANALYZE statement is already not replicated. We dont need to filter if it's analyzing temp tables or not, we allow the user to analyze anything.

38826
BDR4.3.6
Re-add function bdr.column_timestamps_enable_internal()

This function was removed as the code can be merged withbdr.column_timestamps_disable(). However, although that function is deprecated, in a mixed-version cluster it could theoretically be called on an older node, resulting in bdr.column_timestamps_enable_internal() being replicated and causing an error on the nodes where it is no longer present.

BDR4.3.6
Fixed buffer overrun in the writer

Include an extra zero byte at the end of a column value allocation in shared memory queue insert/update/delete messages.

98966
BDR4.3.6
Fix duplicate ids generation for snowflakeid

Disallow multiple backends which concurrently increment the sequences to simultaneously initialize the sequence for same millisecond timestamp value, resulting in duplicate ids both with local seq id component as 0.

BDR4.3.6
Adjust bdr.alter_table_conflict_detection() to propagate correctly to all nodes

Ensure that the propagation of bdr.alter_table_conflict_detection() (as well as the related, deprecated bdr.column_timestamps_(en|dis)able() functions) is carried out correctly to all logical standbys. Previously, this propagation did not occur if the logical standby was not directly attached to the node on which the functions were executed.

40258
BDR4.3.6
Raft-related catalog items

This adds compatibility objects for:

  • bdr.raft_instances
  • bdr.get_raft_status(node_group_name text)

These additions ensure that Raft status queries operate correctly in clusters running multiple major versions.

Utilities4.3.6bdr_pg_upgrade - Create logical slot with twophase set to true for PG 14+