mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-01 15:58:37 +00:00
Merge pull request #50213 from zhangxiaoyu-zidif/fix-comment-cronjob-utils
Automatic merge from submit-queue (batch tested with PRs 50213, 50707, 49502, 51230, 50848) Fix comment of cronjob utils.go **What this PR does / why we need it**: **Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes https://github.com/kubernetes/kubernetes/issues/50951 **Special notes for your reviewer**: **Release note**: ```release-note NONE ```
This commit is contained in:
commit
1d5b365ed5
@ -169,8 +169,6 @@ func getRecentUnmetScheduleTimes(sj batchv2alpha1.CronJob, now time.Time) ([]tim
|
|||||||
return starts, nil
|
return starts, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// XXX unit test this
|
|
||||||
|
|
||||||
// getJobFromTemplate makes a Job from a CronJob
|
// getJobFromTemplate makes a Job from a CronJob
|
||||||
func getJobFromTemplate(sj *batchv2alpha1.CronJob, scheduledTime time.Time) (*batchv1.Job, error) {
|
func getJobFromTemplate(sj *batchv2alpha1.CronJob, scheduledTime time.Time) (*batchv1.Job, error) {
|
||||||
// TODO: consider adding the following labels:
|
// TODO: consider adding the following labels:
|
||||||
@ -200,7 +198,7 @@ func getJobFromTemplate(sj *batchv2alpha1.CronJob, scheduledTime time.Time) (*ba
|
|||||||
return job, nil
|
return job, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// Return Unix Epoch Time
|
// getTimeHash returns Unix Epoch Time
|
||||||
func getTimeHash(scheduledTime time.Time) int64 {
|
func getTimeHash(scheduledTime time.Time) int64 {
|
||||||
return scheduledTime.Unix()
|
return scheduledTime.Unix()
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user