Answers: <p>Key issue with this approach is that applying commits selectively is extremely problematic. Basically, how do you know whether commits are dependent or independent?</p>
  <p>As you correctly mentioned, this is one of the issues with Gitflow itself, so the solution is shifting methodologies. Preferred way today is Trunk-Based Development (TBD) - <a href="https://trunkbaseddevelopment.com/" rel="nofollow noreferrer">https://trunkbaseddevelopment.com/</a> - refer to &quot;Accelerate&quot; book for evidence.</p>
  <p>Under TBD you can choose a style of work where you have short-lived feature branches. Once a feature is complete, pull request is created and QA can test this feature selectively under such short-lived branch and then approve the merge to main.</p>
  <p>This way you know that your branches are independent (unlike commits in Gitflow) and approve features selectively. Note, that you can achieve something similar in Gitflow with multiple different branches, but this gets extremely messy there.</p>
  
Answers: CC BY-SA 4.0
Answers: 2021-02-24T15:15:47.770Z
Answers: 2021-02-24T15:15:47.770Z
Answers: taleodor
Body: <p>I am having some troubles finding a better model for my CI/CD cycle.</p>
  <p>This is mainly gitflow issue.</p>
  <p>My current model : We have 2 bitbucket branches : master and develop.</p>
  <p>Both are linked via webhooks to jenkins to be deployed to prod. and dev. servers.</p>
  <p>QA team for testing features and releases on dev. server.</p>
  <p>Team of developers for both frontend and for backend. With lots of troubles.</p>
  <p>The problem : Team manager wants to be able to have better control over accepted/rejected features. Say : developer1 committed a feature to develop branch, developer2 added a hotfix to develop, we want QA team to easily test them both separately, and then testing both together with the least hassle possible. And afterwards easily select what commit stays and moved to master branch.</p>
  <p>As I said, this is mainly gitflow issue.</p>
  <p>Any suggestions?</p>
  
Tags: <git><deployment><continuous-deployment><continuous-delivery><bitbucket-pipelines>
Title: Is there a better model for my CI/CD cycle?
UserDisplayName: Ahmed Hamad
ThreadText: # Is there a better model for my CI/CD cycle?
  
  (Asked by: username_0 on 2021-02-24)
  
  I am having some troubles finding a better model for my CI/CD cycle.
  
  This is mainly gitflow issue.
  
  My current model : We have 2 bitbucket branches : master and develop.
  
  Both are linked via webhooks to jenkins to be deployed to prod. and dev. servers.
  
  QA team for testing features and releases on dev. server.
  
  Team of developers for both frontend and for backend. With lots of troubles.
  
  The problem : Team manager wants to be able to have better control over accepted/rejected features. Say : developer1 committed a feature to develop branch, developer2 added a hotfix to develop, we want QA team to easily test them both separately, and then testing both together with the least hassle possible. And afterwards easily select what commit stays and moved to master branch.
  
  As I said, this is mainly gitflow issue.
  
  Any suggestions?
  
  **Tags:** git, deployment, continuous-deployment, continuous-delivery, bitbucket-pipelines
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2021-02-24. Score: 1
  
  Key issue with this approach is that applying commits selectively is extremely problematic. Basically, how do you know whether commits are dependent or independent?
  
  As you correctly mentioned, this is one of the issues with Gitflow itself, so the solution is shifting methodologies. Preferred way today is Trunk-Based Development (TBD) - <https://trunkbaseddevelopment.com/> - refer to "Accelerate" book for evidence.
  
  Under TBD you can choose a style of work where you have short-lived feature branches. Once a feature is complete, pull request is created and QA can test this feature selectively under such short-lived branch and then approve the merge to main.
  
  This way you know that your branches are independent (unlike commits in Gitflow) and approve features selectively. Note, that you can achieve something similar in Gitflow with multiple different branches, but this gets extremely messy there.
  
  
  ---
  
  