-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Staged rollouts #666
Staged rollouts #666
Conversation
return new ReleaseEntry(m.Groups[1].Value, filename, size, isDelta, baseUrl, query, stagingPercentage); | ||
} | ||
|
||
public bool IsStagingMatch(Guid? userId) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some comments on how we define a staging match would be 👌.
@paulcbetts Maybe add Docs to that Todo? |
@paulcbetts if you can point me to some example code, I'll can create a doc file for you to review. |
|
||
uint val = BitConverter.ToUInt32(userId.Value.ToByteArray(), 12); | ||
|
||
double percentage = ((double)val / (double)UInt32.MaxValue); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems to me, that in the absence of tracking actual downloads/installs, it is just assuming an even distribution of guid-to-integer-conversions? So, a hopeful approximation?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We create the GUID in a Weird Way by taking random bytes that is more likely to ensure a random distribution, it's not just Guid.Create()
. That being said, I am not a statistician, but it doesn't really matter so much
This PR implements staged rollouts, where a certain percentage of your users will get the newest version of your app.
We do this by adding a magic comment to the RELEASES file - unfortunately, because of a bug in the syntax Regex in existing Squirrel.Windows versions, we have to write this in a super ugly way:
Note that there is no space between the filesize and the comment. In the future, you'll able to put a space there of course :)
TODO: