diff options
Diffstat (limited to 'server/sonar-ce/src')
-rw-r--r-- | server/sonar-ce/src/main/java/org/sonar/ce/container/ComputeEngineContainerImpl.java | 5 | ||||
-rw-r--r-- | server/sonar-ce/src/main/java/org/sonar/ce/db/ReadOnlyPropertiesDao.java | 3 |
2 files changed, 7 insertions, 1 deletions
diff --git a/server/sonar-ce/src/main/java/org/sonar/ce/container/ComputeEngineContainerImpl.java b/server/sonar-ce/src/main/java/org/sonar/ce/container/ComputeEngineContainerImpl.java index e8204854e61..23fd2289ce2 100644 --- a/server/sonar-ce/src/main/java/org/sonar/ce/container/ComputeEngineContainerImpl.java +++ b/server/sonar-ce/src/main/java/org/sonar/ce/container/ComputeEngineContainerImpl.java @@ -83,6 +83,8 @@ import org.sonar.db.DaoModule; import org.sonar.db.DbClient; import org.sonar.db.DefaultDatabase; import org.sonar.db.MyBatis; +import org.sonar.db.audit.AuditPersister; +import org.sonar.db.audit.NoOpAuditPersister; import org.sonar.db.purge.PurgeProfiler; import org.sonar.process.NetworkUtilsImpl; import org.sonar.process.Props; @@ -203,6 +205,9 @@ public class ComputeEngineContainerImpl implements ComputeEngineContainer { level1.getComponentByType(CECoreExtensionsInstaller.class) .install(level1, hasPlatformLevel(1), noAdditionalSideFilter()); + if (level1.getComponentByType(AuditPersister.class) == null) { + level1.add(NoOpAuditPersister.class); + } level1.startComponents(); } diff --git a/server/sonar-ce/src/main/java/org/sonar/ce/db/ReadOnlyPropertiesDao.java b/server/sonar-ce/src/main/java/org/sonar/ce/db/ReadOnlyPropertiesDao.java index ea1c3b3475c..ab6511fc7b3 100644 --- a/server/sonar-ce/src/main/java/org/sonar/ce/db/ReadOnlyPropertiesDao.java +++ b/server/sonar-ce/src/main/java/org/sonar/ce/db/ReadOnlyPropertiesDao.java @@ -25,6 +25,7 @@ import org.sonar.api.utils.System2; import org.sonar.core.util.UuidFactory; import org.sonar.db.DbSession; import org.sonar.db.MyBatis; +import org.sonar.db.audit.NoOpAuditPersister; import org.sonar.db.property.PropertiesDao; import org.sonar.db.property.PropertyDto; @@ -39,7 +40,7 @@ import org.sonar.db.property.PropertyDto; */ public class ReadOnlyPropertiesDao extends PropertiesDao { public ReadOnlyPropertiesDao(MyBatis mybatis, System2 system2, UuidFactory uuidFactory) { - super(mybatis, system2, uuidFactory); + super(mybatis, system2, uuidFactory, new NoOpAuditPersister()); } @Override |