# Can we put two plugins together?

**URL:** <https://discuss.elastic.co/t/can-we-put-two-plugins-together/92577>\
**Category:** Elasticsearch\
**Created:** [July 11, 2017, 5:50am UTC](https://discuss.elastic.co/t/can-we-put-two-plugins-together/92577 "2017-07-11T05:50:38Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Linda\_sunshine](https://avatars.discourse-cdn.com/v4/letter/l/eb8c5e/32.png) [@Linda\_sunshine](https://discuss.elastic.co/u/Linda_sunshine)\
**Post date:** [July 11, 2017, 5:50am UTC](https://discuss.elastic.co/t/can-we-put-two-plugins-together/92577/1 "2017-07-11T05:50:39Z")

</div>

Hello,

I am fresh to Elasticsearch. I would like to merge two plugins into one because the function inside one plugin may call the function in another plugin. Is there a way to achieve that? I noticed that in "plugin-descriptor.properties", we can only register one plugin.

Thanks.😇

Best,  
Lin

---

<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:** [July 11, 2017, 8:39am UTC](https://discuss.elastic.co/t/can-we-put-two-plugins-together/92577/2 "2017-07-11T08:39:42Z")

</div>

No.

Why would you do this?

That said a single plugin can offer multiple features, like extending a REST endpoint, adding an analyzer and an ingest processor...

---

<div class="post-metadata">

**Author:** ![Linda\_sunshine](https://avatars.discourse-cdn.com/v4/letter/l/eb8c5e/32.png) [@Linda\_sunshine](https://discuss.elastic.co/u/Linda_sunshine)\
**Post date:** [July 11, 2017, 3:47pm UTC](https://discuss.elastic.co/t/can-we-put-two-plugins-together/92577/3 "2017-07-11T15:47:21Z")

</div>

Hi David,

Thanks so much for your reply!  
I couldn't find documentation or examples for a single plugin with multiple features. In my case, I would like to register two plugins, one implements SearchPlugin and another implements ActionPlugin. How can I achieve that?

Thanks!😊

Best,  
Lin

---

<div class="post-metadata">

**Author:** ![rjernst](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/rjernst/32/6363_2.png) [@rjernst](https://discuss.elastic.co/u/rjernst)\
**Post date:** [July 11, 2017, 4:49pm UTC](https://discuss.elastic.co/t/can-we-put-two-plugins-together/92577/4 "2017-07-11T16:49:38Z")

</div>

Make your plugin class implement both SearchPlugin and ActionPlugin interfaces.

---

<div class="post-metadata">

**Author:** ![Linda\_sunshine](https://avatars.discourse-cdn.com/v4/letter/l/eb8c5e/32.png) [@Linda\_sunshine](https://discuss.elastic.co/u/Linda_sunshine)\
**Post date:** [July 11, 2017, 5:15pm UTC](https://discuss.elastic.co/t/can-we-put-two-plugins-together/92577/5 "2017-07-11T17:15:52Z")

</div>

Got it! Thanks!!😁

---

<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 8, 2017, 5:16pm UTC](https://discuss.elastic.co/t/can-we-put-two-plugins-together/92577/6 "2017-08-08T17:16:15Z")

</div>

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