C#C
C#3y ago
sepp

✅ .NET Core N-Tier API Project question about repository pattern.

Hi, I am creating a web api project using n-tier architecture, I have API, Entities, DAL(Data access) and Services layer. I have implemented generic repository in DAL layer and now I am creating services in Service layer. I was thinking of a architecture which API layer communicates with Services layer and Services layer With DAL which also has a project reference to Entities layer. But in this way I have to do it like in the picture "new repository()" I added but some say it is bad to use it like this. What is best approach?
image.png
Was this page helpful?