Merge lp:~nikwen/account-polld/directly-poll-with-new-account-data-fix into lp:~ubuntu-push-hackers/account-polld/trunk
Proposed by
Niklas Wenzel
Status: | Merged | ||||
---|---|---|---|---|---|
Approved by: | John Lenton | ||||
Approved revision: | 103 | ||||
Merged at revision: | 112 | ||||
Proposed branch: | lp:~nikwen/account-polld/directly-poll-with-new-account-data-fix | ||||
Merge into: | lp:~ubuntu-push-hackers/account-polld/trunk | ||||
Diff against target: |
21 lines (+3/-0) 1 file modified
cmd/account-polld/main.go (+3/-0) |
||||
To merge this branch: | bzr merge lp:~nikwen/account-polld/directly-poll-with-new-account-data-fix | ||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Niklas Wenzel (community) | Approve | ||
John Lenton (community) | Needs Fixing | ||
Review via email: mp+238901@code.launchpad.net |
Description of the change
Existing accounts which have new account data will now directly poll the server. Otherwise it would wait 5 minutes (until Poll() is called again), recognize it failed before setting the new account data (penaltyCount != 0) and wait 5 minutes again until polling finally happens in the next invokation of Poll().
To post a comment you must log in.
This possibly also fixes a multithreading issue which may occur in the monitorAccounts() function as without this fix it wouldn't wait for the Poll() calls in "case data := <-watcher.C:".