title: Standard way to start and stop StanfordCoreNLP server in python?
body: <p>I used subprocess to start CoreNLP server,</p>
  
  <ol>
  <li><p><code>command = 'java -mx4g -cp "*;stanford-corenlp-full-2017-06-09/*" edu.stanford.nlp.pipeline.StanfordCoreNLPServer -port 9000 -timeout 15000'</code></p></li>
  <li><p><code>server  = subprocess.Popen(command, stdout=subprocess.PIPE)</code></p></li>
  </ol>
  
  <p>to stop the server i have used : </p>
  
  <ol start="3">
  <li><code>server.kill()</code></li>
  </ol>
  
  <p>for the first time running there is no problem,</p>
  
  <p>if i try to start all the above steps again, then it is giving an error:</p>
  
  <blockquote>
    <p>error is: </p>
  </blockquote>
  
  <pre><code>    java.net.BindException: Address already in use: bind
      at sun.nio.ch.Net.bind0(Native Method)
      at sun.nio.ch.Net.bind(Unknown Source)
      at sun.nio.ch.Net.bind(Unknown Source)
      at sun.nio.ch.ServerSocketChannelImpl.bind(Unknown Source)
      at sun.nio.ch.ServerSocketAdaptor.bind(Unknown Source)
      at sun.net.httpserver.ServerImpl.&lt;init&gt;(Unknown Source)
      at sun.net.httpserver.HttpServerImpl.&lt;init&gt;(Unknown Source)
      at sun.net.httpserver.DefaultHttpServerProvider.createHttpServer(Unknown Source)
      at com.sun.net.httpserver.HttpServer.create(Unknown Source)
      at edu.stanford.nlp.pipeline.StanfordCoreNLPServer.run(StanfordCoreNLPServer.java:1277)
      at edu.stanford.nlp.pipeline.StanfordCoreNLPServer.main(StanfordCoreNLPServer.java:1369)
  </code></pre>
  
  <p>could anyone help me out. </p>