You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by ja...@apache.org on 2019/01/18 02:52:00 UTC
[incubator-pinot] branch master updated: Add Pinot code style
(#3705)
This is an automated email from the ASF dual-hosted git repository.
jackie pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-pinot.git
The following commit(s) were added to refs/heads/master by this push:
new a658f19 Add Pinot code style (#3705)
a658f19 is described below
commit a658f19d0c79e77fce6122ab86b5c657c52d91b7
Author: Xiaotian (Jackie) Jiang <17...@users.noreply.github.com>
AuthorDate: Thu Jan 17 18:51:56 2019 -0800
Add Pinot code style (#3705)
Add code style config for eclipse and intellij
Add checkstyle config and maven plugin
All code style configs are borrowed from LinkedIn style
Command for checkstyle plugin: mvn checkstyle:check
Import code style to Intellij: https://www.jetbrains.com/help/idea/settings-code-style.html
1. Navigate to Preferences -> Editor -> Code Style -> Java
2. Select Import Scheme -> Intellij IDES code style XML
3. Choose codestyle-intellij.xml
---
config/checkstyle.xml | 211 ++++++++++
pinot-style.xml => config/codestyle-eclipse.xml | 54 +--
config/codestyle-intellij.xml | 505 ++++++++++++++++++++++++
config/suppressions.xml | 30 ++
pom.xml | 24 +-
5 files changed, 798 insertions(+), 26 deletions(-)
diff --git a/config/checkstyle.xml b/config/checkstyle.xml
new file mode 100644
index 0000000..968b26c
--- /dev/null
+++ b/config/checkstyle.xml
@@ -0,0 +1,211 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+
+-->
+<!DOCTYPE module PUBLIC
+ "-//Checkstyle//DTD Checkstyle Configuration 1.3//EN"
+ "https://checkstyle.org/dtds/configuration_1_3.dtd">
+
+<module name="Checker">
+ <property name="severity" value="${checkstyle.severity}" default="warning"/>
+
+ <module name="TreeWalker">
+ <module name="FileContentsHolder"/>
+
+ <!-- ANNOTATIONS -->
+
+ <!-- No trailing empty parenthesis or commas -->
+ <module name="AnnotationUseStyle">
+ <property name="elementStyle" value="ignore"/>
+ </module>
+ <!-- Ensure @Override is present when {@inheritDoc} Javadoc tag is present -->
+ <module name="MissingOverride"/>
+ <!-- Package level annotations belong in package-info.java -->
+ <module name="PackageAnnotation"/>
+
+ <!-- BLOCKS -->
+
+ <!-- Block opening brace on same line -->
+ <module name="LeftCurly">
+ <property name="option" value="eol"/>
+ </module>
+ <!-- Block blocing brace on same line -->
+ <module name="RightCurly">
+ <property name="option" value="same"/>
+ </module>
+ <!-- Always use braces even if optional -->
+ <module name="NeedBraces"/>
+
+ <!-- CLASS DESIGN -->
+
+ <!-- Classes containing only static methods should not have a public constructor -->
+ <module name="HideUtilityClassConstructor"/>
+
+ <!-- CODING -->
+
+ <!-- Use Java style array declarations (e.g. String[] names), not C style (e.g. String names[]) -->
+ <module name="ArrayTypeStyle"/>
+ <!-- If covariant equals defined, standard equals must also be defined -->
+ <module name="CovariantEquals"/>
+ <!-- Switch 'default' case must appear last -->
+ <module name="DefaultComesLast"/>
+ <!-- Override equals and hashCode together -->
+ <module name="EqualsHashCode"/>
+ <!-- No fall through in switch cases, even the last one -->
+ <module name="FallThrough">
+ <property name="checkLastCaseGroup" value="true"/>
+ </module>
+ <!-- Do not perform assignments embedded within expressions -->
+ <module name="InnerAssignment"/>
+ <!-- Switch statements must have a 'default' case -->
+ <module name="MissingSwitchDefault"/>
+ <!-- Do not modify the 'for' loop control variable -->
+ <module name="ModifiedControlVariable"/>
+ <!-- Each variable delcaration must be on a separate line -->
+ <module name="MultipleVariableDeclarations"/>
+ <!-- Each statement (i.e. code terminated by a semicolon) must be on a separate line -->
+ <module name="OneStatementPerLine"/>
+ <!-- Classes must have an explicit package declaration -->
+ <module name="PackageDeclaration"/>
+ <!-- Do not test boolean expressions against the values true or false -->
+ <module name="SimplifyBooleanExpression"/>
+ <!-- Do not test for boolean conditions and return the values true or false -->
+ <module name="SimplifyBooleanReturn"/>
+ <!-- Do not use '==' to compare string against a literal; use 'equals' -->
+ <module name="StringLiteralEquality"/>
+ <!-- Use 'L' with long literals -->
+ <module name="UpperEll"/>
+
+ <!-- IMPORTS -->
+
+ <!-- No imports statements using '*' notation except static imports -->
+ <module name="AvoidStarImport">
+ <property name="allowStaticMemberImports" value="true"/>
+ </module>
+ <!-- Do not import 'sun' packages -->
+ <module name="IllegalImport"/>
+ <!-- Do not duplicate import statements -->
+ <module name="RedundantImport"/>
+ <!-- Eliminate unused imports -->
+ <module name="UnusedImports"/>
+
+ <!-- JAVADOC COMMENTS -->
+
+ <!-- If you have a Javadoc comment, make sure it is properly formed -->
+ <module name="JavadocStyle">
+ <property name="checkFirstSentence" value="false"/>
+ </module>
+
+ <!-- NAMING CONVENTIONS -->
+
+ <!-- Generic parameters for a class must be uppercase letters (e.g. <T>, <OLD>) -->
+ <module name="ClassTypeParameterName">
+ <property name="format" value="^[A-Z]+$"/>
+ </module>
+ <!-- Constants must be all uppercase letters separated by underscores -->
+ <module name="ConstantName">
+ <property name="format" value="^(_?log)|([A-Z][A-Z0-9]*(_[A-Z0-9]+)*)$"/>
+ </module>
+ <!-- Local variables must be camel case starting with lowercase letter -->
+ <module name="LocalFinalVariableName"/>
+ <module name="LocalVariableName"/>
+ <!-- Member variables must be camel case starting with an underscore and lowercase letter -->
+ <module name="MemberName">
+ <property name="format" value="^_[a-z][a-zA-Z0-9]*$"/>
+ </module>
+ <!-- Method name must be camel case starting with a lowercase letter -->
+ <module name="MethodName"/>
+ <!-- Generic parameters for a method must be uppercase letters (e.g. <V>, <NEW>) -->
+ <module name="MethodTypeParameterName">
+ <property name="format" value="^[A-Z]+$"/>
+ </module>
+ <!-- Package name must be all lowercase letters separated by periods -->
+ <module name="PackageName">
+ <property name="format" value="^[a-z]+(\.[a-z][a-z0-9]*)*$"/>
+ </module>
+ <!-- Parameters must be camel case starting with a lowercase letter -->
+ <module name="ParameterName"/>
+ <!-- Static variables must be camel case starting with an underscore and lowercase letter -->
+ <module name="StaticVariableName">
+ <property name="format" value="^_[a-z][a-zA-Z0-9]*$"/>
+ </module>
+ <!-- Type names must be camel case starting with an uppercase letter -->
+ <module name="TypeName"/>
+
+ <!-- LENGTHS -->
+
+ <!-- Desired line length is 120 but allow some overrun beyond that -->
+ <module name="LineLength">
+ <property name="max" value="160"/>
+ <message key="maxLineLen"
+ value="Line is longer than {0,number,integer} characters (found {1,number,integer}). Try to keep lines under 120 characters."/>
+ </module>
+
+ <!-- WHITESPACE -->
+
+ <module name="GenericWhitespace"/>
+ <module name="MethodParamPad"/>
+ <module name="NoWhitespaceAfter">
+ <property name="tokens" value="BNOT,DEC,DOT,INC,LNOT,UNARY_MINUS,UNARY_PLUS"/>
+ </module>
+ <module name="NoWhitespaceBefore"/>
+ <module name="OperatorWrap"/>
+ <module name="ParenPad"/>
+ <module name="TypecastParenPad">
+ <property name="tokens" value="RPAREN,TYPECAST"/>
+ </module>
+ <module name="WhitespaceAfter"/>
+ <module name="WhitespaceAround"/>
+
+ <!-- Do not allow meaningless, IDE generated parameter names -->
+ <module name="RegexpSinglelineJava">
+ <property name="format" value="[\s]+arg[\d]+[,\)]"/>
+ <property name="message" value="Replace argN with a meaningful parameter name"/>
+ </module>
+ </module>
+
+ <!-- Do not allow tab characters in source files -->
+ <module name="FileTabCharacter"/>
+
+ <!-- Ensure parameter and exception names are present on @param and @throws tags -->
+ <module name="RegexpSingleline">
+ <property name="format" value="\*[\s]*@(throws|param)[\s]*$"/>
+ <property name="message" value="Missing parameter or exception name"/>
+ </module>
+ <!-- IDE generated code must be reviewed by developer -->
+ <module name="RegexpSingleline">
+ <property name="format" value="\/\/[\s]*TODO[\s]+Auto-generated"/>
+ <property name="message" value="Replace IDE generated code with real implementation"/>
+ </module>
+ <!-- Detect commonly misspelled Javadoc tags -->
+ <module name="RegexpSingleline">
+ <property name="format" value="\*[\s]*@(params|throw|returns)[\s]+"/>
+ <property name="message" value="Correct misspelled Javadoc tag"/>
+ </module>
+
+ <!-- Read checker suppressions from a file -->
+ <module name="SuppressionFilter">
+ <property name="file" value="${config_loc}/suppressions.xml"/>
+ </module>
+ <!-- Allow Checkstyle warnings to be suppressed using trailing comments -->
+ <module name="SuppressWithNearbyCommentFilter"/>
+ <!-- Allow Checkstyle warnings to be suppressed using block comments -->
+ <module name="SuppressionCommentFilter"/>
+</module>
diff --git a/pinot-style.xml b/config/codestyle-eclipse.xml
similarity index 94%
rename from pinot-style.xml
rename to config/codestyle-eclipse.xml
index 6433cce..cd6e7b2 100644
--- a/pinot-style.xml
+++ b/config/codestyle-eclipse.xml
@@ -20,8 +20,8 @@
-->
<profiles version="12">
-<profile kind="CodeFormatterProfile" name="Pinot" version="12">
-<setting id="org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags" value="do not insert"/>
+<profile kind="CodeFormatterProfile" name="Pinot Style" version="12">
+<setting id="org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.disabling_tag" value="@formatter:off"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters" value="do not insert"/>
@@ -32,7 +32,7 @@
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries" value="true"/>
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.blank_lines_before_field" value="0"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while" value="do not insert"/>
@@ -42,13 +42,13 @@
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line" value="false"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_ellipsis" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases" value="true"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.alignment_for_multiple_fields" value="16"/>
-<setting id="org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer" value="16"/>
-<setting id="org.eclipse.jdt.core.formatter.alignment_for_conditional_expression" value="80"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer" value="0"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_conditional_expression" value="16"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_binary_operator" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard" value="do not insert"/>
@@ -65,13 +65,13 @@
<setting id="org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation" value="16"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk" value="1"/>
+<setting id="org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk" value="0"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_binary_operator" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.blank_lines_before_package" value="0"/>
<setting id="org.eclipse.jdt.core.compiler.source" value="1.6"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.comment.format_line_comments" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.comment.format_line_comments" value="false"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.join_wrapped_lines" value="true"/>
@@ -92,9 +92,9 @@
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment" value="false"/>
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration" value="insert"/>
-<setting id="org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment" value="true"/>
-<setting id="org.eclipse.jdt.core.formatter.lineSplit" value="100"/>
+<setting id="org.eclipse.jdt.core.formatter.lineSplit" value="120"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression" value="do not insert"/>
@@ -111,6 +111,7 @@
<setting id="org.eclipse.jdt.core.compiler.problem.assertIdentifier" value="error"/>
<setting id="org.eclipse.jdt.core.formatter.tabulation.char" value="space"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.indent_statements_compare_to_body" value="true"/>
<setting id="org.eclipse.jdt.core.formatter.blank_lines_before_method" value="1"/>
@@ -124,6 +125,7 @@
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.alignment_for_method_declaration" value="0"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation" value="do not insert"/>
@@ -136,17 +138,19 @@
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments" value="false"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments" value="do not insert"/>
<setting id="org.eclipse.jdt.core.compiler.problem.enumIdentifier" value="error"/>
-<setting id="org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch" value="false"/>
+<setting id="org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch" value="true"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_ellipsis" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.brace_position_for_block" value="end_of_line"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.brace_position_for_method_declaration" value="end_of_line"/>
<setting id="org.eclipse.jdt.core.formatter.compact_else_if" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch" value="true"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column" value="true"/>
@@ -155,6 +159,7 @@
<setting id="org.eclipse.jdt.core.formatter.brace_position_for_enum_constant" value="end_of_line"/>
<setting id="org.eclipse.jdt.core.formatter.comment.indent_root_tags" value="true"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch" value="16"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters" value="do not insert"/>
@@ -162,15 +167,15 @@
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.tabulation.size" value="2"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws" value="do not insert"/>
-<setting id="org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if" value="do not insert"/>
+<setting id="org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment" value="false"/>
<setting id="org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration" value="16"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator" value="insert"/>
@@ -197,7 +202,7 @@
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line" value="false"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line" value="false"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters" value="insert"/>
@@ -211,15 +216,16 @@
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while" value="do not insert"/>
<setting id="org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode" value="enabled"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line" value="true"/>
-<setting id="org.eclipse.jdt.core.formatter.insert_new_line_after_label" value="insert"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_new_line_after_label" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant" value="16"/>
-<setting id="org.eclipse.jdt.core.formatter.comment.format_javadoc_comments" value="true"/>
-<setting id="org.eclipse.jdt.core.formatter.comment.line_length" value="100"/>
+<setting id="org.eclipse.jdt.core.formatter.comment.format_javadoc_comments" value="false"/>
+<setting id="org.eclipse.jdt.core.formatter.comment.line_length" value="120"/>
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.blank_lines_between_import_groups" value="1"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments" value="do not insert"/>
@@ -235,7 +241,7 @@
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.indent_statements_compare_to_block" value="true"/>
<setting id="org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration" value="16"/>
-<setting id="org.eclipse.jdt.core.formatter.join_lines_in_comments" value="false"/>
+<setting id="org.eclipse.jdt.core.formatter.join_lines_in_comments" value="true"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.alignment_for_compact_if" value="16"/>
@@ -263,10 +269,11 @@
<setting id="org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration" value="16"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer" value="insert"/>
<setting id="org.eclipse.jdt.core.compiler.codegen.targetPlatform" value="1.6"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_resources_in_try" value="16"/>
<setting id="org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations" value="false"/>
-<setting id="org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation" value="0"/>
+<setting id="org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation" value="16"/>
<setting id="org.eclipse.jdt.core.formatter.comment.format_header" value="false"/>
-<setting id="org.eclipse.jdt.core.formatter.comment.format_block_comments" value="true"/>
+<setting id="org.eclipse.jdt.core.formatter.comment.format_block_comments" value="false"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.alignment_for_enum_constants" value="49"/>
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block" value="insert"/>
@@ -291,11 +298,12 @@
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries" value="true"/>
-<setting id="org.eclipse.jdt.core.formatter.blank_lines_after_imports" value="1"/>
+<setting id="org.eclipse.jdt.core.formatter.blank_lines_after_imports" value="2"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header" value="true"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for" value="insert"/>
<setting id="org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column" value="false"/>
+<setting id="org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments" value="do not insert"/>
<setting id="org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column" value="false"/>
<setting id="org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line" value="false"/>
diff --git a/config/codestyle-intellij.xml b/config/codestyle-intellij.xml
new file mode 100644
index 0000000..c02259a
--- /dev/null
+++ b/config/codestyle-intellij.xml
@@ -0,0 +1,505 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+
+-->
+<code_scheme name="Pinot Style">
+ <option name="JAVA_INDENT_OPTIONS">
+ <value>
+ <option name="INDENT_SIZE" value="2"/>
+ <option name="CONTINUATION_INDENT_SIZE" value="4"/>
+ <option name="TAB_SIZE" value="2"/>
+ <option name="USE_TAB_CHARACTER" value="false"/>
+ <option name="SMART_TABS" value="false"/>
+ <option name="LABEL_INDENT_SIZE" value="0"/>
+ <option name="LABEL_INDENT_ABSOLUTE" value="false"/>
+ <option name="USE_RELATIVE_INDENTS" value="false"/>
+ </value>
+ </option>
+ <option name="OTHER_INDENT_OPTIONS">
+ <value>
+ <option name="INDENT_SIZE" value="2"/>
+ <option name="CONTINUATION_INDENT_SIZE" value="4"/>
+ <option name="TAB_SIZE" value="2"/>
+ <option name="USE_TAB_CHARACTER" value="false"/>
+ <option name="SMART_TABS" value="false"/>
+ <option name="LABEL_INDENT_SIZE" value="0"/>
+ <option name="LABEL_INDENT_ABSOLUTE" value="false"/>
+ <option name="USE_RELATIVE_INDENTS" value="false"/>
+ </value>
+ </option>
+ <option name="FIELD_NAME_PREFIX" value="_"/>
+ <option name="CLASS_COUNT_TO_USE_IMPORT_ON_DEMAND" value="1000"/>
+ <option name="NAMES_COUNT_TO_USE_IMPORT_ON_DEMAND" value="5"/>
+ <option name="IMPORT_LAYOUT_TABLE">
+ <value>
+ <package name="" withSubpackages="true" static="false"/>
+ <emptyLine/>
+ <package name="" withSubpackages="true" static="true"/>
+ </value>
+ </option>
+ <option name="ENABLE_JAVADOC_FORMATTING" value="false"/>
+ <option name="JD_ADD_BLANK_AFTER_PARM_COMMENTS" value="true"/>
+ <option name="JD_ADD_BLANK_AFTER_RETURN" value="true"/>
+ <option name="JD_KEEP_INVALID_TAGS" value="false"/>
+ <option name="KEEP_LINE_BREAKS" value="false"/>
+ <option name="KEEP_BLANK_LINES_IN_DECLARATIONS" value="1"/>
+ <option name="KEEP_BLANK_LINES_IN_CODE" value="1"/>
+ <option name="KEEP_BLANK_LINES_BEFORE_RBRACE" value="0"/>
+ <option name="BLANK_LINES_AFTER_PACKAGE" value="2"/>
+ <option name="BLANK_LINES_AFTER_IMPORTS" value="2"/>
+ <option name="BRACE_STYLE" value="2"/>
+ <option name="CLASS_BRACE_STYLE" value="2"/>
+ <option name="METHOD_BRACE_STYLE" value="2"/>
+ <option name="ELSE_ON_NEW_LINE" value="true"/>
+ <option name="WHILE_ON_NEW_LINE" value="true"/>
+ <option name="CATCH_ON_NEW_LINE" value="true"/>
+ <option name="FINALLY_ON_NEW_LINE" value="true"/>
+ <option name="ALIGN_MULTILINE_PARAMETERS_IN_CALLS" value="true"/>
+ <option name="ALIGN_MULTILINE_THROWS_LIST" value="true"/>
+ <option name="ALIGN_MULTILINE_EXTENDS_LIST" value="true"/>
+ <option name="CALL_PARAMETERS_WRAP" value="5"/>
+ <option name="METHOD_PARAMETERS_WRAP" value="5"/>
+ <option name="THROWS_LIST_WRAP" value="1"/>
+ <option name="THROWS_KEYWORD_WRAP" value="2"/>
+ <option name="WRAP_COMMENTS" value="true"/>
+ <XML>
+ <option name="XML_LEGACY_SETTINGS_IMPORTED" value="true"/>
+ </XML>
+ <ADDITIONAL_INDENT_OPTIONS fileType="scala">
+ <option name="INDENT_SIZE" value="2"/>
+ <option name="TAB_SIZE" value="2"/>
+ </ADDITIONAL_INDENT_OPTIONS>
+ <ADDITIONAL_INDENT_OPTIONS fileType="txt">
+ <option name="INDENT_SIZE" value="2"/>
+ </ADDITIONAL_INDENT_OPTIONS>
+ <codeStyleSettings language="CFML">
+ <option name="KEEP_LINE_BREAKS" value="false"/>
+ <option name="KEEP_BLANK_LINES_IN_CODE" value="1"/>
+ <option name="BRACE_STYLE" value="2"/>
+ <option name="ELSE_ON_NEW_LINE" value="true"/>
+ <option name="WHILE_ON_NEW_LINE" value="true"/>
+ <option name="CATCH_ON_NEW_LINE" value="true"/>
+ <option name="ALIGN_MULTILINE_PARAMETERS_IN_CALLS" value="true"/>
+ <option name="CALL_PARAMETERS_WRAP" value="5"/>
+ <option name="METHOD_PARAMETERS_WRAP" value="5"/>
+ <option name="PARENT_SETTINGS_INSTALLED" value="true"/>
+ </codeStyleSettings>
+ <codeStyleSettings language="CSS">
+ <indentOptions>
+ <option name="INDENT_SIZE" value="2"/>
+ <option name="CONTINUATION_INDENT_SIZE" value="4"/>
+ <option name="TAB_SIZE" value="2"/>
+ </indentOptions>
+ </codeStyleSettings>
+ <codeStyleSettings language="CoffeeScript">
+ <option name="KEEP_LINE_BREAKS" value="false"/>
+ <option name="KEEP_BLANK_LINES_IN_CODE" value="1"/>
+ <option name="ALIGN_MULTILINE_PARAMETERS_IN_CALLS" value="true"/>
+ <option name="METHOD_PARAMETERS_WRAP" value="1"/>
+ <option name="PARENT_SETTINGS_INSTALLED" value="true"/>
+ <indentOptions>
+ <option name="CONTINUATION_INDENT_SIZE" value="4"/>
+ </indentOptions>
+ </codeStyleSettings>
+ <codeStyleSettings language="ECMA Script Level 4">
+ <option name="KEEP_LINE_BREAKS" value="false"/>
+ <option name="KEEP_BLANK_LINES_IN_CODE" value="1"/>
+ <option name="BLANK_LINES_AFTER_PACKAGE" value="2"/>
+ <option name="BLANK_LINES_AFTER_IMPORTS" value="2"/>
+ <option name="BRACE_STYLE" value="2"/>
+ <option name="CLASS_BRACE_STYLE" value="2"/>
+ <option name="METHOD_BRACE_STYLE" value="2"/>
+ <option name="ELSE_ON_NEW_LINE" value="true"/>
+ <option name="WHILE_ON_NEW_LINE" value="true"/>
+ <option name="CATCH_ON_NEW_LINE" value="true"/>
+ <option name="FINALLY_ON_NEW_LINE" value="true"/>
+ <option name="ALIGN_MULTILINE_PARAMETERS_IN_CALLS" value="true"/>
+ <option name="ALIGN_MULTILINE_EXTENDS_LIST" value="true"/>
+ <option name="CALL_PARAMETERS_WRAP" value="5"/>
+ <option name="METHOD_PARAMETERS_WRAP" value="5"/>
+ <option name="PARENT_SETTINGS_INSTALLED" value="true"/>
+ </codeStyleSettings>
+ <codeStyleSettings language="GSP">
+ <indentOptions>
+ <option name="INDENT_SIZE" value="2"/>
+ <option name="CONTINUATION_INDENT_SIZE" value="4"/>
+ <option name="TAB_SIZE" value="2"/>
+ </indentOptions>
+ </codeStyleSettings>
+ <codeStyleSettings language="Groovy">
+ <option name="KEEP_LINE_BREAKS" value="false"/>
+ <option name="KEEP_BLANK_LINES_IN_DECLARATIONS" value="1"/>
+ <option name="KEEP_BLANK_LINES_IN_CODE" value="1"/>
+ <option name="KEEP_BLANK_LINES_BEFORE_RBRACE" value="0"/>
+ <option name="BLANK_LINES_AFTER_PACKAGE" value="2"/>
+ <option name="BLANK_LINES_AFTER_IMPORTS" value="2"/>
+ <option name="ALIGN_MULTILINE_PARAMETERS" value="false"/>
+ <option name="CALL_PARAMETERS_WRAP" value="1"/>
+ <option name="METHOD_PARAMETERS_WRAP" value="1"/>
+ <option name="EXTENDS_LIST_WRAP" value="1"/>
+ <option name="THROWS_LIST_WRAP" value="1"/>
+ <option name="THROWS_KEYWORD_WRAP" value="2"/>
+ <option name="METHOD_CALL_CHAIN_WRAP" value="1"/>
+ <option name="BINARY_OPERATION_WRAP" value="1"/>
+ <option name="TERNARY_OPERATION_WRAP" value="1"/>
+ <option name="KEEP_SIMPLE_METHODS_IN_ONE_LINE" value="false"/>
+ <option name="KEEP_SIMPLE_CLASSES_IN_ONE_LINE" value="false"/>
+ <option name="FOR_STATEMENT_WRAP" value="1"/>
+ <option name="IF_BRACE_FORCE" value="3"/>
+ <option name="WHILE_BRACE_FORCE" value="3"/>
+ <option name="FOR_BRACE_FORCE" value="3"/>
+ <option name="ENUM_CONSTANTS_WRAP" value="5"/>
+ <option name="PARENT_SETTINGS_INSTALLED" value="true"/>
+ <indentOptions>
+ <option name="INDENT_SIZE" value="2"/>
+ <option name="CONTINUATION_INDENT_SIZE" value="4"/>
+ <option name="TAB_SIZE" value="2"/>
+ </indentOptions>
+ </codeStyleSettings>
+ <codeStyleSettings language="HTML">
+ <indentOptions>
+ <option name="INDENT_SIZE" value="2"/>
+ <option name="CONTINUATION_INDENT_SIZE" value="4"/>
+ <option name="TAB_SIZE" value="2"/>
+ </indentOptions>
+ </codeStyleSettings>
+ <codeStyleSettings language="JAVA">
+ <option name="KEEP_LINE_BREAKS" value="false"/>
+ <option name="KEEP_BLANK_LINES_IN_DECLARATIONS" value="1"/>
+ <option name="KEEP_BLANK_LINES_IN_CODE" value="1"/>
+ <option name="KEEP_BLANK_LINES_BEFORE_RBRACE" value="0"/>
+ <option name="BLANK_LINES_AFTER_IMPORTS" value="2"/>
+ <option name="ALIGN_MULTILINE_PARAMETERS" value="false"/>
+ <option name="ALIGN_MULTILINE_RESOURCES" value="false"/>
+ <option name="ALIGN_MULTILINE_FOR" value="false"/>
+ <option name="ALIGN_MULTILINE_THROWS_LIST" value="true"/>
+ <option name="ALIGN_MULTILINE_EXTENDS_LIST" value="true"/>
+ <option name="CALL_PARAMETERS_WRAP" value="1"/>
+ <option name="METHOD_PARAMETERS_WRAP" value="1"/>
+ <option name="RESOURCE_LIST_WRAP" value="1"/>
+ <option name="THROWS_LIST_WRAP" value="1"/>
+ <option name="THROWS_KEYWORD_WRAP" value="2"/>
+ <option name="METHOD_CALL_CHAIN_WRAP" value="1"/>
+ <option name="BINARY_OPERATION_WRAP" value="1"/>
+ <option name="BINARY_OPERATION_SIGN_ON_NEXT_LINE" value="true"/>
+ <option name="TERNARY_OPERATION_WRAP" value="1"/>
+ <option name="TERNARY_OPERATION_SIGNS_ON_NEXT_LINE" value="true"/>
+ <option name="FOR_STATEMENT_WRAP" value="1"/>
+ <option name="ASSIGNMENT_WRAP" value="1"/>
+ <option name="WRAP_COMMENTS" value="true"/>
+ <option name="IF_BRACE_FORCE" value="3"/>
+ <option name="DOWHILE_BRACE_FORCE" value="3"/>
+ <option name="WHILE_BRACE_FORCE" value="3"/>
+ <option name="FOR_BRACE_FORCE" value="3"/>
+ <option name="VARIABLE_ANNOTATION_WRAP" value="2"/>
+ <option name="ENUM_CONSTANTS_WRAP" value="5"/>
+ <option name="PARENT_SETTINGS_INSTALLED" value="true"/>
+ <indentOptions>
+ <option name="INDENT_SIZE" value="2"/>
+ <option name="CONTINUATION_INDENT_SIZE" value="4"/>
+ <option name="TAB_SIZE" value="2"/>
+ </indentOptions>
+ <arrangement>
+ <groups>
+ <group>
+ <type>GETTERS_AND_SETTERS</type>
+ <order>KEEP</order>
+ </group>
+ </groups>
+ <rules>
+ <rule>
+ <match>
+ <AND>
+ <FIELD/>
+ <FINAL/>
+ <PUBLIC/>
+ <STATIC/>
+ </AND>
+ </match>
+ </rule>
+ <rule>
+ <match>
+ <AND>
+ <FIELD/>
+ <FINAL/>
+ <PROTECTED/>
+ <STATIC/>
+ </AND>
+ </match>
+ </rule>
+ <rule>
+ <match>
+ <AND>
+ <FIELD/>
+ <FINAL/>
+ <PACKAGE_PRIVATE/>
+ <STATIC/>
+ </AND>
+ </match>
+ </rule>
+ <rule>
+ <match>
+ <AND>
+ <FIELD/>
+ <FINAL/>
+ <PRIVATE/>
+ <STATIC/>
+ </AND>
+ </match>
+ </rule>
+ <rule>
+ <match>
+ <AND>
+ <FIELD/>
+ <PUBLIC/>
+ <STATIC/>
+ </AND>
+ </match>
+ </rule>
+ <rule>
+ <match>
+ <AND>
+ <FIELD/>
+ <PROTECTED/>
+ <STATIC/>
+ </AND>
+ </match>
+ </rule>
+ <rule>
+ <match>
+ <AND>
+ <FIELD/>
+ <PACKAGE_PRIVATE/>
+ <STATIC/>
+ </AND>
+ </match>
+ </rule>
+ <rule>
+ <match>
+ <AND>
+ <FIELD/>
+ <PRIVATE/>
+ <STATIC/>
+ </AND>
+ </match>
+ </rule>
+ <rule>
+ <match>
+ <AND>
+ <FIELD/>
+ <FINAL/>
+ <PUBLIC/>
+ </AND>
+ </match>
+ </rule>
+ <rule>
+ <match>
+ <AND>
+ <FIELD/>
+ <FINAL/>
+ <PROTECTED/>
+ </AND>
+ </match>
+ </rule>
+ <rule>
+ <match>
+ <AND>
+ <FIELD/>
+ <FINAL/>
+ <PACKAGE_PRIVATE/>
+ </AND>
+ </match>
+ </rule>
+ <rule>
+ <match>
+ <AND>
+ <FIELD/>
+ <FINAL/>
+ <PRIVATE/>
+ </AND>
+ </match>
+ </rule>
+ <rule>
+ <match>
+ <AND>
+ <FIELD/>
+ <PUBLIC/>
+ </AND>
+ </match>
+ </rule>
+ <rule>
+ <match>
+ <AND>
+ <FIELD/>
+ <PROTECTED/>
+ </AND>
+ </match>
+ </rule>
+ <rule>
+ <match>
+ <AND>
+ <FIELD/>
+ <PACKAGE_PRIVATE/>
+ </AND>
+ </match>
+ </rule>
+ <rule>
+ <match>
+ <AND>
+ <FIELD/>
+ <PRIVATE/>
+ </AND>
+ </match>
+ </rule>
+ <rule>
+ <match>
+ <FIELD/>
+ </match>
+ </rule>
+ <rule>
+ <match>
+ <CONSTRUCTOR/>
+ </match>
+ </rule>
+ <rule>
+ <match>
+ <AND>
+ <METHOD/>
+ <STATIC/>
+ </AND>
+ </match>
+ </rule>
+ <rule>
+ <match>
+ <METHOD/>
+ </match>
+ </rule>
+ <rule>
+ <match>
+ <ENUM/>
+ </match>
+ </rule>
+ <rule>
+ <match>
+ <INTERFACE/>
+ </match>
+ </rule>
+ <rule>
+ <match>
+ <AND>
+ <CLASS/>
+ <STATIC/>
+ </AND>
+ </match>
+ </rule>
+ <rule>
+ <match>
+ <CLASS/>
+ </match>
+ </rule>
+ </rules>
+ </arrangement>
+ </codeStyleSettings>
+ <codeStyleSettings language="JSP">
+ <indentOptions>
+ <option name="INDENT_SIZE" value="2"/>
+ <option name="CONTINUATION_INDENT_SIZE" value="4"/>
+ <option name="TAB_SIZE" value="2"/>
+ </indentOptions>
+ </codeStyleSettings>
+ <codeStyleSettings language="JavaScript">
+ <option name="KEEP_LINE_BREAKS" value="false"/>
+ <option name="KEEP_BLANK_LINES_IN_CODE" value="1"/>
+ <option name="ALIGN_MULTILINE_PARAMETERS" value="false"/>
+ <option name="ALIGN_MULTILINE_FOR" value="false"/>
+ <option name="CALL_PARAMETERS_WRAP" value="1"/>
+ <option name="METHOD_PARAMETERS_WRAP" value="1"/>
+ <option name="BINARY_OPERATION_WRAP" value="1"/>
+ <option name="BINARY_OPERATION_SIGN_ON_NEXT_LINE" value="true"/>
+ <option name="TERNARY_OPERATION_WRAP" value="1"/>
+ <option name="TERNARY_OPERATION_SIGNS_ON_NEXT_LINE" value="true"/>
+ <option name="FOR_STATEMENT_WRAP" value="1"/>
+ <option name="ARRAY_INITIALIZER_WRAP" value="1"/>
+ <option name="IF_BRACE_FORCE" value="3"/>
+ <option name="DOWHILE_BRACE_FORCE" value="3"/>
+ <option name="WHILE_BRACE_FORCE" value="3"/>
+ <option name="FOR_BRACE_FORCE" value="3"/>
+ <option name="PARENT_SETTINGS_INSTALLED" value="true"/>
+ <indentOptions>
+ <option name="INDENT_SIZE" value="2"/>
+ <option name="TAB_SIZE" value="2"/>
+ </indentOptions>
+ </codeStyleSettings>
+ <codeStyleSettings language="LESS">
+ <indentOptions>
+ <option name="CONTINUATION_INDENT_SIZE" value="4"/>
+ <option name="TAB_SIZE" value="2"/>
+ </indentOptions>
+ </codeStyleSettings>
+ <codeStyleSettings language="SASS">
+ <indentOptions>
+ <option name="CONTINUATION_INDENT_SIZE" value="4"/>
+ <option name="TAB_SIZE" value="2"/>
+ </indentOptions>
+ </codeStyleSettings>
+ <codeStyleSettings language="SCSS">
+ <indentOptions>
+ <option name="CONTINUATION_INDENT_SIZE" value="4"/>
+ <option name="TAB_SIZE" value="2"/>
+ </indentOptions>
+ </codeStyleSettings>
+ <codeStyleSettings language="SQL">
+ <option name="KEEP_BLANK_LINES_IN_CODE" value="1"/>
+ <option name="PARENT_SETTINGS_INSTALLED" value="true"/>
+ </codeStyleSettings>
+ <codeStyleSettings language="TypeScript">
+ <option name="KEEP_LINE_BREAKS" value="false"/>
+ <option name="KEEP_BLANK_LINES_IN_CODE" value="1"/>
+ <option name="BRACE_STYLE" value="2"/>
+ <option name="CLASS_BRACE_STYLE" value="2"/>
+ <option name="METHOD_BRACE_STYLE" value="2"/>
+ <option name="ELSE_ON_NEW_LINE" value="true"/>
+ <option name="WHILE_ON_NEW_LINE" value="true"/>
+ <option name="CATCH_ON_NEW_LINE" value="true"/>
+ <option name="FINALLY_ON_NEW_LINE" value="true"/>
+ <option name="ALIGN_MULTILINE_PARAMETERS_IN_CALLS" value="true"/>
+ <option name="ALIGN_MULTILINE_EXTENDS_LIST" value="true"/>
+ <option name="CALL_PARAMETERS_WRAP" value="5"/>
+ <option name="METHOD_PARAMETERS_WRAP" value="5"/>
+ <option name="PARENT_SETTINGS_INSTALLED" value="true"/>
+ </codeStyleSettings>
+ <codeStyleSettings language="XML">
+ <indentOptions>
+ <option name="INDENT_SIZE" value="2"/>
+ <option name="CONTINUATION_INDENT_SIZE" value="4"/>
+ <option name="TAB_SIZE" value="2"/>
+ </indentOptions>
+ <arrangement>
+ <rules>
+ <rule>
+ <match>
+ <NAME>xmlns:.*</NAME>
+ </match>
+ </rule>
+ </rules>
+ </arrangement>
+ </codeStyleSettings>
+</code_scheme>
+
diff --git a/config/suppressions.xml b/config/suppressions.xml
new file mode 100644
index 0000000..f7c3459
--- /dev/null
+++ b/config/suppressions.xml
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+
+-->
+<!DOCTYPE suppressions PUBLIC
+ "-//Checkstyle//DTD SuppressionFilter Configuration 1.2//EN"
+ "https://checkstyle.org/dtds/suppressions_1_2.dtd">
+
+<suppressions>
+ <!-- Suppress autogenerated files by thrift compiler -->
+ <suppress checks=".*" files="/common/request/.*.java"/>
+ <suppress checks=".*" files="/common/response/ProcessingException.java"/>
+</suppressions>
diff --git a/pom.xml b/pom.xml
index 423568a..696aa75 100644
--- a/pom.xml
+++ b/pom.xml
@@ -922,6 +922,24 @@
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-checkstyle-plugin</artifactId>
+ <version>3.0.0</version>
+ <configuration>
+ <configLocation>config/checkstyle.xml</configLocation>
+ <propertyExpansion>config_loc=config</propertyExpansion>
+ <consoleOutput>true</consoleOutput>
+ </configuration>
+ <!--Uncomment to enable style check during build-->
+ <!--<executions>-->
+ <!--<execution>-->
+ <!--<goals>-->
+ <!--<goal>check</goal>-->
+ <!--</goals>-->
+ <!--</execution>-->
+ <!--</executions>-->
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<!--
Configuration for unit/integration tests section 2 of 3 (plugins) STARTS HERE.
@@ -972,7 +990,7 @@
<phase>site</phase>
<configuration>
<!-- Specific configuration for the aggregate report -->
- <excludePackageNames>org.apache.pinot.pql.parsers:org.apache.pinot.common.response</excludePackageNames>
+ <excludePackageNames>org.apache.pinot.pql.parsers:org.apache.pinot.common.response</excludePackageNames>
<skip>false</skip>
</configuration>
</execution>
@@ -1133,7 +1151,7 @@
<id>non-aggregate</id>
<configuration>
<!-- Specific configuration for the non aggregate report -->
- <excludePackageNames>org.apache.pinot.pql.parsers:org.apache.pinot.common.response</excludePackageNames>
+ <excludePackageNames>org.apache.pinot.pql.parsers:org.apache.pinot.common.response</excludePackageNames>
<skip>true</skip>
</configuration>
<reports>
@@ -1143,7 +1161,7 @@
<reportSet>
<id>aggregate</id>
<configuration>
- <excludePackageNames>org.apache.pinot.pql.parsers:org.apache.pinot.common.response</excludePackageNames>
+ <excludePackageNames>org.apache.pinot.pql.parsers:org.apache.pinot.common.response</excludePackageNames>
<skip>true</skip>
</configuration>
<reports>
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org