Create document for Alluxio coding guidelines

Description

We should have a document similar to the Contributor Guide which codifies the coding style rules we follow. This is especially valuable for rules for which we don't have checkstyle enforcement. The document will be under docs/ and published to the project website.

Things to include (Update this list here until the document is created):

1. After https://alluxio.atlassian.net/browse/ALLUXIO-1819, we never use Lists.newArrayList, Maps.newHashMap, etc, preferring to use the Java 7 diamond operator.
2. @Test method names end with "Test"
3. The tests for file AbcDef go in "AbcDefTest"
4. Test javadoc doesn't require exceptions.
5. Mark classes which aren't intended for extension as final
6. some util/conventions in Alluxio code base, including how to write integration tests (those resources, temp dir), how to access private members and etc
7. Thrift types should be immediately converted to wire types for internal use
8. Comments start with a capital letter and end with a period: // This is a comment.

Environment

None

Activity

Show:
Bin Fan
April 29, 2016, 8:21 AM

should we also add the following?
(1) javadoc Test cases indicating what we are testing and what the expectation is, javadoc doesn't require exceptions.
(2) mark `AbcDefTest` final?
(3) some util/conventions in Alluxio code base, including how to write integration tests (those resources, temp dir), how to access private members and etc

Assignee

Unassigned

Reporter

Andrew Audibert

Labels

Components

Affects versions

Priority

Minor