aboutsummaryrefslogtreecommitdiffstats
path: root/server/sonar-server/src
diff options
context:
space:
mode:
authorTeryk Bellahsene <teryk.bellahsene@sonarsource.com>2014-12-02 15:54:24 +0100
committerTeryk Bellahsene <teryk.bellahsene@sonarsource.com>2014-12-02 16:25:49 +0100
commit6078d64d4cfb41032b4e17bec32905fa3d219ac3 (patch)
tree340bb34bee17ea6f090534175842d3ccf5a41067 /server/sonar-server/src
parentb85022a92061e8f320ea605309fa99107351d506 (diff)
downloadsonarqube-6078d64d4cfb41032b4e17bec32905fa3d219ac3.tar.gz
sonarqube-6078d64d4cfb41032b4e17bec32905fa3d219ac3.zip
SONAR-5804 delete file_sources when deleting a project or during the data cleaning step
Diffstat (limited to 'server/sonar-server/src')
-rw-r--r--server/sonar-server/src/main/java/org/sonar/server/component/ComponentCleanerService.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/server/sonar-server/src/main/java/org/sonar/server/component/ComponentCleanerService.java b/server/sonar-server/src/main/java/org/sonar/server/component/ComponentCleanerService.java
index 91c2a08dbf7..b7c65566034 100644
--- a/server/sonar-server/src/main/java/org/sonar/server/component/ComponentCleanerService.java
+++ b/server/sonar-server/src/main/java/org/sonar/server/component/ComponentCleanerService.java
@@ -25,6 +25,7 @@ import org.sonar.api.resources.Scopes;
import org.sonar.core.component.ComponentDto;
import org.sonar.core.persistence.DbSession;
import org.sonar.core.persistence.MyBatis;
+import org.sonar.core.purge.IdUuidPair;
import org.sonar.core.purge.PurgeDao;
import org.sonar.server.db.DbClient;
import org.sonar.server.issue.index.IssueAuthorizationIndexer;
@@ -51,7 +52,7 @@ public class ComponentCleanerService implements ServerComponent {
if (!Scopes.PROJECT.equals(project.scope())) {
throw new IllegalArgumentException("Only projects can be deleted");
}
- purgeDao.deleteResourceTree(project.getId());
+ purgeDao.deleteResourceTree(new IdUuidPair(project.getId(), project.uuid()));
dbSession.commit();
deleteFromIndices(project.uuid());