异常捕获

This commit is contained in:
wangw 2025-03-27 16:19:59 +08:00
parent 86c475ecdf
commit 2e6143e31b
1 changed files with 2 additions and 2 deletions

View File

@ -31,7 +31,7 @@ import java.util.List;
*/ */
@Slf4j @Slf4j
@Service @Service
@Profile({"prod"}) //@Profile({"prod"})
public class SqlScriptServiceImpl extends ServiceImpl<SqlScriptMapper, SqlScript> implements SqlScriptService { public class SqlScriptServiceImpl extends ServiceImpl<SqlScriptMapper, SqlScript> implements SqlScriptService {
@ -82,7 +82,7 @@ public class SqlScriptServiceImpl extends ServiceImpl<SqlScriptMapper, SqlScript
} }
markSqlAsExecuted(directory.getName(), sqlFile.getName(), sql); markSqlAsExecuted(directory.getName(), sqlFile.getName(), sql);
} }
} catch (IOException e) { } catch (Exception e) {
log.error("执行SQL文件异常:{}", sqlFile.getName()); log.error("执行SQL文件异常:{}", sqlFile.getName());
} }
} }