code: func ValidateNode(node *core.Node) field.ErrorList {
  	fldPath := field.NewPath("metadata")
  	allErrs := ValidateObjectMeta(&node.ObjectMeta, false, ValidateNodeName, fldPath)
  	allErrs = append(allErrs, ValidateNodeSpecificAnnotations(node.ObjectMeta.Annotations, fldPath.Child("annotations"))...)
  	if len(node.Spec.Taints) > 0 {
  		allErrs = append(allErrs, validateNodeTaints(node.Spec.Taints, fldPath.Child("taints"))...)
  	}
  
  	// Only validate spec.
  	// All status fields are optional and can be updated later.
  	// That said, if specified, we need to ensure they are valid.
  	allErrs = append(allErrs, ValidateNodeResources(node)...)
  
  	if len(node.Spec.PodCIDR) != 0 {
  		_, err := ValidateCIDR(node.Spec.PodCIDR)
  		if err != nil {
  			allErrs = append(allErrs, field.Invalid(field.NewPath("spec", "podCIDR"), node.Spec.PodCIDR, "not a valid CIDR"))
  		}
  	}
  	return allErrs
  }
docs: // ValidateNode tests if required fields in the node are set.