Hi.
You find the files here:
/eds-starter-mongodb/src/main/resources/application.properties
/eds-starter-mongodb/src/main/resources/application-development.properties
The first one is the default profile and is active when no profile is specified.
The second file is activated with this system environment flag: -Dspring.profiles.active=development
Spring Boot supports these MongoDB properties:
spring.data.mongodb.host= # the db host
spring.data.mongodb.port=27017 # the connection port (defaults to 27107)
spring.data.mongodb.uri=mongodb://localhost/test # connection URL
spring.data.mongo.repositories.enabled=true # if spring data repository support is enabled
If you need more control you can specify a @Bean like the following example. This example changes the WriteConcern to UNACKNOWLEDGED. The default is ACKNOWLEDGED which waits for a response from the server.
@Bean
public MongoClient mongo() throws Exception {
MongoClient mongoClient = new MongoClient("localhost");
mongoClient.setWriteConcern(WriteConcern.UNACKNOWLEDGED);
return mongoClient;
}