[ 
https://issues.apache.org/jira/browse/GIRAPH-40?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13205976#comment-13205976
 ] 

Avery Ching commented on GIRAPH-40:
-----------------------------------

Here are some examples of one problem:  Checkstyle doesn't seem to be able to 
handle single indent versus double indent of 2 spaces when appropriate.  The 
below examples are what Checkstyle wants to have us do.

{noformat}
    @Override
    public BasicVertex<LongWritable, DoubleWritable, DoubleWritable, M>
    getCurrentVertex() throws IOException, InterruptedException {

  @Override
  public VertexReader<LongWritable, DoubleWritable, DoubleWritable, M>
  createVertexReader(InputSplit split, TaskAttemptContext context)
    throws IOException {
{noformat}

Also, checkstyle won't enforce indenting after a line wrap.  So both of these 
examples are passing checkstyle.

{noformat}
      aggregateVertices =
          configuration.getLong(
              PseudoRandomVertexInputFormat.AGGREGATE_VERTICES, 0);

      aggregateVertices =
        configuration.getLong(
          PseudoRandomVertexInputFormat.AGGREGATE_VERTICES, 0);
{noformat}


That being said, I think this is the right thing to do and we can make some 
sacrifices to have better, more uniform code.  Please let me know your thoughts.
                
> Adding checkstyle enforcement of Giraph code conventions
> --------------------------------------------------------
>
>                 Key: GIRAPH-40
>                 URL: https://issues.apache.org/jira/browse/GIRAPH-40
>             Project: Giraph
>          Issue Type: New Feature
>            Reporter: Avery Ching
>            Assignee: Avery Ching
>            Priority: Minor
>         Attachments: GIRAPH-40.patch
>
>
> Now that we have some code conventions (see GIRAPH-21), we should enforce 
> them with a maven checkstyle plugin.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to