# Include a plugin using Tomcat

**URL:** <https://discuss.elastic.co/t/include-a-plugin-using-tomcat/13556>\
**Category:** Elasticsearch\
**Created:** [September 11, 2013, 12:27pm UTC](https://discuss.elastic.co/t/include-a-plugin-using-tomcat/13556 "2013-09-11T12:27:42Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![Bibin\_Abraham](https://avatars.discourse-cdn.com/v4/letter/b/4af34b/32.png) [@Bibin\_Abraham](https://discuss.elastic.co/u/Bibin_Abraham)\
**Post date:** [September 11, 2013, 12:27pm UTC](https://discuss.elastic.co/t/include-a-plugin-using-tomcat/13556/1 "2013-09-11T12:27:42Z")

</div>

Hi,

I have wrapped Elasticsearch in Tomcat and am using  
elasticsearch-transport-wares for this purpose. How can I add a plugin to  
this instance as Im planning to use jdbc river plugin?

Thanks & Regards

bin 🙂

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<div class="post-metadata">

**Author:** ![Igor\_Motov](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/igor_motov/32/45193_2.png) [@Igor\_Motov](https://discuss.elastic.co/u/Igor_Motov)\
**Post date:** [September 11, 2013, 1:00pm UTC](https://discuss.elastic.co/t/include-a-plugin-using-tomcat/13556/2 "2013-09-11T13:00:28Z")

</div>

Just copy the plugin to any directory that is accessible by the tomcat  
process and specify this directory in the path.plugins setting of your  
elasticsearch node.

On Wednesday, September 11, 2013 8:27:42 AM UTC-4, bin wrote:

> Hi,
> 
> I have wrapped Elasticsearch in Tomcat and am using  
> elasticsearch-transport-wares for this purpose. How can I add a plugin to  
> this instance as Im planning to use jdbc river plugin?
> 
> Thanks & Regards
> 
> bin 🙂

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [September 11, 2013, 1:17pm UTC](https://discuss.elastic.co/t/include-a-plugin-using-tomcat/13556/3 "2013-09-11T13:17:48Z")

</div>

You can also just add your plugin in the classloader.  
For example, add it as a maven dependency in your project and that's all.

--  
David Pilato | Technical Advocate | [Elasticsearch.com](http://Elasticsearch.com)  
@dadoonet | @elasticsearchfr | @scrutmydocs

Le 11 sept. 2013 à 15:00, Igor Motov [imotov@gmail.com](mailto:imotov@gmail.com) a écrit :

> Just copy the plugin to any directory that is accessible by the tomcat process and specify this directory in the path.plugins setting of your elasticsearch node.
> 
> On Wednesday, September 11, 2013 8:27:42 AM UTC-4, bin wrote:  
> Hi,
> 
> I have wrapped Elasticsearch in Tomcat and am using elasticsearch-transport-wares for this purpose. How can I add a plugin to this instance as Im planning to use jdbc river plugin?
> 
> Thanks & Regards
> 
> bin 🙂
> 
> --  
> You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
> To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<div class="post-metadata">

**Author:** ![Bibin\_Abraham](https://avatars.discourse-cdn.com/v4/letter/b/4af34b/32.png) [@Bibin\_Abraham](https://discuss.elastic.co/u/Bibin_Abraham)\
**Post date:** [September 11, 2013, 6:16pm UTC](https://discuss.elastic.co/t/include-a-plugin-using-tomcat/13556/4 "2013-09-11T18:16:11Z")

</div>

Hi Igor,David,

Thanks for your help.

I added the river-jdbc jar in WEB-INF/lib. Then I tried the following:

curl -XPUT "[http://localhost:9200/\_river/my\_jdbc\_river/\_meta](http://localhost:9200/_river/my_jdbc_river/_meta)" -d '{...}'

output:  
{  
"error": "IndexMissingException[[\_river] missing]",  
"status": 404  
}

Then I created a folder-plugins/river-jdbc and added its jars over there. I  
configured the elasticsearch.yml to point to the dir. Still I got the same  
exception.  
Then I made the plugin mandatory and I got  
"org.elasticsearch.ElasticSearchException: Missing mandatory plugins  
[river-jdbc]  
org.elasticsearch.plugins.PluginsService.\<init\>(PluginsService.java:99)  
"

BTW, I gave the absolute path for the above.

Thanks and Regards

bin 🙂

On Wednesday, September 11, 2013 6:47:48 PM UTC+5:30, David Pilato wrote:

> You can also just add your plugin in the classloader.  
> For example, add it as a maven dependency in your project and that's all.
> 
> --  
> _David Pilato_ | _Technical Advocate_ | _[Elasticsearch.com](http://Elasticsearch.com)_  
> @dadoonet [https://twitter.com/dadoonet](https://twitter.com/dadoonet) | @elasticsearchfr[https://twitter.com/elasticsearchfr](https://twitter.com/elasticsearchfr)  
> | @scrutmydocs [https://twitter.com/scrutmydocs](https://twitter.com/scrutmydocs)
> 
> Le 11 sept. 2013 à 15:00, Igor Motov \<[imo...@gmail.com](mailto:imo...@gmail.com) \<javascript:\>\> a  
> écrit :
> 
> Just copy the plugin to any directory that is accessible by the tomcat  
> process and specify this directory in the path.plugins setting of your  
> elasticsearch node.
> 
> On Wednesday, September 11, 2013 8:27:42 AM UTC-4, bin wrote:
> 
> > Hi,
> > 
> > I have wrapped Elasticsearch in Tomcat and am using  
> > elasticsearch-transport-wares for this purpose. How can I add a plugin to  
> > this instance as Im planning to use jdbc river plugin?
> > 
> > Thanks & Regards
> > 
> > bin 🙂
> 
> --  
> You received this message because you are subscribed to the Google Groups  
> "elasticsearch" group.  
> To unsubscribe from this group and stop receiving emails from it, send an  
> email to [elasticsearc...@googlegroups.com](mailto:elasticsearc...@googlegroups.com) \<javascript:\>.  
> For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [September 11, 2013, 7:32pm UTC](https://discuss.elastic.co/t/include-a-plugin-using-tomcat/13556/5 "2013-09-11T19:32:24Z")

</div>

How do you start es from your webapp?

--  
David 😉  
Twitter : @dadoonet / @elasticsearchfr / @scrutmydocs

Le 11 sept. 2013 à 20:16, bin [bibin.abraham.dev@gmail.com](mailto:bibin.abraham.dev@gmail.com) a écrit :

> Hi Igor,David,
> 
> Thanks for your help.
> 
> I added the river-jdbc jar in WEB-INF/lib. Then I tried the following:
> 
> curl -XPUT "[http://localhost:9200/\_river/my\_jdbc\_river/\_meta](http://localhost:9200/_river/my_jdbc_river/_meta)" -d '{...}'
> 
> output:  
> {  
> "error": "IndexMissingException[[\_river] missing]",  
> "status": 404  
> }
> 
> Then I created a folder-plugins/river-jdbc and added its jars over there. I configured the elasticsearch.yml to point to the dir. Still I got the same exception.  
> Then I made the plugin mandatory and I got  
> "org.elasticsearch.ElasticSearchException: Missing mandatory plugins [river-jdbc]  
> org.elasticsearch.plugins.PluginsService.\<init\>(PluginsService.java:99)  
> "
> 
> BTW, I gave the absolute path for the above.
> 
> Thanks and Regards
> 
> bin 🙂
> 
> On Wednesday, September 11, 2013 6:47:48 PM UTC+5:30, David Pilato wrote:
> 
> > You can also just add your plugin in the classloader.  
> > For example, add it as a maven dependency in your project and that's all.
> > 
> > --  
> > David Pilato | Technical Advocate | [Elasticsearch.com](http://Elasticsearch.com)  
> > @dadoonet | @elasticsearchfr | @scrutmydocs
> > 
> > Le 11 sept. 2013 à 15:00, Igor Motov [imo...@gmail.com](mailto:imo...@gmail.com) a écrit :
> > 
> > > Just copy the plugin to any directory that is accessible by the tomcat process and specify this directory in the path.plugins setting of your elasticsearch node.
> > > 
> > > On Wednesday, September 11, 2013 8:27:42 AM UTC-4, bin wrote:
> > > 
> > > > Hi,
> > > > 
> > > > I have wrapped Elasticsearch in Tomcat and am using elasticsearch-transport-wares for this purpose. How can I add a plugin to this instance as Im planning to use jdbc river plugin?
> > > > 
> > > > Thanks & Regards
> > > > 
> > > > bin 🙂
> > > 
> > > --  
> > > You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
> > > To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearc...@googlegroups.com](mailto:elasticsearc...@googlegroups.com).  
> > > For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).
> 
> --  
> You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
> To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<div class="post-metadata">

**Author:** ![Bibin\_Abraham](https://avatars.discourse-cdn.com/v4/letter/b/4af34b/32.png) [@Bibin\_Abraham](https://discuss.elastic.co/u/Bibin_Abraham)\
**Post date:** [September 12, 2013, 1:13am UTC](https://discuss.elastic.co/t/include-a-plugin-using-tomcat/13556/6 "2013-09-12T01:13:21Z")

</div>

I am using elasticsearch-transport-wares servlets

Thanks & Regards

bin 🙂

On Thursday, 12 September 2013 01:02:24 UTC+5:30, David Pilato wrote:

> How do you start es from your webapp?
> 
> --  
> David 😉  
> Twitter : @dadoonet / @elasticsearchfr / @scrutmydocs
> 
> Le 11 sept. 2013 à 20:16, bin \<[bibin.ab...@gmail.com](mailto:bibin.ab...@gmail.com) \<javascript:\>\> a  
> écrit :
> 
> Hi Igor,David,
> 
> Thanks for your help.
> 
> I added the river-jdbc jar in WEB-INF/lib. Then I tried the following:
> 
> curl -XPUT "[http://localhost:9200/\_river/my\_jdbc\_river/\_meta](http://localhost:9200/_river/my_jdbc_river/_meta)" -d '{...}'
> 
> output:  
> {  
> "error": "IndexMissingException[[\_river] missing]",  
> "status": 404  
> }
> 
> Then I created a folder-plugins/river-jdbc and added its jars over there.  
> I configured the elasticsearch.yml to point to the dir. Still I got the  
> same exception.  
> Then I made the plugin mandatory and I got  
> "org.elasticsearch.ElasticSearchException: Missing mandatory plugins  
> [river-jdbc]
> 
> org.elasticsearch.plugins.PluginsService.\<init\>(PluginsService.java:99)  
> "
> 
> BTW, I gave the absolute path for the above.
> 
> Thanks and Regards
> 
> bin 🙂
> 
> On Wednesday, September 11, 2013 6:47:48 PM UTC+5:30, David Pilato wrote:
> 
> > You can also just add your plugin in the classloader.  
> > For example, add it as a maven dependency in your project and that's all.
> > 
> > --  
> > _David Pilato_ | _Technical Advocate_ | _[Elasticsearch.com](http://Elasticsearch.com)_  
> > @dadoonet [https://twitter.com/dadoonet](https://twitter.com/dadoonet) | @elasticsearchfr[https://twitter.com/elasticsearchfr](https://twitter.com/elasticsearchfr)  
> > | @scrutmydocs [https://twitter.com/scrutmydocs](https://twitter.com/scrutmydocs)
> > 
> > Le 11 sept. 2013 à 15:00, Igor Motov [imo...@gmail.com](mailto:imo...@gmail.com) a écrit :
> > 
> > Just copy the plugin to any directory that is accessible by the tomcat  
> > process and specify this directory in the path.plugins setting of your  
> > elasticsearch node.
> > 
> > On Wednesday, September 11, 2013 8:27:42 AM UTC-4, bin wrote:
> > 
> > > Hi,
> > > 
> > > I have wrapped Elasticsearch in Tomcat and am using  
> > > elasticsearch-transport-wares for this purpose. How can I add a plugin to  
> > > this instance as Im planning to use jdbc river plugin?
> > > 
> > > Thanks & Regards
> > > 
> > > bin 🙂
> > 
> > --  
> > You received this message because you are subscribed to the Google Groups  
> > "elasticsearch" group.  
> > To unsubscribe from this group and stop receiving emails from it, send an  
> > email to [elasticsearc...@googlegroups.com](mailto:elasticsearc...@googlegroups.com).  
> > For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).
> > 
> > --  
> > You received this message because you are subscribed to the Google Groups  
> > "elasticsearch" group.  
> > To unsubscribe from this group and stop receiving emails from it, send an  
> > email to [elasticsearc...@googlegroups.com](mailto:elasticsearc...@googlegroups.com) \<javascript:\>.  
> > For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [September 12, 2013, 3:13pm UTC](https://discuss.elastic.co/t/include-a-plugin-using-tomcat/13556/7 "2013-09-12T15:13:04Z")

</div>

I did not play with wares plugin.  
As you are using tomcat, you could try to add all needed libs (and their dependencies!) in:  
WEB-INF/lib or  
$CATALINA\_HOME/lib  
I would recommend to restart tomcat.

Did you add all dependencies? Is there anything in logs?

--  
David Pilato | Technical Advocate | [Elasticsearch.com](http://Elasticsearch.com)  
@dadoonet | @elasticsearchfr | @scrutmydocs

Le 12 sept. 2013 à 03:13, bin [bibin.abraham.dev@gmail.com](mailto:bibin.abraham.dev@gmail.com) a écrit :

> I am using elasticsearch-transport-wares servlets
> 
> Thanks & Regards
> 
> bin 🙂
> 
> On Thursday, 12 September 2013 01:02:24 UTC+5:30, David Pilato wrote:  
> How do you start es from your webapp?
> 
> --  
> David 😉  
> Twitter : @dadoonet / @elasticsearchfr / @scrutmydocs
> 
> Le 11 sept. 2013 à 20:16, bin [bibin.ab...@gmail.com](mailto:bibin.ab...@gmail.com) a écrit :
> 
> > Hi Igor,David,
> > 
> > Thanks for your help.
> > 
> > I added the river-jdbc jar in WEB-INF/lib. Then I tried the following:
> > 
> > curl -XPUT "[http://localhost:9200/\_river/my\_jdbc\_river/\_meta](http://localhost:9200/_river/my_jdbc_river/_meta)" -d '{...}'
> > 
> > output:  
> > {  
> > "error": "IndexMissingException[[\_river] missing]",  
> > "status": 404  
> > }
> > 
> > Then I created a folder-plugins/river-jdbc and added its jars over there. I configured the elasticsearch.yml to point to the dir. Still I got the same exception.  
> > Then I made the plugin mandatory and I got  
> > "org.elasticsearch.ElasticSearchException: Missing mandatory plugins [river-jdbc]  
> > org.elasticsearch.plugins.PluginsService.\<init\>(PluginsService.java:99)  
> > "
> > 
> > BTW, I gave the absolute path for the above.
> > 
> > Thanks and Regards
> > 
> > bin 🙂
> > 
> > On Wednesday, September 11, 2013 6:47:48 PM UTC+5:30, David Pilato wrote:  
> > You can also just add your plugin in the classloader.  
> > For example, add it as a maven dependency in your project and that's all.
> > 
> > --  
> > David Pilato | Technical Advocate | [Elasticsearch.com](http://Elasticsearch.com)  
> > @dadoonet | @elasticsearchfr | @scrutmydocs
> > 
> > Le 11 sept. 2013 à 15:00, Igor Motov [imo...@gmail.com](mailto:imo...@gmail.com) a écrit :
> > 
> > > Just copy the plugin to any directory that is accessible by the tomcat process and specify this directory in the path.plugins setting of your elasticsearch node.
> > > 
> > > On Wednesday, September 11, 2013 8:27:42 AM UTC-4, bin wrote:  
> > > Hi,
> > > 
> > > I have wrapped Elasticsearch in Tomcat and am using elasticsearch-transport-wares for this purpose. How can I add a plugin to this instance as Im planning to use jdbc river plugin?
> > > 
> > > Thanks & Regards
> > > 
> > > bin 🙂
> > > 
> > > --  
> > > You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
> > > To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearc...@googlegroups.com](mailto:elasticsearc...@googlegroups.com).  
> > > For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).
> > 
> > --  
> > You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
> > To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearc...@googlegroups.com](mailto:elasticsearc...@googlegroups.com).  
> > For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).
> 
> --  
> You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
> To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<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:** [July 6, 2017, 2:16am UTC](https://discuss.elastic.co/t/include-a-plugin-using-tomcat/13556/8 "2017-07-06T02:16:53Z")

</div>


