-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
(feat) make embedded mongodb version configurable and set to 3.4.10
(cherry picked from commit 15b4139)
- Loading branch information
1 parent
37e1be5
commit 161d321
Showing
4 changed files
with
28 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
package manon.app.config; | ||
|
||
import org.springframework.beans.factory.annotation.Value; | ||
import org.springframework.boot.autoconfigure.mongo.embedded.EmbeddedMongoProperties; | ||
import org.springframework.context.annotation.Bean; | ||
import org.springframework.context.annotation.Configuration; | ||
import org.springframework.context.annotation.Primary; | ||
|
||
@Configuration | ||
public class MongoConfig { | ||
|
||
@Value("${manon.mongodb.version}") | ||
private String mongodbVersion; | ||
|
||
@Bean | ||
@Primary | ||
public EmbeddedMongoProperties getEmbeddedMongoProperties() { | ||
EmbeddedMongoProperties embeddedMongoProperties = new EmbeddedMongoProperties(); | ||
embeddedMongoProperties.setVersion(mongodbVersion); | ||
return embeddedMongoProperties; | ||
} | ||
} |