/** Runs lifecycle start and starts server. */
 public void start() throws Exception {
   application.initialize(bootstrap);
   bootstrap.run(builtConfig, environment);
   application.run(builtConfig, environment);
   toggleManagedObjects(true);
   jettyServer.start();
 }
 @Override
 public void run(String... arguments) throws Exception {
   if (arguments.length == 0) {
     super.run("server", "hook-consumer.yml");
   } else {
     super.run(arguments);
   }
 }
Пример #3
0
 @Override
 public void initialize(Bootstrap<GCMDemoConfiguration> bootstrap) {
   super.initialize(bootstrap);
   bootstrap.addBundle(
       new SwaggerBundle<GCMDemoConfiguration>() {
         @Override
         public SwaggerBundleConfiguration getSwaggerBundleConfiguration(
             GCMDemoConfiguration configuration) {
           return configuration.getSwaggerBundleConfiguration();
         }
       });
   bootstrap.addBundle(hibernateBundle);
 }
Пример #4
0
 public CheckCommand(Application<T> application) {
   super("check", "Parses and validates the configuration file");
   this.configurationClass = application.getConfigurationClass();
 }