diff --git a/modules/apm/src/main/java/org/elasticsearch/telemetry/apm/AbstractInstrument.java b/modules/apm/src/main/java/org/elasticsearch/telemetry/apm/AbstractInstrument.java index 01f65eb60aa74..61b53f2087f6e 100644 --- a/modules/apm/src/main/java/org/elasticsearch/telemetry/apm/AbstractInstrument.java +++ b/modules/apm/src/main/java/org/elasticsearch/telemetry/apm/AbstractInstrument.java @@ -30,6 +30,7 @@ public abstract class AbstractInstrument implements Instrument { private final String description; private final String unit; + @SuppressWarnings("this-escape") public AbstractInstrument(Meter meter, String name, String description, String unit) { this.name = Objects.requireNonNull(name); this.description = Objects.requireNonNull(description); diff --git a/server/src/main/java/org/elasticsearch/action/search/SearchResponse.java b/server/src/main/java/org/elasticsearch/action/search/SearchResponse.java index a5faad2466083..487a5c5653998 100644 --- a/server/src/main/java/org/elasticsearch/action/search/SearchResponse.java +++ b/server/src/main/java/org/elasticsearch/action/search/SearchResponse.java @@ -538,6 +538,7 @@ public Clusters(int total, int successful, int skipped) { this.clusterInfo = Collections.emptyMap(); // will never be used if created from this constructor } + @SuppressWarnings("this-escape") public Clusters(StreamInput in) throws IOException { this.total = in.readVInt(); int successfulTemp = in.readVInt(); diff --git a/server/src/main/java/org/elasticsearch/action/support/HandledTransportAction.java b/server/src/main/java/org/elasticsearch/action/support/HandledTransportAction.java index 357c042615e5b..69bdfdea31ae4 100644 --- a/server/src/main/java/org/elasticsearch/action/support/HandledTransportAction.java +++ b/server/src/main/java/org/elasticsearch/action/support/HandledTransportAction.java @@ -31,6 +31,7 @@ protected HandledTransportAction( this(actionName, true, transportService, actionFilters, requestReader, executor); } + @SuppressWarnings("this-escape") protected HandledTransportAction( String actionName, boolean canTripCircuitBreaker, diff --git a/server/src/main/java/org/elasticsearch/action/support/nodes/TransportNodesAction.java b/server/src/main/java/org/elasticsearch/action/support/nodes/TransportNodesAction.java index 27dfa1ff609c7..0a4951c8c4125 100644 --- a/server/src/main/java/org/elasticsearch/action/support/nodes/TransportNodesAction.java +++ b/server/src/main/java/org/elasticsearch/action/support/nodes/TransportNodesAction.java @@ -87,6 +87,7 @@ protected TransportNodesAction( * @deprecated Use the local-only constructor instead. */ @Deprecated(forRemoval = true) + @SuppressWarnings("this-escape") protected TransportNodesAction( String actionName, ThreadPool threadPool, diff --git a/x-pack/plugin/esql/build.gradle b/x-pack/plugin/esql/build.gradle index 9643e2b2d8e1e..ce3413441d927 100644 --- a/x-pack/plugin/esql/build.gradle +++ b/x-pack/plugin/esql/build.gradle @@ -197,6 +197,23 @@ tasks.register("regen") { ant.replaceregexp(match: '\t', flags: 'g', replace: ' ', encoding: 'UTF-8') { fileset(dir: outputPath, includes: 'EsqlBase*.java') } + // suppress this-escape warnings on EsqlBaseLexer + ant.replaceregexp( + match: 'public EsqlBaseLexer', + replace: '@SuppressWarnings("this-escape")${line.separator} public EsqlBaseLexer', + encoding: 'UTF-8' + ) { + fileset(dir: outputPath, includes: 'EsqlBaseLexer.java') + } + // suppress this-escape warnings on all internal EsqlBaseParser class constructores + ant.replaceregexp( + match: '([ ]+)public ([A-Z][a-z]+[a-z,A-Z]+\\()', + flags: 'g', + replace: '\\1@SuppressWarnings("this-escape")${line.separator}\\1public \\2', + encoding: 'UTF-8' + ) { + fileset(dir: outputPath, includes: 'EsqlBaseParser.java') + } // fix line endings ant.fixcrlf(srcdir: outputPath, eol: 'lf') { patternset(includes: 'EsqlBase*.java') diff --git a/x-pack/plugin/esql/compute/src/main/java/org/elasticsearch/compute/data/DocVector.java b/x-pack/plugin/esql/compute/src/main/java/org/elasticsearch/compute/data/DocVector.java index 44819359e8e44..842f8719f19dc 100644 --- a/x-pack/plugin/esql/compute/src/main/java/org/elasticsearch/compute/data/DocVector.java +++ b/x-pack/plugin/esql/compute/src/main/java/org/elasticsearch/compute/data/DocVector.java @@ -48,6 +48,7 @@ public class DocVector extends AbstractVector implements Vector { final DocBlock block; + @SuppressWarnings("this-escape") public DocVector(IntVector shards, IntVector segments, IntVector docs, Boolean singleSegmentNonDecreasing) { super(shards.getPositionCount(), null); this.shards = shards; diff --git a/x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/parser/EsqlBaseLexer.java b/x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/parser/EsqlBaseLexer.java index be46b6c6e1797..5a01cfa11b3fd 100644 --- a/x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/parser/EsqlBaseLexer.java +++ b/x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/parser/EsqlBaseLexer.java @@ -127,6 +127,7 @@ public Vocabulary getVocabulary() { } + @SuppressWarnings("this-escape") public EsqlBaseLexer(CharStream input) { super(input); _interp = new LexerATNSimulator(this,_ATN,_decisionToDFA,_sharedContextCache); diff --git a/x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/parser/EsqlBaseParser.java b/x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/parser/EsqlBaseParser.java index 49d9abcc087c7..d136c346927e6 100644 --- a/x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/parser/EsqlBaseParser.java +++ b/x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/parser/EsqlBaseParser.java @@ -139,6 +139,7 @@ public Vocabulary getVocabulary() { @Override public ATN getATN() { return _ATN; } + @SuppressWarnings("this-escape") public EsqlBaseParser(TokenStream input) { super(input); _interp = new ParserATNSimulator(this,_ATN,_decisionToDFA,_sharedContextCache); @@ -150,6 +151,7 @@ public QueryContext query() { return getRuleContext(QueryContext.class,0); } public TerminalNode EOF() { return getToken(EsqlBaseParser.EOF, 0); } + @SuppressWarnings("this-escape") public SingleStatementContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -194,11 +196,13 @@ public final SingleStatementContext singleStatement() throws RecognitionExceptio @SuppressWarnings("CheckReturnValue") public static class QueryContext extends ParserRuleContext { + @SuppressWarnings("this-escape") public QueryContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_query; } + @SuppressWarnings("this-escape") public QueryContext() { } public void copyFrom(QueryContext ctx) { super.copyFrom(ctx); @@ -213,6 +217,7 @@ public QueryContext query() { public ProcessingCommandContext processingCommand() { return getRuleContext(ProcessingCommandContext.class,0); } + @SuppressWarnings("this-escape") public CompositeQueryContext(QueryContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -233,6 +238,7 @@ public static class SingleCommandQueryContext extends QueryContext { public SourceCommandContext sourceCommand() { return getRuleContext(SourceCommandContext.class,0); } + @SuppressWarnings("this-escape") public SingleCommandQueryContext(QueryContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -324,6 +330,7 @@ public RowCommandContext rowCommand() { public ShowCommandContext showCommand() { return getRuleContext(ShowCommandContext.class,0); } + @SuppressWarnings("this-escape") public SourceCommandContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -434,6 +441,7 @@ public EnrichCommandContext enrichCommand() { public MvExpandCommandContext mvExpandCommand() { return getRuleContext(MvExpandCommandContext.class,0); } + @SuppressWarnings("this-escape") public ProcessingCommandContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -573,6 +581,7 @@ public static class WhereCommandContext extends ParserRuleContext { public BooleanExpressionContext booleanExpression() { return getRuleContext(BooleanExpressionContext.class,0); } + @SuppressWarnings("this-escape") public WhereCommandContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -617,11 +626,13 @@ public final WhereCommandContext whereCommand() throws RecognitionException { @SuppressWarnings("CheckReturnValue") public static class BooleanExpressionContext extends ParserRuleContext { + @SuppressWarnings("this-escape") public BooleanExpressionContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_booleanExpression; } + @SuppressWarnings("this-escape") public BooleanExpressionContext() { } public void copyFrom(BooleanExpressionContext ctx) { super.copyFrom(ctx); @@ -633,6 +644,7 @@ public static class LogicalNotContext extends BooleanExpressionContext { public BooleanExpressionContext booleanExpression() { return getRuleContext(BooleanExpressionContext.class,0); } + @SuppressWarnings("this-escape") public LogicalNotContext(BooleanExpressionContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -653,6 +665,7 @@ public static class BooleanDefaultContext extends BooleanExpressionContext { public ValueExpressionContext valueExpression() { return getRuleContext(ValueExpressionContext.class,0); } + @SuppressWarnings("this-escape") public BooleanDefaultContext(BooleanExpressionContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -676,6 +689,7 @@ public ValueExpressionContext valueExpression() { public TerminalNode IS() { return getToken(EsqlBaseParser.IS, 0); } public TerminalNode NULL() { return getToken(EsqlBaseParser.NULL, 0); } public TerminalNode NOT() { return getToken(EsqlBaseParser.NOT, 0); } + @SuppressWarnings("this-escape") public IsNullContext(BooleanExpressionContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -696,6 +710,7 @@ public static class RegexExpressionContext extends BooleanExpressionContext { public RegexBooleanExpressionContext regexBooleanExpression() { return getRuleContext(RegexBooleanExpressionContext.class,0); } + @SuppressWarnings("this-escape") public RegexExpressionContext(BooleanExpressionContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -727,6 +742,7 @@ public ValueExpressionContext valueExpression(int i) { public TerminalNode COMMA(int i) { return getToken(EsqlBaseParser.COMMA, i); } + @SuppressWarnings("this-escape") public LogicalInContext(BooleanExpressionContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -755,6 +771,7 @@ public BooleanExpressionContext booleanExpression(int i) { } public TerminalNode AND() { return getToken(EsqlBaseParser.AND, 0); } public TerminalNode OR() { return getToken(EsqlBaseParser.OR, 0); } + @SuppressWarnings("this-escape") public LogicalBinaryContext(BooleanExpressionContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -958,6 +975,7 @@ public StringContext string() { } public TerminalNode NOT() { return getToken(EsqlBaseParser.NOT, 0); } public TerminalNode RLIKE() { return getToken(EsqlBaseParser.RLIKE, 0); } + @SuppressWarnings("this-escape") public RegexBooleanExpressionContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -1042,11 +1060,13 @@ public final RegexBooleanExpressionContext regexBooleanExpression() throws Recog @SuppressWarnings("CheckReturnValue") public static class ValueExpressionContext extends ParserRuleContext { + @SuppressWarnings("this-escape") public ValueExpressionContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_valueExpression; } + @SuppressWarnings("this-escape") public ValueExpressionContext() { } public void copyFrom(ValueExpressionContext ctx) { super.copyFrom(ctx); @@ -1057,6 +1077,7 @@ public static class ValueExpressionDefaultContext extends ValueExpressionContext public OperatorExpressionContext operatorExpression() { return getRuleContext(OperatorExpressionContext.class,0); } + @SuppressWarnings("this-escape") public ValueExpressionDefaultContext(ValueExpressionContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -1085,6 +1106,7 @@ public List operatorExpression() { public OperatorExpressionContext operatorExpression(int i) { return getRuleContext(OperatorExpressionContext.class,i); } + @SuppressWarnings("this-escape") public ComparisonContext(ValueExpressionContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -1143,11 +1165,13 @@ public final ValueExpressionContext valueExpression() throws RecognitionExceptio @SuppressWarnings("CheckReturnValue") public static class OperatorExpressionContext extends ParserRuleContext { + @SuppressWarnings("this-escape") public OperatorExpressionContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_operatorExpression; } + @SuppressWarnings("this-escape") public OperatorExpressionContext() { } public void copyFrom(OperatorExpressionContext ctx) { super.copyFrom(ctx); @@ -1158,6 +1182,7 @@ public static class OperatorExpressionDefaultContext extends OperatorExpressionC public PrimaryExpressionContext primaryExpression() { return getRuleContext(PrimaryExpressionContext.class,0); } + @SuppressWarnings("this-escape") public OperatorExpressionDefaultContext(OperatorExpressionContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -1189,6 +1214,7 @@ public OperatorExpressionContext operatorExpression(int i) { public TerminalNode PERCENT() { return getToken(EsqlBaseParser.PERCENT, 0); } public TerminalNode PLUS() { return getToken(EsqlBaseParser.PLUS, 0); } public TerminalNode MINUS() { return getToken(EsqlBaseParser.MINUS, 0); } + @SuppressWarnings("this-escape") public ArithmeticBinaryContext(OperatorExpressionContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -1212,6 +1238,7 @@ public OperatorExpressionContext operatorExpression() { } public TerminalNode MINUS() { return getToken(EsqlBaseParser.MINUS, 0); } public TerminalNode PLUS() { return getToken(EsqlBaseParser.PLUS, 0); } + @SuppressWarnings("this-escape") public ArithmeticUnaryContext(OperatorExpressionContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -1356,11 +1383,13 @@ private OperatorExpressionContext operatorExpression(int _p) throws RecognitionE @SuppressWarnings("CheckReturnValue") public static class PrimaryExpressionContext extends ParserRuleContext { + @SuppressWarnings("this-escape") public PrimaryExpressionContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_primaryExpression; } + @SuppressWarnings("this-escape") public PrimaryExpressionContext() { } public void copyFrom(PrimaryExpressionContext ctx) { super.copyFrom(ctx); @@ -1371,6 +1400,7 @@ public static class DereferenceContext extends PrimaryExpressionContext { public QualifiedNameContext qualifiedName() { return getRuleContext(QualifiedNameContext.class,0); } + @SuppressWarnings("this-escape") public DereferenceContext(PrimaryExpressionContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -1391,6 +1421,7 @@ public static class ConstantDefaultContext extends PrimaryExpressionContext { public ConstantContext constant() { return getRuleContext(ConstantContext.class,0); } + @SuppressWarnings("this-escape") public ConstantDefaultContext(PrimaryExpressionContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -1413,6 +1444,7 @@ public BooleanExpressionContext booleanExpression() { return getRuleContext(BooleanExpressionContext.class,0); } public TerminalNode RP() { return getToken(EsqlBaseParser.RP, 0); } + @SuppressWarnings("this-escape") public ParenthesizedExpressionContext(PrimaryExpressionContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -1433,6 +1465,7 @@ public static class FunctionContext extends PrimaryExpressionContext { public FunctionExpressionContext functionExpression() { return getRuleContext(FunctionExpressionContext.class,0); } + @SuppressWarnings("this-escape") public FunctionContext(PrimaryExpressionContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -1523,6 +1556,7 @@ public BooleanExpressionContext booleanExpression(int i) { public TerminalNode COMMA(int i) { return getToken(EsqlBaseParser.COMMA, i); } + @SuppressWarnings("this-escape") public FunctionExpressionContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -1625,6 +1659,7 @@ public static class RowCommandContext extends ParserRuleContext { public FieldsContext fields() { return getRuleContext(FieldsContext.class,0); } + @SuppressWarnings("this-escape") public RowCommandContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -1679,6 +1714,7 @@ public FieldContext field(int i) { public TerminalNode COMMA(int i) { return getToken(EsqlBaseParser.COMMA, i); } + @SuppressWarnings("this-escape") public FieldsContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -1747,6 +1783,7 @@ public QualifiedNameContext qualifiedName() { return getRuleContext(QualifiedNameContext.class,0); } public TerminalNode ASSIGN() { return getToken(EsqlBaseParser.ASSIGN, 0); } + @SuppressWarnings("this-escape") public FieldContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -1820,6 +1857,7 @@ public TerminalNode COMMA(int i) { public MetadataContext metadata() { return getRuleContext(MetadataContext.class,0); } + @SuppressWarnings("this-escape") public FromCommandContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -1906,6 +1944,7 @@ public SourceIdentifierContext sourceIdentifier(int i) { public TerminalNode COMMA(int i) { return getToken(EsqlBaseParser.COMMA, i); } + @SuppressWarnings("this-escape") public MetadataContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -1975,6 +2014,7 @@ public static class EvalCommandContext extends ParserRuleContext { public FieldsContext fields() { return getRuleContext(FieldsContext.class,0); } + @SuppressWarnings("this-escape") public EvalCommandContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -2027,6 +2067,7 @@ public FieldsContext fields() { public GroupingContext grouping() { return getRuleContext(GroupingContext.class,0); } + @SuppressWarnings("this-escape") public StatsCommandContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -2099,6 +2140,7 @@ public FieldsContext fields() { public GroupingContext grouping() { return getRuleContext(GroupingContext.class,0); } + @SuppressWarnings("this-escape") public InlinestatsCommandContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -2165,6 +2207,7 @@ public QualifiedNameContext qualifiedName(int i) { public TerminalNode COMMA(int i) { return getToken(EsqlBaseParser.COMMA, i); } + @SuppressWarnings("this-escape") public GroupingContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -2228,6 +2271,7 @@ public final GroupingContext grouping() throws RecognitionException { public static class SourceIdentifierContext extends ParserRuleContext { public TerminalNode SRC_UNQUOTED_IDENTIFIER() { return getToken(EsqlBaseParser.SRC_UNQUOTED_IDENTIFIER, 0); } public TerminalNode SRC_QUOTED_IDENTIFIER() { return getToken(EsqlBaseParser.SRC_QUOTED_IDENTIFIER, 0); } + @SuppressWarnings("this-escape") public SourceIdentifierContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -2289,6 +2333,7 @@ public IdentifierContext identifier(int i) { public TerminalNode DOT(int i) { return getToken(EsqlBaseParser.DOT, i); } + @SuppressWarnings("this-escape") public QualifiedNameContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -2352,6 +2397,7 @@ public final QualifiedNameContext qualifiedName() throws RecognitionException { public static class IdentifierContext extends ParserRuleContext { public TerminalNode UNQUOTED_IDENTIFIER() { return getToken(EsqlBaseParser.UNQUOTED_IDENTIFIER, 0); } public TerminalNode QUOTED_IDENTIFIER() { return getToken(EsqlBaseParser.QUOTED_IDENTIFIER, 0); } + @SuppressWarnings("this-escape") public IdentifierContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -2403,11 +2449,13 @@ public final IdentifierContext identifier() throws RecognitionException { @SuppressWarnings("CheckReturnValue") public static class ConstantContext extends ParserRuleContext { + @SuppressWarnings("this-escape") public ConstantContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_constant; } + @SuppressWarnings("this-escape") public ConstantContext() { } public void copyFrom(ConstantContext ctx) { super.copyFrom(ctx); @@ -2427,6 +2475,7 @@ public BooleanValueContext booleanValue(int i) { public TerminalNode COMMA(int i) { return getToken(EsqlBaseParser.COMMA, i); } + @SuppressWarnings("this-escape") public BooleanArrayLiteralContext(ConstantContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -2447,6 +2496,7 @@ public static class DecimalLiteralContext extends ConstantContext { public DecimalValueContext decimalValue() { return getRuleContext(DecimalValueContext.class,0); } + @SuppressWarnings("this-escape") public DecimalLiteralContext(ConstantContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -2465,6 +2515,7 @@ public T accept(ParseTreeVisitor visitor) { @SuppressWarnings("CheckReturnValue") public static class NullLiteralContext extends ConstantContext { public TerminalNode NULL() { return getToken(EsqlBaseParser.NULL, 0); } + @SuppressWarnings("this-escape") public NullLiteralContext(ConstantContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -2486,6 +2537,7 @@ public IntegerValueContext integerValue() { return getRuleContext(IntegerValueContext.class,0); } public TerminalNode UNQUOTED_IDENTIFIER() { return getToken(EsqlBaseParser.UNQUOTED_IDENTIFIER, 0); } + @SuppressWarnings("this-escape") public QualifiedIntegerLiteralContext(ConstantContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -2515,6 +2567,7 @@ public StringContext string(int i) { public TerminalNode COMMA(int i) { return getToken(EsqlBaseParser.COMMA, i); } + @SuppressWarnings("this-escape") public StringArrayLiteralContext(ConstantContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -2535,6 +2588,7 @@ public static class StringLiteralContext extends ConstantContext { public StringContext string() { return getRuleContext(StringContext.class,0); } + @SuppressWarnings("this-escape") public StringLiteralContext(ConstantContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -2564,6 +2618,7 @@ public NumericValueContext numericValue(int i) { public TerminalNode COMMA(int i) { return getToken(EsqlBaseParser.COMMA, i); } + @SuppressWarnings("this-escape") public NumericArrayLiteralContext(ConstantContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -2582,6 +2637,7 @@ public T accept(ParseTreeVisitor visitor) { @SuppressWarnings("CheckReturnValue") public static class InputParamContext extends ConstantContext { public TerminalNode PARAM() { return getToken(EsqlBaseParser.PARAM, 0); } + @SuppressWarnings("this-escape") public InputParamContext(ConstantContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -2602,6 +2658,7 @@ public static class IntegerLiteralContext extends ConstantContext { public IntegerValueContext integerValue() { return getRuleContext(IntegerValueContext.class,0); } + @SuppressWarnings("this-escape") public IntegerLiteralContext(ConstantContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -2622,6 +2679,7 @@ public static class BooleanLiteralContext extends ConstantContext { public BooleanValueContext booleanValue() { return getRuleContext(BooleanValueContext.class,0); } + @SuppressWarnings("this-escape") public BooleanLiteralContext(ConstantContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -2805,6 +2863,7 @@ public final ConstantContext constant() throws RecognitionException { public static class LimitCommandContext extends ParserRuleContext { public TerminalNode LIMIT() { return getToken(EsqlBaseParser.LIMIT, 0); } public TerminalNode INTEGER_LITERAL() { return getToken(EsqlBaseParser.INTEGER_LITERAL, 0); } + @SuppressWarnings("this-escape") public LimitCommandContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -2860,6 +2919,7 @@ public OrderExpressionContext orderExpression(int i) { public TerminalNode COMMA(int i) { return getToken(EsqlBaseParser.COMMA, i); } + @SuppressWarnings("this-escape") public SortCommandContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -2933,6 +2993,7 @@ public BooleanExpressionContext booleanExpression() { public TerminalNode DESC() { return getToken(EsqlBaseParser.DESC, 0); } public TerminalNode FIRST() { return getToken(EsqlBaseParser.FIRST, 0); } public TerminalNode LAST() { return getToken(EsqlBaseParser.LAST, 0); } + @SuppressWarnings("this-escape") public OrderExpressionContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -3028,6 +3089,7 @@ public TerminalNode COMMA(int i) { return getToken(EsqlBaseParser.COMMA, i); } public TerminalNode PROJECT() { return getToken(EsqlBaseParser.PROJECT, 0); } + @SuppressWarnings("this-escape") public KeepCommandContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -3137,6 +3199,7 @@ public SourceIdentifierContext sourceIdentifier(int i) { public TerminalNode COMMA(int i) { return getToken(EsqlBaseParser.COMMA, i); } + @SuppressWarnings("this-escape") public DropCommandContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -3211,6 +3274,7 @@ public RenameClauseContext renameClause(int i) { public TerminalNode COMMA(int i) { return getToken(EsqlBaseParser.COMMA, i); } + @SuppressWarnings("this-escape") public RenameCommandContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -3283,6 +3347,7 @@ public List sourceIdentifier() { public SourceIdentifierContext sourceIdentifier(int i) { return getRuleContext(SourceIdentifierContext.class,i); } + @SuppressWarnings("this-escape") public RenameClauseContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -3339,6 +3404,7 @@ public StringContext string() { public CommandOptionsContext commandOptions() { return getRuleContext(CommandOptionsContext.class,0); } + @SuppressWarnings("this-escape") public DissectCommandContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -3402,6 +3468,7 @@ public PrimaryExpressionContext primaryExpression() { public StringContext string() { return getRuleContext(StringContext.class,0); } + @SuppressWarnings("this-escape") public GrokCommandContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -3452,6 +3519,7 @@ public static class MvExpandCommandContext extends ParserRuleContext { public SourceIdentifierContext sourceIdentifier() { return getRuleContext(SourceIdentifierContext.class,0); } + @SuppressWarnings("this-escape") public MvExpandCommandContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -3506,6 +3574,7 @@ public CommandOptionContext commandOption(int i) { public TerminalNode COMMA(int i) { return getToken(EsqlBaseParser.COMMA, i); } + @SuppressWarnings("this-escape") public CommandOptionsContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -3574,6 +3643,7 @@ public IdentifierContext identifier() { public ConstantContext constant() { return getRuleContext(ConstantContext.class,0); } + @SuppressWarnings("this-escape") public CommandOptionContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -3622,6 +3692,7 @@ public final CommandOptionContext commandOption() throws RecognitionException { public static class BooleanValueContext extends ParserRuleContext { public TerminalNode TRUE() { return getToken(EsqlBaseParser.TRUE, 0); } public TerminalNode FALSE() { return getToken(EsqlBaseParser.FALSE, 0); } + @SuppressWarnings("this-escape") public BooleanValueContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -3679,6 +3750,7 @@ public DecimalValueContext decimalValue() { public IntegerValueContext integerValue() { return getRuleContext(IntegerValueContext.class,0); } + @SuppressWarnings("this-escape") public NumericValueContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -3737,6 +3809,7 @@ public static class DecimalValueContext extends ParserRuleContext { public TerminalNode DECIMAL_LITERAL() { return getToken(EsqlBaseParser.DECIMAL_LITERAL, 0); } public TerminalNode PLUS() { return getToken(EsqlBaseParser.PLUS, 0); } public TerminalNode MINUS() { return getToken(EsqlBaseParser.MINUS, 0); } + @SuppressWarnings("this-escape") public DecimalValueContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -3801,6 +3874,7 @@ public static class IntegerValueContext extends ParserRuleContext { public TerminalNode INTEGER_LITERAL() { return getToken(EsqlBaseParser.INTEGER_LITERAL, 0); } public TerminalNode PLUS() { return getToken(EsqlBaseParser.PLUS, 0); } public TerminalNode MINUS() { return getToken(EsqlBaseParser.MINUS, 0); } + @SuppressWarnings("this-escape") public IntegerValueContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -3863,6 +3937,7 @@ public final IntegerValueContext integerValue() throws RecognitionException { @SuppressWarnings("CheckReturnValue") public static class StringContext extends ParserRuleContext { public TerminalNode STRING() { return getToken(EsqlBaseParser.STRING, 0); } + @SuppressWarnings("this-escape") public StringContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -3911,6 +3986,7 @@ public static class ComparisonOperatorContext extends ParserRuleContext { public TerminalNode LTE() { return getToken(EsqlBaseParser.LTE, 0); } public TerminalNode GT() { return getToken(EsqlBaseParser.GT, 0); } public TerminalNode GTE() { return getToken(EsqlBaseParser.GTE, 0); } + @SuppressWarnings("this-escape") public ComparisonOperatorContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -3966,6 +4042,7 @@ public static class ExplainCommandContext extends ParserRuleContext { public SubqueryExpressionContext subqueryExpression() { return getRuleContext(SubqueryExpressionContext.class,0); } + @SuppressWarnings("this-escape") public ExplainCommandContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -4015,6 +4092,7 @@ public QueryContext query() { return getRuleContext(QueryContext.class,0); } public TerminalNode CLOSING_BRACKET() { return getToken(EsqlBaseParser.CLOSING_BRACKET, 0); } + @SuppressWarnings("this-escape") public SubqueryExpressionContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -4061,11 +4139,13 @@ public final SubqueryExpressionContext subqueryExpression() throws RecognitionEx @SuppressWarnings("CheckReturnValue") public static class ShowCommandContext extends ParserRuleContext { + @SuppressWarnings("this-escape") public ShowCommandContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_showCommand; } + @SuppressWarnings("this-escape") public ShowCommandContext() { } public void copyFrom(ShowCommandContext ctx) { super.copyFrom(ctx); @@ -4075,6 +4155,7 @@ public void copyFrom(ShowCommandContext ctx) { public static class ShowInfoContext extends ShowCommandContext { public TerminalNode SHOW() { return getToken(EsqlBaseParser.SHOW, 0); } public TerminalNode INFO() { return getToken(EsqlBaseParser.INFO, 0); } + @SuppressWarnings("this-escape") public ShowInfoContext(ShowCommandContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -4094,6 +4175,7 @@ public T accept(ParseTreeVisitor visitor) { public static class ShowFunctionsContext extends ShowCommandContext { public TerminalNode SHOW() { return getToken(EsqlBaseParser.SHOW, 0); } public TerminalNode FUNCTIONS() { return getToken(EsqlBaseParser.FUNCTIONS, 0); } + @SuppressWarnings("this-escape") public ShowFunctionsContext(ShowCommandContext ctx) { copyFrom(ctx); } @Override public void enterRule(ParseTreeListener listener) { @@ -4173,6 +4255,7 @@ public EnrichWithClauseContext enrichWithClause(int i) { public TerminalNode COMMA(int i) { return getToken(EsqlBaseParser.COMMA, i); } + @SuppressWarnings("this-escape") public EnrichCommandContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @@ -4269,6 +4352,7 @@ public SourceIdentifierContext sourceIdentifier(int i) { return getRuleContext(SourceIdentifierContext.class,i); } public TerminalNode ASSIGN() { return getToken(EsqlBaseParser.ASSIGN, 0); } + @SuppressWarnings("this-escape") public EnrichWithClauseContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } diff --git a/x-pack/plugin/ml/src/main/java/org/elasticsearch/xpack/ml/autoscaling/NodeFakeAvailabilityZoneMapper.java b/x-pack/plugin/ml/src/main/java/org/elasticsearch/xpack/ml/autoscaling/NodeFakeAvailabilityZoneMapper.java index 618db1da71ab8..108b7eaff06e3 100644 --- a/x-pack/plugin/ml/src/main/java/org/elasticsearch/xpack/ml/autoscaling/NodeFakeAvailabilityZoneMapper.java +++ b/x-pack/plugin/ml/src/main/java/org/elasticsearch/xpack/ml/autoscaling/NodeFakeAvailabilityZoneMapper.java @@ -29,10 +29,12 @@ public class NodeFakeAvailabilityZoneMapper extends AbstractNodeAvailabilityZone private static final Logger logger = LogManager.getLogger(NodeFakeAvailabilityZoneMapper.class); + @SuppressWarnings("this-escape") public NodeFakeAvailabilityZoneMapper(Settings settings, ClusterSettings clusterSettings) { this(settings, clusterSettings, null); } + @SuppressWarnings("this-escape") public NodeFakeAvailabilityZoneMapper(Settings settings, ClusterSettings clusterSettings, DiscoveryNodes discoveryNodes) { super(settings, clusterSettings, discoveryNodes); updateNodesByAvailabilityZone(); diff --git a/x-pack/plugin/ml/src/main/java/org/elasticsearch/xpack/ml/autoscaling/NodeRealAvailabilityZoneMapper.java b/x-pack/plugin/ml/src/main/java/org/elasticsearch/xpack/ml/autoscaling/NodeRealAvailabilityZoneMapper.java index dfac0948087df..24da7d2e46563 100644 --- a/x-pack/plugin/ml/src/main/java/org/elasticsearch/xpack/ml/autoscaling/NodeRealAvailabilityZoneMapper.java +++ b/x-pack/plugin/ml/src/main/java/org/elasticsearch/xpack/ml/autoscaling/NodeRealAvailabilityZoneMapper.java @@ -34,10 +34,12 @@ public class NodeRealAvailabilityZoneMapper extends AbstractNodeAvailabilityZone private volatile List awarenessAttributes; + @SuppressWarnings("this-escape") public NodeRealAvailabilityZoneMapper(Settings settings, ClusterSettings clusterSettings) { this(settings, clusterSettings, null); } + @SuppressWarnings("this-escape") public NodeRealAvailabilityZoneMapper(Settings settings, ClusterSettings clusterSettings, DiscoveryNodes discoveryNodes) { super(settings, clusterSettings, discoveryNodes); awarenessAttributes = AwarenessAllocationDecider.CLUSTER_ROUTING_ALLOCATION_AWARENESS_ATTRIBUTE_SETTING.get(settings); diff --git a/x-pack/plugin/spatial/src/main/java/org/elasticsearch/xpack/spatial/index/mapper/GeoShapeWithDocValuesFieldMapper.java b/x-pack/plugin/spatial/src/main/java/org/elasticsearch/xpack/spatial/index/mapper/GeoShapeWithDocValuesFieldMapper.java index b07b6da96833f..89b0c1c6ef922 100644 --- a/x-pack/plugin/spatial/src/main/java/org/elasticsearch/xpack/spatial/index/mapper/GeoShapeWithDocValuesFieldMapper.java +++ b/x-pack/plugin/spatial/src/main/java/org/elasticsearch/xpack/spatial/index/mapper/GeoShapeWithDocValuesFieldMapper.java @@ -125,6 +125,7 @@ public static class Builder extends FieldMapper.Builder { private final IndexVersion version; private final GeoFormatterFactory geoFormatterFactory; + @SuppressWarnings("this-escape") public Builder( String name, IndexVersion version,