Class TinyApplication


  • public abstract class TinyApplication
    extends Object
    Tiny microservice application base class. Extend this class to set up the server itself, and use the static start(TinyApplication, String...) method to actually start it.
    • Constructor Detail

      • TinyApplication

        protected TinyApplication​(String applicationName)
    • Method Detail

      • getApplicationName

        public final String getApplicationName()
      • getApplicationVersion

        protected String getApplicationVersion()
      • getApplicationDescription

        protected String getApplicationDescription()
      • stop

        public final void stop()
        Stop the server and trigger the internal stop mechanisms.
      • start

        public static void start​(TinyApplication app,
                                 String... args)
        Start the server.
        
         public class MyServer extends TinyServer {
             // implement...
        
             public static void main(String[] args) {
                 TinyApplication.start(new MyServer(), args);
             }
         }
         
        Parameters:
        app - The tiny server application to start.
        args - Arguments form command line.