Skip to content

Commit

Permalink
refactor: exact match based on sidecar name
Browse files Browse the repository at this point in the history
  • Loading branch information
l-qing committed Jun 6, 2024
1 parent 54fd9fd commit e8d6be4
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion pkg/pod/status.go
Original file line number Diff line number Diff line change
Expand Up @@ -633,7 +633,9 @@ func areContainersCompleted(ctx context.Context, pod *corev1.Pod) bool {
if config.FromContextOrDefaults(ctx).FeatureFlags.ResultExtractionMethod == config.ResultExtractionMethodSidecarLogs {
// If we are using sidecar logs to extract results, we need to wait for the sidecar to complete.
// Avoid failing to obtain the final result from the sidecar because the sidecar is not yet complete.
nameFilters = append(nameFilters, IsContainerSidecar)
nameFilters = append(nameFilters, func(name string) bool {
return name == pipeline.ReservedResultsSidecarContainerName
})
}
return checkContainersCompleted(pod, nameFilters)
}
Expand Down

0 comments on commit e8d6be4

Please sign in to comment.