@@ -128,21 +128,21 @@ func (p *SchedulerProfile) Run(ctx context.Context, request *types.LLMRequest, c
128128}
129129
130130func (p * SchedulerProfile ) runFilterPlugins (ctx context.Context , request * types.LLMRequest , cycleState * types.CycleState , pods []types.Pod ) []types.Pod {
131- loggerDebug := log .FromContext (ctx ). V ( logutil . DEBUG )
131+ logger := log .FromContext (ctx )
132132 filteredPods := pods
133- loggerDebug .Info ("Before running filter plugins" , "pods" , filteredPods )
133+ logger . V ( logutil . DEBUG ) .Info ("Before running filter plugins" , "pods" , filteredPods )
134134
135135 for _ , filter := range p .filters {
136- loggerDebug .Info ("Running filter plugin" , "plugin" , filter .TypedName ())
136+ logger . V ( logutil . VERBOSE ) .Info ("Running filter plugin" , "plugin" , filter .TypedName ())
137137 before := time .Now ()
138138 filteredPods = filter .Filter (ctx , cycleState , request , filteredPods )
139139 metrics .RecordPluginProcessingLatency (FilterExtensionPoint , filter .TypedName ().Type , filter .TypedName ().Name , time .Since (before ))
140- loggerDebug .Info ("Completed running filter plugin successfully" , "plugin" , filter .TypedName (), "pods" , filteredPods )
140+ logger . V ( logutil . DEBUG ) .Info ("Completed running filter plugin successfully" , "plugin" , filter .TypedName (), "pods" , filteredPods )
141141 if len (filteredPods ) == 0 {
142142 break
143143 }
144144 }
145- loggerDebug .Info ("Completed running filter plugins successfully" )
145+ logger . V ( logutil . VERBOSE ) .Info ("Completed running filter plugins successfully" )
146146
147147 return filteredPods
148148}
@@ -157,7 +157,7 @@ func (p *SchedulerProfile) runScorerPlugins(ctx context.Context, request *types.
157157 }
158158 // Iterate through each scorer in the chain and accumulate the weighted scores.
159159 for _ , scorer := range p .scorers {
160- logger .V (logutil .DEBUG ).Info ("Running scorer plugin" , "plugin" , scorer .TypedName ())
160+ logger .V (logutil .VERBOSE ).Info ("Running scorer plugin" , "plugin" , scorer .TypedName ())
161161 before := time .Now ()
162162 scores := scorer .Score (ctx , cycleState , request , pods )
163163 metrics .RecordPluginProcessingLatency (ScorerExtensionPoint , scorer .TypedName ().Type , scorer .TypedName ().Name , time .Since (before ))
@@ -167,25 +167,25 @@ func (p *SchedulerProfile) runScorerPlugins(ctx context.Context, request *types.
167167 }
168168 logger .V (logutil .DEBUG ).Info ("Completed running scorer plugin successfully" , "plugin" , scorer .TypedName ())
169169 }
170- logger .V (logutil .DEBUG ).Info ("Completed running scorer plugins successfully" )
170+ logger .V (logutil .VERBOSE ).Info ("Completed running scorer plugins successfully" )
171171
172172 return weightedScorePerPod
173173}
174174
175175func (p * SchedulerProfile ) runPickerPlugin (ctx context.Context , cycleState * types.CycleState , weightedScorePerPod map [types.Pod ]float64 ) * types.ProfileRunResult {
176- loggerDebug := log .FromContext (ctx ). V ( logutil . DEBUG )
176+ logger := log .FromContext (ctx )
177177 scoredPods := make ([]* types.ScoredPod , len (weightedScorePerPod ))
178178 i := 0
179179 for pod , score := range weightedScorePerPod {
180180 scoredPods [i ] = & types.ScoredPod {Pod : pod , Score : score }
181181 i ++
182182 }
183-
184- loggerDebug . Info ("Running picker plugin" , "plugin" , p . picker . TypedName (), "pods-weighted-score" , weightedScorePerPod )
183+ logger . V ( logutil . VERBOSE ). Info ( "Running picker plugin" , "plugin" , p . picker . TypedName ())
184+ logger . V ( logutil . DEBUG ). Info ("Candidate pods for picking" , "pods-weighted-score" , scoredPods )
185185 before := time .Now ()
186186 result := p .picker .Pick (ctx , cycleState , scoredPods )
187187 metrics .RecordPluginProcessingLatency (PickerExtensionPoint , p .picker .TypedName ().Type , p .picker .TypedName ().Name , time .Since (before ))
188- loggerDebug .Info ("Completed running picker plugin successfully" , "plugin" , p .picker .TypedName (), "result" , result )
188+ logger . V ( logutil . DEBUG ) .Info ("Completed running picker plugin successfully" , "plugin" , p .picker .TypedName (), "result" , result )
189189
190190 return result
191191}
0 commit comments