// NewDeleteJobSyncer returns a job syncer for hard deletion job. The job which removes the backup
// from remote storage.
NewDeleteJobSyncer returns a job syncer for hard deletion job. The job which removes the backup
from remote storage.
// NewDeleteJobSyncer returns a job syncer for hard deletion job . The job which removes the backup // from remote storage .
func NewDeleteJobSyncer(c client.Client, s *runtime.Scheme, backup *mysqlbackup.MysqlBackup,
	cluster *mysqlcluster.MysqlCluster, opt *options.Options, r record.EventRecorder) syncer.Interface {
	job := &batch.Job{
		ObjectMeta: metav1.ObjectMeta{
			Name:      backup.GetNameForDeletionJob(),
			Namespace: backup.Namespace,
		},
	}
	jobSyncer := deletionJobSyncer{
		cluster:  cluster,
		backup:   backup,
		opt:      opt,
		schema:   s,
		recorder: r,
	}
	return syncer.NewObjectSyncer("BackupCleaner", nil, job, c, func() error {
		return jobSyncer.SyncFn(job)
	})
}
func NewDeleteJobSyncer ( c client . Client , s * runtime . Scheme , backup * mysqlbackup . MysqlBackup , cluster * mysqlcluster . MysqlCluster , opt * options . Options , r record . EventRecorder ) syncer . Interface { job := & batch . Job { ObjectMeta : metav1 . ObjectMeta { Name : backup . GetNameForDeletionJob ( ) , Namespace : backup . Namespace , } , } jobSyncer := deletionJobSyncer { cluster : cluster , backup : backup , opt : opt , schema : s , recorder : r , } return syncer . NewObjectSyncer ( " " , nil , job , c , func ( ) error { return jobSyncer . SyncFn ( job ) } ) }
NewDeleteJobSyncer returns a job syncer for hard deletion job.
NewDeleteJobSyncer returns a job syncer for hard deletion job .