diff --git a/go.mod b/go.mod index 9fe8e9f36..bbdef7fc1 100644 --- a/go.mod +++ b/go.mod @@ -26,7 +26,6 @@ require ( github.com/golang-jwt/jwt/v5 v5.2.0 github.com/google/go-github/v57 v57.0.0 github.com/google/tink/go v1.7.0 - github.com/google/uuid v1.5.0 github.com/gorilla/securecookie v1.1.2 github.com/jellydator/ttlcache/v3 v3.1.1 github.com/joho/godotenv v1.5.1 @@ -102,6 +101,7 @@ require ( github.com/google/go-cmp v0.6.0 // indirect github.com/google/go-querystring v1.1.0 // indirect github.com/google/gofuzz v1.2.0 // indirect + github.com/google/uuid v1.5.0 // indirect github.com/hashicorp/go-cleanhttp v0.5.2 // indirect github.com/hashicorp/go-hclog v1.2.0 // indirect github.com/hashicorp/go-retryablehttp v0.7.4 // indirect diff --git a/pipeline/frontend/yaml/compiler/convert.go b/pipeline/frontend/yaml/compiler/convert.go index 93aa24dc8..07b1eec2b 100644 --- a/pipeline/frontend/yaml/compiler/convert.go +++ b/pipeline/frontend/yaml/compiler/convert.go @@ -20,7 +20,7 @@ import ( "path" "strings" - "github.com/google/uuid" + "github.com/oklog/ulid/v2" backend_types "go.woodpecker-ci.org/woodpecker/v2/pipeline/backend/types" "go.woodpecker-ci.org/woodpecker/v2/pipeline/frontend/metadata" @@ -31,7 +31,7 @@ import ( func (c *Compiler) createProcess(name string, container *yaml_types.Container, stepType backend_types.StepType) (*backend_types.Step, error) { var ( - uuid = uuid.New() + uuid = ulid.Make() detached bool workingdir string diff --git a/pipeline/pipeline.go b/pipeline/pipeline.go index 4c0ef2106..9d620eb38 100644 --- a/pipeline/pipeline.go +++ b/pipeline/pipeline.go @@ -21,7 +21,7 @@ import ( "sync" "time" - "github.com/google/uuid" + "github.com/oklog/ulid/v2" "github.com/rs/zerolog" "github.com/rs/zerolog/log" "golang.org/x/sync/errgroup" @@ -74,7 +74,7 @@ func New(spec *backend.Config, opts ...Option) *Runtime { r.Description = map[string]string{} r.spec = spec r.ctx = context.Background() - r.taskUUID = uuid.New().String() + r.taskUUID = ulid.Make().String() for _, opts := range opts { opts(r) }