Upgrade to Pro — share decks privately, control downloads, hide ads and more …

UUIDは衝突の夢を見るか

Sponsored · SiteGround - Reliable hosting with speed, security, and support you can count on. →
Dorian
April 26, 2017

 UUIDは衝突の夢を見るか

Dorian

April 26, 2017

Transcript

19 slides
  1. require 'securerandom' require 'mysql2' client = Mysql2::Client.new(:host => 'localhost', :username

    => 'root', :password => 'password', :database => 'uuid' ) while true do begin uuid = SecureRandom.uuid client.query("insert into uuid.ruby (`uuid`) values ('#{uuid}')") puts uuid rescue => e p e end end

More Decks by Dorian

Other Decks in Programming