Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

minor tweaks #24

Closed
wants to merge 6 commits into from
Closed

minor tweaks #24

wants to merge 6 commits into from

Conversation

radek-senfeld
Copy link

  • trottelfest checking ttl > 2 * loop_wait
  • user configurable .pgpass filepath

 * user configurable .pgpass file
@@ -18,6 +18,8 @@
class Patroni:

def __init__(self, config):
assert config["etcd"]["ttl"] > 2 * config["loop_wait"]
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And what about other configuration stores?
Currently we already support ZooKeeper and working on Consul support.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good point! Fixed for etcd, no exp with ZK nor Consul..

@@ -88,6 +91,11 @@ def run(self):
try:
if self.ha.state_handler.is_leader():
self.ha.cluster and self.ha.state_handler.create_replication_slots(self.ha.cluster)

# SkyDNS2 support: publish leader
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We'd like to keep the code as generic as possible. This could be implemented by the ACTION_ON_ROLE_CHANGE callback (to call a script for example). This does however require some more documentation

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That was my thinking as well but for our use case callback cannot be used because it's being called just once - on a role change. We need periodic record refresh to keep record's TTL short = faster response when anything goes wrong.

Sorry for that, it wasn't meant to be part of my PR. Still being a git noob, I don't know how to divide future commits from PR I've already made.. :-(

Pavel Milar and others added 2 commits September 4, 2015 21:35
@CyberDem0n
Copy link
Collaborator

Synchronous replication is now supported and it's also possible to configure custom location for pgpass.
For SkyDNS you should use callbacks.

@CyberDem0n CyberDem0n closed this Nov 16, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants