I'm trying to design an rest API in spring boot and what to ask about a few design decisions. I am completely confused by the whole difference between DAO vs Repository pattern/design. After hours of reading I still don't really understand the difference between the two or which one is preferred standard for designing API's that make backend connections.
Here's a simply UML diagram to highlight the high level view of the api:
This is how I understand a good architecture of an API. But then I came across this article using repository pattern instead of dao with a specification design. I don't understand why a dao interface can't just have a query
function? Does that break the idea of what a DAO is or something?
My question is: what's the best standard to use in today's day in developing an API in Spring Boot and Java 8