use of io.federecio.dropwizard.swagger.SwaggerBundleConfiguration in project registry by hortonworks.
the class RegistryApplication method initialize.
@Override
public void initialize(Bootstrap<RegistryConfiguration> bootstrap) {
// always deploy UI on /ui. If there is no other filter like Confluent etc, redirect / to /ui
bootstrap.addBundle(new AssetsBundle("/assets", "/ui", "index.html", "static"));
bootstrap.addBundle(new SwaggerBundle<RegistryConfiguration>() {
@Override
protected SwaggerBundleConfiguration getSwaggerBundleConfiguration(RegistryConfiguration registryConfiguration) {
return registryConfiguration.getSwaggerBundleConfiguration();
}
});
super.initialize(bootstrap);
}
use of io.federecio.dropwizard.swagger.SwaggerBundleConfiguration in project bisq-api by mrosseel.
the class BisqApiApplication method initialize.
@Override
public void initialize(Bootstrap<ApiConfiguration> bootstrap) {
bootstrap.setConfigurationSourceProvider(new ResourceConfigurationSourceProvider());
bootstrap.addBundle(new SwaggerBundle<ApiConfiguration>() {
@Override
protected SwaggerBundleConfiguration getSwaggerBundleConfiguration(ApiConfiguration configuration) {
return configuration.swaggerBundleConfiguration;
}
});
// Overriding settings through environment variables, added to override the http port from 8080 to something else
// See http://www.dropwizard.io/1.1.4/docs/manual/core.html#configuration
bootstrap.setConfigurationSourceProvider(new SubstitutingSourceProvider(bootstrap.getConfigurationSourceProvider(), new EnvironmentVariableSubstitutor(false)));
}
use of io.federecio.dropwizard.swagger.SwaggerBundleConfiguration in project bisq-api by mrosseel.
the class BisqApiApplication method initialize.
@Override
public void initialize(Bootstrap<ApiConfiguration> bootstrap) {
bootstrap.setConfigurationSourceProvider(new ResourceConfigurationSourceProvider());
bootstrap.addBundle(new SwaggerBundle<ApiConfiguration>() {
@Override
protected SwaggerBundleConfiguration getSwaggerBundleConfiguration(ApiConfiguration configuration) {
return configuration.swaggerBundleConfiguration;
}
});
// Overriding settings through environment variables, added to override the http port from 8080 to something else
// See http://www.dropwizard.io/1.1.4/docs/manual/core.html#configuration
bootstrap.setConfigurationSourceProvider(new SubstitutingSourceProvider(bootstrap.getConfigurationSourceProvider(), new EnvironmentVariableSubstitutor(false)));
}
Aggregations