File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
src/supervisor/watchers/handlers Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -69,7 +69,7 @@ function handleReadyPod(workloadMetadata: IWorkload[]): void {
6969 const imagesToScan : IWorkload [ ] = [ ] ;
7070 const imageKeys : string [ ] = [ ] ;
7171 for ( const image of workloadMetadata ) {
72- const imageKey = `${ image . namespace } /${ image . type } /${ image . name } /${ image . imageId } ` ;
72+ const imageKey = `${ image . namespace } /${ image . type } /${ image . uid } /${ image . imageId } ` ;
7373 if ( state . imagesAlreadyScanned . get ( imageKey ) !== undefined ) {
7474 continue ;
7575 }
@@ -110,7 +110,7 @@ export async function podWatchHandler(pod: V1Pod): Promise<void> {
110110 const workloadMember = workloadMetadata [ 0 ] ;
111111 const workloadMetadataPayload = constructWorkloadMetadata ( workloadMember ) ;
112112 const workloadLocator = workloadMetadataPayload . workloadLocator ;
113- const workloadKey = `${ workloadLocator . namespace } /${ workloadLocator . type } /${ workloadLocator . name } ` ;
113+ const workloadKey = `${ workloadLocator . namespace } /${ workloadLocator . type } /${ workloadMember . uid } ` ;
114114 const workloadRevision = workloadMember . revision ? workloadMember . revision . toString ( ) : '' ; // this is actually the observed generation
115115 if ( state . workloadsAlreadyScanned . get ( workloadKey ) !== workloadRevision ) { // either not exists or different
116116 state . workloadsAlreadyScanned . set ( workloadKey , workloadRevision ) ; // empty string takes zero bytes and is !== undefined
You can’t perform that action at this time.
0 commit comments