TimeZone.setDefault(TimeZone.getTimeZone("UTC"));
Discovery discovery = Discovery.build();
ConfigurationImpl configuration = ConfigurationImpl.load();
Extensions extensions = new Extensions(configuration, discovery);
List<Module> modules = Lists.newArrayList();
modules.add(new NullMetricsModule());
modules.add(new GuiceXaasConfig(configuration));
modules.add(new ConfigurationModule(configuration));
modules.add(new CacheModule());
modules.add(new JdbcGuiceModule());
modules.add(new PlatformLayerServletModule(extensions));
modules.add(new PlatformlayerValidationModule());
Injector injector = extensions.createInjector(configuration, modules);
ResultSetMappersProvider provider = injector.getInstance(ResultSetMappersProvider.class);
provider.addAll(ItemEntity.class, TagEntity.class, SchedulerRecordEntity.class, JobEntity.class,
JobExecutionEntity.class);
extensions.addEntities(provider);
StandaloneXaasWebserver server = injector.getInstance(StandaloneXaasWebserver.class);
// Temporary hack
if (args.length != 0) {