@@ -215,19 +215,21 @@ func (r *BatchJobReconciler) desiredEnqueuerJob(batchJob batch.BatchJob, queueUR
215215 Namespace : batchJob .Namespace ,
216216 Parallelism : 1 ,
217217 Labels : map [string ]string {
218- "apiKind" : userconfig .BatchAPIKind .String (),
219- "apiName" : batchJob .Spec .APIName ,
220- "apiID" : batchJob .Spec .APIID ,
221- "jobID" : batchJob .Name ,
222- "cortex.dev/api" : "true" ,
218+ "apiKind" : userconfig .BatchAPIKind .String (),
219+ "apiName" : batchJob .Spec .APIName ,
220+ "apiID" : batchJob .Spec .APIID ,
221+ "jobID" : batchJob .Name ,
222+ "cortex.dev/api" : "true" ,
223+ "cortex.dev/batch" : "enqueuer" ,
223224 },
224225 PodSpec : k8s.PodSpec {
225226 Labels : map [string ]string {
226- "apiKind" : userconfig .BatchAPIKind .String (),
227- "apiName" : batchJob .Spec .APIName ,
228- "apiID" : batchJob .Spec .APIID ,
229- "jobID" : batchJob .Name ,
230- "cortex.dev/api" : "true" ,
227+ "apiKind" : userconfig .BatchAPIKind .String (),
228+ "apiName" : batchJob .Spec .APIName ,
229+ "apiID" : batchJob .Spec .APIID ,
230+ "jobID" : batchJob .Name ,
231+ "cortex.dev/api" : "true" ,
232+ "cortex.dev/batch" : "enqueuer" ,
231233 },
232234 Annotations : map [string ]string {
233235 "traffic.sidecar.istio.io/excludeOutboundIPRanges" : "0.0.0.0/0" ,
@@ -294,23 +296,25 @@ func (r *BatchJobReconciler) desiredWorkerJob(batchJob batch.BatchJob, apiSpec s
294296 Namespace : batchJob .Namespace ,
295297 Parallelism : batchJob .Spec .Workers ,
296298 Labels : map [string ]string {
297- "apiKind" : userconfig .BatchAPIKind .String (),
298- "apiName" : batchJob .Spec .APIName ,
299- "apiID" : batchJob .Spec .APIID ,
300- "specID" : apiSpec .SpecID ,
301- "handlerID" : apiSpec .HandlerID ,
302- "jobID" : batchJob .Name ,
303- "cortex.dev/api" : "true" ,
299+ "apiKind" : userconfig .BatchAPIKind .String (),
300+ "apiName" : batchJob .Spec .APIName ,
301+ "apiID" : batchJob .Spec .APIID ,
302+ "specID" : apiSpec .SpecID ,
303+ "handlerID" : apiSpec .HandlerID ,
304+ "jobID" : batchJob .Name ,
305+ "cortex.dev/api" : "true" ,
306+ "cortex.dev/batch" : "worker" ,
304307 },
305308 PodSpec : k8s.PodSpec {
306309 Labels : map [string ]string {
307- "apiKind" : userconfig .BatchAPIKind .String (),
308- "apiName" : batchJob .Spec .APIName ,
309- "apiID" : batchJob .Spec .APIID ,
310- "specID" : apiSpec .SpecID ,
311- "handlerID" : apiSpec .HandlerID ,
312- "jobID" : batchJob .Name ,
313- "cortex.dev/api" : "true" ,
310+ "apiKind" : userconfig .BatchAPIKind .String (),
311+ "apiName" : batchJob .Spec .APIName ,
312+ "apiID" : batchJob .Spec .APIID ,
313+ "specID" : apiSpec .SpecID ,
314+ "handlerID" : apiSpec .HandlerID ,
315+ "jobID" : batchJob .Name ,
316+ "cortex.dev/api" : "true" ,
317+ "cortex.dev/batch" : "worker" ,
314318 },
315319 Annotations : map [string ]string {
316320 "traffic.sidecar.istio.io/excludeOutboundIPRanges" : "0.0.0.0/0" ,
0 commit comments