Skip to content
This repository has been archived by the owner on Apr 12, 2023. It is now read-only.
/ ads-uuidv7 Public archive
forked from GoWebProd/uuid7

Go UUIDv7 implementation

Notifications You must be signed in to change notification settings

janetechinc/ads-uuidv7

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

uuid7

Documentation: https://datatracker.ietf.org/doc/html/draft-peabody-dispatch-new-uuid-format-03

Example

package main

import (
    "log"

    uuidv7 "github.com/janetechinc/ads-uuidv7"
)

func main() {
    u := uuidv7.New()

    log.Println(u.Next().String())
}

Benchmark

% go test -bench=. -test.benchmem
goos: darwin
goarch: arm64
pkg: github.com/janetechinc/ads-uuidv7
BenchmarkNext-8         21308299                53.93 ns/op            0 B/op          0 allocs/op
BenchmarkString-8       44208190                26.25 ns/op           48 B/op          1 allocs/op
BenchmarkParse-8        25415180                46.92 ns/op            0 B/op          0 allocs/op
PASS
ok      github.com/janetechinc/ads-uuidv7       4.701s

About

Go UUIDv7 implementation

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Go 100.0%