|
3 | 3 | Release notes |
4 | 4 | ============= |
5 | 5 |
|
| 6 | +Version 4.1.0 |
| 7 | +------------- |
| 8 | + |
| 9 | +Released 2025-09-23 |
| 10 | + |
| 11 | +**New features** |
| 12 | + |
| 13 | +- Add support for systemd "notify" unit type (Ronan Dunklau) |
| 14 | + |
| 15 | + Without a notify unit type, it is possible to start Patroni and immediately send it a SIGHUP signal using systemd, effectively killing it before it had time to set up its signal handlers. |
| 16 | + |
| 17 | +- Provide receive and replay LSN/lag information in API and ctl (Polina Bungina) |
| 18 | + |
| 19 | + Patroni REST API ``/cluster`` endpoint and ``patronictl list`` command now provide receive LSN, replay LSN, receive lag, and replay lag information for each replica member. |
| 20 | + |
| 21 | +- Ensure clean demotion to standby cluster (Polina Bungina) |
| 22 | + |
| 23 | + Make sure the introduction of the ``standby_cluster`` section in the dynamic configuration leads to a clean cluster demotion. |
| 24 | + |
| 25 | +- Implement ``patronictl demote-cluster`` and ``promote-cluster`` commands (Polina Bungina) |
| 26 | + |
| 27 | + New commands for cluster demotion and promotion handle both the dynamic configuration editing and checking the result status. |
| 28 | + |
| 29 | +- Implement ``sync_priority`` tag (Polina Bungina) |
| 30 | + |
| 31 | + This parameter controls the priority a member should have during synchronous replica selection when ``synchronous_mode`` is set to ``on``. |
| 32 | + |
| 33 | +- Implement ``--print`` option for ``--validate-config`` (Polina Bungina) |
| 34 | + |
| 35 | + Print out local configuration (including environment configuration overrides) after it has been successfully validated. |
| 36 | + |
| 37 | +- Implement ``kubernetes.bootstrap_labels`` (Polina Bungina) |
| 38 | + |
| 39 | + This feature allows you to define labels that will be assigned to a member pod when in ``initializing new cluster``, ``running custom bootstrap script``, ``starting after custom bootstrap``, or ``creating replica`` state. |
| 40 | + |
| 41 | +- Add configuration option to suppress duplicate heartbeat logs (Michael Morris) |
| 42 | + |
| 43 | + If set to ``true``, successive heartbeat logs that are identical shall not be output. |
| 44 | + |
| 45 | +- Add optional ``cluster_type`` attribute to permanent replication slots (Michael Banck) |
| 46 | + |
| 47 | + This allows you to set whether a particular permanent replication slot should always be created, or just on a primary or standby cluster. |
| 48 | + |
| 49 | +- Make HTTP Server header configurable (David Grierson) |
| 50 | + |
| 51 | + Introduce the ``restapi.server_tokens`` configuration parameter that allows you to restrict information disclosed in the HTTP Server header. |
| 52 | + |
| 53 | +- Implement readiness API checks for replication on replica members (Ants Aasma) |
| 54 | + |
| 55 | + The previous implementation considered replicas ready as soon as PostgreSQL was started. With this change, a replica pod is only considered ready when PostgreSQL is replicating and is not too far behind the leader. |
| 56 | + |
| 57 | + |
| 58 | +**Improvements** |
| 59 | + |
| 60 | +- Reduce log level of watchdog configuration failure (Ants Aasma) |
| 61 | + |
| 62 | + Show the `Could not activate Linux watchdog device` log line on debug logging level, when the watchdog is configured with ``required`` mode. It was previously shown on info level. |
| 63 | + |
| 64 | +- Take advantage of ``written_lsn`` and ``latest_end_lsn`` from ``pg_stat_wal_receiver`` (Alexander Kukushkin) |
| 65 | + |
| 66 | + ``written_lsn``, the actual write LSN, is now preferred over the one returned by ``pg_last_wal_receive_lsn()``, which is in fact the flush LSN. ``latest_end_lsn`` points to WAL flush on the source host. In case of a primary, it allows better calculation of the replay lag, because values stored in DCS are updated only every ``loop_wait`` seconds. |
| 67 | + |
| 68 | +- Avoid interactions with slots created with the ``failover=true`` option (Alexander Kukushkin) |
| 69 | + |
| 70 | + This change is required to make the logical failover slots feature fully functional. |
| 71 | + |
| 72 | +- Add PostgreSQL state to ``/metrics`` REST API endpoint (Ivan Filianin) |
| 73 | + |
| 74 | + PostgreSQL instance state information is now available in the Prometheus format output of the ``/metrics`` REST API endpoint. |
| 75 | + |
| 76 | + |
| 77 | +Version 4.0.7 |
| 78 | +------------- |
| 79 | + |
| 80 | +Released 2025-09-22 |
| 81 | + |
| 82 | +**New features** |
| 83 | + |
| 84 | +- Add support for PostgreSQL 18 RC1 (Alexander Kukushkin) |
| 85 | + |
| 86 | + GUC's validator rules were extended. Patroni now properly handles the new background I/O worker. |
| 87 | + |
| 88 | + |
| 89 | +**Bugfixes** |
| 90 | + |
| 91 | +- Fix potential issue around resolving localhost to IPv6 on Windows (András Váczi) |
| 92 | + |
| 93 | + When configuring ``listen_addresses`` in PostgreSQL, using ``0.0.0.0`` or ``127.0.0.1`` will restrict listening to IPv4 only, excluding IPv6. On typical Windows systems, however, ``localhost`` often resolves to the IPv6 address ``::1`` by default. To ensure compatibility, Patroni now configures PostgreSQL to listen on ``127.0.0.1``, instead of ``localhost``, on Windows systems. |
| 94 | + |
| 95 | +- Return global config only when ``/config`` key exists in DCS (Alexander Kukushkin) |
| 96 | + |
| 97 | + Patroni REST API was returning an empty configuration instead of raising an error if the ``/config`` key was missing in DCS. |
| 98 | + |
| 99 | +- Fix the issue of failsafe mode not being triggered in case of Etcd unavailability (Alexander Kukushkin) |
| 100 | + |
| 101 | + Patroni was not always properly handling ``etcd3`` exceptions, which resulted in failsafe mode not being triggered. |
| 102 | + |
| 103 | +- Fix signal handler reentrancy deadlock (Waynerv) |
| 104 | + |
| 105 | + Patroni running in a Docker container with ``PID=1`` in some special cases was experiencing deadlock after receiving ``SIGCHLD``. |
| 106 | + |
| 107 | +- Recreate (permanent) physical slot when it doesn't reserve WAL (Israel Barth Rubio) |
| 108 | + |
| 109 | + Permanent physical replication slots created outside of Patroni scope without reserving WALs were causing a ``replication slot cannot be advanced`` error. To avoid this, Patroni now recreates such slots. |
| 110 | + |
| 111 | +- Handle watch cancelation messages in ``etcd3`` properly (Alexander Kukushkin) |
| 112 | + |
| 113 | + When ``etcd3`` sends a cancelation message to the watch channel, it doesn't close the connection. This results in Patroni using stale data. Patroni now solves it by breaking a loop of reading chunked response and closing the connection on the Patroni side. |
| 114 | + |
| 115 | +- Handle case when ``HTTPConnection`` socket is wrapped with ``pyopenssl`` (Alexander Kukushkin) |
| 116 | + |
| 117 | + Patroni was not correctly using ``pyopenssl`` interfaces, enforced in ``python-etcd``. |
| 118 | + |
| 119 | + |
| 120 | +**Documentation improvements** |
| 121 | + |
| 122 | +- Improve 2-node cluster guidance (Nikolay Samokhvalov) |
| 123 | + |
| 124 | + Clarify behaviour during failover and DCS requirements. |
| 125 | + |
| 126 | + |
6 | 127 | Version 4.0.6 |
7 | 128 | ------------- |
8 | 129 |
|
|
0 commit comments