-
Notifications
You must be signed in to change notification settings - Fork 2
Gem migration
Kenichi Kamiya edited this page Jul 18, 2022
·
7 revisions
As far as I know, major prior arts are below
It is just providing basic String
generator only.
So you can replace the code as below
-ULID.generate
+ULID.encode
NOTE: In version before 1.3.0
, timestamps might not be correct value.
NOTE: PR for decoder exists
It is providing basic generator(except monotonic generator) and parser. Major methods can be replaced as below.
-ULID.generate
+ULID.encode
-ULID.at(time)
+ULID.at(time).to_s
-ULID.time(string)
+ULID.decode_time(string)
-ULID.min_ulid_at(time)
+ULID.min(time).to_s
-ULID.max_ulid_at(time)
+ULID.max(time).to_s
NOTE: In version before 1.0.2
, timestamps might not be correct value.
- Parsed time object has more than milliseconds
- Fix to handle timestamp precision in parser
- Fix to handle timestamp precision in generator
- Released in 1.0.2
This gem is NOT
providing faster string generators than others. See also Benchmark if your system requires severe performance for ID generation.