Skip to content

Commit

Permalink
feat: logging house messages store
Browse files Browse the repository at this point in the history
  • Loading branch information
Glaucio Jannotti committed Jul 1, 2024
1 parent 3df5a4b commit cb9127c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -103,9 +103,6 @@ public class LoggingHouseClientExtension implements ServiceExtension {
@Setting
private static final String EDC_DATASOURCE_REPAIR_SETTING = "edc.flyway.repair";

@Setting
private static final String FLYWAY_CLEAN_ENABLED = "edc.flyway.clean.enable";

@Setting
private static final String FLYWAY_CLEAN = "edc.flyway.clean";

Expand Down Expand Up @@ -163,7 +160,6 @@ private void runFlywayMigrations(ServiceExtensionContext context) {
var flywayService = new FlywayService(
context.getMonitor(),
context.getSetting(EDC_DATASOURCE_REPAIR_SETTING, false),
context.getSetting(FLYWAY_CLEAN_ENABLED, false),
context.getSetting(FLYWAY_CLEAN, false)
);
var migrationManager = new DatabaseMigrationManager(context.getConfig(), context.getMonitor(), flywayService);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,13 +35,11 @@ public class FlywayService {

private final Monitor monitor;
private final boolean tryRepairOnFailedMigration;
private final boolean cleanEnabled;
private final boolean clean;

public FlywayService(Monitor monitor, boolean tryRepairOnFailedMigration, boolean cleanEnabled, boolean clean) {
public FlywayService(Monitor monitor, boolean tryRepairOnFailedMigration, boolean clean) {
this.monitor = monitor;
this.tryRepairOnFailedMigration = tryRepairOnFailedMigration;
this.cleanEnabled = cleanEnabled;
this.clean = clean;
}

Expand Down Expand Up @@ -104,7 +102,7 @@ private Flyway setupFlyway(DatasourceProperties datasourceProperties) {
.dataSource(dataSource)
.table(MIGRATION_TABLE_NAME)
.locations(migrationLocations.toArray(new String[0]))
.cleanDisabled(!cleanEnabled)
.cleanDisabled(!clean)
.load();
}

Expand Down

0 comments on commit cb9127c

Please sign in to comment.