本文整理了Java中com.googlecode.flyway.core.Flyway.clean()
方法的一些代码示例,展示了Flyway.clean()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Flyway.clean()
方法的具体详情如下:
包路径:com.googlecode.flyway.core.Flyway
类名称:Flyway
方法名:clean
[英]Drops all objects (tables, views, procedures, triggers, ...) in the configured schemas. The schemas are cleaned in the order specified by the schemas property.
[中]删除所有对象(表、视图、过程、触发器等)在配置的模式中。按照schemas属性指定的顺序清理架构。
代码示例来源:origin: DeemOpen/zkui
public void checkNCreate() {
try {
Flyway flyway = new Flyway();
flyway.setDataSource(globalProps.getProperty("jdbcUrl"), globalProps.getProperty("jdbcUser"), globalProps.getProperty("jdbcPwd"));
//Will wipe db each time. Avoid this in prod.
if (globalProps.getProperty("env").equals("dev")) {
flyway.clean();
}
//Remove the above line if deploying to prod.
flyway.migrate();
} catch (Exception ex) {
logger.error("Error trying to migrate db! Not severe hence proceeding forward.");
}
}
代码示例来源:origin: com.googlecode.flyway/flyway-ant
@Override
protected void doExecute(Flyway flyway) throws Exception {
flyway.clean();
}
}
代码示例来源:origin: minnal/minnal
public void destroy() {
flyway.clean();
}
代码示例来源:origin: ch.inftec.ju/ju-testing
@Override
public void execute(DataSource ds) {
Flyway flyway = new Flyway();
flyway.setDataSource(ds);
flyway.clean(); // FIXME: Try Liquibase.dropAll()
}
});
代码示例来源:origin: com.googlecode.flyway-test-extensions/flyway-spring3-test
+ executionInfo + "'.");
flyWay.clean();
代码示例来源:origin: com.googlecode.flyway-test-extensions/flyway-spring-test
+ executionInfo + "'.");
flyWay.clean();
代码示例来源:origin: com.googlecode.flyway-test-extensions/flyway-spring4-test
+ executionInfo + "'.");
flyWay.clean();
代码示例来源:origin: com.googlecode.flyway/flyway-commandline
flyway.clean();
} else if ("init".equals(operation)) {
flyway.init();
内容来源于网络,如有侵权,请联系作者删除!