# Why plugins can't be added dynamically into ES

**URL:** <https://discuss.elastic.co/t/why-plugins-cant-be-added-dynamically-into-es/122610>\
**Category:** Elasticsearch\
**Created:** [March 5, 2018, 11:01pm UTC](https://discuss.elastic.co/t/why-plugins-cant-be-added-dynamically-into-es/122610 "2018-03-05T23:01:43Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![fhalde](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/fhalde/32/21419_2.png) [@fhalde](https://discuss.elastic.co/u/fhalde)\
**Post date:** [March 5, 2018, 11:01pm UTC](https://discuss.elastic.co/t/why-plugins-cant-be-added-dynamically-into-es/122610/1 "2018-03-05T23:01:44Z")

</div>

Just wondering what is the ES internal design like that makes it difficult to install a plugin dynamically?

Why is it that we always have to restart the nodes?

---

<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:** [March 9, 2018, 6:36am UTC](https://discuss.elastic.co/t/why-plugins-cant-be-added-dynamically-into-es/122610/2 "2018-03-09T06:36:38Z")

</div>

Elasticsearch does a lot of initialization when a node starts. In particular, note only are plugins constructed during Node construction, but all of the services which control node behavior, eg ClusterService, IndicesService, ScriptService, etc are constructed based on the builtin and plugin supplied implementations of relevant objects. Thus, once the Node. has been constructed, there is no easy way to load a plugin without reconstructing the Node. While this would be a great thing to have long term, the unfortunate truth is we are a very long way away from having hot reloadability. Essentially all internal services within the node would need to have the objects they operate on dynamically loadable (eg ScriptService being able to add/remove ScriptEngine implementations dynamically).

---

<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:** [April 6, 2018, 6:36am UTC](https://discuss.elastic.co/t/why-plugins-cant-be-added-dynamically-into-es/122610/3 "2018-04-06T06:36:48Z")

</div>

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