Skip to content

Commit

Permalink
Merge pull request #462 from UmanShahzad/patch-1
Browse files Browse the repository at this point in the history
Update sync standby names to include choose keyword
  • Loading branch information
gclough authored Mar 6, 2020
2 parents 97d6d5c + 5ad154b commit d8fc0d3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion templates/postgresql.conf-11.j2
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,7 @@ track_commit_timestamp = {{ 'on' if postgresql_track_commit_timestamp else 'off'

# These settings are ignored on a standby server.

synchronous_standby_names = '{{ postgresql_synchronous_standby_num_sync }}{% if postgresql_synchronous_standby_names != [] %} ({{ postgresql_synchronous_standby_names | join(',') }}){% endif %}' # standby servers that provide sync rep
synchronous_standby_names = '{% if postgresql_synchronous_standby_names != [] %}{% if postgresql_synchronous_standby_choose_sync != "" and postgresql_synchronous_standby_num_sync != "" %}{{ postgresql_synchronous_standby_choose_sync }} {% endif %}{% if postgresql_synchronous_standby_num_sync != "" %}{{ postgresql_synchronous_standby_num_sync }} ({% endif %}"{{ postgresql_synchronous_standby_names | join('\",\"') }}"{% if postgresql_synchronous_standby_num_sync != "" %}){% endif %}{% endif %}' # standby servers that provide sync rep
# method to choose sync standbys, number of sync standbys,
# and comma-separated list of application_name
# from standby(s); '*' = all
Expand Down
2 changes: 1 addition & 1 deletion templates/postgresql.conf-12.j2
Original file line number Diff line number Diff line change
Expand Up @@ -299,7 +299,7 @@ track_commit_timestamp = {{ 'on' if postgresql_track_commit_timestamp else 'off'

# These settings are ignored on a standby server.

synchronous_standby_names = '{{ postgresql_synchronous_standby_num_sync }}{% if postgresql_synchronous_standby_names != [] %} ({{ postgresql_synchronous_standby_names | join(',') }}){% endif %}' # standby servers that provide sync rep
synchronous_standby_names = '{% if postgresql_synchronous_standby_names != [] %}{% if postgresql_synchronous_standby_choose_sync != "" and postgresql_synchronous_standby_num_sync != "" %}{{ postgresql_synchronous_standby_choose_sync }} {% endif %}{% if postgresql_synchronous_standby_num_sync != "" %}{{ postgresql_synchronous_standby_num_sync }} ({% endif %}"{{ postgresql_synchronous_standby_names | join('\",\"') }}"{% if postgresql_synchronous_standby_num_sync != "" %}){% endif %}{% endif %}' # standby servers that provide sync rep
# method to choose sync standbys, number of sync standbys,
# and comma-separated list of application_name
# from standby(s); '*' = all
Expand Down

0 comments on commit d8fc0d3

Please sign in to comment.