For the upgrade from spring boot 2.5.6 to 2.6.1 I followed the instructions in the release notes: https://github.com/spring-projects/spring-boot/wiki/Spring-Boot-2.6-Release-Notes#embedded-mongo and added the key
spring.mongodb.embedded.version=3.6.23
to my application properties. Similar to issue https://github.com/flapdoodle-oss/de.flapdoodle.embed.mongo/issues/223 which is referenced in https://github.com/spring-projects/spring-boot/issues/12575. As suggested there i added
spring.mongodb.embedded.features=sync_delay,no_http_interface_arg
This does not fix the problem:
Caused by: java.io.IOException: Could not open inputStream for https://downloads.mongodb.org/win32/mongodb-win32-x86_64-3.6.23.zip with proxy Optional.empty
at de.flapdoodle.embed.process.store.UrlConnectionDownloader.downloadInputStream(UrlConnectionDownloader.java:134)
at de.flapdoodle.embed.process.store.UrlConnectionDownloader.download(UrlConnectionDownloader.java:72)
at de.flapdoodle.embed.process.store.ArtifactStore.checkDistribution(ArtifactStore.java:74)
at de.flapdoodle.embed.process.store.ArtifactStore.extractFileSet(ArtifactStore.java:79)
at de.flapdoodle.embed.process.store.ExtractedArtifactStore.extractFileSet(ExtractedArtifactStore.java:107)
at de.flapdoodle.embed.process.runtime.Starter.prepare(Starter.java:58)
... 105 more
Caused by: java.io.IOException: Server returned HTTP response code: 403 for URL: https://downloads.mongodb.org/win32/mongodb-win32-x86_64-3.6.23.zip
at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1894)
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1492)
at sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(HttpsURLConnectionImpl.java:263)
at de.flapdoodle.embed.process.store.UrlConnectionDownloader.downloadInputStream(UrlConnectionDownloader.java:130)
... 110 more
The problem is also present in version 2.5.6 if I add the two parameters to the application.properties, but my tests run if I leave them out.
I am working on a Windows machine.
Comment From: kloetzsch
What worked for me was to download the zip archive directly from https://fastdl.mongodb.org/win32/mongodb-win32-x86_64-2008plus-ssl-3.6.23.zip , rename it and save it manually into my user/.embeddedmongo/win32. So maybe only the download link is broken.
Comment From: snicoll
@kloetzsch there's nothing we can do about not being able to download MongoDB 3.6.23
. We use 3.5.5 just fine. I suggest to report this against the MongoDB project.