# Building First Filter Plugin

**URL:** https://discuss.elastic.co/t/building-first-filter-plugin/76084
**Category:** Logstash
**Created:** [February 22, 2017, 4:51pm UTC](https://discuss.elastic.co/t/building-first-filter-plugin/76084 "2017-02-22T16:51:24Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![dishmael](https://avatars.discourse-cdn.com/v4/letter/d/a88e57/32.png) [@dishmael](https://discuss.elastic.co/u/dishmael)
#### Post date: [February 22, 2017, 4:51pm UTC](https://discuss.elastic.co/t/building-first-filter-plugin/76084/1 "2017-02-22T16:51:24Z")

</div>

I am following along with the [How to write a Logstash filter plugin](https://www.elastic.co/guide/en/logstash/current/_how_to_write_a_logstash_filter_plugin.html), but when I get to the section for building, I'm getting an error:

```
$ build install
Fetching git://github.com/elastic/logstash.git
Fetching git://github.com/rest-client/rest-client.git
Fetching gem metadata from https://rubygems.org/........
Fetching version metadata from https://rubygems.org/..
Fetching dependency metadata from https://rubygems.org/.
Could not find gem 'logstash java' in git://github.com/elastic/logstash.git (at 5.2@81e342d).
Source does not contain any versions of 'logstash java'

```

Not sure what to do here. Any help is greatly appreciated.

---

<div class="post-metadata">

### Author: ![dishmael](https://avatars.discourse-cdn.com/v4/letter/d/a88e57/32.png) [@dishmael](https://discuss.elastic.co/u/dishmael)
#### Post date: [February 22, 2017, 5:00pm UTC](https://discuss.elastic.co/t/building-first-filter-plugin/76084/2 "2017-02-22T17:00:39Z")

</div>

I modified the Gemfile and it builds. This is my first Logstash plugin so I don't know if commenting out the "logstash" line is the right workaround.

```
$ cat Gemfile
source 'https://rubygems.org'                                                      
gemspec                                                                            
#gem "logstash", :github => "elastic/logstash", :branch => "5.2"                   
gem "rest-client", :github => "rest-client/rest-client", :branch => "2.0.x"

```

Did I break anything commenting out that line?

---

<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: [March 22, 2017, 5:00pm UTC](https://discuss.elastic.co/t/building-first-filter-plugin/76084/3 "2017-03-22T17:00:41Z")

</div>

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