# Logstash translate plugin example leads to error

**URL:** <https://discuss.elastic.co/t/logstash-translate-plugin-example-leads-to-error/141444>\
**Category:** Logstash\
**Created:** [July 24, 2018, 8:14pm UTC](https://discuss.elastic.co/t/logstash-translate-plugin-example-leads-to-error/141444 "2018-07-24T20:14:00Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Harsh\_Karn](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/harsh_karn/32/33693_2.png) [@Harsh\_Karn](https://discuss.elastic.co/u/Harsh_Karn)\
**Post date:** [July 24, 2018, 8:14pm UTC](https://discuss.elastic.co/t/logstash-translate-plugin-example-leads-to-error/141444/1 "2018-07-24T20:14:01Z")

</div>

The example given for dictionary field for logstash translate plugin is incorrect and when used causes logstash error.

In the example for dictionary field in [translate plugin documentation](https://www.elastic.co/guide/en/logstash/current/plugins-filters-translate.html#plugins-filters-translate-dictionary), there should be no commas. Following is the text which is present on the website.

```
  translate {
    dictionary => {
      "100" => "Continue",
      "101" => "Switching Protocols",
      "merci" => "thank you",
      "old version" => "new version"
    }
  }
}
```

---

<div class="post-metadata">

**Author:** ![guyboertje](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/guyboertje/32/31592_2.png) [@guyboertje](https://discuss.elastic.co/u/guyboertje)\
**Post date:** [July 25, 2018, 9:48am UTC](https://discuss.elastic.co/t/logstash-translate-plugin-example-leads-to-error/141444/2 "2018-07-25T09:48:47Z")

</div>

Thanks for that report. The docs will be fixed in [this Pull Request](https://github.com/logstash-plugins/logstash-filter-translate/pull/67).

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [August 22, 2018, 9:57am UTC](https://discuss.elastic.co/t/logstash-translate-plugin-example-leads-to-error/141444/3 "2018-08-22T09:57:40Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
