Skip to content

Grading Checklist

  • Identifies label selector mismatch between the Service and the pods as the root cause.
  • Demonstrates how to compare service selector with pod labels using kubectl get svc, kubectl get pods --show-labels.
  • Explains that Kubernetes uses label selectors to populate the Endpoints object.
  • Shows the exact mismatch (e.g., app: user-svc vs. app: user-service).
  • Fixes the Service selector to match the actual pod labels (or vice versa).
  • Verifies the fix by checking that endpoints are now populated.
  • Mentions that kubectl get endpoints is the first diagnostic step for service connectivity issues.
  • Notes that readiness probe failures can also cause empty endpoints, and explains how to rule that out.
  • Suggests using kubectl describe svc to see the selector in one view.
  • Recommends using consistent labeling conventions to prevent recurrence.
  • Warns against editing pod labels directly; the fix should be in the Service manifest or Deployment template.