Skip to content

Instantly share code, notes, and snippets.

@cpetersen
Created October 2, 2012 20:20
Show Gist options
  • Save cpetersen/3823037 to your computer and use it in GitHub Desktop.
Save cpetersen/3823037 to your computer and use it in GitHub Desktop.
Attempt to generate overlapping blocks of uuids in couch
curl http://localhost:5985/_uuids?count=100000 > 1.json &
curl http://localhost:5985/_uuids?count=100000 > 2.json &
curl http://localhost:5985/_uuids?count=100000 > 3.json &
curl http://localhost:5985/_uuids?count=100000 > 4.json &
curl http://localhost:5985/_uuids?count=100000 > 5.json &
def uuids(filename)
JSON.parse(File.read(filename))["uuids"]
end
uuids1 = uuids("1.json")
uuids2 = uuids("2.json")
uuids3 = uuids("3.json")
uuids4 = uuids("4.json")
uuids5 = uuids("5.json")
uuids1 & uuids2
uuids1 & uuids3
uuids1 & uuids4
uuids1 & uuids5
uuids2 & uuids3
uuids2 & uuids4
uuids2 & uuids5
uuids3 & uuids4
uuids3 & uuids5
uuids4 & uuids5
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment