Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 11 for validateAnnotations (0.81 sec)

  1. staging/src/k8s.io/apiserver/pkg/admission/audit_test.go

    		annotations := make(map[string]string, len(tc.admitAnnotations)+len(tc.validateAnnotations))
    		for k, v := range tc.admitAnnotations {
    			annotations[k] = v
    		}
    		for k, v := range tc.validateAnnotations {
    			annotations[k] = v
    		}
    		if len(annotations) == 0 {
    			assert.Nil(t, ae.Annotations, tcName+": unexptected annotations set in audit event")
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Jul 03 16:16:51 UTC 2023
    - 5.8K bytes
    - Viewed (0)
  2. platforms/jvm/language-java/src/main/java/org/gradle/api/internal/tasks/compile/processing/AggregatingProcessingStrategy.java

        public void recordProcessingInputs(Set<String> supportedAnnotationTypes, Set<? extends TypeElement> annotations, RoundEnvironment roundEnv) {
            validateAnnotations(annotations);
            recordAggregatedTypes(supportedAnnotationTypes, annotations, roundEnv);
        }
    
        private void validateAnnotations(Set<? extends TypeElement> annotations) {
            for (TypeElement annotation : annotations) {
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Tue Aug 29 15:12:07 UTC 2023
    - 4.1K bytes
    - Viewed (0)
  3. staging/src/k8s.io/apimachinery/pkg/api/validation/objectmeta.go

    var BannedOwners = map[schema.GroupVersionKind]struct{}{
    	{Group: "", Version: "v1", Kind: "Event"}: {},
    }
    
    // ValidateAnnotations validates that a set of annotations are correctly defined.
    func ValidateAnnotations(annotations map[string]string, fldPath *field.Path) field.ErrorList {
    	allErrs := field.ErrorList{}
    	for k := range annotations {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Sep 07 03:12:31 UTC 2022
    - 12K bytes
    - Viewed (0)
  4. staging/src/k8s.io/apimachinery/pkg/api/validation/objectmeta_test.go

    		{
    			"a": strings.Repeat("b", TotalAnnotationSizeLimitB/2-1),
    			"c": strings.Repeat("d", TotalAnnotationSizeLimitB/2-1),
    		},
    	}
    	for i := range successCases {
    		errs := ValidateAnnotations(successCases[i], field.NewPath("field"))
    		if len(errs) != 0 {
    			t.Errorf("case[%d] expected success, got %#v", i, errs)
    		}
    	}
    
    	nameErrorCases := []struct {
    		annotations map[string]string
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Sep 07 03:12:31 UTC 2022
    - 17.8K bytes
    - Viewed (0)
  5. staging/src/k8s.io/apiserver/pkg/storage/value/encrypt/envelope/kmsv2/envelope.go

    	}
    	return nil
    }
    
    // validateAnnotations tests the following:
    //  1. checks if the annotation key is fully qualified
    //  2. The size of annotations keys + values is less than 32 kB.
    func validateAnnotations(annotations map[string][]byte) error {
    	var errs []error
    	var totalSize uint64
    	for k, v := range annotations {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Oct 27 00:23:50 UTC 2023
    - 18.7K bytes
    - Viewed (0)
  6. pkg/kube/inject/validate.go

    	if err := protomarshal.ApplyYAML(value, config); err != nil {
    		return fmt.Errorf("failed to convert to apply proxy config: %v", err)
    	}
    	return agent.ValidateMeshConfigProxyConfig(config)
    }
    
    func validateAnnotations(annotations map[string]string) (err error) {
    	for name, value := range annotations {
    		if v, ok := AnnotationValidation[name]; ok {
    			if e := v(value); e != nil {
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Wed Apr 17 20:06:41 UTC 2024
    - 5.9K bytes
    - Viewed (0)
  7. staging/src/k8s.io/apiserver/pkg/storage/value/encrypt/envelope/kmsv2/envelope_test.go

    	}
    	t.Run("success", func(t *testing.T) {
    		for i := range successCases {
    			i := i
    			t.Run(fmt.Sprintf("%d", i), func(t *testing.T) {
    				t.Parallel()
    				if err := validateAnnotations(successCases[i]); err != nil {
    					t.Errorf("case[%d] expected success, got %#v", i, err)
    				}
    			})
    		}
    	})
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Oct 25 16:50:20 UTC 2023
    - 47.2K bytes
    - Viewed (0)
  8. pkg/apis/apps/validation/validation.go

    		allErrs = append(allErrs, unversionedvalidation.ValidateLabels(template.Labels, fldPath.Child("labels"))...)
    		allErrs = append(allErrs, apivalidation.ValidateAnnotations(template.Annotations, fldPath.Child("annotations"))...)
    		allErrs = append(allErrs, apivalidation.ValidatePodSpecificAnnotations(template.Annotations, &template.Spec, fldPath.Child("annotations"), opts)...)
    	}
    	return allErrs
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sat Apr 06 22:11:20 UTC 2024
    - 41.4K bytes
    - Viewed (0)
  9. staging/src/k8s.io/apiextensions-apiserver/pkg/apiserver/conversion/webhook_converter.go

    			}
    			var errs field.ErrorList
    			if fld == "labels" {
    				errs = metav1validation.ValidateLabels(stringMap, field.NewPath("metadata", "labels"))
    			} else {
    				errs = apivalidation.ValidateAnnotations(stringMap, field.NewPath("metadata", "annotation"))
    			}
    			if len(errs) > 0 {
    				return errs.ToAggregate()
    			}
    		}
    
    		convertedMetaData[fld] = responseField
    	}
    
    	return nil
    }
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Jun 07 19:37:55 UTC 2023
    - 20.6K bytes
    - Viewed (0)
  10. pkg/kube/inject/inject.go

    func RunTemplate(params InjectionParameters) (mergedPod *corev1.Pod, templatePod *corev1.Pod, err error) {
    	metadata := &params.pod.ObjectMeta
    	meshConfig := params.meshConfig
    
    	if err := validateAnnotations(metadata.GetAnnotations()); err != nil {
    		log.Errorf("Injection failed due to invalid annotations: %v", err)
    		return nil, nil, err
    	}
    
    	cluster, network := extractClusterAndNetwork(params)
    
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Fri May 31 20:35:11 UTC 2024
    - 28.8K bytes
    - Viewed (0)
Back to top