Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(3760)

Issue 5976074: Managed Connections for txzk

Can't Edit
Can't Publish+Mail
Start Review
Created:
12 years ago by hazmat
Modified:
12 years ago
Reviewers:
jimbaker, mp+100715, fwereade
Visibility:
Public.

Description

Managed Connections for txzk A managed connection automatically handles transient connection failures, and session expiration. On session expiration it recreates ephemeral nodes, and fire watch events on extant watchers. https://code.launchpad.net/~hazmat/txzookeeper/managed-watch-and-ephemeral/+merge/100715 (do not edit description out of merge proposal)

Patch Set 1 #

Total comments: 7

Patch Set 2 : Managed Connections for txzk #

Total comments: 7
Unified diffs Side-by-side diffs Delta from patch set Stats (+718 lines, -53 lines) Patch
A .bzrignore View 1 chunk +4 lines, -0 lines 0 comments Download
A [revision details] View 1 1 chunk +2 lines, -0 lines 0 comments Download
M setup.py View 1 chunk +2 lines, -2 lines 0 comments Download
M txzookeeper/client.py View 17 chunks +63 lines, -40 lines 0 comments Download
A txzookeeper/managed.py View 1 1 chunk +350 lines, -0 lines 6 comments Download
M txzookeeper/retry.py View 3 chunks +10 lines, -9 lines 0 comments Download
M txzookeeper/tests/__init__.py View 2 chunks +22 lines, -0 lines 0 comments Download
M txzookeeper/tests/test_client.py View 1 chunk +1 line, -1 line 0 comments Download
A txzookeeper/tests/test_managed.py View 1 1 chunk +263 lines, -0 lines 1 comment Download
M txzookeeper/tests/test_retry.py View 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 5
hazmat
Please take a look.
12 years ago (2012-04-04 00:55:03 UTC) #1
fwereade
This looks very nice indeed, but the vagueness of the "comes at a cost" comment ...
12 years ago (2012-04-04 13:23:29 UTC) #2
hazmat
On 2012/04/04 13:23:29, fwereade wrote: > This looks very nice indeed, but the vagueness of ...
12 years ago (2012-04-04 18:09:00 UTC) #3
hazmat
Please take a look. https://codereview.appspot.com/5976074/diff/1/txzookeeper/managed.py File txzookeeper/managed.py (right): https://codereview.appspot.com/5976074/diff/1/txzookeeper/managed.py#newcode66 txzookeeper/managed.py:66: mgr # keep the flakes ...
12 years ago (2012-04-04 18:09:46 UTC) #4
jimbaker
12 years ago (2012-04-07 00:08:39 UTC) #5
+1, LGTM, just some minors

https://codereview.appspot.com/5976074/diff/4001/txzookeeper/managed.py
File txzookeeper/managed.py (right):

https://codereview.appspot.com/5976074/diff/4001/txzookeeper/managed.py#newco...
txzookeeper/managed.py:153: def cb_restablish_session(self, e=None):
Presumably this should be cb_re_establish... but I don't see the difference here
with the easier synonym: restore. Good either way with me.

https://codereview.appspot.com/5976074/diff/4001/txzookeeper/managed.py#newco...
txzookeeper/managed.py:162: # If its been explicitly closed, don't restablish.
it's... re-establish

(or are you saying something about being restful? ;) )

https://codereview.appspot.com/5976074/diff/4001/txzookeeper/managed.py#newco...
txzookeeper/managed.py:166: # If its a stale handle, don't restablish
it's... re-establish

https://codereview.appspot.com/5976074/diff/4001/txzookeeper/managed.py#newco...
txzookeeper/managed.py:174: # Its already been restablished, don't restablish.
It's... re-established... re-establish

https://codereview.appspot.com/5976074/diff/4001/txzookeeper/managed.py#newco...
txzookeeper/managed.py:183: # Restablish
I'm not going to mark any more of these!

https://codereview.appspot.com/5976074/diff/4001/txzookeeper/managed.py#newco...
txzookeeper/managed.py:189: log.error("error while restablish %r %s" % (e, e))
Another minor: probably want some consistency in beginning with uppercase. Not
certain why you use log.error here, but log.exception later for what appears to
be a similar case.

https://codereview.appspot.com/5976074/diff/4001/txzookeeper/tests/test_manag...
File txzookeeper/tests/test_managed.py (right):

https://codereview.appspot.com/5976074/diff/4001/txzookeeper/tests/test_manag...
txzookeeper/tests/test_managed.py:110: """Reset fires a synthentic client event,
and clears watches.
no need for comma
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b