Rename/add configuration file options

In previous versions of repmgr, some options had ambiguous meanings,
and/or were used for slightly different purposes. This way we end
up with a couple more options (most of which probably won't need
adjusting) but greater clarity and flexibility.

Removed:

  master_reponse_timeout:
    renamed to "async_query_timeout", as this was its main usage

  retry_promote_interval_secs:
    replaced by "primary_notification_timeout"

Added:
  async_query_timeout:
    timeout (in seconds) when executing asynchronous queries

  primary_notification_timeout:
    number of seconds to wait for notification from the new primary
    after a failover

  primary_follow_timeout:
    number of seconds to wait for the new primary to become available
    when executing "repmgr standby follow"
This commit is contained in:
Ian Barwick
2017-07-25 11:05:15 +09:00
parent cbe19d5868
commit 56b2e9bb84
7 changed files with 90 additions and 47 deletions

View File

@@ -78,12 +78,13 @@ typedef struct
char promote_command[MAXLEN];
char follow_command[MAXLEN];
int monitor_interval_secs;
int primary_response_timeout;
int reconnect_attempts;
int reconnect_interval;
int retry_promote_interval_secs;
bool monitoring_history;
int degraded_monitoring_timeout;
int async_query_timeout;
int primary_notification_timeout;
int primary_follow_timeout;
/* BDR settings */
bool bdr_local_monitoring_only;
@@ -125,10 +126,12 @@ typedef struct
/* repmgrd settings */ \
FAILOVER_MANUAL, DEFAULT_LOCATION, DEFAULT_PRIORITY, "", "", \
DEFAULT_STATS_REPORTING_INTERVAL, \
60, \
DEFAULT_RECONNECTION_ATTEMPTS, \
DEFAULT_RECONNECTION_INTERVAL, \
300, false, -1, \
false, -1, \
DEFAULT_ASYNC_QUERY_TIMEOUT, \
DEFAULT_PRIMARY_NOTIFICATION_TIMEOUT, \
DEFAULT_PRIMARY_FOLLOW_TIMEOUT, \
/* BDR settings */ \
false, false, \
/* service settings */ \