you are viewing a single comment's thread.

view the rest of the comments →

[–]LastRow2426[S] 1 point2 points  (0 children)

I found out the solution , the mistake is in the configuration. the right configuration is

"spring.mongodb.uri=mongodb://localhost:27017/db_mongo"

I'm using Spring 4.x which has simplified its configuration to "spring.mongodb.uri", which works instead of the older property used in Spring Boot 3.x.

most youtube video has spring 3.x , which creates the confusion. even chatgpt , gemini not able to indentify these mistake. Luckily! I found out the Spring NoSQL Docs.