deployment damaged fixed

This commit is contained in:
Jörg Henke
2026-01-15 18:16:43 +01:00
parent c5604d3ce8
commit 9699032250

View File

@@ -23,16 +23,17 @@ public class Main extends SpringBootServletInitializer {
@Override
protected SpringApplicationBuilder configure(SpringApplicationBuilder builder) {
ConfigurableApplicationContext context = builder.run();
DSLContext jooq = context.getBean(DSLContext.class);
Integer foundDbVersion = null;
try {
foundDbVersion = jooq.selectFrom(V_VERSION).fetchOne(V_VERSION.VERSION);
} catch (DataAccessException e) {
String msg = String.format("Wrong database version found; %d is required, but found %d", requiredDbVersion,
foundDbVersion);
throw new RuntimeException(msg);
}
// deactivated; damages deployment...
// ConfigurableApplicationContext context = builder.run();
// DSLContext jooq = context.getBean(DSLContext.class);
// Integer foundDbVersion = null;
// try {
// foundDbVersion = jooq.selectFrom(V_VERSION).fetchOne(V_VERSION.VERSION);
// } catch (DataAccessException e) {
// String msg = String.format("Wrong database version found; %d is required, but found %d", requiredDbVersion,
// foundDbVersion);
// throw new RuntimeException(msg);
// }
return builder.sources(Main.class);
}