Git Branching and Merging Strategy for a Shared Team Resource #21756
-
Hello to All, My team is facing a source control workflow challenge with Git when it comes to having a shared resource. Here is the team make-up:
Now, each sprint we have available the following branches:
See attached for diagrammed version of the branching structure above The problem is that the shared DBA needs to constantly and consistently make changes across teams for SQL-related items. In addition, for just SQL related items his changes need to be considered authoritative. His changes are localized to a specific folder, if that helps. Is there either a workflow or git configuration that will allow for the shared resource to effectively work either on his own branch while allowing for the team to effectively collaborate with his changes? Thank you for your time. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
The basic git branching workflow is this:
So let’s say that you have the following setup at the start of sprint S:
As the sprint continues, members of Team 1 and Team 2 follow the basic git workflow by:
So your shared resource has two options when doing their work:
So let’s say that in sprint S, the teams request the following:
If the two changes are independent, in other words they can be developed completely separately from each other, then the shared resource could choose to do the following for Team 1’s request:
And then do the same for Team 2’s request, just replace But if the two changes are dependent, in other words something in “update Y with Z” will require the work from “create X” to be done first, then the shared resource could choose to do the following:
Now you might say, “Whoa! Waitaminute! This isn’t the basic git workflow at all, Lee! What are you trying to pull?” Well, it is the basic git workflow, just modified a little. You see, back up above I said that both Team 1 and the shared resource created their branches based on Then when the shared resource moves on to the “update Y” task, they would:
This results in another three-way merge into The thing to keep in mind is that all of these are essentially the same workflow:
Keep in mind that: The more your two branches have in common when merging, the easier the merge process will be. I hope that helps! |
Beta Was this translation helpful? Give feedback.
-
Thank you for this write-up! Reviewing but looks great so far. Will ask questions when done. |
Beta Was this translation helpful? Give feedback.
The basic git branching workflow is this:
So let’s say that you have the following setup at the start of sprint S:
team-1-development
pointing tocurrent-release
team-2-development
pointing tocurrent-release
As the sprint continues, members of Team 1 and Team 2 follow the basic git workflow by:
team-1-development
orteam-2-development