Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Removed outdated commit instructions.

...

A committer must sign off on a patch. It is very helpful if the community also reviews the patch, but in the end a committer must take responsibility for the correctness of the patch. If the match patch is simple enough and the committer feels confident in the review, a single +1 from a committer is sufficient to commit the patch. (Remember committers cannot review their own patch, so if . If a committer submits a patch, they should make sure that another committer reviews it.)

With the required number of approvals, a committer (any committer can do this including the one that committed the patch) can now make the change to the code base. Here are the recommended steps for committing:

  • make sure the code is up-to-date
    • git fetch
  • check out the correct branch
    • git checkout -b branch_name
  • apply the patch
    • patch -p0 < path_to_patch
  • Please make sure you run the tests are your machine as a final check before you commit using 
       mvn clean test.
        
       In case the mvn clean test is failing please do not commit. File a JIRA and ping the person who has committed the last patch on the branch you are committing to and politely ask him to revert. The committer responsible for the broken build can either choose to fix or revert the patch. This is quite important since broken unit tests can cause a lot of churn and confusion for other developers. Its best to keep the trunk/builds healthy.

...

Follow the instructions in How to Contribute guide to commit changes to Ambari.

If the Jira is a bug fix you may also need to commit the patch to the latest branch in git (trunk).