use of io.elastest.eim.database.mysql.EimDbCreator in project elastest-instrumentation-manager by elastest.
the class Bootstrap method init.
@Override
public void init(ServletConfig config) throws ServletException {
Info info = new Info().title("Swagger Server").description("RESTful API specification for the ElasTest Instrumentation Manager (EIM)").termsOfService("TBD").contact(new Contact().email("david.rojoa@atos.net")).license(new License().name("Apache 2.0").url("http://www.apache.org/licenses/LICENSE-2.0.html"));
ServletContext context = config.getServletContext();
Swagger swagger = new Swagger().info(info);
// load properties
String propertiesFile = "/WEB-INF/bootstrap.properties";
Properties.load(config.getServletContext().getResourceAsStream(propertiesFile), propertiesFile);
// create database schema
EimDbCreator dbCreator = new EimDbCreator();
dbCreator.createSchema();
new SwaggerContextService().withServletConfig(config).updateSwagger(swagger);
}
Aggregations