Skip to content

Commit

Permalink
fix: clean cron implem refacto (#14)
Browse files Browse the repository at this point in the history
  • Loading branch information
devthejo authored Jul 1, 2024
2 parents fb994ce + 409c67d commit f6ad4c8
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 8 deletions.
6 changes: 1 addition & 5 deletions pkg/config/load-cfg.go
Original file line number Diff line number Diff line change
@@ -1,18 +1,14 @@
package config

import (
"time"

"github.com/SocialGouv/oblik/pkg/calculator"
"k8s.io/apimachinery/pkg/api/resource"
vpa "k8s.io/autoscaler/vertical-pod-autoscaler/pkg/apis/autoscaling.k8s.io/v1"
"k8s.io/klog/v2"
)

type LoadCfg struct {
Key string
CronExpr string
CronMaxRandomDelay time.Duration
Key string

RequestCPUApplyMode *ApplyMode
RequestMemoryApplyMode *ApplyMode
Expand Down
8 changes: 5 additions & 3 deletions pkg/config/vpa-workload-cfg.go
Original file line number Diff line number Diff line change
Expand Up @@ -59,10 +59,12 @@ func CreateVpaWorkloadCfg(vpaResource *vpa.VerticalPodAutoscaler) *VpaWorkloadCf
}

type VpaWorkloadCfg struct {
Key string
Key string
CronExpr string
CronMaxRandomDelay time.Duration
DryRun bool
Containers map[string]*VpaContainerCfg
*LoadCfg
Containers map[string]*VpaContainerCfg
DryRun bool
}

func (v *VpaWorkloadCfg) GetDryRun() bool {
Expand Down

0 comments on commit f6ad4c8

Please sign in to comment.