Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 14 for IsExtendedResourceName (0.41 sec)

  1. plugin/pkg/admission/extendedresourcetoleration/admission.go

    		for resourceName := range container.Resources.Requests {
    			if helper.IsExtendedResourceName(resourceName) {
    				resources.Insert(string(resourceName))
    			}
    		}
    	}
    	for _, container := range pod.Spec.InitContainers {
    		for resourceName := range container.Resources.Requests {
    			if helper.IsExtendedResourceName(resourceName) {
    				resources.Insert(string(resourceName))
    			}
    		}
    	}
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Aug 20 15:11:00 UTC 2019
    - 3.1K bytes
    - Viewed (0)
  2. pkg/apis/core/helper/helpers.go

    }
    
    // IsExtendedResourceName returns true if:
    // 1. the resource name is not in the default namespace;
    // 2. resource name does not have "requests." prefix,
    // to avoid confusion with the convention in quota
    // 3. it satisfies the rules in IsQualifiedName() after converted into quota resource name
    func IsExtendedResourceName(name core.ResourceName) bool {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sat Oct 28 07:31:28 UTC 2023
    - 16.1K bytes
    - Viewed (0)
  3. pkg/kubelet/cm/devicemanager/plugin/v1beta1/handler.go

    	if !s.isVersionCompatibleWithPlugin(versions...) {
    		return fmt.Errorf("manager version, %s, is not among plugin supported versions %v", api.Version, versions)
    	}
    
    	if !v1helper.IsExtendedResourceName(core.ResourceName(pluginName)) {
    		return fmt.Errorf("invalid name of device plugin socket: %s", fmt.Sprintf(errInvalidResourceName, pluginName))
    	}
    
    	return nil
    }
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sat Mar 16 14:21:15 UTC 2024
    - 3.3K bytes
    - Viewed (0)
  4. pkg/apis/core/v1/helper/helpers.go

    	"k8s.io/kubernetes/pkg/apis/core/helper"
    )
    
    // IsExtendedResourceName returns true if:
    // 1. the resource name is not in the default namespace;
    // 2. resource name does not have "requests." prefix,
    // to avoid confusion with the convention in quota
    // 3. it satisfies the rules in IsQualifiedName() after converted into quota resource name
    func IsExtendedResourceName(name v1.ResourceName) bool {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu May 30 23:03:54 UTC 2024
    - 11.4K bytes
    - Viewed (0)
  5. pkg/kubelet/cm/devicemanager/plugin/v1beta1/server.go

    		klog.InfoS("Bad registration request from device plugin with resource", "resourceName", r.ResourceName, "err", err)
    		return &api.Empty{}, err
    	}
    
    	if !v1helper.IsExtendedResourceName(core.ResourceName(r.ResourceName)) {
    		err := fmt.Errorf(errInvalidResourceName, r.ResourceName)
    		klog.InfoS("Bad registration request from device plugin", "err", err)
    		return &api.Empty{}, err
    	}
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sat Jan 27 02:10:25 UTC 2024
    - 5.4K bytes
    - Viewed (0)
  6. pkg/scheduler/util/utils.go

    }
    
    // IsScalarResourceName validates the resource for Extended, Hugepages, Native and AttachableVolume resources
    func IsScalarResourceName(name v1.ResourceName) bool {
    	return v1helper.IsExtendedResourceName(name) || v1helper.IsHugePageResourceName(name) ||
    		v1helper.IsPrefixedNativeResource(name) || v1helper.IsAttachableVolumeResourceName(name)
    }
    
    // As converts two objects to the given type.
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Sep 21 01:40:44 UTC 2023
    - 6.2K bytes
    - Viewed (0)
  7. pkg/apis/core/v1/validation/validation.go

    			return append(allErrs, field.Invalid(fldPath, value, "must be a standard resource for containers"))
    		}
    	} else if !v1helper.IsNativeResource(v1.ResourceName(value)) {
    		if !v1helper.IsExtendedResourceName(v1.ResourceName(value)) {
    			return append(allErrs, field.Invalid(fldPath, value, "doesn't follow extended resource name standard"))
    		}
    	}
    	return allErrs
    }
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sat Oct 28 07:31:28 UTC 2023
    - 6.7K bytes
    - Viewed (0)
  8. pkg/kubelet/lifecycle/predicate.go

    		// does not use Limits.
    		podCopy.Spec.Containers[i].Resources.Requests = make(v1.ResourceList)
    		for rName, rQuant := range c.Resources.Requests {
    			if v1helper.IsExtendedResourceName(rName) {
    				if _, found := nodeInfo.Allocatable.ScalarResources[rName]; !found {
    					continue
    				}
    			}
    			podCopy.Spec.Containers[i].Resources.Requests[rName] = rQuant
    		}
    	}
    	return podCopy
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Oct 19 00:47:50 UTC 2023
    - 10.9K bytes
    - Viewed (0)
  9. pkg/scheduler/apis/config/validation/validation.go

    		validationErrors = append(validationErrors, field.Invalid(path, name, msg))
    	}
    	if len(validationErrors) != 0 {
    		return validationErrors
    	}
    	if !v1helper.IsExtendedResourceName(name) {
    		validationErrors = append(validationErrors, field.Invalid(path, string(name), "is an invalid extended resource name"))
    	}
    	return validationErrors
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Apr 25 06:27:01 UTC 2024
    - 11.5K bytes
    - Viewed (0)
  10. pkg/quota/v1/evaluator/core/pods.go

    			result[resource] = request
    			result[maskResourceWithPrefix(resource, corev1.DefaultResourceRequestsPrefix)] = request
    		}
    		// for extended resources
    		if helper.IsExtendedResourceName(resource) {
    			// only quota objects in format of "requests.resourceName" is allowed for extended resource.
    			result[maskResourceWithPrefix(resource, corev1.DefaultResourceRequestsPrefix)] = request
    		}
    	}
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri May 05 00:02:47 UTC 2023
    - 17.4K bytes
    - Viewed (0)
Back to top