kubernetes/kops · error

not all objects were applied

Error message

not all objects were applied

What it means

ClientApplier.Apply checks the applyset results after ApplyOnce: every object must report applied. If any object did not reach the applied state (even without a hard error from ApplyOnce), this error is returned. It means the manifest was only partially or not at all materialized on the cluster.

Source

Thrown at channels/pkg/channels/clientapplier.go:80

	}

	var applyableObjects []applyset.ApplyableObject
	for _, object := range objects {
		applyableObjects = append(applyableObjects, object)
	}
	if err := s.SetDesiredObjects(applyableObjects); err != nil {
		return err
	}

	results, err := s.ApplyOnce(ctx)
	if err != nil {
		return fmt.Errorf("failed to apply objects: %w", err)
	}

	// TODO: Implement pruning

	if !results.AllApplied() {
		return fmt.Errorf("not all objects were applied")
	}

	// TODO: Check object health status
	if !results.AllHealthy() {
		return fmt.Errorf("not all objects were healthy")
	}

	return nil
}

View on GitHub (pinned to 4c8573c808)

Solutions

  1. Inspect applyset per-object results/logs to find which objects were not applied.
  2. Re-run Apply — partial failures are often resolved by a retry.
  3. Fix RBAC/validation issues reported for the specific failing objects.
  4. Check API server and admission webhook logs for rejections during the apply.

Example fix

// before
if err := applier.Apply(ctx, manifest); err != nil { return err }
// after
if err := applier.Apply(ctx, manifest); err != nil {
    if err.Error() == "not all objects were applied" {
        return retryApplyWithBackoff(ctx, applier, manifest)
    }
    return err
}
Defensive patterns

Strategy: retry

Type guard

func isPartialApply(err error) bool {
    return strings.Contains(err.Error(), "not all objects were applied")
}

Try / catch

err := applier.Apply(ctx, manifest)
if isPartialApply(err) {
    return retry.Do(func() error { return applier.Apply(ctx, manifest) },
        retry.Attempts(3), retry.Delay(time.Second))
}

Prevention

When it happens

Trigger: results.AllApplied() returning false after ApplyOnce — one or more objects in the manifest failed to apply without the overall apply returning a wrapped error.

Common situations: Partial applies where some objects hit per-object errors; race conditions or webhook rejections on individual objects; flaky API server responses during a large manifest apply.

Related errors


AI-assisted analysis of kubernetes/kops@4c8573c808 (2026-09-05). Data as JSON: /api/errors/db9d6218c7ca998e. Report an issue: GitHub.