# Java Node api: isStarted() isStopped() methods needed

**URL:** <https://discuss.elastic.co/t/java-node-api-isstarted-isstopped-methods-needed/16929>\
**Category:** Elasticsearch\
**Created:** [April 10, 2014, 3:40pm UTC](https://discuss.elastic.co/t/java-node-api-isstarted-isstopped-methods-needed/16929 "2014-04-10T15:40:54Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Doru\_Sular](https://avatars.discourse-cdn.com/v4/letter/d/e9bcb4/32.png) [@Doru\_Sular](https://discuss.elastic.co/u/Doru_Sular)\
**Post date:** [April 10, 2014, 3:40pm UTC](https://discuss.elastic.co/t/java-node-api-isstarted-isstopped-methods-needed/16929/1 "2014-04-10T15:40:54Z")

</div>

Hi guys,

I am using elasticsearch embedded in my webapplication. I really need the  
methods "isStarted" and "isStopped" on Node api. Currently I wait in my  
current thread for several seconds for starting/stopping, but I think that  
it will bring more code clarity to have this methods in the java api.  
Something like this:  
/\*\*

- Returns true if the node is active and ready to be used, false otherwise.  
\*/  
public boolean isStarted();

/\*\*

- Returns true if the node managed to stop all threads started by it,  
false otherwise.  
\*/  
public boolean isStopped();

Can you help me in this issue?

Thank you very much,  
Doru

--  
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).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/c9dc6a19-53a5-4b4d-a911-9408ae63af8c%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/c9dc6a19-53a5-4b4d-a911-9408ae63af8c%40googlegroups.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![spinscale](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/spinscale/32/25011_2.png) [@spinscale](https://discuss.elastic.co/u/spinscale)\
**Post date:** [April 21, 2014, 11:40am UTC](https://discuss.elastic.co/t/java-node-api-isstarted-isstopped-methods-needed/16929/2 "2014-04-21T11:40:03Z")

</div>

Hey

maybe isClosed() can help you here?

--Alex

On Thu, Apr 10, 2014 at 5:40 PM, Doru Sular [doru.sular@gmail.com](mailto:doru.sular@gmail.com) wrote:

> Hi guys,
> 
> I am using elasticsearch embedded in my webapplication. I really need the  
> methods "isStarted" and "isStopped" on Node api. Currently I wait in my  
> current thread for several seconds for starting/stopping, but I think that  
> it will bring more code clarity to have this methods in the java api.  
> Something like this:  
> /\*\*
> 
> - Returns true if the node is active and ready to be used, false  
> otherwise.  
> \*/  
> public boolean isStarted();
> 
> /\*\*
> 
> - Returns true if the node managed to stop all threads started by it,  
> false otherwise.  
> \*/  
> public boolean isStopped();
> 
> Can you help me in this issue?
> 
> Thank you very much,  
> Doru
> 
> --  
> 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).  
> To view this discussion on the web visit  
> [https://groups.google.com/d/msgid/elasticsearch/c9dc6a19-53a5-4b4d-a911-9408ae63af8c%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/c9dc6a19-53a5-4b4d-a911-9408ae63af8c%40googlegroups.com)[https://groups.google.com/d/msgid/elasticsearch/c9dc6a19-53a5-4b4d-a911-9408ae63af8c%40googlegroups.com?utm\_medium=email&utm\_source=footer](https://groups.google.com/d/msgid/elasticsearch/c9dc6a19-53a5-4b4d-a911-9408ae63af8c%40googlegroups.com?utm_medium=email&utm_source=footer)  
> .  
> For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

--  
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).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/CAGCwEM9v4NLxhbEm8NSzd13RdEXfEX\_6SWRvjB%2BhEtFm-0hmQA%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAGCwEM9v4NLxhbEm8NSzd13RdEXfEX_6SWRvjB%2BhEtFm-0hmQA%40mail.gmail.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<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, 1:34am UTC](https://discuss.elastic.co/t/java-node-api-isstarted-isstopped-methods-needed/16929/3 "2017-07-06T01:34:40Z")

</div>


