Class JettyUtil

java.lang.Object
ca.uhn.fhir.test.utilities.JettyUtil

public class JettyUtil extends Object
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static void
    closeServer(org.eclipse.jetty.server.Server theServer)
    Shut down the given Jetty server, and release held resources.
    static int
    getPortForStartedServer(org.eclipse.jetty.server.Server server)
    Gets the local port for the given server.
    static void
    startServer(org.eclipse.jetty.server.Server theServer)
    Starts the given Jetty server, and configures it for graceful shutdown

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

  • Method Details

    • getPortForStartedServer

      public static int getPortForStartedServer(org.eclipse.jetty.server.Server server)
      Gets the local port for the given server. The server must be started.
    • startServer

      public static void startServer(@Nonnull org.eclipse.jetty.server.Server theServer) throws Exception
      Starts the given Jetty server, and configures it for graceful shutdown
      Throws:
      Exception
    • closeServer

      public static void closeServer(@Nullable org.eclipse.jetty.server.Server theServer) throws Exception
      Shut down the given Jetty server, and release held resources.
      Throws:
      Exception