Question 133 of 997
Container OrchestrationhardMultiple ChoiceObjective-mapped

Kubernetes Job for Queue-Based Batch Processing

This KCNA practice question tests your understanding of container orchestration. Read the scenario carefully and evaluate each option against the stated constraints before committing to an answer. A key principle to apply: job. Once you have made your selection, read the full explanation to reinforce the concept and understand why each distractor is designed to mislead on exam day.

You need to deploy a batch job that processes a queue and runs to completion. The job should run exactly once and create exactly one pod per work item, but some items may fail. Which Kubernetes resource is best suited?

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

Job

A Kubernetes Job is the correct resource for batch processing tasks that run to completion, such as processing a queue where each work item corresponds to a pod. By configuring the `.spec.completions` and `.spec.parallelism` fields, you can ensure exactly one pod per work item and control concurrency. The Job automatically retries failed pods (up to a configurable limit) without restarting the entire batch, making it ideal for handling some failures. In contrast, a Deployment (A) is for long-running, continuously available services; a CronJob (C) is for scheduled recurring jobs; and a DaemonSet (D) runs a pod on every node for infrastructure tasks. Therefore, Job (B) is the best fit.

Key principle: Job

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • Deployment

    Why it's wrong here

    Deployments are for long-running services, not batch jobs that run to completion.

  • Job

    Why this is correct

    A Job is designed for batch processing, ensuring a specified number of pods complete successfully.

    Related concept

    Job

  • CronJob

    Why it's wrong here

    CronJob is for scheduled jobs, but the requirement is to run once, not on a schedule.

  • DaemonSet

    Why it's wrong here

    DaemonSet runs one pod per node, not appropriate for batch jobs.

Common exam traps

Common exam trap: answer the scenario, not the keyword

The KCNA exam often tests the distinction between batch and long-running workloads, and the trap here is that candidates may confuse a Job with a Deployment because both can create multiple pods, but a Deployment is designed for continuous availability, not one-time execution.

Detailed technical explanation

How to think about this question

Under the hood, a Job tracks pod completions via the .status.succeeded field and can be configured with a backoffLimit (default 6) to handle pod failures, ensuring retries without exceeding the limit. For queue-based processing, you can use a work queue pattern where the Job creates multiple pods that each consume one item from the queue, and the Job's completion is tied to the total number of items processed, not the number of pods. A real-world scenario is processing messages from a RabbitMQ or AWS SQS queue, where each pod picks up a message, processes it, and exits, with the Job ensuring all messages are handled exactly once.

KKey Concepts to Remember

  • Job
  • Completions
  • Parallelism
  • Backoff Limit

TExam Day Tips

  • Watch for words such as best, first, most likely and least administrative effort.
  • Review why wrong options are wrong, not only why the correct option is correct.

Key takeaway

Job

Real-world example

How this comes up in practice

A practitioner preparing for the KCNA exam encounters this exact type of scenario on the job. The correct answer here is not the most general option — it is the best answer for the specific constraint described. Job Real exam questions reward reading the full scenario before eliminating options, because the constraint defines which answer fits.

What to study next

Got this wrong? Here's your next step.

Review job, then practise related KCNA questions on the same topic to reinforce the concept.

Related practice questions

Related KCNA practice-question pages

Use these pages to review the topic behind this question. This is how one missed question becomes focused revision.

Practice this exam

Start a free KCNA practice session

Short sessions build daily habit. Longer sessions build exam-day stamina. Try a timed session to simulate real conditions.

FAQ

Questions learners often ask

What does this KCNA question test?

Container Orchestration — This question tests Container Orchestration — Job.

What is the correct answer to this question?

The correct answer is: Job — A Kubernetes Job is the correct resource for batch processing tasks that run to completion, such as processing a queue where each work item corresponds to a pod. By configuring the `.spec.completions` and `.spec.parallelism` fields, you can ensure exactly one pod per work item and control concurrency. The Job automatically retries failed pods (up to a configurable limit) without restarting the entire batch, making it ideal for handling some failures. In contrast, a Deployment (A) is for long-running, continuously available services; a CronJob (C) is for scheduled recurring jobs; and a DaemonSet (D) runs a pod on every node for infrastructure tasks. Therefore, Job (B) is the best fit.

What should I do if I get this KCNA question wrong?

Review job, then practise related KCNA questions on the same topic to reinforce the concept.

What is the key concept behind this question?

Job

About these practice questions

Courseiva creates original exam-style practice questions with explanations and wrong-answer analysis. It does not publish real exam questions, exam dumps, or protected exam content. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

Same concept, more angles

5 more ways this is tested on KCNA

These questions test the same concept from different angles. Work through them to make sure you can recognise it however the exam phrases it.

Variation 1. Which Kubernetes resource is best suited for running a batch processing job that must complete successfully exactly once?

medium
  • A.DaemonSet
  • B.Deployment
  • C.CronJob
  • D.Job

Why D: A Kubernetes Job is designed specifically for batch processing tasks that need to run to completion exactly once. It creates one or more Pods and ensures that a specified number of them successfully terminate, making it ideal for workloads like data processing or backups that must finish without retries or restarts.

Variation 2. A company wants to run a batch job that processes data and then terminates. Which Kubernetes resource should they use?

medium
  • A.CronJob
  • B.Job
  • C.Deployment
  • D.DaemonSet

Why B: A Job is the correct Kubernetes resource for a batch job that processes data and then terminates. Unlike controllers that maintain a desired state (like Deployments), a Job creates one or more Pods and ensures they run to successful completion. Once the specified number of Pods terminate successfully, the Job is considered complete and does not restart the Pods, making it ideal for one-off or finite processing tasks.

Variation 3. Which Kubernetes resource is used to run a batch job that runs to completion?

easy
  • A.DaemonSet
  • B.StatefulSet
  • C.Job
  • D.Deployment

Why C: A Kubernetes Job is specifically designed to run a finite task to completion, creating one or more Pods and ensuring they successfully terminate. Unlike controllers that maintain a desired state of running Pods, a Job tracks the number of successful completions and stops when the specified parallelism or completions count is reached.

Variation 4. A team wants to deploy a batch job that runs once to process a large dataset. The job should run to completion and then terminate. Which Kubernetes resource should be used?

medium
  • A.DaemonSet
  • B.CronJob
  • C.Deployment
  • D.Job

Why D: A Job resource is designed for batch processing tasks that run to completion and then terminate. It creates one or more Pods and ensures they successfully finish their work, making it the correct choice for a one-time data processing job.

Variation 5. You need to run a batch job that processes a queue and then terminates. Which Kubernetes resource should you use?

medium
  • A.Deployment
  • B.DaemonSet
  • C.StatefulSet
  • D.Job

Why D: A Job is the correct Kubernetes resource for running a batch process that executes a finite task (e.g., processing a queue) and then terminates. Unlike controllers that maintain a desired state indefinitely, a Job creates one or more Pods and ensures they run to successful completion, after which the Job itself completes and no further Pods are created.

Keep practising

More KCNA practice questions

Last reviewed: Jul 4, 2026

Question Discussion

Share a tip, memory trick, or ask about the reasoning behind this question. Do not post real exam questions, leaked content, braindumps, or copyrighted exam material. Comments are moderated and may be removed without notice.

Loading comments…

Sign in to join the discussion.

This KCNA practice question is part of Courseiva's free CNCF certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the KCNA exam.