diff options
author | Simon Brandhof <simon.brandhof@gmail.com> | 2012-01-26 19:46:20 +0100 |
---|---|---|
committer | Simon Brandhof <simon.brandhof@gmail.com> | 2012-01-26 19:46:20 +0100 |
commit | 14091c078d2ca1793e5186ef4dd7b55002d1b1cd (patch) | |
tree | a5e3a7d5b8e9e065ca2cc7b27fb9b62e2609eb8f /plugins/sonar-dbcleaner-plugin | |
parent | c9141239198bdb0ac0155c018f44d8e04c1e4747 (diff) | |
download | sonarqube-14091c078d2ca1793e5186ef4dd7b55002d1b1cd.tar.gz sonarqube-14091c078d2ca1793e5186ef4dd7b55002d1b1cd.zip |
DBCleaner : fix deletion of events + improve mybatis batch mode
Diffstat (limited to 'plugins/sonar-dbcleaner-plugin')
3 files changed, 3 insertions, 4 deletions
diff --git a/plugins/sonar-dbcleaner-plugin/src/main/java/org/sonar/plugins/dbcleaner/period/DefaultPeriodCleaner.java b/plugins/sonar-dbcleaner-plugin/src/main/java/org/sonar/plugins/dbcleaner/period/DefaultPeriodCleaner.java index ea50bac1d65..c313ecc4f8b 100644 --- a/plugins/sonar-dbcleaner-plugin/src/main/java/org/sonar/plugins/dbcleaner/period/DefaultPeriodCleaner.java +++ b/plugins/sonar-dbcleaner-plugin/src/main/java/org/sonar/plugins/dbcleaner/period/DefaultPeriodCleaner.java @@ -19,7 +19,6 @@ */ package org.sonar.plugins.dbcleaner.period; -import com.google.common.annotations.VisibleForTesting; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.sonar.api.config.Settings; @@ -59,7 +58,7 @@ public final class DefaultPeriodCleaner implements PeriodCleaner { private void delete(List<PurgeableSnapshotDto> snapshots) { for (PurgeableSnapshotDto snapshot : snapshots) { - LOG.debug("<- Delete snapshot: " + DateUtils.formatDateTime(snapshot.getDate()) + " [" + snapshot.getSnapshotId() + "]"); + LOG.info("<- Delete snapshot: " + DateUtils.formatDateTime(snapshot.getDate()) + " [" + snapshot.getSnapshotId() + "]"); purgeDao.deleteSnapshots(PurgeSnapshotQuery.create().setRootSnapshotId(snapshot.getSnapshotId())); } } diff --git a/plugins/sonar-dbcleaner-plugin/src/main/java/org/sonar/plugins/dbcleaner/period/DeleteAllFilter.java b/plugins/sonar-dbcleaner-plugin/src/main/java/org/sonar/plugins/dbcleaner/period/DeleteAllFilter.java index 51fdd03ff05..78273c440c8 100644 --- a/plugins/sonar-dbcleaner-plugin/src/main/java/org/sonar/plugins/dbcleaner/period/DeleteAllFilter.java +++ b/plugins/sonar-dbcleaner-plugin/src/main/java/org/sonar/plugins/dbcleaner/period/DeleteAllFilter.java @@ -47,6 +47,6 @@ class DeleteAllFilter extends Filter { @Override void log() { - LoggerFactory.getLogger(getClass()).debug("-> Delete data prior to: " + DateUtils.formatDate(before)); + LoggerFactory.getLogger(getClass()).info("-> Delete data prior to: " + DateUtils.formatDate(before)); } } diff --git a/plugins/sonar-dbcleaner-plugin/src/main/java/org/sonar/plugins/dbcleaner/period/KeepOneFilter.java b/plugins/sonar-dbcleaner-plugin/src/main/java/org/sonar/plugins/dbcleaner/period/KeepOneFilter.java index fa8c5b3255f..7775c9bece9 100644 --- a/plugins/sonar-dbcleaner-plugin/src/main/java/org/sonar/plugins/dbcleaner/period/KeepOneFilter.java +++ b/plugins/sonar-dbcleaner-plugin/src/main/java/org/sonar/plugins/dbcleaner/period/KeepOneFilter.java @@ -55,7 +55,7 @@ class KeepOneFilter extends Filter { @Override void log() { - LoggerFactory.getLogger(getClass()).debug("-> Keep one snapshot per " + label + " between " + DateUtils.formatDate(start) + " and " + DateUtils.formatDate(end)); + LoggerFactory.getLogger(getClass()).info("-> Keep one snapshot per " + label + " between " + DateUtils.formatDate(start) + " and " + DateUtils.formatDate(end)); } private void appendSnapshotsToDelete(Interval interval, List<PurgeableSnapshotDto> toDelete) { |