# How to register a customer TransportAction in elk

**URL:** <https://discuss.elastic.co/t/how-to-register-a-customer-transportaction-in-elk/58761>\
**Category:** Elasticsearch\
**Created:** [August 24, 2016, 3:14am UTC](https://discuss.elastic.co/t/how-to-register-a-customer-transportaction-in-elk/58761 "2016-08-24T03:14:14Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ttjslbz](https://avatars.discourse-cdn.com/v4/letter/t/73ab20/32.png) [@ttjslbz](https://discuss.elastic.co/u/ttjslbz)\
**Post date:** [August 24, 2016, 3:14am UTC](https://discuss.elastic.co/t/how-to-register-a-customer-transportaction-in-elk/58761/1 "2016-08-24T03:14:14Z")

</div>

Hi all  
i want to write a plugin to manage my index cache. I have finish the rest layer and register it to restController now.  
I want to write a transportAction extends the TransportReplicationAction that helps me notify all replica shard update related index. But how can i register the customer action to a nodeClient?  
My elasticsearch version is 2.4.0.

I have referenced the old plugin [https://github.com/spinscale/elasticsearch-suggest-plugin/blob/master/src/main/java/de/spinscale/elasticsearch/plugin/suggest/SuggestPlugin.java](https://github.com/spinscale/elasticsearch-suggest-plugin/blob/master/src/main/java/de/spinscale/elasticsearch/plugin/suggest/SuggestPlugin.java).  
But it's wired.  
I can't understand the method public void onModule(ActionModule actionModule). How elasticsearch call a plugin method which has not appeared in Plugin interface.

---

<div class="post-metadata">

**Author:** ![jasontedor](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jasontedor/32/66992_2.png) [@jasontedor](https://discuss.elastic.co/u/jasontedor)\
**Post date:** [August 24, 2016, 4:06am UTC](https://discuss.elastic.co/t/how-to-register-a-customer-transportaction-in-elk/58761/2 "2016-08-24T04:06:55Z")

</div>

> [@ttjslbz](#):
>
> How elasticsearch call a plugin method which has not appeared in Plugin interface.

In 2.x, it's done reflectively.

---

<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 5, 2017, 10:25pm UTC](https://discuss.elastic.co/t/how-to-register-a-customer-transportaction-in-elk/58761/3 "2017-07-05T22:25:43Z")

</div>


