How to Contribute To Hama
Getting the source code
Download the latest stable Hama source release from http://www.apache.org/dyn/closer.cgi/hama and extract the files. You can get the latest source code using:
Eclipse Project File Generation
We are using Maven so you can easily generate project files for our modules.
First you should make sure you have set up your workspace correctly with maven:
Note: "/home/user/workspace/" should be the path to your workspace.
You can check if it was successful in Eclipse via:
If you see the M2_REPO variable, it worked correctly.
Now run the following commands:
You can now import the projects into your eclipse workspace via:
Before you start, send a message to the Hama developer mailing list, or file a bug report in Jira. Describe your proposed changes and check that they fit in with what others are doing and have planned for the project. Be patient, it may take folks a while to understand your requirements.
- Jira usage guidelines
Modify the source code and add some (very) nice features using your favorite IDE.
But take care about the following points
- All public classes and methods should have informative Javadoc comments.
- Code should be formatted according to hama-code-formatter hama-code-formatter fallbacklink
- Contributions should pass existing unit tests.
- New unit tests should be provided to demonstrate bugs and fixes.
- Please resolve all warnings according to "Eclipse Warning Levels" below
Creating a patch
Check to see what files you have modified with:
Add any new files with:
In order to create a patch, type
Submitting a pull request to GitHub
The Hama apache repository is cloned at the GitHub https://github.com/apache/hama, which is connected to the JIRA issue manager. First, you need to create a GitHub account. Then, you need to fork the Hama master by pushing the fork button on the Hama master. Let say that your GitHub username is xxxxx. You should always bring your local fork up-to-date using the following git commands:
Lets say that you want to create a pull request for the HAMA issue [HAMA-1234] ...issue-title.... You need to create a new branch of your local fork, say named HAMA-1234
Contributors should join the Hama mailing lists. In particular, the commit list (to see changes as they are made), the dev list (to join discussions of changes) and the user list (to help others).
- Variables should be meaningful so that they are easily understood by other developers. For instance, the declaration of 'String serverName' would be better than 'String str'.
- Indentation is 2 spaces, not 4.
- Argument checks for NullPointerException, IlleagalArgumentException, etc.
Eclipse Warning Levels
We expect that you turn on following warnings in eclipse:
(can be found in the project preferences or global preferences under Java/Compiler/"Errors/Warnings")