Skip to content

Commit 679231c

Browse files
juherrsnicoll
authored andcommitted
Upgrade to Embedded Mongo 3.2.5
See gh-28543
1 parent c5817f2 commit 679231c

File tree

3 files changed

+7
-13
lines changed

3 files changed

+7
-13
lines changed

spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/mongo/embedded/EmbeddedMongoAutoConfiguration.java

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -204,9 +204,11 @@ static class RuntimeConfigConfiguration {
204204
RuntimeConfig embeddedMongoRuntimeConfig(
205205
ObjectProvider<DownloadConfigBuilderCustomizer> downloadConfigBuilderCustomizers) {
206206
Logger logger = LoggerFactory.getLogger(getClass().getPackage().getName() + ".EmbeddedMongo");
207-
ProcessOutput processOutput = new ProcessOutput(Processors.logTo(logger, Slf4jLevel.INFO),
208-
Processors.logTo(logger, Slf4jLevel.ERROR),
209-
Processors.named("[console>]", Processors.logTo(logger, Slf4jLevel.DEBUG)));
207+
ProcessOutput processOutput = ProcessOutput.builder()
208+
.output(Processors.logTo(logger, Slf4jLevel.INFO))
209+
.error(Processors.logTo(logger, Slf4jLevel.ERROR))
210+
.commands(Processors.named("[console>]", Processors.logTo(logger, Slf4jLevel.DEBUG)))
211+
.build();
210212
return Defaults.runtimeConfigFor(Command.MongoD, logger).processOutput(processOutput)
211213
.artifactStore(getArtifactStore(logger, downloadConfigBuilderCustomizers.orderedStream()))
212214
.isDaemonProcess(false).build();

spring-boot-project/spring-boot-autoconfigure/src/test/java/org/springframework/boot/autoconfigure/mongo/embedded/EmbeddedMongoAutoConfigurationTests.java

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -98,11 +98,7 @@ void customUnknownVersion() {
9898

9999
@Test
100100
void customFeatures() {
101-
EnumSet<Feature> features = EnumSet.of(Feature.TEXT_SEARCH, Feature.SYNC_DELAY, Feature.ONLY_WITH_SSL,
102-
Feature.NO_HTTP_INTERFACE_ARG);
103-
if (isWindows()) {
104-
features.add(Feature.ONLY_WINDOWS_2008_SERVER);
105-
}
101+
EnumSet<Feature> features = EnumSet.of(Feature.TEXT_SEARCH, Feature.SYNC_DELAY, Feature.NO_HTTP_INTERFACE_ARG);
106102
loadWithValidVersion("spring.mongodb.embedded.features="
107103
+ features.stream().map(Feature::name).collect(Collectors.joining(", ")));
108104
assertThat(this.context.getBean(EmbeddedMongoProperties.class).getFeatures())
@@ -242,10 +238,6 @@ private void loadWithValidVersion(Class<?> config, String... environment) {
242238
this.context = ctx;
243239
}
244240

245-
private boolean isWindows() {
246-
return File.separatorChar == '\\';
247-
}
248-
249241
private int getPort(MongoClient client) {
250242
return client.getClusterDescription().getClusterSettings().getHosts().get(0).getPort();
251243
}

spring-boot-project/spring-boot-dependencies/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -307,7 +307,7 @@ bom {
307307
]
308308
}
309309
}
310-
library("Embedded Mongo", "3.0.0") {
310+
library("Embedded Mongo", "3.2.0") {
311311
group("de.flapdoodle.embed") {
312312
modules = [
313313
"de.flapdoodle.embed.mongo"

0 commit comments

Comments
 (0)