Skip to content

Commit

Permalink
Integ/sl google java format5 (#332)
Browse files Browse the repository at this point in the history
Adding core final GJF fix.

Signed-off-by: Mitchell Gale <[email protected]>
  • Loading branch information
MitchellGale authored Aug 8, 2023
1 parent d144706 commit a198b99
Show file tree
Hide file tree
Showing 454 changed files with 12,165 additions and 12,449 deletions.
5 changes: 2 additions & 3 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -84,18 +84,17 @@ repositories {
spotless {
java {
target fileTree('.') {
include '**/*.java'
include 'core/**/*.java'
exclude '**/build/**', '**/build-*/**'
}
importOrder()
// licenseHeader("/*\n" +
// " * Copyright OpenSearch Contributors\n" +
// " * SPDX-License-Identifier: Apache-2.0\n" +
// " */\n\n")
removeUnusedImports()
trimTrailingWhitespace()
endWithNewline()
// googleJavaFormat('1.17.0').reflowLongStrings().groupArtifact('com.google.googlejavaformat:google-java-format')
googleJavaFormat('1.17.0').reflowLongStrings().groupArtifact('com.google.googlejavaformat:google-java-format')
}
}

Expand Down
8 changes: 8 additions & 0 deletions core/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,11 @@ repositories {
mavenCentral()
}

// Being ignored as a temporary measure before being removed in favour of
// spotless https://github.com/opensearch-project/sql/issues/1101
checkstyleTest.ignoreFailures = true
checkstyleMain.ignoreFailures = true

pitest {
targetClasses = ['org.opensearch.sql.*']
pitestVersion = '1.9.0'
Expand Down Expand Up @@ -61,6 +66,9 @@ dependencies {
testImplementation group: 'org.mockito', name: 'mockito-junit-jupiter', version: '3.12.4'
}

checkstyleMain.ignoreFailures = true
checkstyleTest.ignoreFailures = true

test {
useJUnitPlatform()
testLogging {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,4 @@ public class DataSourceSchemaName {
private final String dataSourceName;

private final String schemaName;

}
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
* SPDX-License-Identifier: Apache-2.0
*/


package org.opensearch.sql.analysis;

import java.util.ArrayList;
Expand All @@ -13,26 +12,22 @@
import org.opensearch.sql.expression.NamedExpression;
import org.opensearch.sql.expression.function.FunctionProperties;

/**
* The context used for Analyzer.
*/
/** The context used for Analyzer. */
public class AnalysisContext {
/**
* Environment stack for symbol scope management.
*/
/** Environment stack for symbol scope management. */
private TypeEnvironment environment;
@Getter
private final List<NamedExpression> namedParseExpressions;

@Getter
private final FunctionProperties functionProperties;
@Getter private final List<NamedExpression> namedParseExpressions;

@Getter private final FunctionProperties functionProperties;

public AnalysisContext() {
this(new TypeEnvironment(null));
}

/**
* Class CTOR.
*
* @param environment Env to set to a new instance.
*/
public AnalysisContext(TypeEnvironment environment) {
Expand All @@ -41,9 +36,7 @@ public AnalysisContext(TypeEnvironment environment) {
this.functionProperties = new FunctionProperties();
}

/**
* Push a new environment.
*/
/** Push a new environment. */
public void push() {
environment = new TypeEnvironment(environment);
}
Expand Down
Loading

0 comments on commit a198b99

Please sign in to comment.