本文整理了Java中com.googlecode.flyway.core.Flyway.setCleanOnValidationError()
方法的一些代码示例,展示了Flyway.setCleanOnValidationError()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Flyway.setCleanOnValidationError()
方法的具体详情如下:
包路径:com.googlecode.flyway.core.Flyway
类名称:Flyway
方法名:setCleanOnValidationError
[英]Whether to automatically call clean or not when a validation error occurs.
This is exclusively intended as a convenience for development. Even tough we strongly recommend not to change migration scripts once they have been checked into SCM and run, this provides a way of dealing with this case in a smooth manner. The database will be wiped clean automatically, ensuring that the next migration will bring you back to the state checked into SCM.
Warning ! Do not enable in production !
[中]发生验证错误时是否自动调用clean。
这完全是为了方便开发。即使很难,我们强烈建议在将迁移脚本签入SCM并运行后不要更改它们,这提供了一种平稳处理这种情况的方法。数据库将被自动清除,确保下一次迁移将使您恢复到已签入SCM的状态。
警告请勿在生产中启用!
代码示例来源:origin: com.googlecode.flyway/flyway-core
setCleanOnValidationError(Boolean.parseBoolean(cleanOnValidationErrorProp));
代码示例来源:origin: com.googlecode.flyway/flyway-ant
flyway.setValidationErrorMode(ValidationErrorMode.valueOf(validationErrorModeValue.toUpperCase()));
flyway.setCleanOnValidationError(useValueIfPropertyNotSet(cleanOnValidationError, "cleanOnValidationError"));
flyway.setOutOfOrder(useValueIfPropertyNotSet(outOfOrder, "outOfOrder"));
String targetValue = useValueIfPropertyNotSet(target, "target");
内容来源于网络,如有侵权,请联系作者删除!