Interface RequestHandlerWithLifecycle

  • All Superinterfaces:
    com.thetransactioncompany.jsonrpc2.server.RequestHandler

    public interface RequestHandlerWithLifecycle
    extends com.thetransactioncompany.jsonrpc2.server.RequestHandler
    JSON-RPC 2.0 request handler with lifecycle. Extends the basic request handler interface by providing a start() method for initialising and allocating resources, such as database connections, and a stop() method for freeing them when the handler is to be shut down.
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      void start()
      Starts the request handler.
      void stop()
      Stops the request handler.
      • Methods inherited from interface com.thetransactioncompany.jsonrpc2.server.RequestHandler

        handledRequests, process
    • Method Detail

      • start

        void start()
            throws Exception
        Starts the request handler.
        Throws:
        Exception - If the request handler couldn't be started.
      • stop

        void stop()
           throws Exception
        Stops the request handler.
        Throws:
        Exception - If an exception was encountered.