# \[Just Pushed\] Service Wrapper and Restart API

**URL:** <https://discuss.elastic.co/t/just-pushed-service-wrapper-and-restart-api/2935>\
**Category:** Elasticsearch\
**Created:** [May 1, 2010, 12:26am UTC](https://discuss.elastic.co/t/just-pushed-service-wrapper-and-restart-api/2935 "2010-05-01T00:26:25Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![kimchy](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kimchy/32/44952_2.png) [@kimchy](https://discuss.elastic.co/u/kimchy)\
**Post date:** [May 1, 2010, 12:26am UTC](https://discuss.elastic.co/t/just-pushed-service-wrapper-and-restart-api/2935/1 "2010-05-01T00:26:25Z")

</div>

Hi,

I just pushed Java Service Wrapper support for elasticsearch. The idea of  
Java Service Wrapper is to have a lightweight process forking the actual  
Java process that is elasticsearch. This process allows to run elasticsearch  
in console mode, as well as to start it in the background, and stop it  
(finally, a command line option to stop it). The script also allows to  
install elasticsearch in init.d/launchd(mac)/windows service. The scripts  
exists under the bin/service directory. On top of that, the shutdown API now  
automatically uses service wrapper when its run under it to send the stop  
command through the service wrapper.

Also, a restart API as been added (similar to the shutdown API, just  
replace shutdown with restart). When running in regular mode, it will  
restart elasticsearch within the same JVM. When run under the service  
wrapper, the wrapper will restart the whole JVM and starting a fresh JVM  
with a fresh elasticsearch node.

The wrapper also provides a nice ping ability to detect if the process is  
hung, and if so, it will restart it automatically. The default ping timeout  
is 5 minutes, but all is configurable under the  
bin/service/elasticsearch.conf.

A note regarding the service wrapper. Memory configuration (min/max) are  
configured within the elasticsearch.conf file. All the rest of elasticsearch  
configuration can be configured in any case through the  
elasticsearch.(yml|json) files.

cheers,  
shay.banon

---

<div class="post-metadata">

**Author:** ![mooky](https://avatars.discourse-cdn.com/v4/letter/m/43a26b/32.png) [@mooky](https://discuss.elastic.co/u/mooky)\
**Post date:** [May 1, 2010, 12:44am UTC](https://discuss.elastic.co/t/just-pushed-service-wrapper-and-restart-api/2935/2 "2010-05-01T00:44:59Z")

</div>

cool 🙂  
jsw rocks

On 1 May 2010 01:26, Shay Banon [shay.banon@elasticsearch.com](mailto:shay.banon@elasticsearch.com) wrote:

> Hi,  
> I just pushed Java Service Wrapper support for elasticsearch. The idea of  
> Java Service Wrapper is to have a lightweight process forking the actual  
> Java process that is elasticsearch. This process allows to run elasticsearch  
> in console mode, as well as to start it in the background, and stop it  
> (finally, a command line option to stop it). The script also allows to  
> install elasticsearch in init.d/launchd(mac)/windows service. The scripts  
> exists under the bin/service directory. On top of that, the shutdown API now  
> automatically uses service wrapper when its run under it to send the stop  
> command through the service wrapper.  
> Also, a restart API as been added (similar to the shutdown API, just  
> replace shutdown with restart). When running in regular mode, it will  
> restart elasticsearch within the same JVM. When run under the service  
> wrapper, the wrapper will restart the whole JVM and starting a fresh JVM  
> with a fresh elasticsearch node.  
> The wrapper also provides a nice ping ability to detect if the process is  
> hung, and if so, it will restart it automatically. The default ping timeout  
> is 5 minutes, but all is configurable under the  
> bin/service/elasticsearch.conf.  
> A note regarding the service wrapper. Memory configuration (min/max) are  
> configured within the elasticsearch.conf file. All the rest of elasticsearch  
> configuration can be configured in any case through the  
> elasticsearch.(yml|json) files.  
> cheers,  
> shay.banon

---

<div class="post-metadata">

**Author:** ![Adrian2](https://avatars.discourse-cdn.com/v4/letter/a/ed655f/32.png) [@Adrian2](https://discuss.elastic.co/u/Adrian2)\
**Post date:** [November 27, 2012, 6:29pm UTC](https://discuss.elastic.co/t/just-pushed-service-wrapper-and-restart-api/2935/3 "2012-11-27T18:29:31Z")

</div>

Looks like this to "Windows 32-bit". This for "64bit windows"?

---

<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, 3:02am UTC](https://discuss.elastic.co/t/just-pushed-service-wrapper-and-restart-api/2935/4 "2017-07-06T03:02:38Z")

</div>


