---
title: error.occurred.karafka
description: A Karafka consumer or the Karafka framework raised an error.
url: https://docs.honeybadger.io/insights/event-types/ruby/error.occurred.karafka/
---

A Karafka consumer or the Karafka framework raised an error.

Source **Karafka** Category **Jobs** Fields **9** [honeybadger-ruby](https://docs.honeybadger.io/lib/ruby/)

## Fields

| Field            | Type    | Description                                                                                                  |
| ---------------- | ------- | ------------------------------------------------------------------------------------------------------------ |
| `event_type`     | string  | Allowed value: `error.occurred.karafka`.                                                                     |
| `type`           | string  | Error source identifier, e.g., 'consumer.consume.error' or 'connection.error'.                               |
| `error`          | string  | Exception message and class name.                                                                            |
| `topic`          | string  | Kafka topic where the error occurred, if applicable.                                                         |
| `partition`      | integer | Kafka partition where the error occurred, if applicable.                                                     |
| `consumer_group` | string  | Consumer group where the error occurred, if applicable.                                                      |
| `request_id`     | string  | Rails request UUID from the active web request context, if any. Merged globally by the Honeybadger agent.    |
| `hostname`       | string  | Server hostname. Attached to every event by default (events.attach\_hostname).                               |
| `environment`    | string  | Application environment, e.g. "production". Attached to every event by default (events.attach\_environment). |

## Example

```json
{
  "event_type": "error.occurred.karafka",
  "type": "consumer.consume.error",
  "error": "JSON::ParserError: unexpected token at 'invalid'",
  "topic": "orders",
  "partition": 0,
  "consumer_group": "orders_consumers",
  "request_id": "3d9c2f81-6e5a-4f7b-9c0d-8a1b2c3d4e5f",
  "hostname": "worker-1.example.com",
  "environment": "production"
}
```

---

## Try Honeybadger for FREE

Intelligent logging, error tracking, and Just Enough APM™ in one dev-friendly platform. Find and fix problems before users notice.

[Start free trial](https://app.honeybadger.io/users/sign_up)

[See plans and pricing](https://www.honeybadger.io/plans/)
