Skip to content

xor the random number seed with the pid #38

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

waltman
Copy link

@waltman waltman commented May 15, 2022

This prevents 2 processes starting at the same microsecond (e.g. after a fork) from generating the same UUID. This fixes the bug reported at https://blog.afoolishmanifesto.com/posts/log-loss-detection/

This prevents 2 processes starting at the same microsecond (e.g. after
a fork) from generating the same UUID.
@waltman
Copy link
Author

waltman commented May 15, 2022

I tested this using the shell command frew used in his blog post, but I don't know how do write it within Perl's testing framework.

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.

1 participant