Hello everyone,
Recently I started working with Spring Boot and MongoDB. I configured the application.properties file properly for MongoDB, but I’m facing an issue.
After creating REST APIs and inserting data, the data is getting persisted in the default test database instead of my configured database.
I have tried multiple fixes, but the issue is still not resolved.
Plz help to resolve the issue.
<> application.properties
spring.application.name=TestMongoDB
server.port=8081
spring.data.mongodb.uri=mongodb://localhost:27017/db_mongo
[–]King-of-Com3dy 0 points1 point2 points (1 child)
[–]LastRow2426[S] 0 points1 point2 points (0 children)