Im developing 3 Azure Functions called EmployeeAPI, StudentAPI, ProjectsAPI all of which is accessing the same SQL database. I was instructed to make sure that each of projects are deployed separately independent of each other (separate code repository for each).
My problem is there are some common projects that are shared between the 3 and its a pain maintaining all 3 of them. If I changed 1 item let's say a database column, I need to update it on other projects as well.
Is there a way that the common project will reside in 1 repository and the changes will reflect on the 3 projects? Some advised me to create a Nuget package or reference the project.
This is the solution structure of each project (simplified)
EmployeeAPI
ApplicationLayer (shared)
DomainLayer (shared)
InfraLayer (shared)
Tests (shared)
StudentAPI
ApplicationLayer (shared)
DomainLayer (shared)
InfraLayer (shared)
Tests (shared)
ProjectsAPI
ApplicationLayer (shared)
DomainLayer (shared)
InfraLayer (shared)
Tests (shared)
I hope I explained it well :-D
Actually moving shared project to nuget package is the best what you can do if you want to keep API projects in separate repositories. Here you have docs showing you how to push nuget packages to feed.
You can also move all your shared project to 4th repo and the use them as submodule on your API projects. Here you have details about using submodules in Azure DevOps.