mirror of
https://github.com/EnterpriseDB/repmgr.git
synced 2026-03-26 16:46:28 +00:00
"cluster show": fix formatting with multiple digit node IDs
This commit is contained in:
1
HISTORY
1
HISTORY
@@ -14,6 +14,7 @@
|
|||||||
it will actually be possible to stream from the target node (Ian)
|
it will actually be possible to stream from the target node (Ian)
|
||||||
repmgr: "standby switchover": improve handling of connection URIs when
|
repmgr: "standby switchover": improve handling of connection URIs when
|
||||||
executing "node rejoin" on the demotion candidate; GitHub #525 (Ian)
|
executing "node rejoin" on the demotion candidate; GitHub #525 (Ian)
|
||||||
|
repmgr: fix long node ID display in "cluster show"; (Ian)
|
||||||
repmgrd: check binary and extension major versions match; GitHub #515 (Ian)
|
repmgrd: check binary and extension major versions match; GitHub #515 (Ian)
|
||||||
repmgrd: on a cascaded standby, don't fail over if "failover=manual";
|
repmgrd: on a cascaded standby, don't fail over if "failover=manual";
|
||||||
GitHub #531 (Ian)
|
GitHub #531 (Ian)
|
||||||
|
|||||||
@@ -155,11 +155,18 @@ REPMGRD_OPTS="--daemonize=false"</programlisting>
|
|||||||
|
|
||||||
<listitem>
|
<listitem>
|
||||||
<para>
|
<para>
|
||||||
<application>repmgrd</application>: on a cascaded standby, don't fail over if
|
<application>repmgrd</application>: on a cascaded standby, don't fail over if
|
||||||
<literal>failover=manual</literal>. GitHub #531.
|
<literal>failover=manual</literal>. GitHub #531.
|
||||||
</para>
|
</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
|
|
||||||
|
<listitem>
|
||||||
|
<para>
|
||||||
|
<command><link linkend="repmgr-cluster-show">repmgr cluster show</link></command>:
|
||||||
|
fix display of node IDs with multiple digits.
|
||||||
|
</para>
|
||||||
|
</listitem>
|
||||||
|
|
||||||
</itemizedlist>
|
</itemizedlist>
|
||||||
</para>
|
</para>
|
||||||
</sect2>
|
</sect2>
|
||||||
|
|||||||
@@ -137,6 +137,7 @@ do_cluster_show(void)
|
|||||||
for (cell = nodes.head; cell; cell = cell->next)
|
for (cell = nodes.head; cell; cell = cell->next)
|
||||||
{
|
{
|
||||||
PQExpBufferData details;
|
PQExpBufferData details;
|
||||||
|
PQExpBufferData node_id;
|
||||||
|
|
||||||
cell->node_info->conn = establish_db_connection_quiet(cell->node_info->conninfo);
|
cell->node_info->conn = establish_db_connection_quiet(cell->node_info->conninfo);
|
||||||
|
|
||||||
@@ -352,6 +353,11 @@ do_cluster_show(void)
|
|||||||
PQfinish(cell->node_info->conn);
|
PQfinish(cell->node_info->conn);
|
||||||
cell->node_info->conn = NULL;
|
cell->node_info->conn = NULL;
|
||||||
|
|
||||||
|
initPQExpBuffer(&node_id);
|
||||||
|
appendPQExpBuffer(&node_id, "%i", cell->node_info->node_id);
|
||||||
|
headers_show[SHOW_ID].cur_length = strlen(node_id.data);
|
||||||
|
termPQExpBuffer(&node_id);
|
||||||
|
|
||||||
headers_show[SHOW_ROLE].cur_length = strlen(get_node_type_string(cell->node_info->type));
|
headers_show[SHOW_ROLE].cur_length = strlen(get_node_type_string(cell->node_info->type));
|
||||||
headers_show[SHOW_NAME].cur_length = strlen(cell->node_info->node_name);
|
headers_show[SHOW_NAME].cur_length = strlen(cell->node_info->node_name);
|
||||||
headers_show[SHOW_STATUS].cur_length = strlen(cell->node_info->details);
|
headers_show[SHOW_STATUS].cur_length = strlen(cell->node_info->details);
|
||||||
|
|||||||
Reference in New Issue
Block a user