# Kafka Offset

You can use the **Kafka Offset** job entry to reset the offset value of all partitions in a topic based on a given timestamp or epoch value.

### General

* **Entry name**: Specify the unique name of the Kafka Offset entry on the canvas. You can customize the name or leave it as the default.

### Options

The Kafka Offset entry includes three tabs: **Setup**, **Options**, and **Offset settings**.

#### Setup tab

![Setup tab for Kafka Offset job](/files/i7mNjZyDuDzWf1vRI7jw)

Use this tab to define connections, topics, and the consumer group.

| Option                | Description                                                                                                                                                                                                         |
| --------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **Bootstrap servers** | Specify the bootstrap servers to use for the Kafka connection.                                                                                                                                                      |
| **Topics**            | Enter the name of each Kafka topic you want to target. You must include all relevant topics.                                                                                                                        |
| **Consumer group**    | <p>Enter the consumer group name. When part of a consumer group, each consumer is assigned a subset of partitions from the subscribed topics.</p><p>Each Kafka consumer instance runs a single consumer thread.</p> |

#### Options tab

![Options tab for Kafka Offset job](/files/tsCG4JD1ihE93RP43HZh)

Use this tab to send parameters (properties) to the broker when connecting. Parameter values can be encrypted.

A few common options are included for convenience, but you can enter any Kafka property.

For more information, see the Apache Kafka documentation: <https://kafka.apache.org/documentation/>.

#### Offset settings tab

To reset the offset value, set the start date in **Offset timestamp** and select the format in **Timestamp format**.

![Offset settings tab for Kafka Offset job](/files/pB2Qy32rJ89DZuJtm363)

| Option               | Description                                                                                                                                                                 |
| -------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **Offset timestamp** | The start timestamp to use as the offset. The timestamp can be in the past or future. When you run the job entry, each partition offset is reset to the timestamp provided. |
| **Timestamp format** | The timestamp format for the offset. If you provide an epoch value, you do not need to specify a timestamp format.                                                          |

### Examples

The `kafka_job_abort.kjb` sample job in `design-tools/data-integration/plugins/kafka-job-plugins-zip-9.5.1.0-110/kafka-offset-job/samples/transformations` demonstrates this job entry by using the Abort step.

![Kafka Offset example kafka\_job\_abort](/files/3ikrHWGre5wLqkrcOAOW)

The `kafka_job.kjb` sample job in `design-tools/data-integration/plugins/pentaho-streaming-kafka-plugin-zip-9.5.1.0-110/pentaho-streaming-kafka-plugin/samples/transformations` demonstrates a job with both successes and failures. Comments in the transformations explain how the steps are used.

![Kafka offset example kafka\_job.kjb](/files/ECOPw8Bg7L4lWOWulcfT)


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.pentaho.com/pdia-data-integration/pdi-job-entries-reference-overview/kafka-offset.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
