Revert changes to ULID generation

This commit is contained in:
maddie 2020-02-27 00:57:00 +08:00 committed by GitHub
parent a81bb0380d
commit 5144486472
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -176,7 +176,7 @@ func Record(w http.ResponseWriter, r *http.Request) {
record.Jitter = jitter
record.Log = logs
t := time.Unix(1048576, 0)
t := time.Now()
entropy := ulid.Monotonic(rand.New(rand.NewSource(t.UnixNano())), 0)
uuid := ulid.MustNew(ulid.Timestamp(t), entropy)
record.UUID = uuid.String()