JettySolrRunner (Solr 3.6.2 API)
Keywords: org.apache.solr.client.solrj.embedded.JettySolrRunner class

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.solr.client.solrj.embedded
Class JettySolrRunner

    java.lang.Object
      org.apache.solr.client.solrj.embedded.JettySolrRunner

    public class JettySolrRunner

extends Object

Run solr using jetty

Since:
  solr 1.3

Nested Class Summary
`static class` | `JettySolrRunner.Servlet404` This is a stupid hack to give jetty something to attach to

Constructor Summary
`JettySolrRunner(String context, int port)`
`JettySolrRunner(String context, int port, String solrConfigFilename)`

Method Summary
`int` | `getLocalPort()` Returns the Local Port of the first Connector found for the jetty Server.
`static void` | `main(String[] args)` A main class that starts jetty+solr This is useful for debugging
`void` | `start()`
`void` | `start(boolean waitForSolr)`
`void` | `stop()`
`void` | `waitForSolr(String context)` Waits until a ping query to the solr server succeeds, retrying every 200 milliseconds up to 2 minutes.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### JettySolrRunner

    public JettySolrRunner(String context,
                           int port)

### JettySolrRunner

    public JettySolrRunner(String context,
                           int port,
                           String solrConfigFilename)

Method Detail

### start

    public void start()
               throws Exception

  Throws:
    `Exception`

### start

    public void start(boolean waitForSolr)
               throws Exception

  Throws:
    `Exception`

### stop

    public void stop()
              throws Exception

  Throws:
    `Exception`

### waitForSolr

    public void waitForSolr(String context)
                     throws Exception

  Waits until a ping query to the solr server succeeds, retrying every 200 milliseconds up to 2 minutes.

  Throws:
    `Exception`

### getLocalPort

    public int getLocalPort()

  Returns the Local Port of the first Connector found for the jetty Server.

  Throws:
    `RuntimeException` - if there is no Connector

### main

    public static void main(String[] args)

  A main class that starts jetty+solr This is useful for debugging

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD