Skip to content

Commit

Permalink
fix: prevent false duplicate job error
Browse files Browse the repository at this point in the history
  • Loading branch information
msvticket committed Jan 4, 2024
1 parent f6279b4 commit a132f2c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions pkg/config/job/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -161,9 +161,9 @@ func (c *Config) Validate(lh lighthouse.Config) error {
validPeriodics := sets.NewString()
// Ensure that the periodic durations are valid and specs exist.
for _, p := range c.Periodics {
if validPeriodics.Has(p.Name) {
return fmt.Errorf("duplicated periodic job : %s", p.Name)
}
//if validPeriodics.Has(p.Name) {
// return fmt.Errorf("duplicated periodic job : %s", p.Name)
//}
validPeriodics.Insert(p.Name)
if err := p.Base.Validate(PeriodicJob, lh.PodNamespace); err != nil {
return fmt.Errorf("invalid periodic job %s: %v", p.Name, err)
Expand Down

0 comments on commit a132f2c

Please sign in to comment.