{"payload":{"feedbackUrl":"https://github.com/orgs/community/discussions/53140","repo":{"id":44721555,"defaultBranch":"master","name":"retry","ownerLogin":"juju","currentUserCanPush":false,"isFork":false,"isEmpty":false,"createdAt":"2015-10-22T04:11:40.000Z","ownerAvatar":"https://avatars.githubusercontent.com/u/4604548?v=4","public":true,"private":false,"isOrgOwned":true},"refInfo":{"name":"","listCacheKey":"v0:1726502399.0","currentOid":""},"activityList":{"items":[{"before":"62423bf332875c7155412ec69197dbabcaa335b9","after":"d9c58a06d0a5affd4122f2dc572c607246deefca","ref":"refs/heads/master","pushedAt":"2024-09-16T15:55:02.000Z","pushType":"pr_merge","commitsCount":4,"pusher":{"login":"jujubot","name":null,"path":"/jujubot","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/7779494?s=80&v=4"},"commit":{"message":"Merge pull request #12 from jameinel/jitter-cleanup\n\nhttps://github.com/juju/retry/pull/12\n\nThe original implementation of jitter computed the new delay, and then did a range of actual delay in the range of 0-100% of that value. On average, that actually means that we delay 1/2 as long as the desired values. In practice it was slightly more, because we then capped to min and max, which meant for the simple tests it was a 60% bias.\n\nThe new algorithm does a +/- 20% logic, which means that on average, we actually end up very close to the expected values (my averaging ratios normally came out within 1% of the expected values, and worse case was about a 3.6% bias). Since it is random, it could be anything (you could have a string of 100 minimum possible values). But that is unlikely enough that I'll leave the test suite as asserting we are within 10% and live with the 1 in 1 billion chance that it fails.\n\nAlso, there was a flaky test (StopChannel) where it could get an extra trigger sometimes, and we had the bug that if a user incorrectly supplied a exponential backoff that was <1.0 we would actually end up going below minDelay, rather than capping it at min. (we would check if you applied jitter, but not normally).\n\nThere isn't a lot to QA manually, as I think the test cases are pretty thorough.\n\nI'm a bit unhappy about my \"1ms\" limits on the 20% over and under, but I think that is still ok. Certainly it is ok in practice.","shortMessageHtmlLink":"Merge pull request #12 from jameinel/jitter-cleanup"}}],"hasNextPage":false,"hasPreviousPage":false,"activityType":"all","actor":null,"timePeriod":"all","sort":"DESC","perPage":30,"cursor":"Y3Vyc29yOnYyOpK7MjAyNC0wOS0xNlQxNTo1NTowMi4wMDAwMDBazwAAAAS3n2QR","startCursor":"Y3Vyc29yOnYyOpK7MjAyNC0wOS0xNlQxNTo1NTowMi4wMDAwMDBazwAAAAS3n2QR","endCursor":"Y3Vyc29yOnYyOpK7MjAyNC0wOS0xNlQxNTo1NTowMi4wMDAwMDBazwAAAAS3n2QR"}},"title":"Activity ยท juju/retry"}