You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ignite.apache.org by ni...@apache.org on 2024/02/07 12:39:03 UTC
(ignite) branch master updated: IGNITE-14823 Value abbrevation (#11235)
This is an automated email from the ASF dual-hosted git repository.
nizhikov pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/ignite.git
The following commit(s) were added to refs/heads/master by this push:
new 0c87c39d22b IGNITE-14823 Value abbrevation (#11235)
0c87c39d22b is described below
commit 0c87c39d22b841b2dca140b07af2a0c5b08657ae
Author: Nikolay <ni...@apache.org>
AuthorDate: Wed Feb 7 15:38:53 2024 +0300
IGNITE-14823 Value abbrevation (#11235)
---
.../ignite/internal/benchmarks/model/IntValue.java | 4 +-
.../query/calcite/exec/exp/RexImpTable.java | 132 ++++++++++-----------
.../query/calcite/exec/exp/RexToLixTranslator.java | 72 +++++------
.../query/calcite/externalize/RelJson.java | 4 +-
.../query/calcite/externalize/RelJsonReader.java | 4 +-
.../query/calcite/externalize/RelJsonWriter.java | 6 +-
.../query/calcite/metadata/IgniteMdCollation.java | 6 +-
.../checkstyle/src/main/resources/abbrevations.csv | 2 +-
.../rest/JettyRestProcessorGetAllAsArrayTest.java | 8 +-
.../thin/JdbcThinMissingLongArrayResultsTest.java | 16 +--
.../snapshot/SnapshotCompressionBasicTest.java | 4 +-
.../argument/parser/CLIArgumentParser.java | 12 +-
.../org/apache/ignite/internal/IgniteFeatures.java | 8 +-
.../management/cache/CacheFindGarbageCommand.java | 4 +-
.../diagnostic/DiagnosticConnectivityCommand.java | 4 +-
.../processors/cache/GridCacheAdapter.java | 4 +-
.../persistence/pagemem/ExponentialBackoff.java | 4 +-
.../continuous/CacheContinuousQueryHandler.java | 16 +--
.../cache/store/GridCacheWriteBehindStore.java | 54 ++++-----
.../processors/cluster/ClusterProcessor.java | 4 +-
.../processors/odbc/odbc/OdbcMessageParser.java | 8 +-
.../websession/PlatformDotNetSessionData.java | 6 +-
.../internal/processors/query/stat/hll/HLL.java | 80 ++++++-------
.../BigEndianAscendingWordDeserializer.java | 16 +--
.../stat/hll/serialization/SchemaVersionOne.java | 18 +--
.../processors/query/stat/hll/util/BitVector.java | 10 +-
.../processors/query/stat/hll/util/HLLUtil.java | 4 +-
.../internal/sql/command/SqlAnalyzeCommand.java | 4 +-
.../internal/util/InitializationProtector.java | 12 +-
.../util/tostring/CircularStringBuilder.java | 8 +-
.../ignite/internal/GridNodeLocalSelfTest.java | 4 +-
.../binary/BinaryFieldExtractionSelfTest.java | 4 +-
.../internal/binary/BinaryMarshallerSelfTest.java | 4 +-
.../cache/GridCacheAbstractFullApiSelfTest.java | 4 +-
.../cache/GridCacheMarshallerTxAbstractTest.java | 14 +--
.../cache/GridCacheTtlManagerEvictionSelfTest.java | 4 +-
.../cache/IgniteCacheInvokeAbstractTest.java | 10 +-
.../cache/IgniteCacheManyAsyncOperationsTest.java | 4 +-
.../cache/IgniteCacheObjectPutSelfTest.java | 4 +-
.../cache/IgniteClusterActivateDeactivateTest.java | 6 +-
...ridCacheAtomicReferenceApiSelfAbstractTest.java | 8 +-
.../GridCacheQueueClientDisconnectTest.java | 2 +-
.../dht/IgniteCacheStartWithLoadTest.java | 4 +-
.../near/GridCacheNearClientHitTest.java | 20 ++--
...lancingDelayedPartitionMapExchangeSelfTest.java | 4 +-
.../IgnitePdsCacheRebalancingAbstractTest.java | 26 ++--
.../persistence/db/IgniteLogicalRecoveryTest.java | 6 +-
...IgnitePdsCacheWalDisabledOnRebalancingTest.java | 4 +-
.../db/file/IgnitePdsThreadInterruptionTest.java | 12 +-
.../IgniteCacheQueryCacheDestroySelfTest.java | 4 +-
.../metastorage/DistributedMetaStorageTest.java | 4 +-
.../platform/PlatformCacheEntryEventFilter.java | 10 +-
.../platform/PlatformCacheEntryEventFilterCpp.java | 10 +-
.../PlatformCacheEntryEventFilterFactory.java | 10 +-
.../ignite/platform/PlatformProcessUtils.java | 4 +-
.../org/apache/ignite/platform/model/Value.java | 4 +-
.../stream/socket/SocketStreamerSelfTest.java | 4 +-
.../testframework/wal/record/RecordUtils.java | 4 +-
.../ignite/development/utils/DataEntryWrapper.java | 10 +-
.../utils/IgniteWalConverterSensitiveDataTest.java | 6 +-
.../development/utils/IgniteWalConverterTest.java | 14 +--
.../processors/query/h2/opt/GridH2IndexBase.java | 6 +-
.../processors/query/h2/opt/H2IndexCostedBase.java | 38 +++---
.../cache/index/H2DynamicTableSelfTest.java | 4 +-
.../cache/index/IndexCorruptionRebuildTest.java | 4 +-
.../persistence/db/wal/IgniteWalRecoveryTest.java | 26 ++--
.../query/IgniteSqlCreateTableTemplateTest.java | 12 +-
.../query/IgniteSqlSplitterSelfTest.java | 6 +-
.../query/stat/StatisticsStorageRestartTest.java | 6 +-
.../processors/query/stat/hll/FullHLLTest.java | 20 ++--
.../query/stat/hll/ProbabilisticTestUtil.java | 10 +-
.../OpenCensusMetricExporterSpiTest.java | 8 +-
.../protocols/http/jetty/GridJettyRestHandler.java | 6 +-
.../internal/websession/WebSessionSelfTest.java | 14 +--
74 files changed, 461 insertions(+), 461 deletions(-)
diff --git a/modules/benchmarks/src/main/java/org/apache/ignite/internal/benchmarks/model/IntValue.java b/modules/benchmarks/src/main/java/org/apache/ignite/internal/benchmarks/model/IntValue.java
index e68a0772794..025191ad53d 100644
--- a/modules/benchmarks/src/main/java/org/apache/ignite/internal/benchmarks/model/IntValue.java
+++ b/modules/benchmarks/src/main/java/org/apache/ignite/internal/benchmarks/model/IntValue.java
@@ -90,9 +90,9 @@ public class IntValue implements Externalizable, Binarylizable {
if (o == null || getClass() != o.getClass())
return false;
- IntValue value = (IntValue)o;
+ IntValue val = (IntValue)o;
- return val == value.val;
+ return this.val == val.val;
}
/** {@inheritDoc} */
diff --git a/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/exec/exp/RexImpTable.java b/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/exec/exp/RexImpTable.java
index c5c8a378b2a..05f085ce273 100644
--- a/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/exec/exp/RexImpTable.java
+++ b/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/exec/exp/RexImpTable.java
@@ -458,9 +458,9 @@ public class RexImpTable {
map.put(REINTERPRET, new ReinterpretImplementor());
- final RexCallImplementor value = new ValueConstructorImplementor();
- map.put(MAP_VALUE_CONSTRUCTOR, value);
- map.put(ARRAY_VALUE_CONSTRUCTOR, value);
+ final RexCallImplementor val = new ValueConstructorImplementor();
+ map.put(MAP_VALUE_CONSTRUCTOR, val);
+ map.put(ARRAY_VALUE_CONSTRUCTOR, val);
map.put(ITEM, new ItemImplementor());
map.put(DEFAULT, new DefaultImplementor());
@@ -829,8 +829,8 @@ public class RexImpTable {
@Override Expression implementSafe(final RexToLixTranslator translator,
final RexCall call, final List<Expression> argValueList) {
final boolean strict = !translator.conformance.allowExtendedTrim();
- final Object value = translator.getLiteralValue(argValueList.get(0));
- SqlTrimFunction.Flag flag = (SqlTrimFunction.Flag)value;
+ final Object val = translator.getLiteralValue(argValueList.get(0));
+ SqlTrimFunction.Flag flag = (SqlTrimFunction.Flag)val;
return Expressions.call(
BuiltInMethod.TRIM.method,
Expressions.constant(
@@ -1056,9 +1056,9 @@ public class RexImpTable {
List<Expression> leftExprs = Util.skip(argValueList, 2);
// Default value for JSON_VALUE behaviors.
Expression emptyBehavior = Expressions.constant(SqlJsonValueEmptyOrErrorBehavior.NULL);
- Expression dfltValueOnEmpty = Expressions.constant(null);
+ Expression dfltValOnEmpty = Expressions.constant(null);
Expression errorBehavior = Expressions.constant(SqlJsonValueEmptyOrErrorBehavior.NULL);
- Expression dfltValueOnError = Expressions.constant(null);
+ Expression dfltValOnError = Expressions.constant(null);
// Patched up with user defines.
if (!leftExprs.isEmpty()) {
for (int i = 0; i < leftExprs.size(); i++) {
@@ -1070,7 +1070,7 @@ public class RexImpTable {
if (dfltSymbolIdx >= 0
&& translator.getLiteralValue(leftExprs.get(dfltSymbolIdx))
== SqlJsonValueEmptyOrErrorBehavior.DEFAULT) {
- dfltValueOnEmpty = leftExprs.get(i - 1);
+ dfltValOnEmpty = leftExprs.get(i - 1);
emptyBehavior = leftExprs.get(dfltSymbolIdx);
}
else
@@ -1080,7 +1080,7 @@ public class RexImpTable {
if (dfltSymbolIdx >= 0
&& translator.getLiteralValue(leftExprs.get(dfltSymbolIdx))
== SqlJsonValueEmptyOrErrorBehavior.DEFAULT) {
- dfltValueOnError = leftExprs.get(i - 1);
+ dfltValOnError = leftExprs.get(i - 1);
errorBehavior = leftExprs.get(dfltSymbolIdx);
}
else
@@ -1090,9 +1090,9 @@ public class RexImpTable {
}
}
newOperands.add(emptyBehavior);
- newOperands.add(dfltValueOnEmpty);
+ newOperands.add(dfltValOnEmpty);
newOperands.add(errorBehavior);
- newOperands.add(dfltValueOnError);
+ newOperands.add(dfltValOnError);
Class clazz = method.getDeclaringClass();
expression = EnumUtils.call(null, clazz, method.getName(), newOperands);
@@ -1302,23 +1302,23 @@ public class RexImpTable {
/** {@inheritDoc} */
@Override Expression implementSafe(RexToLixTranslator translator,
RexCall call, List<Expression> argValueList) {
- final Expression argValue = argValueList.get(0);
+ final Expression argVal = argValueList.get(0);
final Expression e;
//Special case for implementing unary minus with BigDecimal type
//for other data type(except BigDecimal) '-' operator is OK, but for
//BigDecimal, we should call negate method of BigDecimal
- if (expressionType == ExpressionType.Negate && argValue.type == BigDecimal.class
+ if (expressionType == ExpressionType.Negate && argVal.type == BigDecimal.class
&& null != backupMethodName)
- e = Expressions.call(argValue, backupMethodName);
+ e = Expressions.call(argVal, backupMethodName);
else
- e = Expressions.makeUnary(expressionType, argValue);
+ e = Expressions.makeUnary(expressionType, argVal);
- if (e.type.equals(argValue.type))
+ if (e.type.equals(argVal.type))
return e;
// Certain unary operators do not preserve type. For example, the "-"
// operator applied to a "byte" expression returns an "int".
- return Expressions.convert_(e, argValue.type);
+ return Expressions.convert_(e, argVal.type);
}
}
@@ -1601,22 +1601,22 @@ public class RexImpTable {
false);
for (int i = 0; i < argValueList.size(); i++) {
Expression key = argValueList.get(i++);
- Expression value = argValueList.get(i);
+ Expression val = argValueList.get(i);
blockBuilder.add(
Expressions.statement(
Expressions.call(map, BuiltInMethod.MAP_PUT.method,
- Expressions.box(key), Expressions.box(value))));
+ Expressions.box(key), Expressions.box(val))));
}
return map;
case ARRAY_VALUE_CONSTRUCTOR:
Expression lyst =
blockBuilder.append("list", Expressions.new_(ArrayList.class),
false);
- for (Expression value : argValueList) {
+ for (Expression val : argValueList) {
blockBuilder.add(
Expressions.statement(
Expressions.call(lyst, BuiltInMethod.COLLECTION_ADD.method,
- Expressions.box(value))));
+ Expressions.box(val))));
}
return lyst;
default:
@@ -1901,17 +1901,17 @@ public class RexImpTable {
final RexCall call,
final List<RexToLixTranslator.Result> arguments) {
final List<Expression> argIsNullList = new ArrayList<>();
- final List<Expression> argValueList = new ArrayList<>();
+ final List<Expression> argValList = new ArrayList<>();
for (RexToLixTranslator.Result result : arguments) {
argIsNullList.add(result.isNullVariable);
- argValueList.add(result.valueVariable);
+ argValList.add(result.valueVariable);
}
final Expression condition = getCondition(argIsNullList);
- final ParameterExpression valueVariable =
- genValueStatement(translator, call, argValueList, condition);
+ final ParameterExpression valVariable =
+ genValueStatement(translator, call, argValList, condition);
final ParameterExpression isNullVariable =
- genIsNullStatement(translator, valueVariable);
- return new RexToLixTranslator.Result(isNullVariable, valueVariable);
+ genIsNullStatement(translator, valVariable);
+ return new RexToLixTranslator.Result(isNullVariable, valVariable);
}
/** */
@@ -1939,15 +1939,15 @@ public class RexImpTable {
final RexToLixTranslator translator,
final RexCall call, final List<Expression> argValueList,
final Expression condition) {
- List<Expression> optimizedArgValueList = argValueList;
+ List<Expression> optimizedArgValList = argValueList;
if (harmonize) {
- optimizedArgValueList =
- harmonize(optimizedArgValueList, translator, call);
+ optimizedArgValList =
+ harmonize(optimizedArgValList, translator, call);
}
- optimizedArgValueList = unboxIfNecessary(optimizedArgValueList);
+ optimizedArgValList = unboxIfNecessary(optimizedArgValList);
- final Expression callValue =
- implementSafe(translator, call, optimizedArgValueList);
+ final Expression callVal =
+ implementSafe(translator, call, optimizedArgValList);
// In general, RexCall's type is correct for code generation
// and thus we should ensure the consistency.
@@ -1956,25 +1956,25 @@ public class RexImpTable {
final SqlOperator op = call.getOperator();
final Type returnType = translator.typeFactory.getJavaClass(call.getType());
final boolean noConvert = (returnType == null)
- || (returnType == callValue.getType())
+ || (returnType == callVal.getType())
|| (op instanceof SqlTableFunction)
|| (op instanceof SqlUserDefinedTableMacro)
|| (op instanceof SqlUserDefinedTableFunction);
- final Expression convertedCallValue =
+ final Expression convertedCallVal =
noConvert
- ? callValue
- : ConverterUtils.convert(callValue, returnType);
+ ? callVal
+ : ConverterUtils.convert(callVal, returnType);
- final Expression valueExpression =
+ final Expression valExpression =
Expressions.condition(condition,
- getIfTrue(convertedCallValue.getType(), argValueList),
- convertedCallValue);
- final ParameterExpression value =
- Expressions.parameter(convertedCallValue.getType(),
+ getIfTrue(convertedCallVal.getType(), argValueList),
+ convertedCallVal);
+ final ParameterExpression val =
+ Expressions.parameter(convertedCallVal.getType(),
translator.getBlockBuilder().newName(getVariableName() + "_value"));
translator.getBlockBuilder().add(
- Expressions.declare(Modifier.FINAL, value, valueExpression));
- return value;
+ Expressions.declare(Modifier.FINAL, val, valExpression));
+ return val;
}
/** */
@@ -2028,9 +2028,9 @@ public class RexImpTable {
final Type javaCls =
translator.typeFactory.getJavaClass(type);
final List<Expression> harmonizedArgValues = new ArrayList<>();
- for (Expression argValue : argValueList) {
+ for (Expression argVal : argValueList) {
harmonizedArgValues.add(
- EnumUtils.convert(argValue, javaCls));
+ EnumUtils.convert(argVal, javaCls));
}
return harmonizedArgValues;
}
@@ -2039,18 +2039,18 @@ public class RexImpTable {
* Under null check, it is safe to unbox the operands before entering the implementor.
*/
private List<Expression> unboxIfNecessary(final List<Expression> argValueList) {
- List<Expression> unboxValueList = argValueList;
+ List<Expression> unboxValList = argValueList;
if (nullPolicy == NullPolicy.STRICT || nullPolicy == NullPolicy.ANY
|| nullPolicy == NullPolicy.SEMI_STRICT) {
- unboxValueList = argValueList.stream()
+ unboxValList = argValueList.stream()
.map(this::unboxExpression)
.collect(Collectors.toList());
}
if (nullPolicy == NullPolicy.ARG0 && !argValueList.isEmpty()) {
- final Expression unboxArg0 = unboxExpression(unboxValueList.get(0));
- unboxValueList.set(0, unboxArg0);
+ final Expression unboxArg0 = unboxExpression(unboxValList.get(0));
+ unboxValList.set(0, unboxArg0);
}
- return unboxValueList;
+ return unboxValList;
}
/** */
@@ -2110,19 +2110,19 @@ public class RexImpTable {
Expressions.condition(hasNull, NULL_EXPR, BOXED_TRUE_EXPR));
final RexImpTable.NullAs nullAs = translator.isNullable(call)
? RexImpTable.NullAs.NULL : RexImpTable.NullAs.NOT_POSSIBLE;
- final Expression valueExpression = nullAs.handle(callExpression);
- final ParameterExpression valueVariable =
- Expressions.parameter(valueExpression.getType(),
+ final Expression valExpression = nullAs.handle(callExpression);
+ final ParameterExpression valVariable =
+ Expressions.parameter(valExpression.getType(),
translator.getBlockBuilder().newName(getVariableName() + "_value"));
- final Expression isNullExpression = translator.checkNull(valueVariable);
+ final Expression isNullExpression = translator.checkNull(valVariable);
final ParameterExpression isNullVariable =
Expressions.parameter(Boolean.TYPE,
translator.getBlockBuilder().newName(getVariableName() + "_isNull"));
translator.getBlockBuilder().add(
- Expressions.declare(Modifier.FINAL, valueVariable, valueExpression));
+ Expressions.declare(Modifier.FINAL, valVariable, valExpression));
translator.getBlockBuilder().add(
Expressions.declare(Modifier.FINAL, isNullVariable, isNullExpression));
- return new RexToLixTranslator.Result(isNullVariable, valueVariable);
+ return new RexToLixTranslator.Result(isNullVariable, valVariable);
}
/** {@inheritDoc} */
@@ -2164,19 +2164,19 @@ public class RexImpTable {
Expressions.condition(hasNull, NULL_EXPR, BOXED_FALSE_EXPR));
final RexImpTable.NullAs nullAs = translator.isNullable(call)
? RexImpTable.NullAs.NULL : RexImpTable.NullAs.NOT_POSSIBLE;
- final Expression valueExpression = nullAs.handle(callExpression);
- final ParameterExpression valueVariable =
- Expressions.parameter(valueExpression.getType(),
+ final Expression valExpression = nullAs.handle(callExpression);
+ final ParameterExpression valVariable =
+ Expressions.parameter(valExpression.getType(),
translator.getBlockBuilder().newName(getVariableName() + "_value"));
- final Expression isNullExpression = translator.checkNull(valueExpression);
+ final Expression isNullExpression = translator.checkNull(valExpression);
final ParameterExpression isNullVariable =
Expressions.parameter(Boolean.TYPE,
translator.getBlockBuilder().newName(getVariableName() + "_isNull"));
translator.getBlockBuilder().add(
- Expressions.declare(Modifier.FINAL, valueVariable, valueExpression));
+ Expressions.declare(Modifier.FINAL, valVariable, valExpression));
translator.getBlockBuilder().add(
Expressions.declare(Modifier.FINAL, isNullVariable, isNullExpression));
- return new RexToLixTranslator.Result(isNullVariable, valueVariable);
+ return new RexToLixTranslator.Result(isNullVariable, valVariable);
}
/** {@inheritDoc} */
@@ -2224,14 +2224,14 @@ public class RexImpTable {
/** {@inheritDoc} */
@Override Expression implementSafe(RexToLixTranslator translator,
RexCall call, List<Expression> argValueList) {
- List<Expression> argValueList0 = ConverterUtils.fromInternal(method.getParameterTypes(), argValueList);
+ List<Expression> argValList0 = ConverterUtils.fromInternal(method.getParameterTypes(), argValueList);
if ((method.getModifiers() & Modifier.STATIC) != 0)
- return Expressions.call(method, argValueList0);
+ return Expressions.call(method, argValList0);
// The UDF class must have a public zero-args constructor.
// Assume that the validator checked already.
final Expression target = Expressions.new_(method.getDeclaringClass());
- return Expressions.call(target, method, argValueList0);
+ return Expressions.call(target, method, argValList0);
}
}
diff --git a/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/exec/exp/RexToLixTranslator.java b/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/exec/exp/RexToLixTranslator.java
index 95ff5d77780..43ed1dbd638 100644
--- a/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/exec/exp/RexToLixTranslator.java
+++ b/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/exec/exp/RexToLixTranslator.java
@@ -747,9 +747,9 @@ public class RexToLixTranslator implements RexVisitor<RexToLixTranslator.Result>
break;
default:
final Primitive primitive = Primitive.ofBoxOr(javaCls);
- final Comparable value = literal.getValueAs(Comparable.class);
+ final Comparable val = literal.getValueAs(Comparable.class);
- value2 = primitive != null && value instanceof Number ? primitive.number((Number)value) : value;
+ value2 = primitive != null && val instanceof Number ? primitive.number((Number)val) : val;
}
return Expressions.constant(value2, javaCls);
}
@@ -901,30 +901,30 @@ public class RexToLixTranslator implements RexVisitor<RexToLixTranslator.Result>
// Generate one line of code to get the input, e.g.,
// "final Employee current =(Employee) inputEnumerator.current();"
- final Expression valueExpression = inputGetter.field(
+ final Expression valExpression = inputGetter.field(
list, inputRef.getIndex(), currentStorageType);
// Generate one line of code for the value of RexInputRef, e.g.,
// "final Integer input_value = current.commission;"
- final ParameterExpression valueVariable =
+ final ParameterExpression valVariable =
Expressions.parameter(
- valueExpression.getType(), list.newName("input_value"));
- list.add(Expressions.declare(Modifier.FINAL, valueVariable, valueExpression));
+ valExpression.getType(), list.newName("input_value"));
+ list.add(Expressions.declare(Modifier.FINAL, valVariable, valExpression));
// Generate one line of code to check whether RexInputRef is null, e.g.,
// "final boolean input_isNull = input_value == null;"
- final Expression isNullExpression = checkNull(valueVariable);
+ final Expression isNullExpression = checkNull(valVariable);
final ParameterExpression isNullVariable =
Expressions.parameter(
Boolean.TYPE, list.newName("input_isNull"));
list.add(Expressions.declare(Modifier.FINAL, isNullVariable, isNullExpression));
- final Result result = new Result(isNullVariable, valueVariable);
+ final Result result = new Result(isNullVariable, valVariable);
// Cache <RexInputRef, currentStorageType>'s result
rexWithStorageTypeResultMap.put(key, result);
- return new Result(isNullVariable, valueVariable);
+ return new Result(isNullVariable, valVariable);
}
/** {@inheritDoc} */
@@ -944,15 +944,15 @@ public class RexToLixTranslator implements RexVisitor<RexToLixTranslator.Result>
// Generate one line of code for the value of RexLiteral, e.g.,
// "final int literal_value = 10;"
- final Expression valueExpression = literal.isNull()
+ final Expression valExpression = literal.isNull()
// Note: even for null literal, we can't loss its type information
? getTypedNullLiteral(literal)
: translateLiteral(literal, literal.getType(),
typeFactory, RexImpTable.NullAs.NOT_POSSIBLE);
- final ParameterExpression valueVariable =
- Expressions.parameter(valueExpression.getType(),
+ final ParameterExpression valVariable =
+ Expressions.parameter(valExpression.getType(),
list.newName("literal_value"));
- list.add(Expressions.declare(Modifier.FINAL, valueVariable, valueExpression));
+ list.add(Expressions.declare(Modifier.FINAL, valVariable, valExpression));
// Generate one line of code to check whether RexLiteral is null, e.g.,
// "final boolean literal_isNull = false;"
@@ -963,8 +963,8 @@ public class RexToLixTranslator implements RexVisitor<RexToLixTranslator.Result>
list.add(Expressions.declare(Modifier.FINAL, isNullVariable, isNullExpression));
// Maintain the map from valueVariable (ParameterExpression) to real Expression
- literalMap.put(valueVariable, valueExpression);
- final Result result = new Result(isNullVariable, valueVariable);
+ literalMap.put(valVariable, valExpression);
+ final Result result = new Result(isNullVariable, valVariable);
// Cache RexLiteral's result
rexResultMap.put(literal, result);
return result;
@@ -1068,18 +1068,18 @@ public class RexToLixTranslator implements RexVisitor<RexToLixTranslator.Result>
*/
private Result implementCaseWhen(RexCall call) {
final Type returnType = typeFactory.getJavaClass(call.getType());
- final ParameterExpression valueVariable =
+ final ParameterExpression valVariable =
Expressions.parameter(returnType,
list.newName("case_when_value"));
- list.add(Expressions.declare(0, valueVariable, null));
+ list.add(Expressions.declare(0, valVariable, null));
final List<RexNode> operandList = call.getOperands();
- implementRecursively(this, operandList, valueVariable, 0);
- final Expression isNullExpression = checkNull(valueVariable);
+ implementRecursively(this, operandList, valVariable, 0);
+ final Expression isNullExpression = checkNull(valVariable);
final ParameterExpression isNullVariable =
Expressions.parameter(
Boolean.TYPE, list.newName("case_when_isNull"));
list.add(Expressions.declare(Modifier.FINAL, isNullVariable, isNullExpression));
- final Result result = new Result(isNullVariable, valueVariable);
+ final Result result = new Result(isNullVariable, valVariable);
rexResultMap.put(call, result);
return result;
}
@@ -1162,18 +1162,18 @@ public class RexToLixTranslator implements RexVisitor<RexToLixTranslator.Result>
/** */
private Result toInnerStorageType(final Result result, final Type storageType) {
- final Expression valueExpression =
+ final Expression valExpression =
ConverterUtils.toInternal(result.valueVariable, storageType);
- if (valueExpression.equals(result.valueVariable))
+ if (valExpression.equals(result.valueVariable))
return result;
- final ParameterExpression valueVariable =
+ final ParameterExpression valVariable =
Expressions.parameter(
- valueExpression.getType(),
+ valExpression.getType(),
list.newName(result.valueVariable.name + "_inner_type"));
- list.add(Expressions.declare(Modifier.FINAL, valueVariable, valueExpression));
+ list.add(Expressions.declare(Modifier.FINAL, valVariable, valExpression));
final ParameterExpression isNullVariable = result.isNullVariable;
- return new Result(isNullVariable, valueVariable);
+ return new Result(isNullVariable, valVariable);
}
/** {@inheritDoc} */
@@ -1190,16 +1190,16 @@ public class RexToLixTranslator implements RexVisitor<RexToLixTranslator.Result>
final Expression ctxGet = Expressions.call(root, IgniteMethod.CONTEXT_GET_PARAMETER_VALUE.method(),
Expressions.constant("?" + dynamicParam.getIndex()), Expressions.constant(paramType));
- final Expression valueExpression = SqlTypeUtil.isDecimal(dynamicParam.getType()) ?
+ final Expression valExpression = SqlTypeUtil.isDecimal(dynamicParam.getType()) ?
ConverterUtils.convertToDecimal(ctxGet, dynamicParam.getType()) : ConverterUtils.convert(ctxGet, storageType);
- final ParameterExpression valueVariable =
- Expressions.parameter(valueExpression.getType(), list.newName("value_dynamic_param"));
- list.add(Expressions.declare(Modifier.FINAL, valueVariable, valueExpression));
+ final ParameterExpression valVariable =
+ Expressions.parameter(valExpression.getType(), list.newName("value_dynamic_param"));
+ list.add(Expressions.declare(Modifier.FINAL, valVariable, valExpression));
final ParameterExpression isNullVariable =
Expressions.parameter(Boolean.TYPE, list.newName("isNull_dynamic_param"));
- list.add(Expressions.declare(Modifier.FINAL, isNullVariable, checkNull(valueVariable)));
- final Result result = new Result(isNullVariable, valueVariable);
+ list.add(Expressions.declare(Modifier.FINAL, isNullVariable, checkNull(valVariable)));
+ final Result result = new Result(isNullVariable, valVariable);
rexWithStorageTypeResultMap.put(key, result);
return result;
}
@@ -1224,17 +1224,17 @@ public class RexToLixTranslator implements RexVisitor<RexToLixTranslator.Result>
final Expression input = getter.field(
list, fieldIdx, currentStorageType);
final Expression condition = checkNull(input);
- final ParameterExpression valueVariable =
+ final ParameterExpression valVariable =
Expressions.parameter(input.getType(), list.newName("corInp_value"));
- list.add(Expressions.declare(Modifier.FINAL, valueVariable, input));
+ list.add(Expressions.declare(Modifier.FINAL, valVariable, input));
final ParameterExpression isNullVariable =
Expressions.parameter(Boolean.TYPE, list.newName("corInp_isNull"));
final Expression isNullExpression = Expressions.condition(
condition,
RexImpTable.TRUE_EXPR,
- checkNull(valueVariable));
+ checkNull(valVariable));
list.add(Expressions.declare(Modifier.FINAL, isNullVariable, isNullExpression));
- final Result result1 = new Result(isNullVariable, valueVariable);
+ final Result result1 = new Result(isNullVariable, valVariable);
rexWithStorageTypeResultMap.put(key, result1);
return result1;
default:
diff --git a/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/externalize/RelJson.java b/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/externalize/RelJson.java
index 7eacd2d8ea5..98597e1d1d6 100644
--- a/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/externalize/RelJson.java
+++ b/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/externalize/RelJson.java
@@ -821,9 +821,9 @@ class RelJson {
return map;
case LITERAL:
RexLiteral literal = (RexLiteral)node;
- Object value = literal.getValue3();
+ Object val = literal.getValue3();
map = map();
- map.put("literal", toJson(value));
+ map.put("literal", toJson(val));
map.put("type", toJson(node.getType()));
return map;
diff --git a/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/externalize/RelJsonReader.java b/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/externalize/RelJsonReader.java
index d740af19174..531f9c94e1d 100644
--- a/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/externalize/RelJsonReader.java
+++ b/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/externalize/RelJsonReader.java
@@ -319,8 +319,8 @@ public class RelJsonReader {
private ImmutableList<RexLiteral> getTuple(List jsonTuple) {
ImmutableList.Builder<RexLiteral> builder =
ImmutableList.builder();
- for (Object jsonValue : jsonTuple)
- builder.add((RexLiteral)relJson.toRex(this, jsonValue));
+ for (Object jsonVal : jsonTuple)
+ builder.add((RexLiteral)relJson.toRex(this, jsonVal));
return builder.build();
}
diff --git a/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/externalize/RelJsonWriter.java b/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/externalize/RelJsonWriter.java
index 0a2ae5a60c6..e3aaf1e5bd7 100644
--- a/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/externalize/RelJsonWriter.java
+++ b/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/externalize/RelJsonWriter.java
@@ -136,11 +136,11 @@ public class RelJsonWriter implements RelWriter {
map.put("id", null); // ensure that id is the first attribute
map.put("relOp", relJson.classToTypeName(rel.getClass()));
- for (Pair<String, Object> value : values) {
- if (value.right instanceof RelNode)
+ for (Pair<String, Object> val : values) {
+ if (val.right instanceof RelNode)
continue;
- map.put(value.left, relJson.toJson(value.right));
+ map.put(val.left, relJson.toJson(val.right));
}
// omit 'inputs: ["3"]' if "3" is the preceding rel
final List<Object> list = explainInputs(rel.getInputs());
diff --git a/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/metadata/IgniteMdCollation.java b/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/metadata/IgniteMdCollation.java
index 364afaba798..3dd9e38d3ee 100644
--- a/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/metadata/IgniteMdCollation.java
+++ b/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/metadata/IgniteMdCollation.java
@@ -286,15 +286,15 @@ public class IgniteMdCollation implements MetadataHandler<BuiltInMetadata.Collat
new ArrayList<>();
for (Map.Entry<Integer, SqlMonotonicity> entry
: targetsWithMonotonicity.entrySet()) {
- final SqlMonotonicity value = entry.getValue();
- switch (value) {
+ final SqlMonotonicity val = entry.getValue();
+ switch (val) {
case NOT_MONOTONIC:
case CONSTANT:
break;
default:
fieldCollationsForRexCalls.add(
new RelFieldCollation(entry.getKey(),
- RelFieldCollation.Direction.of(value)));
+ RelFieldCollation.Direction.of(val)));
break;
}
}
diff --git a/modules/checkstyle/src/main/resources/abbrevations.csv b/modules/checkstyle/src/main/resources/abbrevations.csv
index c828e45cb8c..2793cf94a92 100644
--- a/modules/checkstyle/src/main/resources/abbrevations.csv
+++ b/modules/checkstyle/src/main/resources/abbrevations.csv
@@ -73,5 +73,5 @@ subject,subj
system,sys
topology,top
#topologyversion,topVer
-#value,val
+value,val
version,ver
\ No newline at end of file
diff --git a/modules/clients/src/test/java/org/apache/ignite/internal/processors/rest/JettyRestProcessorGetAllAsArrayTest.java b/modules/clients/src/test/java/org/apache/ignite/internal/processors/rest/JettyRestProcessorGetAllAsArrayTest.java
index 582f7a6add3..a58dbf3f4c8 100644
--- a/modules/clients/src/test/java/org/apache/ignite/internal/processors/rest/JettyRestProcessorGetAllAsArrayTest.java
+++ b/modules/clients/src/test/java/org/apache/ignite/internal/processors/rest/JettyRestProcessorGetAllAsArrayTest.java
@@ -71,12 +71,12 @@ public class JettyRestProcessorGetAllAsArrayTest extends JettyRestProcessorCommo
assertTrue(res.isArray());
- Set<Map<String, String>> returnValue = new HashSet<>();
+ Set<Map<String, String>> returnVal = new HashSet<>();
- returnValue.add(F.asMap("key", "getKey1", "value", "getVal1"));
- returnValue.add(F.asMap("key", "getKey2", "value", "getVal2"));
+ returnVal.add(F.asMap("key", "getKey1", "value", "getVal1"));
+ returnVal.add(F.asMap("key", "getKey2", "value", "getVal2"));
- assertEquals(returnValue, JSON_MAPPER.treeToValue(res, Set.class));
+ assertEquals(returnVal, JSON_MAPPER.treeToValue(res, Set.class));
}
/** {@inheritDoc} */
diff --git a/modules/clients/src/test/java/org/apache/ignite/jdbc/thin/JdbcThinMissingLongArrayResultsTest.java b/modules/clients/src/test/java/org/apache/ignite/jdbc/thin/JdbcThinMissingLongArrayResultsTest.java
index be619631382..d5dba11fe78 100644
--- a/modules/clients/src/test/java/org/apache/ignite/jdbc/thin/JdbcThinMissingLongArrayResultsTest.java
+++ b/modules/clients/src/test/java/org/apache/ignite/jdbc/thin/JdbcThinMissingLongArrayResultsTest.java
@@ -104,7 +104,7 @@ public class JdbcThinMissingLongArrayResultsTest extends JdbcThinAbstractSelfTes
final int maxBlocks = SAMPLE_SIZE / BLOCK_SIZE;
Key key = new Key();
- Value value = new Value();
+ Value val = new Value();
long date = System.nanoTime();
for (int blockId = 0; blockId < maxBlocks; blockId++) {
@@ -130,15 +130,15 @@ public class JdbcThinMissingLongArrayResultsTest extends JdbcThinAbstractSelfTes
key.setDate(date);
key.setSecurityId(secId);
- value.setTime(time); // BUG in providing it via JDBC
+ val.setTime(time); // BUG in providing it via JDBC
- value.setOpen(open);
- value.setHigh(high);
- value.setLow(low);
- value.setClose(close);
- value.setMarketVWAP(marketVWAP);
+ val.setOpen(open);
+ val.setHigh(high);
+ val.setLow(low);
+ val.setClose(close);
+ val.setMarketVWAP(marketVWAP);
- streamer.addData(key, value);
+ streamer.addData(key, val);
secId++; // for unique values
//secId = RAND.nextInt(1000);
diff --git a/modules/compress/src/test/java/org/apache/ignite/internal/processors/cache/persistence/snapshot/SnapshotCompressionBasicTest.java b/modules/compress/src/test/java/org/apache/ignite/internal/processors/cache/persistence/snapshot/SnapshotCompressionBasicTest.java
index 133355ac260..9820303e51a 100644
--- a/modules/compress/src/test/java/org/apache/ignite/internal/processors/cache/persistence/snapshot/SnapshotCompressionBasicTest.java
+++ b/modules/compress/src/test/java/org/apache/ignite/internal/processors/cache/persistence/snapshot/SnapshotCompressionBasicTest.java
@@ -483,9 +483,9 @@ public class SnapshotCompressionBasicTest extends AbstractSnapshotSelfTest {
if (o == null || getClass() != o.getClass())
return false;
- Value value = (Value)o;
+ Value val = (Value)o;
- return Objects.equals(name, value.name);
+ return Objects.equals(name, val.name);
}
/** {@inheritDoc} */
diff --git a/modules/control-utility/src/main/java/org/apache/ignite/internal/commandline/argument/parser/CLIArgumentParser.java b/modules/control-utility/src/main/java/org/apache/ignite/internal/commandline/argument/parser/CLIArgumentParser.java
index 0f6b1546e48..ff7f2f84a79 100644
--- a/modules/control-utility/src/main/java/org/apache/ignite/internal/commandline/argument/parser/CLIArgumentParser.java
+++ b/modules/control-utility/src/main/java/org/apache/ignite/internal/commandline/argument/parser/CLIArgumentParser.java
@@ -86,11 +86,11 @@ public class CLIArgumentParser {
if (positionalIdx < positionalArgCfg.size()) {
cliArg = positionalArgCfg.get(positionalIdx);
- Object value = parseVal(arg, cliArg.type());
+ Object val = parseVal(arg, cliArg.type());
- ((CLIArgument<Object>)cliArg).validator().accept(cliArg.name(), value);
+ ((CLIArgument<Object>)cliArg).validator().accept(cliArg.name(), val);
- parsedPositionalArgs.add(value);
+ parsedPositionalArgs.add(val);
positionalIdx++;
}
@@ -113,11 +113,11 @@ public class CLIArgumentParser {
throw new IllegalArgumentException("Unexpected value: " + strVal);
try {
- Object value = parseVal(strVal, cliArg.type());
+ Object val = parseVal(strVal, cliArg.type());
- ((CLIArgument<Object>)cliArg).validator().accept(cliArg.name(), value);
+ ((CLIArgument<Object>)cliArg).validator().accept(cliArg.name(), val);
- parsedArgs.put(cliArg.name(), value);
+ parsedArgs.put(cliArg.name(), val);
}
catch (IllegalArgumentException e) {
throw new IllegalArgumentException("Failed to parse " + cliArg.name() + " command argument. "
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/IgniteFeatures.java b/modules/core/src/main/java/org/apache/ignite/internal/IgniteFeatures.java
index 4f8fdba44cb..b38c9392608 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/IgniteFeatures.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/IgniteFeatures.java
@@ -241,13 +241,13 @@ public enum IgniteFeatures {
public static byte[] allFeatures() {
final BitSet set = new BitSet();
- for (IgniteFeatures value : IgniteFeatures.values()) {
- if (value == PME_FREE_SWITCH && getBoolean(IGNITE_PME_FREE_SWITCH_DISABLED))
+ for (IgniteFeatures val : IgniteFeatures.values()) {
+ if (val == PME_FREE_SWITCH && getBoolean(IGNITE_PME_FREE_SWITCH_DISABLED))
continue;
- final int featureId = value.getFeatureId();
+ final int featureId = val.getFeatureId();
- assert !set.get(featureId) : "Duplicate feature ID found for [" + value + "] having same ID ["
+ assert !set.get(featureId) : "Duplicate feature ID found for [" + val + "] having same ID ["
+ featureId + "]";
set.set(featureId);
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/management/cache/CacheFindGarbageCommand.java b/modules/core/src/main/java/org/apache/ignite/internal/management/cache/CacheFindGarbageCommand.java
index 57244ef00fb..eb2c6bb36f4 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/management/cache/CacheFindGarbageCommand.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/management/cache/CacheFindGarbageCommand.java
@@ -60,9 +60,9 @@ public class CacheFindGarbageCommand
printer.accept("Garbage found on node " + nodeEntry.getKey() + ":");
- FindAndDeleteGarbageInPersistenceJobResult value = nodeEntry.getValue();
+ FindAndDeleteGarbageInPersistenceJobResult val = nodeEntry.getValue();
- Map<Integer, Map<Integer, Long>> grpPartErrorsCnt = value.checkResult();
+ Map<Integer, Map<Integer, Long>> grpPartErrorsCnt = val.checkResult();
if (!grpPartErrorsCnt.isEmpty()) {
for (Map.Entry<Integer, Map<Integer, Long>> entry : grpPartErrorsCnt.entrySet()) {
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/management/diagnostic/DiagnosticConnectivityCommand.java b/modules/core/src/main/java/org/apache/ignite/internal/management/diagnostic/DiagnosticConnectivityCommand.java
index 159fe151dcc..62426423baa 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/management/diagnostic/DiagnosticConnectivityCommand.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/management/diagnostic/DiagnosticConnectivityCommand.java
@@ -99,9 +99,9 @@ public class DiagnosticConnectivityCommand
String consId = key.consistentId().toString();
String isClient = key.isClient() ? NODE_TYPE_CLIENT : NODE_TYPE_SERVER;
- ConnectivityResult value = entry.getValue();
+ ConnectivityResult val = entry.getValue();
- Map<ClusterNode, Boolean> statuses = value.getNodeIds();
+ Map<ClusterNode, Boolean> statuses = val.getNodeIds();
List<List<String>> row = statuses.entrySet().stream().map(nodeStat -> {
ClusterNode remoteNode = nodeStat.getKey();
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
index 757e4ba4c90..789bbc11a1d 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
@@ -2292,7 +2292,7 @@ public abstract class GridCacheAdapter<K, V> implements IgniteInternalCache<K, V
IgniteInternalFuture<GridCacheReturn> fut =
tx.invokeAsync(ctx, null, (Map<? extends K, ? extends EntryProcessor<K, V, Object>>)map, args);
- Map<K, EntryProcessorResult<T>> value = fut.get().value();
+ Map<K, EntryProcessorResult<T>> val = fut.get().value();
if (statsEnabled)
metrics0().addInvokeTimeNanos(System.nanoTime() - start);
@@ -2300,7 +2300,7 @@ public abstract class GridCacheAdapter<K, V> implements IgniteInternalCache<K, V
if (performanceStatsEnabled)
writeStatistics(OperationType.CACHE_INVOKE_ALL, start);
- return value;
+ return val;
}
});
}
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/pagemem/ExponentialBackoff.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/pagemem/ExponentialBackoff.java
index c684f8bed97..1d00179e2ba 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/pagemem/ExponentialBackoff.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/pagemem/ExponentialBackoff.java
@@ -68,7 +68,7 @@ class ExponentialBackoff {
* @return {@code true} iff this backoff was not already in a reset state
*/
public boolean reset() {
- int oldValue = exponentialBackoffCounter.getAndSet(0);
- return oldValue != 0;
+ int oldVal = exponentialBackoffCounter.getAndSet(0);
+ return oldVal != 0;
}
}
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/continuous/CacheContinuousQueryHandler.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/continuous/CacheContinuousQueryHandler.java
index 4118e9bd854..46e6cebc461 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/continuous/CacheContinuousQueryHandler.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/continuous/CacheContinuousQueryHandler.java
@@ -1616,23 +1616,23 @@ public class CacheContinuousQueryHandler<K, V> implements GridContinuousHandler
EventType type = evt.entry().eventType();
- CacheObject oldValue;
- CacheObject newValue;
+ CacheObject oldVal;
+ CacheObject newVal;
if (type == EXPIRED || type == REMOVED) {
- newValue = null;
- oldValue = cacheObj;
+ newVal = null;
+ oldVal = cacheObj;
}
else {
- newValue = cacheObj;
- oldValue = null;
+ newVal = cacheObj;
+ oldVal = null;
}
return new CacheContinuousQueryEntry(evt.entry().cacheId(),
evt.entry().eventType(),
null,
- newValue,
- oldValue,
+ newVal,
+ oldVal,
evt.entry().isKeepBinary(),
evt.entry().partition(),
evt.entry().updateCounter(),
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/store/GridCacheWriteBehindStore.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/store/GridCacheWriteBehindStore.java
index ae647957cd8..9a24cf10b42 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/store/GridCacheWriteBehindStore.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/store/GridCacheWriteBehindStore.java
@@ -429,39 +429,39 @@ public class GridCacheWriteBehindStore<K, V> implements CacheStore<K, V>, Lifecy
Collection<K> remaining = null;
for (K key : keys) {
- StatefulValue<K, V> val;
+ StatefulValue<K, V> statefulVal;
if (writeCoalescing)
- val = writeCache.get(key);
+ statefulVal = writeCache.get(key);
else
- val = flusher(key).flusherWriteMap.get(key);
+ statefulVal = flusher(key).flusherWriteMap.get(key);
- if (val != null) {
- val.readLock().lock();
+ if (statefulVal != null) {
+ statefulVal.readLock().lock();
try {
StoreOperation op;
- V value;
+ V val;
- if (writeCoalescing && val.nextOperation() != null) {
- op = val.nextOperation();
+ if (writeCoalescing && statefulVal.nextOperation() != null) {
+ op = statefulVal.nextOperation();
- value = (op == StoreOperation.PUT) ? val.nextEntry().getValue() : null;
+ val = (op == StoreOperation.PUT) ? statefulVal.nextEntry().getValue() : null;
}
else {
- op = val.operation();
+ op = statefulVal.operation();
- value = (op == StoreOperation.PUT) ? val.entry().getValue() : null;
+ val = (op == StoreOperation.PUT) ? statefulVal.entry().getValue() : null;
}
if (op == StoreOperation.PUT)
- loaded.put(key, value);
+ loaded.put(key, val);
else
assert op == StoreOperation.RMV : op;
}
finally {
- val.readLock().unlock();
+ statefulVal.readLock().unlock();
}
}
else {
@@ -489,45 +489,45 @@ public class GridCacheWriteBehindStore<K, V> implements CacheStore<K, V>, Lifecy
log.debug(S.toString("Store load",
"key", key, true));
- StatefulValue<K, V> val;
+ StatefulValue<K, V> statefulVal;
if (writeCoalescing)
- val = writeCache.get(key);
+ statefulVal = writeCache.get(key);
else
- val = flusher(key).flusherWriteMap.get(key);
+ statefulVal = flusher(key).flusherWriteMap.get(key);
- if (val != null) {
- val.readLock().lock();
+ if (statefulVal != null) {
+ statefulVal.readLock().lock();
try {
StoreOperation op;
- V value;
+ V val;
- if (writeCoalescing && val.nextOperation() != null) {
- op = val.nextOperation();
+ if (writeCoalescing && statefulVal.nextOperation() != null) {
+ op = statefulVal.nextOperation();
- value = (op == StoreOperation.PUT) ? val.nextEntry().getValue() : null;
+ val = (op == StoreOperation.PUT) ? statefulVal.nextEntry().getValue() : null;
}
else {
- op = val.operation();
+ op = statefulVal.operation();
- value = (op == StoreOperation.PUT) ? val.entry().getValue() : null;
+ val = (op == StoreOperation.PUT) ? statefulVal.entry().getValue() : null;
}
switch (op) {
case PUT:
- return value;
+ return val;
case RMV:
return null;
default:
- assert false : "Unexpected operation: " + val.status();
+ assert false : "Unexpected operation: " + statefulVal.status();
}
}
finally {
- val.readLock().unlock();
+ statefulVal.readLock().unlock();
}
}
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cluster/ClusterProcessor.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cluster/ClusterProcessor.java
index 0f899ee30c8..fa813ee5130 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cluster/ClusterProcessor.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cluster/ClusterProcessor.java
@@ -305,10 +305,10 @@ public class ClusterProcessor extends GridProcessorAdapter implements Distribute
"Please try again later.");
if (!metastorage.compareAndSet(CLUSTER_ID_TAG_KEY, oldTag, new ClusterIdAndTag(oldTag.id(), newTag))) {
- ClusterIdAndTag concurrentValue = metastorage.read(CLUSTER_ID_TAG_KEY);
+ ClusterIdAndTag concurrentVal = metastorage.read(CLUSTER_ID_TAG_KEY);
throw new IgniteCheckedException("Cluster tag has been concurrently updated to different value: " +
- concurrentValue.tag());
+ concurrentVal.tag());
}
else
cluster.setTag(newTag);
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/odbc/odbc/OdbcMessageParser.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/odbc/odbc/OdbcMessageParser.java
index 587e640818a..5a64524cbe4 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/odbc/odbc/OdbcMessageParser.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/odbc/odbc/OdbcMessageParser.java
@@ -448,16 +448,16 @@ public class OdbcMessageParser implements ClientListenerMessageParser {
if (ver.compareTo(OdbcConnectionContext.VER_2_3_2) < 0) {
long summ = 0;
- for (Long value : affectedRows)
- summ += value == null ? 0 : value;
+ for (Long val : affectedRows)
+ summ += val == null ? 0 : val;
writer.writeLong(summ);
}
else {
writer.writeInt(affectedRows.length);
- for (long value : affectedRows)
- writer.writeLong(value);
+ for (long val : affectedRows)
+ writer.writeLong(val);
}
}
}
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/websession/PlatformDotNetSessionData.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/websession/PlatformDotNetSessionData.java
index 6c44dbd5e95..aa173a32326 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/websession/PlatformDotNetSessionData.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/websession/PlatformDotNetSessionData.java
@@ -167,10 +167,10 @@ public class PlatformDotNetSessionData implements Binarylizable {
for (Map.Entry<String, byte[]> e : items.entrySet()) {
String key = e.getKey();
- byte[] value = e.getValue();
+ byte[] val = e.getValue();
- if (value != null)
- this.items.put(key, value);
+ if (val != null)
+ this.items.put(key, val);
else
this.items.remove(key); // Null value indicates removed key.
}
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/query/stat/hll/HLL.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/query/stat/hll/HLL.java
index e099d0e639c..f0e9bc78a17 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/query/stat/hll/HLL.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/query/stat/hll/HLL.java
@@ -382,14 +382,14 @@ public class HLL implements Cloneable {
if (!sparseOff) {
initializeStorage(HLLType.SPARSE);
- for (final long value : explicitStorage)
- addRawSparseProbabilistic(value);
+ for (final long val : explicitStorage)
+ addRawSparseProbabilistic(val);
}
else {
initializeStorage(HLLType.FULL);
- for (final long value : explicitStorage)
- addRawProbabilistic(value);
+ for (final long val : explicitStorage)
+ addRawProbabilistic(val);
}
explicitStorage = null;
}
@@ -436,10 +436,10 @@ public class HLL implements Cloneable {
// lsb(pwMaxMask) = 2^(registerValueInBits) - 2,
// thus lsb(any_long | pwMaxMask) <= 2^(registerValueInBits) - 2,
// thus 1 + lsb(any_long | pwMaxMask) <= 2^(registerValueInBits) -1.
- final long substreamValue = (rawValue >>> log2m);
+ final long substreamVal = (rawValue >>> log2m);
final byte p_w;
- if (substreamValue == 0L) {
+ if (substreamVal == 0L) {
// The paper does not cover p(0x0), so the special value 0 is used.
// 0 is the original initialization value of the registers, so by
// doing this the multiset simply ignores it. This is acceptable
@@ -447,7 +447,7 @@ public class HLL implements Cloneable {
p_w = 0;
}
else
- p_w = (byte)(1 + BitUtil.leastSignificantBit(substreamValue | pwMaxMask));
+ p_w = (byte)(1 + BitUtil.leastSignificantBit(substreamVal | pwMaxMask));
// Short-circuit if the register is being set to zero, since algorithmically
// this corresponds to an "unset" register, and "unset" registers aren't
@@ -731,8 +731,8 @@ public class HLL implements Cloneable {
else
initializeStorage(HLLType.FULL);
- for (final long value : other.explicitStorage)
- addRaw(value);
+ for (final long val : other.explicitStorage)
+ addRaw(val);
}
return;
@@ -749,8 +749,8 @@ public class HLL implements Cloneable {
initializeStorage(HLLType.FULL);
for (final int registerIdx : other.sparseProbabilisticStorage.keySet()) {
- final byte registerValue = other.sparseProbabilisticStorage.get(registerIdx);
- probabilisticStorage.setMaxRegister(registerIdx, registerValue);
+ final byte registerVal = other.sparseProbabilisticStorage.get(registerIdx);
+ probabilisticStorage.setMaxRegister(registerIdx, registerVal);
}
}
return;
@@ -794,8 +794,8 @@ public class HLL implements Cloneable {
initializeStorage(HLLType.FULL);
for (final int registerIdx : other.sparseProbabilisticStorage.keySet()) {
- final byte registerValue = other.sparseProbabilisticStorage.get(registerIdx);
- probabilisticStorage.setMaxRegister(registerIdx, registerValue);
+ final byte registerVal = other.sparseProbabilisticStorage.get(registerIdx);
+ probabilisticStorage.setMaxRegister(registerIdx, registerVal);
}
}
}
@@ -804,8 +804,8 @@ public class HLL implements Cloneable {
probabilisticStorage = other.probabilisticStorage.clone();
}
- for (final long value : explicitStorage)
- addRaw(value);
+ for (final long val : explicitStorage)
+ addRaw(val);
explicitStorage = null;
return;
@@ -816,8 +816,8 @@ public class HLL implements Cloneable {
// dest: SPARSE
// Add the raw values from the source to the destination.
- for (final long value : other.explicitStorage)
- addRaw(value);
+ for (final long val : other.explicitStorage)
+ addRaw(val);
// NOTE: addRaw will handle promotion cleanup
}
@@ -833,8 +833,8 @@ public class HLL implements Cloneable {
probabilisticStorage = other.probabilisticStorage.clone();
for (final int registerIdx : sparseProbabilisticStorage.keySet()) {
- final byte registerValue = sparseProbabilisticStorage.get(registerIdx);
- probabilisticStorage.setMaxRegister(registerIdx, registerValue);
+ final byte registerVal = sparseProbabilisticStorage.get(registerIdx);
+ probabilisticStorage.setMaxRegister(registerIdx, registerVal);
}
sparseProbabilisticStorage = null;
@@ -849,8 +849,8 @@ public class HLL implements Cloneable {
// Add the raw values from the source to the destination.
// Promotion is not possible, so don't bother checking.
- for (final long value : other.explicitStorage)
- addRaw(value);
+ for (final long val : other.explicitStorage)
+ addRaw(val);
}
else /*source is HLLType.SPARSE*/ {
@@ -860,8 +860,8 @@ public class HLL implements Cloneable {
// Promotion is not possible, so don't bother checking.
for (final int registerIdx : other.sparseProbabilisticStorage.keySet()) {
- final byte registerValue = other.sparseProbabilisticStorage.get(registerIdx);
- probabilisticStorage.setMaxRegister(registerIdx, registerValue);
+ final byte registerVal = other.sparseProbabilisticStorage.get(registerIdx);
+ probabilisticStorage.setMaxRegister(registerIdx, registerVal);
}
}
@@ -882,18 +882,18 @@ public class HLL implements Cloneable {
// union of empty and empty is empty
return;
case EXPLICIT:
- for (final long value : other.explicitStorage)
- addRaw(value);
+ for (final long val : other.explicitStorage)
+ addRaw(val);
// NOTE: #addRaw() will handle promotion, if necessary
return;
case SPARSE:
for (final int registerIdx : other.sparseProbabilisticStorage.keySet()) {
- final byte registerValue = other.sparseProbabilisticStorage.get(registerIdx);
- final byte curRegisterValue = sparseProbabilisticStorage.getOrDefault(registerIdx, (byte)0);
+ final byte registerVal = other.sparseProbabilisticStorage.get(registerIdx);
+ final byte curRegisterVal = sparseProbabilisticStorage.getOrDefault(registerIdx, (byte)0);
- if (registerValue > curRegisterValue)
- sparseProbabilisticStorage.put(registerIdx, registerValue);
+ if (registerVal > curRegisterVal)
+ sparseProbabilisticStorage.put(registerIdx, registerVal);
}
// promotion, if necessary
@@ -901,8 +901,8 @@ public class HLL implements Cloneable {
initializeStorage(HLLType.FULL);
for (final int registerIdx : sparseProbabilisticStorage.keySet()) {
- final byte registerValue = sparseProbabilisticStorage.get(registerIdx);
- probabilisticStorage.setMaxRegister(registerIdx, registerValue);
+ final byte registerVal = sparseProbabilisticStorage.get(registerIdx);
+ probabilisticStorage.setMaxRegister(registerIdx, registerVal);
}
sparseProbabilisticStorage = null;
@@ -911,8 +911,8 @@ public class HLL implements Cloneable {
return;
case FULL:
for (int i = 0; i < m; i++) {
- final long registerValue = other.probabilisticStorage.getRegister(i);
- probabilisticStorage.setMaxRegister(i, registerValue);
+ final long registerVal = other.probabilisticStorage.getRegister(i);
+ probabilisticStorage.setMaxRegister(i, registerVal);
}
return;
@@ -955,8 +955,8 @@ public class HLL implements Cloneable {
final long[] values = explicitStorage.stream().mapToLong(Long::longValue).toArray();
Arrays.sort(values);
- for (final long value : values)
- serializer.writeWord(value);
+ for (final long val : values)
+ serializer.writeWord(val);
bytes = serializer.getBytes();
@@ -970,9 +970,9 @@ public class HLL implements Cloneable {
Arrays.sort(indices);
for (final int registerIdx : indices) {
- final long registerValue = sparseProbabilisticStorage.get(registerIdx);
+ final long registerVal = sparseProbabilisticStorage.get(registerIdx);
// pack index and value into "short word"
- final long shortWord = ((registerIdx << regwidth) | registerValue);
+ final long shortWord = ((registerIdx << regwidth) | registerVal);
serializer.writeWord(shortWord);
}
@@ -1081,11 +1081,11 @@ public class HLL implements Cloneable {
// in the sparse representation.
for (int i = 0; i < deserializer.totalWordCount(); i++) {
final long shortWord = deserializer.readWord();
- final byte registerValue = (byte)(shortWord & hll.valueMask);
+ final byte registerVal = (byte)(shortWord & hll.valueMask);
// Only set non-zero registers.
- if (registerValue != 0)
- hll.sparseProbabilisticStorage.put((int)(shortWord >>> hll.regwidth), registerValue);
+ if (registerVal != 0)
+ hll.sparseProbabilisticStorage.put((int)(shortWord >>> hll.regwidth), registerVal);
}
break;
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/query/stat/hll/serialization/BigEndianAscendingWordDeserializer.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/query/stat/hll/serialization/BigEndianAscendingWordDeserializer.java
index 452a21b2d5b..faa708dcd70 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/query/stat/hll/serialization/BigEndianAscendingWordDeserializer.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/query/stat/hll/serialization/BigEndianAscendingWordDeserializer.java
@@ -118,7 +118,7 @@ public class BigEndianAscendingWordDeserializer implements IWordDeserializer {
throw new ArrayIndexOutOfBoundsException("Word out of bounds of backing array.");
// Accumulator
- long value = 0;
+ long val = 0;
// --------------------------------------------------------------------
// First byte
@@ -132,11 +132,11 @@ public class BigEndianAscendingWordDeserializer implements IWordDeserializer {
// Right-align relevant bits of first byte.
firstByte >>>= (bitsRemainingInFirstByte - bitsToConsumeInFirstByte);
- value |= firstByte;
+ val |= firstByte;
// If the first byte contains the whole word, short-circuit.
if (firstByteIdx == lastByteIdx)
- return value;
+ return val;
// --------------------------------------------------------------------
// Middle bytes
@@ -145,18 +145,18 @@ public class BigEndianAscendingWordDeserializer implements IWordDeserializer {
for (int i = 0; i < middleByteCnt; i++) {
final long middleByte = (bytes[firstByteIdx + i + 1] & BYTE_MASK);
// Push middle byte onto accumulator.
- value <<= BITS_PER_BYTE;
- value |= middleByte;
+ val <<= BITS_PER_BYTE;
+ val |= middleByte;
}
// --------------------------------------------------------------------
// Last byte
long lastByte = (bytes[lastByteIdx] & BYTE_MASK);
lastByte >>= (BITS_PER_BYTE - lastByteBitsToConsume);
- value <<= lastByteBitsToConsume;
- value |= lastByte;
+ val <<= lastByteBitsToConsume;
+ val |= lastByte;
- return value;
+ return val;
}
/* (non-Javadoc)
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/query/stat/hll/serialization/SchemaVersionOne.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/query/stat/hll/serialization/SchemaVersionOne.java
index 4849985bf20..6830cfae7a7 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/query/stat/hll/serialization/SchemaVersionOne.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/query/stat/hll/serialization/SchemaVersionOne.java
@@ -63,17 +63,17 @@ public class SchemaVersionOne implements ISchemaVersion {
final HLLType type = metadata.HLLType();
final int typeOrdinal = getOrdinal(type);
- final int explicitCutoffValue;
+ final int explicitCutoffVal;
if (metadata.explicitOff())
- explicitCutoffValue = EXPLICIT_OFF;
+ explicitCutoffVal = EXPLICIT_OFF;
else if (metadata.explicitAuto())
- explicitCutoffValue = EXPLICIT_AUTO;
+ explicitCutoffVal = EXPLICIT_AUTO;
else
- explicitCutoffValue = metadata.log2ExplicitCutoff() + 1/*per spec*/;
+ explicitCutoffVal = metadata.log2ExplicitCutoff() + 1/*per spec*/;
bytes[0] = SerializationUtil.packVersionByte(SCHEMA_VERSION, typeOrdinal);
bytes[1] = SerializationUtil.packParametersByte(metadata.registerWidth(), metadata.registerCountLog2());
- bytes[2] = SerializationUtil.packCutoffByte(explicitCutoffValue, metadata.sparseEnabled());
+ bytes[2] = SerializationUtil.packCutoffByte(explicitCutoffVal, metadata.sparseEnabled());
}
/* (non-Javadoc)
@@ -85,10 +85,10 @@ public class SchemaVersionOne implements ISchemaVersion {
final byte cutoffByte = bytes[2];
final int typeOrdinal = SerializationUtil.typeOrdinal(verByte);
- final int explicitCutoffValue = SerializationUtil.explicitCutoff(cutoffByte);
- final boolean explicitOff = (explicitCutoffValue == EXPLICIT_OFF);
- final boolean explicitAuto = (explicitCutoffValue == EXPLICIT_AUTO);
- final int log2ExplicitCutoff = (explicitOff || explicitAuto) ? -1/*sentinel*/ : (explicitCutoffValue - 1/*per spec*/);
+ final int explicitCutoffVal = SerializationUtil.explicitCutoff(cutoffByte);
+ final boolean explicitOff = (explicitCutoffVal == EXPLICIT_OFF);
+ final boolean explicitAuto = (explicitCutoffVal == EXPLICIT_AUTO);
+ final int log2ExplicitCutoff = (explicitOff || explicitAuto) ? -1/*sentinel*/ : (explicitCutoffVal - 1/*per spec*/);
return new HLLMetadata(SCHEMA_VERSION,
getType(typeOrdinal),
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/query/stat/hll/util/BitVector.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/query/stat/hll/util/BitVector.java
index 6ddbf66d93c..5f01014e4c0 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/query/stat/hll/util/BitVector.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/query/stat/hll/util/BitVector.java
@@ -228,16 +228,16 @@ public class BitVector implements Cloneable {
final int bitRemainder = (int)(bitIdx & BITS_PER_WORD_MASK)/*aka (bitIndex % BITS_PER_WORD)*/;
// NOTE: matches getRegister()
- final long registerValue;
+ final long registerVal;
final long words[] = this.words/*for convenience/performance*/;
if (firstWordIdx == secondWordIdx)
- registerValue = ((words[firstWordIdx] >>> bitRemainder) & registerMask);
+ registerVal = ((words[firstWordIdx] >>> bitRemainder) & registerMask);
else /*register spans words*/
- registerValue = (words[firstWordIdx] >>> bitRemainder)/*no need to mask since at top of word*/
+ registerVal = (words[firstWordIdx] >>> bitRemainder)/*no need to mask since at top of word*/
| (words[secondWordIdx] << (BITS_PER_WORD - bitRemainder)) & registerMask;
// determine which is the larger and update as necessary
- if (value > registerValue) {
+ if (value > registerVal) {
// NOTE: matches setRegister()
if (firstWordIdx == secondWordIdx) {
// clear then set
@@ -255,7 +255,7 @@ public class BitVector implements Cloneable {
}
} /* else -- the register value is greater (or equal) so nothing needs to be done */
- return (value >= registerValue);
+ return (value >= registerVal);
}
// ========================================================================
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/query/stat/hll/util/HLLUtil.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/query/stat/hll/util/HLLUtil.java
index 4e78fa9872e..298b89436d9 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/query/stat/hll/util/HLLUtil.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/query/stat/hll/util/HLLUtil.java
@@ -70,12 +70,12 @@ public final class HLLUtil {
static {
for (int regWidth = HLL.MINIMUM_REGWIDTH_PARAM; regWidth <= HLL.MAXIMUM_REGWIDTH_PARAM; regWidth++) {
for (int log2m = HLL.MINIMUM_LOG2M_PARAM; log2m <= HLL.MAXIMUM_LOG2M_PARAM; log2m++) {
- int maxRegisterValue = (1 << regWidth) - 1;
+ int maxRegisterVal = (1 << regWidth) - 1;
// Since 1 is added to p(w) in the insertion algorithm, only
// (maxRegisterValue - 1) bits are inspected hence the hash
// space is one power of two smaller.
- final int pwBits = (maxRegisterValue - 1);
+ final int pwBits = (maxRegisterVal - 1);
final int totalBits = (pwBits + log2m);
final double twoToL = Math.pow(2, totalBits);
TWO_TO_L[(REG_WIDTH_INDEX_MULTIPLIER * regWidth) + log2m] = twoToL;
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/sql/command/SqlAnalyzeCommand.java b/modules/core/src/main/java/org/apache/ignite/internal/sql/command/SqlAnalyzeCommand.java
index 3a05fb18600..9c8f3e4f5df 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/sql/command/SqlAnalyzeCommand.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/sql/command/SqlAnalyzeCommand.java
@@ -171,8 +171,8 @@ public class SqlAnalyzeCommand extends SqlStatisticsCommands {
if (map == null)
return dfltVal;
- String value = map.remove(key);
- return (value == null) ? dfltVal : Byte.valueOf(value);
+ String val = map.remove(key);
+ return (val == null) ? dfltVal : Byte.valueOf(val);
}
/**
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/util/InitializationProtector.java b/modules/core/src/main/java/org/apache/ignite/internal/util/InitializationProtector.java
index 7c501c42486..f4b7dfb2280 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/util/InitializationProtector.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/util/InitializationProtector.java
@@ -43,19 +43,19 @@ public class InitializationProtector {
*/
public <T> T protect(Object protectedKey, Supplier<T> initializedVal,
IgniteThrowableRunner initializationCode) throws IgniteCheckedException {
- T value = initializedVal.get();
+ T val = initializedVal.get();
- if (value != null)
- return value;
+ if (val != null)
+ return val;
Lock lock = stripedLock.getLock(protectedKey.hashCode() % stripedLock.concurrencyLevel());
lock.lock();
try {
- value = initializedVal.get();
+ val = initializedVal.get();
- if (value != null)
- return value;
+ if (val != null)
+ return val;
initializationCode.run();
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/util/tostring/CircularStringBuilder.java b/modules/core/src/main/java/org/apache/ignite/internal/util/tostring/CircularStringBuilder.java
index dc9833aff95..1bd54ba879b 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/util/tostring/CircularStringBuilder.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/util/tostring/CircularStringBuilder.java
@@ -181,13 +181,13 @@ public class CircularStringBuilder {
@Override public String toString() {
// Create a copy, don't share the array
if (full) {
- char strValue[] = new char[value.length];
+ char strVal[] = new char[value.length];
int firstPart = value.length - finishAt - 1;
- System.arraycopy(value, finishAt + 1, strValue, 0, firstPart);
- System.arraycopy(value, 0, strValue, firstPart, value.length - firstPart);
+ System.arraycopy(value, finishAt + 1, strVal, 0, firstPart);
+ System.arraycopy(value, 0, strVal, firstPart, value.length - firstPart);
- return new String(strValue, 0, strValue.length);
+ return new String(strVal, 0, strVal.length);
}
else
return new String(value, 0, finishAt + 1);
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridNodeLocalSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridNodeLocalSelfTest.java
index d8f89acd398..aa7b0a9fe3a 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/GridNodeLocalSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/GridNodeLocalSelfTest.java
@@ -75,12 +75,12 @@ public class GridNodeLocalSelfTest extends GridCommonAbstractTest {
@Test
public void testClearNodeLocalMap() throws Exception {
final String key = "key";
- final String value = "value";
+ final String val = "value";
Ignite grid = G.ignite(getTestIgniteInstanceName());
ConcurrentMap<Object, Object> nodeLocMap = grid.cluster().nodeLocalMap();
- nodeLocMap.put(key, value);
+ nodeLocMap.put(key, val);
assert !nodeLocMap.isEmpty() : "Empty node local map";
assert nodeLocMap.containsKey(key);
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/binary/BinaryFieldExtractionSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/binary/BinaryFieldExtractionSelfTest.java
index 94f3c79fc7d..d9ba30c5a03 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/binary/BinaryFieldExtractionSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/binary/BinaryFieldExtractionSelfTest.java
@@ -255,8 +255,8 @@ public class BinaryFieldExtractionSelfTest extends GridCommonAbstractTest {
ByteBuffer buf = ByteBuffer.allocate(64);
- for (BigDecimal value : values) {
- decVal = new DecimalValue(value);
+ for (BigDecimal val : values) {
+ decVal = new DecimalValue(val);
binObj = toBinary(decVal, marsh);
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/binary/BinaryMarshallerSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/binary/BinaryMarshallerSelfTest.java
index b906d1c3db4..93dda57a999 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/binary/BinaryMarshallerSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/binary/BinaryMarshallerSelfTest.java
@@ -5518,9 +5518,9 @@ public class BinaryMarshallerSelfTest extends AbstractBinaryArraysTest {
if (!(o instanceof Value))
return false;
- Value value = (Value)o;
+ Value val = (Value)o;
- return val == value.val;
+ return this.val == val.val;
}
/** {@inheritDoc} */
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheAbstractFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheAbstractFullApiSelfTest.java
index c178abb77b3..0218587cd9e 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheAbstractFullApiSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheAbstractFullApiSelfTest.java
@@ -6806,9 +6806,9 @@ public abstract class GridCacheAbstractFullApiSelfTest extends GridCacheAbstract
if (!(o instanceof TestValue))
return false;
- TestValue value = (TestValue)o;
+ TestValue val = (TestValue)o;
- if (val != value.val)
+ if (this.val != val.val)
return false;
return true;
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheMarshallerTxAbstractTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheMarshallerTxAbstractTest.java
index 33821d39b08..5f4a7861efb 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheMarshallerTxAbstractTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheMarshallerTxAbstractTest.java
@@ -74,15 +74,15 @@ public abstract class GridCacheMarshallerTxAbstractTest extends GridCommonAbstra
@Test
public void testValueMarshallerFail() throws Exception {
String key = UUID.randomUUID().toString();
- String value = UUID.randomUUID().toString();
- String newValue = UUID.randomUUID().toString();
+ String val = UUID.randomUUID().toString();
+ String newVal = UUID.randomUUID().toString();
String key2 = UUID.randomUUID().toString();
- GridCacheWrongValue1 wrongValue = new GridCacheWrongValue1();
+ GridCacheWrongValue1 wrongVal = new GridCacheWrongValue1();
Transaction tx = grid().transactions().txStart(PESSIMISTIC, REPEATABLE_READ);
try {
- grid().cache(DEFAULT_CACHE_NAME).put(key, value);
+ grid().cache(DEFAULT_CACHE_NAME).put(key, val);
tx.commit();
}
@@ -93,11 +93,11 @@ public abstract class GridCacheMarshallerTxAbstractTest extends GridCommonAbstra
tx = grid().transactions().txStart(PESSIMISTIC, REPEATABLE_READ);
try {
- assert value.equals(grid().cache(DEFAULT_CACHE_NAME).get(key));
+ assert val.equals(grid().cache(DEFAULT_CACHE_NAME).get(key));
- grid().cache(DEFAULT_CACHE_NAME).put(key, newValue);
+ grid().cache(DEFAULT_CACHE_NAME).put(key, newVal);
- grid().cache(DEFAULT_CACHE_NAME).put(key2, wrongValue);
+ grid().cache(DEFAULT_CACHE_NAME).put(key2, wrongVal);
tx.commit();
}
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheTtlManagerEvictionSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheTtlManagerEvictionSelfTest.java
index 9287ad3d1d7..92ab4b913c0 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheTtlManagerEvictionSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheTtlManagerEvictionSelfTest.java
@@ -96,9 +96,9 @@ public class GridCacheTtlManagerEvictionSelfTest extends GridCommonAbstractTest
for (int i = 1; i <= ENTRIES_TO_PUT; i++) {
String key = "Some test entry key#" + i;
- String value = "Some test entry value#" + i;
+ String val = "Some test entry value#" + i;
- cache.put(key, value);
+ cache.put(key, val);
}
if (log.isTraceEnabled())
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheInvokeAbstractTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheInvokeAbstractTest.java
index 25eb0cdfd2e..9277574da3f 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheInvokeAbstractTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheInvokeAbstractTest.java
@@ -356,9 +356,9 @@ public abstract class IgniteCacheInvokeAbstractTest extends IgniteCacheAbstractT
entry.remove();
}
else {
- Integer value = entry.getValue() == null ? 0 : entry.getValue();
+ Integer val = entry.getValue() == null ? 0 : entry.getValue();
- entry.setValue(++value);
+ entry.setValue(++val);
}
if (key.startsWith("register_type"))
@@ -381,12 +381,12 @@ public abstract class IgniteCacheInvokeAbstractTest extends IgniteCacheAbstractT
assertNull(storeMap.get(keys));
}
else {
- int value = entry.getValue();
+ int val = entry.getValue();
- assertEquals("\"" + key + "' entry has wrong value, exp=1 actl=" + value, 1, value);
+ assertEquals("\"" + key + "' entry has wrong value, exp=1 actl=" + val, 1, val);
if (cacheStoreFactory() != null)
- assertEquals("\"" + key + "' entry has wrong value in cache store, exp=1 actl=" + value,
+ assertEquals("\"" + key + "' entry has wrong value in cache store, exp=1 actl=" + val,
1, (int)storeMap.get(key));
}
}
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheManyAsyncOperationsTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheManyAsyncOperationsTest.java
index d2098672648..54d2601c300 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheManyAsyncOperationsTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheManyAsyncOperationsTest.java
@@ -115,9 +115,9 @@ public class IgniteCacheManyAsyncOperationsTest extends IgniteCacheAbstractTest
IgniteCache<Integer, BinaryObject> cache = client.cache(DEFAULT_CACHE_NAME).withKeepBinary();
- BinaryObject value = client.binary().builder("TEST").build();
+ BinaryObject val = client.binary().builder("TEST").build();
- cache.put(1, value);
+ cache.put(1, val);
// Start parallel operations to initiate operation retry.
List<IgniteFuture<Void>> futs = IntStream.range(0, 1000).parallel().mapToObj(i ->
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheObjectPutSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheObjectPutSelfTest.java
index 6fa28779e53..a9bc75aa721 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheObjectPutSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheObjectPutSelfTest.java
@@ -164,9 +164,9 @@ public class IgniteCacheObjectPutSelfTest extends GridCommonAbstractTest {
if (!(o instanceof TestValue))
return false;
- TestValue value = (TestValue)o;
+ TestValue val = (TestValue)o;
- return val == value.val;
+ return this.val == val.val;
}
/** {@inheritDoc} */
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteClusterActivateDeactivateTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteClusterActivateDeactivateTest.java
index b05d3e9e8a6..9cd45a97a21 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteClusterActivateDeactivateTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteClusterActivateDeactivateTest.java
@@ -479,14 +479,14 @@ public class IgniteClusterActivateDeactivateTest extends GridCommonAbstractTest
for (int j = 0; j < 10; j++) {
Integer key = ThreadLocalRandom.current().nextInt(1000);
- Integer value = j;
+ Integer val = j;
if (state == ACTIVE)
cache.put(key, j);
else
- assertThrowsWithCause(() -> cache.put(key, value), IgniteClusterReadOnlyException.class);
+ assertThrowsWithCause(() -> cache.put(key, val), IgniteClusterReadOnlyException.class);
- assertEquals(state == ACTIVE ? value : null, cache.get(key));
+ assertEquals(state == ACTIVE ? val : null, cache.get(key));
}
}
}
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/datastructures/GridCacheAtomicReferenceApiSelfAbstractTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/datastructures/GridCacheAtomicReferenceApiSelfAbstractTest.java
index 680d8ccb3b8..171cad41938 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/datastructures/GridCacheAtomicReferenceApiSelfAbstractTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/datastructures/GridCacheAtomicReferenceApiSelfAbstractTest.java
@@ -162,16 +162,16 @@ public abstract class GridCacheAtomicReferenceApiSelfAbstractTest extends Ignite
try {
String atomicName = UUID.randomUUID().toString();
- String initValue = "qazwsx";
+ String initVal = "qazwsx";
- IgniteAtomicReference<String> atomicRef = ignite.atomicReference(atomicName, initValue, true);
+ IgniteAtomicReference<String> atomicRef = ignite.atomicReference(atomicName, initVal, true);
try (Transaction tx = ignite.transactions().txStart()) {
cache.put(1, 1);
- assertEquals(initValue, atomicRef.get());
+ assertEquals(initVal, atomicRef.get());
- assertTrue(atomicRef.compareAndSet(initValue, "aaa"));
+ assertTrue(atomicRef.compareAndSet(initVal, "aaa"));
assertEquals("aaa", atomicRef.get());
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/datastructures/GridCacheQueueClientDisconnectTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/datastructures/GridCacheQueueClientDisconnectTest.java
index d9d7560de6b..627810ac2eb 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/datastructures/GridCacheQueueClientDisconnectTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/datastructures/GridCacheQueueClientDisconnectTest.java
@@ -84,7 +84,7 @@ public class GridCacheQueueClientDisconnectTest extends GridCommonAbstractTest {
GridTestUtils.runAsync(new Runnable() {
@Override public void run() {
try {
- Object value = queue.take();
+ Object val = queue.take();
}
catch (IgniteClientDisconnectedException icd) {
latch.countDown();
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/IgniteCacheStartWithLoadTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/IgniteCacheStartWithLoadTest.java
index 9e8d9c6a93d..450142b266f 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/IgniteCacheStartWithLoadTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/IgniteCacheStartWithLoadTest.java
@@ -101,9 +101,9 @@ public class IgniteCacheStartWithLoadTest extends GridCommonAbstractTest {
try (Transaction tx = node.transactions().txStart(PESSIMISTIC, REPEATABLE_READ)) {
for (int it = 0; it < keys; it++) {
int key = rnd.nextInt(keysSpace);
- byte[] value = new byte[2048];
+ byte[] val = new byte[2048];
- cache.put(key, value);
+ cache.put(key, val);
}
tx.commit();
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/GridCacheNearClientHitTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/GridCacheNearClientHitTest.java
index 4170e986866..e20282d5537 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/GridCacheNearClientHitTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/GridCacheNearClientHitTest.java
@@ -94,31 +94,31 @@ public class GridCacheNearClientHitTest extends GridCommonAbstractTest {
cache.put(remoteKey, remoteKey);
- Object value = nearCache.localPeek(remoteKey, NEAR);
+ Object val = nearCache.localPeek(remoteKey, NEAR);
- assertNull("The value should not be loaded from a remote node.", value);
+ assertNull("The value should not be loaded from a remote node.", val);
nearCache.get(remoteKey);
- value = nearCache.localPeek(remoteKey, NEAR);
+ val = nearCache.localPeek(remoteKey, NEAR);
- assertNotNull("The returned value should not be null.", value);
+ assertNotNull("The returned value should not be null.", val);
srvNode.close();
awaitPartitionMapExchange();
- value = nearCache.localPeek(remoteKey, NEAR);
+ val = nearCache.localPeek(remoteKey, NEAR);
- assertNull("The value should not be loaded from a remote node.", value);
+ assertNull("The value should not be loaded from a remote node.", val);
- value = nearCache.get(remoteKey);
+ val = nearCache.get(remoteKey);
- assertNotNull("The value should be loaded from a remote node.", value);
+ assertNotNull("The value should be loaded from a remote node.", val);
- value = nearCache.localPeek(remoteKey, NEAR);
+ val = nearCache.localPeek(remoteKey, NEAR);
- assertNotNull("The returned value should not be null.", value);
+ assertNotNull("The returned value should not be null.", val);
}
finally {
stopAllGrids();
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/rebalancing/GridCacheRabalancingDelayedPartitionMapExchangeSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/rebalancing/GridCacheRabalancingDelayedPartitionMapExchangeSelfTest.java
index e988d1d1c5c..b83b5309c9b 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/rebalancing/GridCacheRabalancingDelayedPartitionMapExchangeSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/rebalancing/GridCacheRabalancingDelayedPartitionMapExchangeSelfTest.java
@@ -90,7 +90,7 @@ public class GridCacheRabalancingDelayedPartitionMapExchangeSelfTest extends Gri
assert !replay.get() : "Record of message is not allowed after replay";
- Runnable prevValue = rs.putIfAbsent(node.id(), new Runnable() {
+ Runnable prevVal = rs.putIfAbsent(node.id(), new Runnable() {
@Override public void run() {
if (log.isDebugEnabled())
log.debug("Replay: " + msg);
@@ -99,7 +99,7 @@ public class GridCacheRabalancingDelayedPartitionMapExchangeSelfTest extends Gri
}
});
- assert prevValue == null : "Duplicate message registered to [" + node.id() + "]";
+ assert prevVal == null : "Duplicate message registered to [" + node.id() + "]";
}
else
try {
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/IgnitePdsCacheRebalancingAbstractTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/IgnitePdsCacheRebalancingAbstractTest.java
index c4d8aeff1db..95f889ac256 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/IgnitePdsCacheRebalancingAbstractTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/IgnitePdsCacheRebalancingAbstractTest.java
@@ -701,10 +701,10 @@ public abstract class IgnitePdsCacheRebalancingAbstractTest extends GridCommonAb
IgniteCache<Integer, TestValue> cacheInMem = ignite0.cache(INDEXED_CACHE_IN_MEMORY);
for (int i = 0; i < entriesCnt / 2; i++) {
- TestValue value = new TestValue(i, i * 2, i * 3);
+ TestValue val = new TestValue(i, i * 2, i * 3);
- cachePds.put(i, value);
- cacheInMem.put(i, value);
+ cachePds.put(i, val);
+ cacheInMem.put(i, val);
}
forceCheckpoint();
@@ -712,10 +712,10 @@ public abstract class IgnitePdsCacheRebalancingAbstractTest extends GridCommonAb
stopGrid(1);
for (int i = entriesCnt / 2; i < entriesCnt; i++) {
- TestValue value = new TestValue(i, i * 2, i * 3);
+ TestValue val = new TestValue(i, i * 2, i * 3);
- cachePds.put(i, value);
- cacheInMem.put(i, value);
+ cachePds.put(i, val);
+ cacheInMem.put(i, val);
}
IgniteEx ignite1 = startGrid(1);
@@ -731,10 +731,10 @@ public abstract class IgnitePdsCacheRebalancingAbstractTest extends GridCommonAb
assertEquals(entriesCnt, cacheInMem1.localSize(peekAll));
for (int i = 0; i < entriesCnt; i++) {
- TestValue value = new TestValue(i, i * 2, i * 3);
+ TestValue val = new TestValue(i, i * 2, i * 3);
- assertEquals(value, cachePds1.localPeek(i, peekAll));
- assertEquals(value, cacheInMem1.localPeek(i, peekAll));
+ assertEquals(val, cachePds1.localPeek(i, peekAll));
+ assertEquals(val, cacheInMem1.localPeek(i, peekAll));
}
}
@@ -773,11 +773,11 @@ public abstract class IgnitePdsCacheRebalancingAbstractTest extends GridCommonAb
if (o == null || getClass() != o.getClass()) return false;
- TestValue testValue = (TestValue)o;
+ TestValue testVal = (TestValue)o;
- return order == testValue.order &&
- v1 == testValue.v1 &&
- v2 == testValue.v2;
+ return order == testVal.order &&
+ v1 == testVal.v1 &&
+ v2 == testVal.v2;
}
/** {@inheritDoc} */
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/IgniteLogicalRecoveryTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/IgniteLogicalRecoveryTest.java
index 20cd5dc67c3..33de3a09ece 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/IgniteLogicalRecoveryTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/IgniteLogicalRecoveryTest.java
@@ -649,10 +649,10 @@ public class IgniteLogicalRecoveryTest extends GridCommonAbstractTest {
if (o == null || getClass() != o.getClass())
return false;
- TestValue testValue = (TestValue)o;
+ TestValue testVal = (TestValue)o;
- return indexedField == testValue.indexedField &&
- Arrays.equals(payload, testValue.payload);
+ return indexedField == testVal.indexedField &&
+ Arrays.equals(payload, testVal.payload);
}
/** {@inheritDoc} */
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/IgnitePdsCacheWalDisabledOnRebalancingTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/IgnitePdsCacheWalDisabledOnRebalancingTest.java
index b5afddf5d67..1ac9d70e70d 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/IgnitePdsCacheWalDisabledOnRebalancingTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/IgnitePdsCacheWalDisabledOnRebalancingTest.java
@@ -515,9 +515,9 @@ public class IgnitePdsCacheWalDisabledOnRebalancingTest extends GridCommonAbstra
String cacheName = cache.getName();
for (int i = 0; i < size; i++) {
- String value = (String)cache.get(i);
+ String val = (String)cache.get(i);
- assertEquals(generatingFunc.apply(cacheName, i), value);
+ assertEquals(generatingFunc.apply(cacheName, i), val);
}
}
}
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/file/IgnitePdsThreadInterruptionTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/file/IgnitePdsThreadInterruptionTest.java
index 57548f62be0..12a3c842664 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/file/IgnitePdsThreadInterruptionTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/file/IgnitePdsThreadInterruptionTest.java
@@ -116,14 +116,14 @@ public class IgnitePdsThreadInterruptionTest extends GridCommonAbstractTest {
int keyCnt = 10_000;
- byte[] value = new byte[8_192];
+ byte[] val = new byte[8_192];
// Load data.
try (IgniteDataStreamer<Integer, byte[]> st = ignite.dataStreamer(DEFAULT_CACHE_NAME)) {
st.allowOverwrite(true);
for (int i = 0; i < keyCnt; i++)
- st.addData(i, value);
+ st.addData(i, val);
}
IgniteCache<Integer, byte[]> cache = ignite.cache(DEFAULT_CACHE_NAME);
@@ -170,7 +170,7 @@ public class IgnitePdsThreadInterruptionTest extends GridCommonAbstractTest {
assertThat(readThreadsError, empty());
for (int i = 0; i < keyCnt; i++)
- assertArrayEquals(String.valueOf(i), cache.get(i), value);
+ assertArrayEquals(String.valueOf(i), cache.get(i), val);
}
/**
@@ -192,7 +192,7 @@ public class IgnitePdsThreadInterruptionTest extends GridCommonAbstractTest {
AtomicBoolean stop = new AtomicBoolean();
- byte[] value = new byte[8_192];
+ byte[] val = new byte[8_192];
Thread[] workers = new Thread[THREADS_CNT];
@@ -202,7 +202,7 @@ public class IgnitePdsThreadInterruptionTest extends GridCommonAbstractTest {
while (!stop.get()) {
int key = ThreadLocalRandom.current().nextInt(100_000);
- cache.put(key, value);
+ cache.put(key, val);
keysToCheck.add(key);
}
@@ -235,6 +235,6 @@ public class IgnitePdsThreadInterruptionTest extends GridCommonAbstractTest {
// Post check.
for (Integer key: keysToCheck)
- assertArrayEquals(String.valueOf(key), value, cache.get(key));
+ assertArrayEquals(String.valueOf(key), val, cache.get(key));
}
}
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/query/IgniteCacheQueryCacheDestroySelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/query/IgniteCacheQueryCacheDestroySelfTest.java
index c7590e54696..6f14bfbff80 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/query/IgniteCacheQueryCacheDestroySelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/query/IgniteCacheQueryCacheDestroySelfTest.java
@@ -119,9 +119,9 @@ public class IgniteCacheQueryCacheDestroySelfTest extends GridCommonAbstractTest
try (QueryCursor cursor = example.query(scanQry)) {
for (Object p : cursor) {
- String value = (String)((Cache.Entry)p).getValue();
+ String val = (String)((Cache.Entry)p).getValue();
- assertNotNull(value);
+ assertNotNull(val);
}
}
}
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/metastorage/DistributedMetaStorageTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/metastorage/DistributedMetaStorageTest.java
index 63110f68c89..49f576ef603 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/metastorage/DistributedMetaStorageTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/metastorage/DistributedMetaStorageTest.java
@@ -166,7 +166,7 @@ public class DistributedMetaStorageTest extends GridCommonAbstractTest {
String clientName = "client0";
String key = "key";
- String value = "value";
+ String val = "value";
GridTestUtils.runAsync(() -> startClientGrid(clientName));
@@ -193,7 +193,7 @@ public class DistributedMetaStorageTest extends GridCommonAbstractTest {
GridTestUtils.assertThrows(null, new Callable<Object>() {
@Override public Object call() throws Exception {
- clDms.write(key, value);
+ clDms.write(key, val);
return null;
}
diff --git a/modules/core/src/test/java/org/apache/ignite/platform/PlatformCacheEntryEventFilter.java b/modules/core/src/test/java/org/apache/ignite/platform/PlatformCacheEntryEventFilter.java
index 17d564af549..8740802ece8 100644
--- a/modules/core/src/test/java/org/apache/ignite/platform/PlatformCacheEntryEventFilter.java
+++ b/modules/core/src/test/java/org/apache/ignite/platform/PlatformCacheEntryEventFilter.java
@@ -180,13 +180,13 @@ public class PlatformCacheEntryEventFilter implements CacheEntryEventSerializabl
assert Integer.valueOf(1).equals(((BinaryObject)objArr[0]).field("Int"));
assert "2".equals(((BinaryObject)objArr[0]).field("String"));
- Object value = event.getValue();
+ Object val = event.getValue();
- if (value instanceof String)
- return ((String)value).startsWith(startsWith);
+ if (val instanceof String)
+ return ((String)val).startsWith(startsWith);
- assert value instanceof BinaryObject;
+ assert val instanceof BinaryObject;
- return ((String)((BinaryObject)value).field("String")).startsWith(startsWith);
+ return ((String)((BinaryObject)val).field("String")).startsWith(startsWith);
}
}
diff --git a/modules/core/src/test/java/org/apache/ignite/platform/PlatformCacheEntryEventFilterCpp.java b/modules/core/src/test/java/org/apache/ignite/platform/PlatformCacheEntryEventFilterCpp.java
index dc78d3575ed..4bfa63c8d84 100644
--- a/modules/core/src/test/java/org/apache/ignite/platform/PlatformCacheEntryEventFilterCpp.java
+++ b/modules/core/src/test/java/org/apache/ignite/platform/PlatformCacheEntryEventFilterCpp.java
@@ -110,13 +110,13 @@ public class PlatformCacheEntryEventFilterCpp implements CacheEntryEventSerializ
assert Integer.valueOf(1).equals(objField.field("i32Field"));
assert "2".equals(objField.field("strField"));
- Object value = event.getValue();
+ Object val = event.getValue();
- if (value instanceof String)
- return ((String)value).startsWith(startsWith);
+ if (val instanceof String)
+ return ((String)val).startsWith(startsWith);
- assert value instanceof BinaryObject;
+ assert val instanceof BinaryObject;
- return ((String)((BinaryObject)value).field("String")).startsWith(startsWith);
+ return ((String)((BinaryObject)val).field("String")).startsWith(startsWith);
}
}
diff --git a/modules/core/src/test/java/org/apache/ignite/platform/PlatformCacheEntryEventFilterFactory.java b/modules/core/src/test/java/org/apache/ignite/platform/PlatformCacheEntryEventFilterFactory.java
index 9711d8003b6..64d94c644c7 100644
--- a/modules/core/src/test/java/org/apache/ignite/platform/PlatformCacheEntryEventFilterFactory.java
+++ b/modules/core/src/test/java/org/apache/ignite/platform/PlatformCacheEntryEventFilterFactory.java
@@ -43,14 +43,14 @@ public class PlatformCacheEntryEventFilterFactory implements Serializable,
return new CacheEntryEventSerializableFilter() {
@Override public boolean evaluate(CacheEntryEvent event) throws CacheEntryListenerException {
- Object value = event.getValue();
+ Object val = event.getValue();
- if (value instanceof String)
- return ((String)value).startsWith(startsWith);
+ if (val instanceof String)
+ return ((String)val).startsWith(startsWith);
- assert value instanceof BinaryObject;
+ assert val instanceof BinaryObject;
- return ((String)((BinaryObject)value).field("String")).startsWith(startsWith);
+ return ((String)((BinaryObject)val).field("String")).startsWith(startsWith);
}
};
}
diff --git a/modules/core/src/test/java/org/apache/ignite/platform/PlatformProcessUtils.java b/modules/core/src/test/java/org/apache/ignite/platform/PlatformProcessUtils.java
index b25ca06e440..375ccda076e 100644
--- a/modules/core/src/test/java/org/apache/ignite/platform/PlatformProcessUtils.java
+++ b/modules/core/src/test/java/org/apache/ignite/platform/PlatformProcessUtils.java
@@ -104,12 +104,12 @@ public class PlatformProcessUtils {
}
if (!process.isAlive()) {
- int exitValue = process.exitValue();
+ int exitVal = process.exitValue();
process = null;
String logStr = String.join(System.lineSeparator(), log);
- throw new Exception("Process has exited unexpectedly (" + exitValue + "): " + logStr);
+ throw new Exception("Process has exited unexpectedly (" + exitVal + "): " + logStr);
}
}
diff --git a/modules/core/src/test/java/org/apache/ignite/platform/model/Value.java b/modules/core/src/test/java/org/apache/ignite/platform/model/Value.java
index 7143bff97cc..0cd96f5f5f2 100644
--- a/modules/core/src/test/java/org/apache/ignite/platform/model/Value.java
+++ b/modules/core/src/test/java/org/apache/ignite/platform/model/Value.java
@@ -40,8 +40,8 @@ public class Value {
return true;
if (o == null || getClass() != o.getClass())
return false;
- Value value = (Value)o;
- return Objects.equals(val, value.val);
+ Value val = (Value)o;
+ return Objects.equals(this.val, val.val);
}
/** {@inheritDoc} */
diff --git a/modules/core/src/test/java/org/apache/ignite/stream/socket/SocketStreamerSelfTest.java b/modules/core/src/test/java/org/apache/ignite/stream/socket/SocketStreamerSelfTest.java
index 220571e4d05..75ead89642f 100644
--- a/modules/core/src/test/java/org/apache/ignite/stream/socket/SocketStreamerSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/stream/socket/SocketStreamerSelfTest.java
@@ -294,8 +294,8 @@ public class SocketStreamerSelfTest extends GridCommonAbstractTest {
sockStmr.setMultipleTupleExtractor(new StreamMultipleTupleExtractor<Message, Integer, String>() {
@Override public Map<Integer, String> extract(Message msg) {
Map<Integer, String> answer = new HashMap<>();
- for (int value : msg.values) {
- answer.put(value, Integer.toString(value));
+ for (int val : msg.values) {
+ answer.put(val, Integer.toString(val));
}
return answer;
}
diff --git a/modules/core/src/test/java/org/apache/ignite/testframework/wal/record/RecordUtils.java b/modules/core/src/test/java/org/apache/ignite/testframework/wal/record/RecordUtils.java
index 00c88ebc06f..92d2a2a41a3 100644
--- a/modules/core/src/test/java/org/apache/ignite/testframework/wal/record/RecordUtils.java
+++ b/modules/core/src/test/java/org/apache/ignite/testframework/wal/record/RecordUtils.java
@@ -533,9 +533,9 @@ public class RecordUtils {
/** **/
public static MetastoreDataRecord buildMetastoreDataRecord() {
- byte[] value = {1, 3, 5};
+ byte[] val = {1, 3, 5};
- return new MetastoreDataRecord("key", value);
+ return new MetastoreDataRecord("key", val);
}
/** **/
diff --git a/modules/dev-utils/src/main/java/org/apache/ignite/development/utils/DataEntryWrapper.java b/modules/dev-utils/src/main/java/org/apache/ignite/development/utils/DataEntryWrapper.java
index dfdc26ba40b..d63c198e392 100644
--- a/modules/dev-utils/src/main/java/org/apache/ignite/development/utils/DataEntryWrapper.java
+++ b/modules/dev-utils/src/main/java/org/apache/ignite/development/utils/DataEntryWrapper.java
@@ -77,28 +77,28 @@ class DataEntryWrapper extends DataEntry {
/** {@inheritDoc} */
@Override public String toString() {
final String keyStr;
- final String valueStr;
+ final String valStr;
if (source instanceof UnwrapDataEntry) {
final UnwrapDataEntry unwrappedDataEntry = (UnwrapDataEntry)this.source;
keyStr = toString(unwrappedDataEntry.unwrappedKey(), this.source.key());
- valueStr = toString(unwrappedDataEntry.unwrappedValue(), this.source.value());
+ valStr = toString(unwrappedDataEntry.unwrappedValue(), this.source.value());
}
else if (source instanceof RecordDataV1Serializer.EncryptedDataEntry) {
keyStr = "<encrypted>";
- valueStr = "<encrypted>";
+ valStr = "<encrypted>";
}
else {
keyStr = toString(null, this.source.key());
- valueStr = toString(null, this.source.value());
+ valStr = toString(null, this.source.value());
}
return new SB(this.source.getClass().getSimpleName())
.a("[k = ").a(keyStr)
- .a(", v = [").a(valueStr).a("]")
+ .a(", v = [").a(valStr).a("]")
.a(", super = [").a(S.toString(DataEntry.class, source)).a("]]")
.toString();
}
diff --git a/modules/dev-utils/src/test/java/org/apache/ignite/development/utils/IgniteWalConverterSensitiveDataTest.java b/modules/dev-utils/src/test/java/org/apache/ignite/development/utils/IgniteWalConverterSensitiveDataTest.java
index 75ed5432fa6..866b5087e9b 100644
--- a/modules/dev-utils/src/test/java/org/apache/ignite/development/utils/IgniteWalConverterSensitiveDataTest.java
+++ b/modules/dev-utils/src/test/java/org/apache/ignite/development/utils/IgniteWalConverterSensitiveDataTest.java
@@ -258,11 +258,11 @@ public class IgniteWalConverterSensitiveDataTest extends GridCommonAbstractTest
else
assertNotContains(log, testOutStr, SENSITIVE_DATA_VALUE_PREFIX);
- for (String sensitiveDataValue : sensitiveValues) {
+ for (String sensitiveDataVal : sensitiveValues) {
if (containsData)
- assertContains(log, testOutStr, converter.apply(sensitiveDataValue));
+ assertContains(log, testOutStr, converter.apply(sensitiveDataVal));
else
- assertNotContains(log, testOutStr, converter.apply(sensitiveDataValue));
+ assertNotContains(log, testOutStr, converter.apply(sensitiveDataVal));
}
}
diff --git a/modules/dev-utils/src/test/java/org/apache/ignite/development/utils/IgniteWalConverterTest.java b/modules/dev-utils/src/test/java/org/apache/ignite/development/utils/IgniteWalConverterTest.java
index dd38c76bf61..be7e8e47bcb 100644
--- a/modules/dev-utils/src/test/java/org/apache/ignite/development/utils/IgniteWalConverterTest.java
+++ b/modules/dev-utils/src/test/java/org/apache/ignite/development/utils/IgniteWalConverterTest.java
@@ -265,9 +265,9 @@ public class IgniteWalConverterTest extends GridCommonAbstractTest {
idx = result.indexOf("]", start);
if (idx > 0) {
- final String value = result.substring(start, idx);
+ final String val = result.substring(start, idx);
- find = new String(Base64.getDecoder().decode(value)).contains(person.getName());
+ find = new String(Base64.getDecoder().decode(val)).contains(person.getName());
}
}
}
@@ -586,16 +586,16 @@ public class IgniteWalConverterTest extends GridCommonAbstractTest {
for (int i = 0; i < 10; i++) {
final PersonKey key = new PersonKey(i);
- final Person value;
+ final Person val;
if (i % 2 == 0)
- value = new Person(i, PERSON_NAME_PREFIX + i);
+ val = new Person(i, PERSON_NAME_PREFIX + i);
else
- value = new PersonEx(i, PERSON_NAME_PREFIX + i, "Additional information " + i, "Description " + i);
+ val = new PersonEx(i, PERSON_NAME_PREFIX + i, "Additional information " + i, "Description " + i);
- cache.put(key, value);
+ cache.put(key, val);
- list.add(value);
+ list.add(val);
}
if (afterPopulateConsumer != null)
diff --git a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/opt/GridH2IndexBase.java b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/opt/GridH2IndexBase.java
index 6cbd7ae325e..18213d0ae9d 100644
--- a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/opt/GridH2IndexBase.java
+++ b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/opt/GridH2IndexBase.java
@@ -182,11 +182,11 @@ public abstract class GridH2IndexBase extends H2IndexCostedBase {
CacheObject key;
- final Value keyColValue = row.getValue(QueryUtils.KEY_COL);
+ final Value keyColVal = row.getValue(QueryUtils.KEY_COL);
- assert keyColValue != null;
+ assert keyColVal != null;
- final Object o = keyColValue.getObject();
+ final Object o = keyColVal.getObject();
if (o instanceof CacheObject)
key = (CacheObject)o;
diff --git a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/opt/H2IndexCostedBase.java b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/opt/H2IndexCostedBase.java
index 0792fa1e878..1b2d5e5749c 100644
--- a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/opt/H2IndexCostedBase.java
+++ b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/opt/H2IndexCostedBase.java
@@ -131,8 +131,8 @@ public abstract class H2IndexCostedBase extends BaseIndex {
break;
}
// Estimate by is null
- Value equalValue = getEqualValue(ses, column, filter);
- Boolean equalNull = (equalValue == null) ? null : equalValue.getType() == Value.NULL;
+ Value equalVal = getEqualValue(ses, column, filter);
+ Boolean equalNull = (equalVal == null) ? null : equalVal.getType() == Value.NULL;
rowCount = getColumnSize(colStats, rowCount, equalNull);
if (colStats != null && equalNull == Boolean.TRUE) {
@@ -223,7 +223,7 @@ public abstract class H2IndexCostedBase extends BaseIndex {
* @return "Equal" value or {@code null} if there are no equal clause with constant expression.
*/
private Value getEqualValue(Session ses, Column column, TableFilter filter) {
- Value maxValue = null;
+ Value maxVal = null;
for (IndexCondition cond : filter.getIndexConditions()) {
if (!column.equals(cond.getColumn()))
continue;
@@ -233,12 +233,12 @@ public abstract class H2IndexCostedBase extends BaseIndex {
Expression expr = cond.getExpression();
if (expr != null && expr.isConstant()) {
Value curVal = cond.getCurrentValue(ses);
- if (null == maxValue || (curVal != null || filter.getTable().compareTypeSafe(curVal, maxValue) < 0))
- maxValue = curVal;
+ if (null == maxVal || (curVal != null || filter.getTable().compareTypeSafe(curVal, maxVal) < 0))
+ maxVal = curVal;
}
}
}
- return maxValue;
+ return maxVal;
}
/**
@@ -252,7 +252,7 @@ public abstract class H2IndexCostedBase extends BaseIndex {
private Value getStartValue(Session ses, Column column, TableFilter filter) {
if (filter == null)
return null;
- Value maxValue = null;
+ Value maxVal = null;
for (IndexCondition cond : filter.getIndexConditions()) {
if (!column.equals(cond.getColumn()))
continue;
@@ -264,12 +264,12 @@ public abstract class H2IndexCostedBase extends BaseIndex {
Expression expr = cond.getExpression();
if (expr != null && expr.isConstant()) {
Value curVal = cond.getCurrentValue(ses);
- if (null == maxValue || (curVal != null || filter.getTable().compareTypeSafe(curVal, maxValue) < 0))
- maxValue = curVal;
+ if (null == maxVal || (curVal != null || filter.getTable().compareTypeSafe(curVal, maxVal) < 0))
+ maxVal = curVal;
}
}
}
- return maxValue;
+ return maxVal;
}
/**
@@ -283,7 +283,7 @@ public abstract class H2IndexCostedBase extends BaseIndex {
private Value getEndValue(Session ses, Column column, TableFilter filter) {
if (filter == null)
return null;
- Value minValue = null;
+ Value minVal = null;
for (IndexCondition cond : filter.getIndexConditions()) {
if (!column.equals(cond.getColumn()))
continue;
@@ -294,12 +294,12 @@ public abstract class H2IndexCostedBase extends BaseIndex {
Expression expr = cond.getExpression();
if (expr != null && expr.isConstant()) {
Value curVal = cond.getCurrentValue(ses);
- if (null == minValue || (curVal != null || filter.getTable().compareTypeSafe(minValue, curVal) < 0))
- minValue = curVal;
+ if (null == minVal || (curVal != null || filter.getTable().compareTypeSafe(minVal, curVal) < 0))
+ minVal = curVal;
}
}
}
- return minValue;
+ return minVal;
}
/**
@@ -368,10 +368,10 @@ public abstract class H2IndexCostedBase extends BaseIndex {
// Fall back to previous behaviour without statistics, even without min/max testing
return estimatePercentFallback(min, max);
- BigDecimal minValue = (min == null) ? null : getComparableValue(min);
- BigDecimal maxValue = (max == null) ? null : getComparableValue(max);
+ BigDecimal minVal = (min == null) ? null : getComparableValue(min);
+ BigDecimal maxVal = (max == null) ? null : getComparableValue(max);
- if (minValue == null && maxValue == null)
+ if (minVal == null && maxVal == null)
return estimatePercentFallback(min, max);
BigDecimal minStat = colStat.min();
@@ -380,8 +380,8 @@ public abstract class H2IndexCostedBase extends BaseIndex {
if (minStat == null || maxStat == null)
return estimatePercentFallback(min, max);
- BigDecimal start = (minValue == null || minValue.compareTo(minStat) < 0) ? minStat : minValue;
- BigDecimal end = (maxValue == null || maxValue.compareTo(maxStat) > 0) ? maxStat : maxValue;
+ BigDecimal start = (minVal == null || minVal.compareTo(minStat) < 0) ? minStat : minVal;
+ BigDecimal end = (maxVal == null || maxVal.compareTo(maxStat) > 0) ? maxStat : maxVal;
BigDecimal actual = end.subtract(start);
diff --git a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/H2DynamicTableSelfTest.java b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/H2DynamicTableSelfTest.java
index c0a877807da..f05807e43ff 100644
--- a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/H2DynamicTableSelfTest.java
+++ b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/H2DynamicTableSelfTest.java
@@ -1981,9 +1981,9 @@ public class H2DynamicTableSelfTest extends AbstractSchemaSelfTest {
if (o == null || getClass() != o.getClass())
return false;
- TestValue testValue = (TestValue)o;
+ TestValue testVal = (TestValue)o;
- return notUniqueId == testValue.notUniqueId;
+ return notUniqueId == testVal.notUniqueId;
}
/** {@inheritDoc} */
diff --git a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/IndexCorruptionRebuildTest.java b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/IndexCorruptionRebuildTest.java
index bc8ea9a8878..fb5cfccbaf3 100644
--- a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/IndexCorruptionRebuildTest.java
+++ b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/index/IndexCorruptionRebuildTest.java
@@ -163,14 +163,14 @@ public class IndexCorruptionRebuildTest extends GridCommonAbstractTest {
for (int i = 0; i < 100; i++) {
int counter = i;
- String value = "test" + i;
+ String val = "test" + i;
String insertQry = "insert into %s(col1, col2, col3, col4) values (?1, ?2, ?3, ?4)";
Stream.of(TABLE_NAME_1, TABLE_NAME_2)
.map(tableName ->
new SqlFieldsQuery(String.format(insertQry, tableName))
- .setArgs(String.valueOf(counter), value, value, value)
+ .setArgs(String.valueOf(counter), val, val, val)
).forEach(cache::query);
}
diff --git a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/wal/IgniteWalRecoveryTest.java b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/wal/IgniteWalRecoveryTest.java
index c588ca1889b..9494be9f7a5 100644
--- a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/wal/IgniteWalRecoveryTest.java
+++ b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/wal/IgniteWalRecoveryTest.java
@@ -1284,9 +1284,9 @@ public class IgniteWalRecoveryTest extends GridCommonAbstractTest {
}
for (int i = 0; i < cnt; i++) {
- byte[] value = storage.readRaw(String.valueOf(i));
- assert value != null;
- assert value.length == 3;
+ byte[] val = storage.readRaw(String.valueOf(i));
+ assert val != null;
+ assert val.length == 3;
}
stopGrid(0);
@@ -1302,8 +1302,8 @@ public class IgniteWalRecoveryTest extends GridCommonAbstractTest {
assert storage != null;
for (int i = 0; i < cnt; i++) {
- byte[] value = storage.readRaw(String.valueOf(i));
- assert value != null;
+ byte[] val = storage.readRaw(String.valueOf(i));
+ assert val != null;
}
}
@@ -1582,11 +1582,11 @@ public class IgniteWalRecoveryTest extends GridCommonAbstractTest {
for (int op = 0; op < operationsPerTransaction; op++) {
int key = random.nextInt(1000) + 1;
- Object value = random.nextBoolean() ? randomString(random) + key : new BigObject(key);
+ Object val = random.nextBoolean() ? randomString(random) + key : new BigObject(key);
- changesInTransaction.put(key, value);
+ changesInTransaction.put(key, val);
- cache.put(key, value);
+ cache.put(key, val);
}
if (random.nextBoolean()) {
@@ -1609,9 +1609,9 @@ public class IgniteWalRecoveryTest extends GridCommonAbstractTest {
cache = ignite.cache(cacheName);
for (Object key : map.keySet()) {
- Object expectedValue = map.get(key);
- Object actualValue = cache.get(key);
- Assert.assertEquals("Unexpected value for key " + key, expectedValue, actualValue);
+ Object expectedVal = map.get(key);
+ Object actualVal = cache.get(key);
+ Assert.assertEquals("Unexpected value for key " + key, expectedVal, actualVal);
}
}
@@ -1661,9 +1661,9 @@ public class IgniteWalRecoveryTest extends GridCommonAbstractTest {
for (int op = 0; op < operationsPerTransaction; op++) {
int key = random.nextInt(1000) + 1;
- Object value = random.nextBoolean() ? randomString(random) + key : new BigObject(key);
+ Object val = random.nextBoolean() ? randomString(random) + key : new BigObject(key);
- cache.put(key, value);
+ cache.put(key, val);
}
if (random.nextBoolean())
diff --git a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/IgniteSqlCreateTableTemplateTest.java b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/IgniteSqlCreateTableTemplateTest.java
index aad067160d4..6f8ef9920d5 100644
--- a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/IgniteSqlCreateTableTemplateTest.java
+++ b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/IgniteSqlCreateTableTemplateTest.java
@@ -76,21 +76,21 @@ public class IgniteSqlCreateTableTemplateTest extends AbstractIndexingCommonTest
keyBuilder.setField("ID", 1);
keyBuilder.setField("AFF_PERSON", 2);
- BinaryObjectBuilder valueBuilder = ignite.binary().builder("PERSON_VALUE");
- valueBuilder.setField("NAME", "test");
+ BinaryObjectBuilder valBuilder = ignite.binary().builder("PERSON_VALUE");
+ valBuilder.setField("NAME", "test");
- ignite.cache("PERSON_CACHE").withKeepBinary().put(keyBuilder.build(), valueBuilder.build());
+ ignite.cache("PERSON_CACHE").withKeepBinary().put(keyBuilder.build(), valBuilder.build());
keyBuilder = ignite.binary().builder("ORGANIZATION_KEY");
keyBuilder.setField("ID", 1);
keyBuilder.setField("AFF_ORGANIZATION", 2);
- valueBuilder = ignite.binary().builder("ORGANIZATION_VALUE");
+ valBuilder = ignite.binary().builder("ORGANIZATION_VALUE");
- valueBuilder.setField("NAME", "test");
+ valBuilder.setField("NAME", "test");
- ignite.cache("ORGANIZATION_CACHE").withKeepBinary().put(keyBuilder.build(), valueBuilder.build());
+ ignite.cache("ORGANIZATION_CACHE").withKeepBinary().put(keyBuilder.build(), valBuilder.build());
assertEquals(1, ignite.cache("PERSON_CACHE").query(
new SqlFieldsQuery("Select NAME from PERSON where ID = 1")).getAll().size()
diff --git a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/IgniteSqlSplitterSelfTest.java b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/IgniteSqlSplitterSelfTest.java
index 6e5cbbab8dc..3c1262d4ea6 100644
--- a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/IgniteSqlSplitterSelfTest.java
+++ b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/IgniteSqlSplitterSelfTest.java
@@ -2023,10 +2023,10 @@ public class IgniteSqlSplitterSelfTest extends AbstractIndexingCommonTest {
ignite(0).getOrCreateCache(cacheConfig(cacheName, true, Integer.class, AvgDataTypes.class));
// avg 13.125; int avg 13
- double value[] = new double[] {1, 5, 7, 8, 10.5, 13.5, 20, 40};
+ double val[] = new double[] {1, 5, 7, 8, 10.5, 13.5, 20, 40};
- for (int i = 0; i < value.length; i++) {
- Number v = value[i];
+ for (int i = 0; i < val.length; i++) {
+ Number v = val[i];
cache.put(i, new AvgDataTypes(
v.byteValue(),
diff --git a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/stat/StatisticsStorageRestartTest.java b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/stat/StatisticsStorageRestartTest.java
index 178aa42fdea..1cecc59ac94 100644
--- a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/stat/StatisticsStorageRestartTest.java
+++ b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/stat/StatisticsStorageRestartTest.java
@@ -125,8 +125,8 @@ public class StatisticsStorageRestartTest extends StatisticsAbstractTest {
metastorage.write(statKeyInvalid, new byte[2]);
String outerStatKey = "some.key.1";
- byte[] outerStatValue = new byte[] {1, 2};
- metastorage.write(outerStatKey, outerStatValue);
+ byte[] outerStatVal = new byte[] {1, 2};
+ metastorage.write(outerStatKey, outerStatVal);
IgniteStatisticsPersistenceStoreImpl statStore2 = new IgniteStatisticsPersistenceStoreImpl(subscriptionProcessor,
new IgniteCacheDatabaseSharedManager(new GridTestKernalContext(log)){}, cls -> log);
@@ -136,6 +136,6 @@ public class StatisticsStorageRestartTest extends StatisticsAbstractTest {
assertNull(metastorage.read(statKeyInvalid));
assertTrue(statStore.getLocalPartitionsStatistics(k1).isEmpty());
assertFalse(statStore.getLocalPartitionsStatistics(k2).isEmpty());
- assertTrue(Arrays.equals(outerStatValue, (byte[])metastorage.read(outerStatKey)));
+ assertTrue(Arrays.equals(outerStatVal, (byte[])metastorage.read(outerStatKey)));
}
}
diff --git a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/stat/hll/FullHLLTest.java b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/stat/hll/FullHLLTest.java
index e31c9b389f8..4ba3add32ae 100644
--- a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/stat/hll/FullHLLTest.java
+++ b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/stat/hll/FullHLLTest.java
@@ -98,14 +98,14 @@ public class FullHLLTest {
// all registers at 'medium' value
{
- final int registerValue = 7/*chosen to ensure neither correction kicks in*/;
+ final int registerVal = 7/*chosen to ensure neither correction kicks in*/;
for (int i = 0; i < m; i++)
- hll.addRaw(ProbabilisticTestUtil.constructHLLValue(log2m, i, registerValue));
+ hll.addRaw(ProbabilisticTestUtil.constructHLLValue(log2m, i, registerVal));
final long cardinality = hll.cardinality();
// Simplified estimator when all registers take same value: alpha / (m/2^val)
- final double estimator = HLLUtil.alphaMSquared(m) / ((double)m / Math.pow(2, registerValue));
+ final double estimator = HLLUtil.alphaMSquared(m) / ((double)m / Math.pow(2, registerVal));
// Assert conditions for uncorrected range
assertTrue(estimator <= Math.pow(2, l) / 30);
@@ -132,14 +132,14 @@ public class FullHLLTest {
256/*sparseThreshold, arbitrary, unused*/, HLLType.FULL);
{
- final int registerValue = 31/*chosen to ensure large correction kicks in*/;
+ final int registerVal = 31/*chosen to ensure large correction kicks in*/;
for (int i = 0; i < m; i++)
- hll.addRaw(ProbabilisticTestUtil.constructHLLValue(log2m, i, registerValue));
+ hll.addRaw(ProbabilisticTestUtil.constructHLLValue(log2m, i, registerVal));
final long cardinality = hll.cardinality();
// Simplified estimator when all registers take same value: alpha / (m/2^val)
- final double estimator = HLLUtil.alphaMSquared(m) / ((double)m / Math.pow(2, registerValue));
+ final double estimator = HLLUtil.alphaMSquared(m) / ((double)m / Math.pow(2, registerVal));
// Assert conditions for large range
@@ -306,8 +306,8 @@ public class FullHLLTest {
256/*sparseThreshold, arbitrary, unused*/, HLLType.FULL);
for (int i = 0; i < 3; i++) {
- final long rawValue = ProbabilisticTestUtil.constructHLLValue(log2m, i, (i + 9));
- hll.addRaw(rawValue);
+ final long rawVal = ProbabilisticTestUtil.constructHLLValue(log2m, i, (i + 9));
+ hll.addRaw(rawVal);
}
final byte[] bytes = hll.toBytes(schemaVer);
@@ -326,8 +326,8 @@ public class FullHLLTest {
256/*sparseThreshold, arbitrary, unused*/, HLLType.FULL);
for (int i = 0; i < (1 << log2m)/*aka 2^log2m*/; i++) {
- final long rawValue = ProbabilisticTestUtil.constructHLLValue(log2m, i, (i % 9) + 1);
- hll.addRaw(rawValue);
+ final long rawVal = ProbabilisticTestUtil.constructHLLValue(log2m, i, (i % 9) + 1);
+ hll.addRaw(rawVal);
}
final byte[] bytes = hll.toBytes(schemaVer);
diff --git a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/stat/hll/ProbabilisticTestUtil.java b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/stat/hll/ProbabilisticTestUtil.java
index fb32acf5c4e..f94fef25ce6 100644
--- a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/stat/hll/ProbabilisticTestUtil.java
+++ b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/stat/hll/ProbabilisticTestUtil.java
@@ -37,8 +37,8 @@ public class ProbabilisticTestUtil {
*/
public static long constructHLLValue(final int log2m, final int registerIndex, final int registerValue) {
final long partition = registerIndex;
- final long substreamValue = (1L << (registerValue - 1));
- return (substreamValue << log2m) | partition;
+ final long substreamVal = (1L << (registerValue - 1));
+ return (substreamVal << log2m) | partition;
}
/**
@@ -54,10 +54,10 @@ public class ProbabilisticTestUtil {
* Extracts the HLL register value from a raw value.
*/
public static byte getRegisterValue(final long rawValue, final int log2m) {
- final long substreamValue = (rawValue >>> log2m);
+ final long substreamVal = (rawValue >>> log2m);
final byte p_w;
- if (substreamValue == 0L) {
+ if (substreamVal == 0L) {
// The paper does not cover p(0x0), so the special value 0 is used.
// 0 is the original initialization value of the registers, so by
// doing this the HLL simply ignores it. This is acceptable
@@ -65,7 +65,7 @@ public class ProbabilisticTestUtil {
p_w = 0;
}
else
- p_w = (byte)Math.min(1 + BitUtil.leastSignificantBit(substreamValue), 31);
+ p_w = (byte)Math.min(1 + BitUtil.leastSignificantBit(substreamVal), 31);
return p_w;
}
diff --git a/modules/opencensus/src/test/java/org/apache/ignite/internal/processors/monitoring/opencensus/OpenCensusMetricExporterSpiTest.java b/modules/opencensus/src/test/java/org/apache/ignite/internal/processors/monitoring/opencensus/OpenCensusMetricExporterSpiTest.java
index 3f4df06d797..5b042b944a8 100644
--- a/modules/opencensus/src/test/java/org/apache/ignite/internal/processors/monitoring/opencensus/OpenCensusMetricExporterSpiTest.java
+++ b/modules/opencensus/src/test/java/org/apache/ignite/internal/processors/monitoring/opencensus/OpenCensusMetricExporterSpiTest.java
@@ -153,8 +153,8 @@ public class OpenCensusMetricExporterSpiTest extends AbstractExporterSpiTest {
HistogramMetricImpl histogramMetric =
ignite.context().metric().registry(registryName).histogram(histogramName, bounds, histogramDesc);
- for (long value : testValues)
- histogramMetric.value(value);
+ for (long val : testValues)
+ histogramMetric.value(val);
assertTrue("Histogram metrics should be exported via http", checkHttpMetrics(expectedValuesPtrn));
@@ -162,8 +162,8 @@ public class OpenCensusMetricExporterSpiTest extends AbstractExporterSpiTest {
histogramMetric.reset(bounds);
- for (long value : testValues)
- histogramMetric.value(value);
+ for (long val : testValues)
+ histogramMetric.value(val);
expectedValuesPtrn = new String[] {
"test_registry_test_histogram_0_50.* 3",
diff --git a/modules/rest-http/src/main/java/org/apache/ignite/internal/processors/rest/protocols/http/jetty/GridJettyRestHandler.java b/modules/rest-http/src/main/java/org/apache/ignite/internal/processors/rest/protocols/http/jetty/GridJettyRestHandler.java
index 05874457e88..ba09e7ff04b 100644
--- a/modules/rest-http/src/main/java/org/apache/ignite/internal/processors/rest/protocols/http/jetty/GridJettyRestHandler.java
+++ b/modules/rest-http/src/main/java/org/apache/ignite/internal/processors/rest/protocols/http/jetty/GridJettyRestHandler.java
@@ -452,12 +452,12 @@ public class GridJettyRestHandler extends AbstractHandler {
throw new IllegalStateException("Received null result from handler: " + hnd);
if (getAllAsArray && cmd == GridRestCommand.CACHE_GET_ALL) {
- List<Object> resKeyValue = new ArrayList<>();
+ List<Object> resKeyVal = new ArrayList<>();
for (Map.Entry<Object, Object> me : ((Map<Object, Object>)cmdRes.getResponse()).entrySet())
- resKeyValue.add(new IgniteBiTuple<>(me.getKey(), me.getValue()));
+ resKeyVal.add(new IgniteBiTuple<>(me.getKey(), me.getValue()));
- cmdRes.setResponse(resKeyValue);
+ cmdRes.setResponse(resKeyVal);
}
byte[] sesTok = cmdRes.sessionTokenBytes();
diff --git a/modules/web/src/test/java/org/apache/ignite/internal/websession/WebSessionSelfTest.java b/modules/web/src/test/java/org/apache/ignite/internal/websession/WebSessionSelfTest.java
index 04ea7435645..0e4c1d48c66 100644
--- a/modules/web/src/test/java/org/apache/ignite/internal/websession/WebSessionSelfTest.java
+++ b/modules/web/src/test/java/org/apache/ignite/internal/websession/WebSessionSelfTest.java
@@ -1071,7 +1071,7 @@ public class WebSessionSelfTest extends GridCommonAbstractTest {
* @return sesId
*/
private String getSessionIdFromCookie(URLConnection conn) {
- String sesCookieValue = null;
+ String sesCookieVal = null;
String sesId = null;
Map<String, List<String>> hdrFields = conn.getHeaderFields();
Set<String> hdrFieldsSet = hdrFields.keySet();
@@ -1081,13 +1081,13 @@ public class WebSessionSelfTest extends GridCommonAbstractTest {
String hdrFieldKey = hdrFieldsIter.next();
if ("Set-Cookie".equalsIgnoreCase(hdrFieldKey)) {
- List<String> hdrFieldValue = hdrFields.get(hdrFieldKey);
+ List<String> hdrFieldVal = hdrFields.get(hdrFieldKey);
- for (String hdrValue : hdrFieldValue) {
- String[] fields = hdrValue.split(";");
- sesCookieValue = fields[0];
- sesId = sesCookieValue.substring(sesCookieValue.indexOf("=") + 1,
- sesCookieValue.length());
+ for (String hdrVal : hdrFieldVal) {
+ String[] fields = hdrVal.split(";");
+ sesCookieVal = fields[0];
+ sesId = sesCookieVal.substring(sesCookieVal.indexOf("=") + 1,
+ sesCookieVal.length());
}
}
}