bug5619: introduced readConcern parameter for MetadataCollection; use MAJORITY only for tests, otherwise DEFAULT

This commit is contained in:
Axel Uhl
2021-08-24 11:09:56 +02:00
parent 6174a765f6
commit ff695c49f4
10 changed files with 27 additions and 16 deletions
@@ -43,6 +43,7 @@ import org.mockito.Matchers;
import org.mockito.Mockito;
import com.mongodb.MongoException;
import com.mongodb.ReadConcern;
import com.mongodb.WriteConcern;
import com.sap.sailing.domain.abstractlog.AbstractLogEventAuthor;
import com.sap.sailing.domain.abstractlog.impl.LogEventAuthorImpl;
@@ -264,7 +265,7 @@ public class MasterDataImportTest {
.spy(new RacingEventServiceImpl(null, MongoSensorFixStoreFactory.INSTANCE.getMongoGPSFixStore(
PersistenceFactory.INSTANCE
.getDefaultMongoObjectFactory(serviceFinderFactory), PersistenceFactory.INSTANCE
.getDefaultDomainObjectFactory(), serviceFinderFactory, WriteConcern.MAJORITY), serviceFinderFactory));
.getDefaultDomainObjectFactory(), serviceFinderFactory, ReadConcern.MAJORITY, WriteConcern.MAJORITY), serviceFinderFactory));
Mockito.doReturn(securityService).when(sourceService).getSecurityService();
Event event = sourceService.addEvent(TEST_EVENT_NAME, /* eventDescription */null, eventStartDate, eventEndDate,
"testVenue", false, eventUUID);