Skip to content

Commit 527cec2

Browse files
committed
Init DiscardReserved cache for NodeResourceTopology plugin when DiscardReservedNodes option is true
Signed-off-by: pprokop <[email protected]>
1 parent 1631b42 commit 527cec2

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

pkg/noderesourcetopology/pluginhelpers.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,10 @@ func initNodeTopologyInformer(tcfg *apiconfig.NodeResourceTopologyMatchArgs, han
5151
topologyInformerFactory.Start(ctx.Done())
5252
topologyInformerFactory.WaitForCacheSync(ctx.Done())
5353

54+
if tcfg.DiscardReservedNodes {
55+
return nrtcache.NewDiscardReserved(nodeTopologyLister), nil
56+
}
57+
5458
if tcfg.CacheResyncPeriodSeconds <= 0 {
5559
return nrtcache.NewPassthrough(nodeTopologyLister), nil
5660
}

0 commit comments

Comments
 (0)