Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • Create feature branches for new features using git flow
  • Push code to remote branches early and often (ideally at least once a day)
  • Have a clear and concise commit message
  • Write unit tests to cover the functionality both positive and negative cases
  • Build the code locally using maven without -DskipTests and check for any errors
  • Check the builds on bamboo for your feature branch
    • Make sure you fix errors early 
  • Ensure there are no checkstyle errors
    • mvn package -DskipTests will run checkstyle
  • Create pull request to merge the code to develop branch
  • Pull request description should contain the reason why the PR is created in a short summary
  • Keep the pull requests small and focused 
  • You can keep the same feature branch and keep sending pull requests as and when the feature is complete
    • Example: If you are working on implementing a metrics framework, the following steps would be logical points to send code reviews:
      • Java API  (without implementation)
      • REST API (without implementation)
      • Metrics processor implementation 
      • Java API implementation review
      • REST API implementation review
      • Kafka integration review
  • Fix all code review comments
  • Merge code after there is an approval in a pull request

...


Code Block
languagebash
titleSample development workflow
$ # Pull the latest develop
$ git flow feature start <feature-name> checkout -B develop origin/develop


$ # Create new feature branch
$ git checkout -b feature/CDAP-xxxx-description
 
$ # Make your changes
 
$ git add <files>
 
$ git commit -m "Clear and concise commit messages"
 
$ git# Rebase checkouton developlatest  changes $from gitdevelop pull if  needed 
$ git checkout feature/<branch>
 fetch origin 
$ git rebase origin/develop 
 

$ git push floworigin feature publish <feature-name>
 
$ git flow feature close <feature-name> 

...

/CDAP-xxxx-description

Checklist before sending pull requests
  •  Unit test builds for feature branches are successful in bamboo
  •  No checkstyle errors in feature branch
  •  Adequate unit tests are written for the feature

 

Continuous Delivery

The idea of Continuous Delivery (CD) is to keep the software always releasable so that we can release as often as possible whenever we wanted.

...

Basically new abstractions are built (e.g. new interfaces) and have an implementation of the existing behavior. New features can then now be built by implementing the same interfaces, and potentially uses feature toggle to select what implementation to be used.