diff --git a/cmd/serve.go b/cmd/serve.go index c6742b2..4d247e4 100644 --- a/cmd/serve.go +++ b/cmd/serve.go @@ -115,50 +115,6 @@ var serveCmd = &cobra.Command{ if err != nil { log.Printf("failed to enqueue bootstrap_bastion: %v", err) } - - /* - _, err = jobs.Enqueue( - context.Background(), - uuid.NewString(), - "prepare_cluster", - bg.ClusterPrepareArgs{IntervalS: 120}, - archer.WithMaxRetries(3), - archer.WithScheduleTime(time.Now().Add(60*time.Second)), - ) - if err != nil { - log.Printf("failed to enqueue prepare_cluster: %v", err) - } - - _, err = jobs.Enqueue( - context.Background(), - uuid.NewString(), - "cluster_setup", - bg.ClusterSetupArgs{ - IntervalS: 120, - }, - archer.WithMaxRetries(3), - archer.WithScheduleTime(time.Now().Add(60*time.Second)), - ) - - if err != nil { - log.Printf("failed to enqueue cluster setup: %v", err) - } - - _, err = jobs.Enqueue( - context.Background(), - uuid.NewString(), - "cluster_bootstrap", - bg.ClusterBootstrapArgs{ - IntervalS: 120, - }, - archer.WithMaxRetries(3), - archer.WithScheduleTime(time.Now().Add(60*time.Second)), - ) - if err != nil { - log.Printf("failed to enqueue cluster bootstrap: %v", err) - } - */ - _, err = jobs.Enqueue( context.Background(), uuid.NewString(), diff --git a/go.mod b/go.mod index ad17b05..ab18964 100644 --- a/go.mod +++ b/go.mod @@ -116,10 +116,8 @@ require ( github.com/xi2/xz v0.0.0-20171230120015-48954b6210f8 // indirect github.com/zeebo/xxh3 v1.0.2 // indirect go.mongodb.org/mongo-driver/v2 v2.5.0 // indirect - go.uber.org/mock v0.6.0 // indirect go.yaml.in/yaml/v3 v3.0.4 // indirect golang.org/x/arch v0.22.0 // indirect - golang.org/x/mod v0.32.0 // indirect golang.org/x/net v0.51.0 // indirect golang.org/x/sync v0.19.0 // indirect golang.org/x/sys v0.41.0 // indirect diff --git a/internal/bg/bg.go b/internal/bg/bg.go index 2c533fd..ff8b0b7 100644 --- a/internal/bg/bg.go +++ b/internal/bg/bg.go @@ -107,30 +107,6 @@ func NewJobs(gdb *gorm.DB, dbUrl, baseURL string) (*Jobs, error) { archer.WithInstances(1), archer.WithTimeout(2*time.Minute), ) - /* - c.Register( - "prepare_cluster", - ClusterPrepareWorker(gdb, jobs), - archer.WithInstances(1), - archer.WithTimeout(2*time.Minute), - ) - - c.Register( - "cluster_setup", - ClusterSetupWorker(gdb, jobs), - archer.WithInstances(1), - archer.WithTimeout(2*time.Minute), - ) - - c.Register( - "cluster_bootstrap", - ClusterBootstrapWorker(gdb, jobs), - archer.WithInstances(1), - archer.WithTimeout(60*time.Minute), - ) - - */ - c.Register( "org_key_sweeper", OrgKeySweeperWorker(gdb, jobs), @@ -141,7 +117,7 @@ func NewJobs(gdb *gorm.DB, dbUrl, baseURL string) (*Jobs, error) { c.Register( "cluster_action", ClusterActionWorker(gdb, baseURL), - archer.WithInstances(1), + archer.WithInstances(30), ) return jobs, nil }