chenyulin0719 commented on code in PR #808:
URL: https://github.com/apache/yunikorn-k8shim/pull/808#discussion_r1595344530


##########
pkg/common/utils/utils.go:
##########
@@ -373,10 +373,27 @@ func GetPlaceholderFlagFromPodSpec(pod *v1.Pod) bool {
                }
        }
 
-       if value := GetPodLabelValue(pod, constants.LabelPlaceholderFlag); 
value != "" {
+       // Deprecated: Support for old placeholder flags should be removed in 
version 1.7.0.
+       if value := GetPodAnnotationValue(pod, 
constants.OldAnnotationPlaceholderFlag); value != "" { // nolint:staticcheck
                if v, err := strconv.ParseBool(value); err == nil {
+                       log.Log(log.ShimUtils).Warn("Using deprecated 
placeholder annotation. The support for old placeholder flag will be removed in 
version 1.7.0",

Review Comment:
   @chia7712 Thanks for the review.  However, I still think we should print a 
warning only if the placeholder tag is from the deprecated label or annotation. 
 If the input is invalid, it's simply ignored, no need to warn users that we're 
using deprecated ones.  



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to