use of io.datarouter.web.config.service.PrivateDomain in project datarouter by hotpads.
the class DatarouterWebGuiceModule method configureServlets.
@Override
protected void configureServlets() {
install(new DatarouterSecretPluginBuilderImpl().build().getAsDefaultBinderModule());
install(new DatarouterStorageGuiceModule());
bind(ServletContextSupplier.class).toInstance(new ServletContextProvider(getServletContext()));
bind(JsonSerializer.class).annotatedWith(Names.named(HandlerEncoder.DEFAULT_HANDLER_SERIALIZER)).to(GsonJsonSerializer.class);
bind(PortIdentifier.class).annotatedWith(Names.named(CompoundPortIdentifier.COMPOUND_PORT_IDENTIFIER)).to(CompoundPortIdentifier.class);
bindDefault(DatarouterAuthenticationConfig.class, BaseDatarouterAuthenticationConfig.class);
bindDefaultInstance(ServiceName.class, new ServiceName(""));
bindDefaultInstance(PublicDomain.class, new PublicDomain(""));
bindDefaultInstance(PrivateDomain.class, new PrivateDomain(""));
bindDefaultInstance(ContextName.class, new ContextName(""));
bindDefault(BaseDatarouterSessionDao.class, NoOpDatarouterSessionDao.class);
bindDefault(BaseDatarouterSamlDao.class, NoOpDatarouterSamlDao.class);
bindDefault(ExceptionRecorder.class, NoOpExceptionRecorder.class);
optionalBinder(AppNavBar.class);
bindDefault(RoleManager.class, DatarouterRoleManager.class);
optionalBinder(SamlRegistrar.class);
bindDefault(SettingFinder.class, MemorySettingFinder.class);
bindDefault(UserSessionService.class, NoOpUserSessionService.class);
bindDefault(CurrentSessionInfo.class, NoOpCurrentSessionInfo.class);
bindDefault(LatencyMonitoringGraphLink.class, NoOpLatencyMonitoringGraphLink.class);
bindDefault(AppNavBarRegistrySupplier.class, NoOpAppNavBarRegistry.class);
bindDefault(ChangelogRecorder.class, NoOpChangelogRecorder.class);
// define as singleton for everybody
bind(Gson.class).toInstance(GsonTool.GSON);
bindDefaultInstance(DefaultEmailDistributionListZoneId.class, new DefaultEmailDistributionListZoneId(ZoneId.systemDefault()));
}
use of io.datarouter.web.config.service.PrivateDomain in project datarouter by hotpads.
the class DatarouterWebPlugin method configure.
@Override
public void configure() {
bind(FilesRoot.class).to(filesClass);
bindActualNullSafe(ExceptionRecorder.class, exceptionRecorderClass);
bindActualNullSafe(DatarouterAuthenticationConfig.class, authenticationConfigClass);
bindActualNullSafe(CurrentSessionInfo.class, currentSessionInfoClass);
bindDefault(ExceptionHandlingConfig.class, exceptionHandlingConfigClass);
bindActualInstance(AppListenersClasses.class, new DatarouterAppListenersClasses(appListenerClasses));
bindActualInstance(WebAppListenersClasses.class, new DatarouterWebAppListenersClasses(webAppListenerClasses));
bindActualNullSafe(RoleManager.class, roleManagerClass);
bindActualNullSafe(UserSessionService.class, userSessionServiceClass);
bindActualNullSafe(DatarouterUserExternalDetailService.class, datarouterUserExternalDetailClass);
bindActualNullSafe(AppNavBarRegistrySupplier.class, appNavBarRegistrySupplier);
bind(HomepageHandler.class).to(homepageHandler);
bind(HomepageRouteSet.class).to(homepageRouteSet);
bindActualInstance(PluginRegistrySupplier.class, new PluginRegistry(registeredPlugins));
bindActualInstance(NodeWidgetDatabeanExporterLinkSupplier.class, new NodeWidgetDatabeanExporterLink(nodeWidgetDatabeanExporterLink));
bindActualInstance(NodeWidgetTableCountLinkSupplier.class, new NodeWidgetTableCountLink(nodeWidgetTableCountLink));
bind(RequestProxySetter.class).to(requestProxy);
bindActualInstance(DefaultEmailDistributionListZoneId.class, new DefaultEmailDistributionListZoneId(defaultEmailDistributionListZoneId));
bindActualInstance(DailyDigestEmailZoneId.class, new DailyDigestEmailZoneId(dailyDigestEmailZoneId));
bindActualInstance(ServiceName.class, new ServiceName(serviceName));
bindActualInstance(PublicDomain.class, new PublicDomain(publicDomain));
bindActualInstance(PrivateDomain.class, new PrivateDomain(privateDomain));
bindActualInstance(ContextName.class, new ContextName(contextName));
}
Aggregations