How to close the Loading of data by logstash programmatically


I am loading the data in ES using Logstash pro grammatically by starting the process cmd.exe.But I am not able to close this loading of data . can you help me that How can i shutdown logsatsh programmatically.

If you know Logstash is done processing the data, just kill the process. Depending on which language you're using you might be able to interrupt it in a graceful way (similar to SIGINT on a Unix-like system), otherwise it'll be a hard shutdown.

Is there any way to know the size of index programmatically .Right now I am trying "http://localhost:9200/_cat/indices?h=index,store.size" which give size upto one decimal (For eg 2.6 for both 2.60 and 2.66). so Kindly suggest some points with this also.

You'll have better luck asking about index sizes in the Elasticsearch category. I have no straight answer.

Thanks for all the response. I got the answer. This URL "http://localhost:9200/_cat/indices?h=index,store.size&bytes=b" Will give the size in bytes and pretty much solve my issue.