From 4417f070576b9eb8d1c452ea1a38aff3e58a0529 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=81ukasz=20Osipiuk?= Date: Wed, 30 Oct 2024 13:34:45 +0100 Subject: [PATCH] Consistent empty braces formatting --- .../main/java/io/trino/cli/NullPrinter.java | 8 +-- .../auth/external/MemoryCachedKnownToken.java | 4 +- .../client/auth/external/MockTokenPoller.java | 4 +- .../jdbc/TestingRedirectHandlerInjector.java | 4 +- .../main/java/io/trino/TrinoMediaTypes.java | 4 +- .../java/io/trino/block/BlockSerdeUtil.java | 4 +- .../trino/execution/NoOpFailureInjector.java | 4 +- .../FixedSourcePartitionedScheduler.java | 4 +- .../scheduler/TaskLifecycleListener.java | 8 +-- .../DeduplicatingDirectExchangeBuffer.java | 4 +- .../io/trino/operator/DevNullOperator.java | 8 +-- .../io/trino/operator/FinishedOperator.java | 4 +- .../main/java/io/trino/operator/Operator.java | 4 +- .../io/trino/operator/PositionSearcher.java | 4 +- .../RefreshMaterializedViewOperator.java | 4 +- .../DoubleHistogramAggregation.java | 4 +- .../partial/SkipAggregationBuilder.java | 4 +- .../RegularTableFunctionPartition.java | 4 +- .../io/trino/operator/index/IndexLoader.java | 4 +- .../trino/operator/index/IndexSnapshot.java | 4 +- .../operator/index/PageBufferOperator.java | 4 +- .../trino/operator/index/PageRecordSet.java | 4 +- .../java/io/trino/operator/join/JoinHash.java | 4 +- .../join/PartitionedLookupSourceFactory.java | 4 +- .../operator/output/TaskOutputOperator.java | 4 +- .../trino/operator/scalar/JsonOperators.java | 4 +- .../json/execution/ExecutionPlanner.java | 4 +- .../json/execution/SequenceEvaluator.java | 4 +- .../main/java/io/trino/sql/gen/Bootstrap.java | 4 +- .../java/io/trino/sql/gen/LambdaCapture.java | 4 +- .../sql/planner/ExpressionExtractor.java | 4 +- .../io/trino/sql/planner/IrTypeAnalyzer.java | 4 +- .../sql/planner/iterative/rule/Util.java | 4 +- .../io/trino/testing/NullOutputOperator.java | 4 +- .../io/trino/type/ArrayParametricType.java | 4 +- .../java/io/trino/type/BooleanOperators.java | 4 +- .../java/io/trino/type/DateTimeOperators.java | 4 +- .../java/io/trino/type/DecimalOperators.java | 4 +- .../java/io/trino/type/DoubleOperators.java | 4 +- .../io/trino/type/FunctionParametricType.java | 4 +- .../java/io/trino/type/RealOperators.java | 4 +- .../java/io/trino/type/RowParametricType.java | 4 +- .../main/java/io/trino/type/TypeUtils.java | 4 +- .../type/setdigest/SetDigestFunctions.java | 4 +- .../trino/util/Long2LongOpenBigHashMap.java | 8 +-- .../LongLong2LongOpenCustomBigHashMap.java | 4 +- .../io/trino/util/PowerOfTwoValidator.java | 4 +- .../test/java/io/trino/SessionTestUtils.java | 4 +- .../buffer/BenchmarkDataGenerator.java | 4 +- .../TestSpoolingExchangeOutputBuffer.java | 4 +- .../executor/timesharing/SimulationSplit.java | 4 +- .../TestTimeSharingTaskExecutor.java | 4 +- .../TestSourcePartitionedScheduler.java | 4 +- .../io/trino/operator/OperatorAssertion.java | 4 +- .../operator/TestDirectExchangeClient.java | 12 ++--- .../operator/TestHashAggregationOperator.java | 4 +- .../operator/TestTableWriterOperator.java | 4 +- .../join/TestLookupJoinPageBuilder.java | 4 +- .../unspilled/TestLookupJoinPageBuilder.java | 4 +- .../operator/output/TestPagePartitioner.java | 32 +++--------- .../security/TestAccessControlManager.java | 4 +- .../server/security/TestResourceSecurity.java | 8 +-- ...seOAuth2WebUiAuthenticationFilterTest.java | 4 +- .../oauth2/TestJweTokenSerializer.java | 4 +- .../java/io/trino/server/ui/TestWebUi.java | 4 +- .../java/io/trino/split/MockSplitSource.java | 8 +-- .../io/trino/type/TestLongTimestampType.java | 4 +- .../java/io/trino/server/rpm/TestDummy.java | 4 +- .../java/io/trino/spi/block/BlockUtil.java | 4 +- .../java/io/trino/spi/block/EncoderUtil.java | 4 +- .../trino/spi/connector/FixedSplitSource.java | 4 +- .../io/trino/spi/connector/SchemaUtil.java | 4 +- .../spi/eventlistener/EventListener.java | 16 ++---- .../java/io/trino/spi/metrics/Metrics.java | 4 +- .../java/io/trino/spi/type/TypeUtils.java | 4 +- .../TestFuzzAlluxioCacheFileSystem.java | 4 +- .../filesystem/s3/S3FileSystemStats.java | 4 +- .../java/io/trino/hdfs/s3/MockAmazonS3.java | 4 +- .../trino/hdfs/s3/TestTrinoS3FileSystem.java | 4 +- .../main/java/io/trino/metastore/Storage.java | 4 +- .../orc/reader/SliceDirectColumnReader.java | 4 +- .../io/trino/orc/reader/UuidColumnReader.java | 4 +- .../io/trino/orc/TestingOrcPredicate.java | 4 +- .../trino/orc/stream/TestDecimalStream.java | 4 +- .../TupleDomainParquetPredicate.java | 4 +- .../reader/decoders/ByteBitUnpackers.java | 4 +- .../reader/decoders/IntBitUnpackers.java | 4 +- .../reader/decoders/LongBitUnpackers.java | 4 +- .../decoders/VectorIntBitUnpackers.java | 4 +- .../writer/repdef/DefLevelWriterProvider.java | 4 +- .../BenchmarkFlatDefinitionLevelDecoder.java | 4 +- .../io/trino/plugin/base/TemporaryTables.java | 4 +- .../AggregateFunctionPatterns.java | 4 +- .../authentication/KerberosTicketUtils.java | 4 +- .../base/security/FileBasedAccessControl.java | 8 +-- .../FileBasedSystemAccessControl.java | 4 +- .../base/security/ReadOnlyAccessControl.java | 16 ++---- .../security/ReadOnlySystemAccessControl.java | 52 +++++-------------- .../plugin/blackhole/BlackHoleMetadata.java | 4 +- .../cassandra/CassandraRecordCursor.java | 4 +- .../ClickHouseConnectionFactory.java | 12 ++--- .../TestClickHouseConnectorTest.java | 4 +- .../elasticsearch/CountQueryPageSource.java | 4 +- .../plugin/example/ExampleRecordCursor.java | 4 +- .../local/LocalFileSystemExchangeStorage.java | 4 +- .../hdfs/HadoopFileSystemExchangeStorage.java | 4 +- .../google/sheets/SheetsRecordCursor.java | 4 +- .../coercions/DoubleToVarcharCoercers.java | 4 +- .../VarcharToIntegralNumericCoercers.java | 4 +- .../security/SqlStandardAccessControl.java | 24 +++------ .../io/trino/plugin/hive/util/HiveUtil.java | 4 +- .../plugin/hive/util/HiveWriteUtils.java | 4 +- .../plugin/hive/TestHiveSplitSource.java | 8 +-- ...ransactionScopeCachingDirectoryLister.java | 8 +-- .../parquet/hadoop/DisabledMemoryManager.java | 8 +-- .../compaction/HudiCompactionOperation.java | 4 +- .../io/trino/plugin/hudi/files/FSUtils.java | 4 +- .../hudi/timeline/HudiActiveTimeline.java | 4 +- .../hudi/timeline/HudiDefaultTimeline.java | 4 +- .../plugin/eventlistener/kafka/TestUtils.java | 4 +- .../plugin/kudu/KuduConnectorFactory.java | 4 +- .../io/trino/plugin/kudu/KuduPageSink.java | 4 +- .../trino/plugin/kudu/KuduSecurityModule.java | 4 +- .../plugin/kudu/TestKuduConnectorTest.java | 8 +-- .../plugin/memory/MemoryPageSinkProvider.java | 4 +- .../java/io/trino/plugin/ml/MLFunctions.java | 4 +- .../java/io/trino/plugin/ml/ModelUtils.java | 4 +- .../trino/plugin/mongodb/MongoPageSink.java | 4 +- .../opensearch/CountQueryPageSource.java | 4 +- .../plugin/phoenix5/PhoenixMetadata.java | 3 +- .../plugin/phoenix5/PhoenixQueryRunner.java | 4 +- .../pinot/auth/PinotAuthenticationModule.java | 8 +-- .../plugin/pinot/decoders/DecoderFactory.java | 4 +- .../pinot/query/DynamicTableBuilder.java | 4 +- .../pinot/query/DynamicTablePqlExtractor.java | 4 +- .../plugin/pinot/query/PinotQueryBuilder.java | 4 +- .../io/trino/plugin/pinot/MetadataUtil.java | 4 +- .../trino/plugin/redis/RedisRecordCursor.java | 4 +- .../TestRedshiftAutomaticJoinPushdown.java | 4 +- .../resourcegroups/db/FlywayMigration.java | 4 +- .../functions/TeradataDateFunctions.java | 4 +- .../api/datatypes/TrinoThriftTypeUtils.java | 4 +- .../thrift/server/ListBasedRecordSet.java | 4 +- .../java/io/trino/plugin/tpch/TpchTables.java | 4 +- .../launcher/env/ContainerListener.java | 16 ++---- .../launcher/env/EnvironmentListener.java | 20 ++----- .../io/trino/tests/product/TpcTestUtils.java | 4 +- .../trino/tests/product/TpchTableResults.java | 4 +- .../product/hive/HiveTableDefinitions.java | 4 +- .../product/hive/util/TableLocationUtils.java | 4 +- .../trino/testing/kafka/JsonSerializer.java | 8 +-- .../services/ReportInnerTestClasses.java | 4 +- .../io/trino/testing/QueryAssertions.java | 4 +- .../java/io/trino/testing/ResultsSession.java | 4 +- .../tpch/MaterializedTupleRecordSet.java | 4 +- ...stractTestCoordinatorDynamicFiltering.java | 4 +- .../TestDeprecatedFunctionWarning.java | 16 ++---- .../TestAccessControlTableRedirection.java | 16 ++---- .../trino/tests/TestQueryPlanDeterminism.java | 20 ++----- 159 files changed, 223 insertions(+), 668 deletions(-) diff --git a/client/trino-cli/src/main/java/io/trino/cli/NullPrinter.java b/client/trino-cli/src/main/java/io/trino/cli/NullPrinter.java index 17f588685fac..f885e5add7d2 100644 --- a/client/trino-cli/src/main/java/io/trino/cli/NullPrinter.java +++ b/client/trino-cli/src/main/java/io/trino/cli/NullPrinter.java @@ -19,12 +19,8 @@ public class NullPrinter implements OutputPrinter { @Override - public void printRows(List> rows, boolean complete) - { - } + public void printRows(List> rows, boolean complete) {} @Override - public void finish() - { - } + public void finish() {} } diff --git a/client/trino-client/src/main/java/io/trino/client/auth/external/MemoryCachedKnownToken.java b/client/trino-client/src/main/java/io/trino/client/auth/external/MemoryCachedKnownToken.java index 1d429d8465a6..15d6b6ff571c 100644 --- a/client/trino-client/src/main/java/io/trino/client/auth/external/MemoryCachedKnownToken.java +++ b/client/trino-client/src/main/java/io/trino/client/auth/external/MemoryCachedKnownToken.java @@ -43,9 +43,7 @@ class MemoryCachedKnownToken private final Lock writeLock = lock.writeLock(); private Optional knownToken = Optional.empty(); - private MemoryCachedKnownToken() - { - } + private MemoryCachedKnownToken() {} @Override public Optional getToken() diff --git a/client/trino-client/src/test/java/io/trino/client/auth/external/MockTokenPoller.java b/client/trino-client/src/test/java/io/trino/client/auth/external/MockTokenPoller.java index e1fd3678ba37..33b17eeb944f 100644 --- a/client/trino-client/src/test/java/io/trino/client/auth/external/MockTokenPoller.java +++ b/client/trino-client/src/test/java/io/trino/client/auth/external/MockTokenPoller.java @@ -40,9 +40,7 @@ public TokenPollResult pollForToken(URI tokenUri, Duration timeout) } @Override - public void tokenReceived(URI tokenUri) - { - } + public void tokenReceived(URI tokenUri) {} }; } diff --git a/client/trino-jdbc/src/main/java/io/trino/jdbc/TestingRedirectHandlerInjector.java b/client/trino-jdbc/src/main/java/io/trino/jdbc/TestingRedirectHandlerInjector.java index e56c52fa2989..bebe7fbe6946 100644 --- a/client/trino-jdbc/src/main/java/io/trino/jdbc/TestingRedirectHandlerInjector.java +++ b/client/trino-jdbc/src/main/java/io/trino/jdbc/TestingRedirectHandlerInjector.java @@ -18,9 +18,7 @@ public class TestingRedirectHandlerInjector { - private TestingRedirectHandlerInjector() - { - } + private TestingRedirectHandlerInjector() {} public static void setRedirectHandler(Consumer redirectHandler) { diff --git a/core/trino-main/src/main/java/io/trino/TrinoMediaTypes.java b/core/trino-main/src/main/java/io/trino/TrinoMediaTypes.java index 16108f98a8f0..1cba1188e658 100644 --- a/core/trino-main/src/main/java/io/trino/TrinoMediaTypes.java +++ b/core/trino-main/src/main/java/io/trino/TrinoMediaTypes.java @@ -20,7 +20,5 @@ public final class TrinoMediaTypes public static final String TRINO_PAGES = "application/x-trino-pages"; public static final MediaType TRINO_PAGES_TYPE = MediaType.create("application", "x-trino-pages"); - private TrinoMediaTypes() - { - } + private TrinoMediaTypes() {} } diff --git a/core/trino-main/src/main/java/io/trino/block/BlockSerdeUtil.java b/core/trino-main/src/main/java/io/trino/block/BlockSerdeUtil.java index 1ef48170cd28..6df4baed2192 100644 --- a/core/trino-main/src/main/java/io/trino/block/BlockSerdeUtil.java +++ b/core/trino-main/src/main/java/io/trino/block/BlockSerdeUtil.java @@ -29,9 +29,7 @@ public final class BlockSerdeUtil public static final MethodHandle READ_BLOCK = methodHandle(BlockSerdeUtil.class, "readBlock", BlockEncodingSerde.class, Slice.class); public static final MethodHandle READ_BLOCK_VALUE = methodHandle(BlockSerdeUtil.class, "readBlockValue", BlockEncodingSerde.class, Type.class, Slice.class); - private BlockSerdeUtil() - { - } + private BlockSerdeUtil() {} public static Block readBlock(BlockEncodingSerde blockEncodingSerde, Slice slice) { diff --git a/core/trino-main/src/main/java/io/trino/execution/NoOpFailureInjector.java b/core/trino-main/src/main/java/io/trino/execution/NoOpFailureInjector.java index 18ecd45dd2c4..e196694b5458 100644 --- a/core/trino-main/src/main/java/io/trino/execution/NoOpFailureInjector.java +++ b/core/trino-main/src/main/java/io/trino/execution/NoOpFailureInjector.java @@ -22,9 +22,7 @@ public class NoOpFailureInjector implements FailureInjector { @Override - public void injectTaskFailure(String traceToken, int stageId, int partitionId, int attemptId, InjectedFailureType injectionType, Optional errorType) - { - } + public void injectTaskFailure(String traceToken, int stageId, int partitionId, int attemptId, InjectedFailureType injectionType, Optional errorType) {} @Override public Optional getInjectedFailure(String traceToken, int stageId, int partitionId, int attemptId) diff --git a/core/trino-main/src/main/java/io/trino/execution/scheduler/FixedSourcePartitionedScheduler.java b/core/trino-main/src/main/java/io/trino/execution/scheduler/FixedSourcePartitionedScheduler.java index b730b69e5aef..39522e92cc13 100644 --- a/core/trino-main/src/main/java/io/trino/execution/scheduler/FixedSourcePartitionedScheduler.java +++ b/core/trino-main/src/main/java/io/trino/execution/scheduler/FixedSourcePartitionedScheduler.java @@ -193,9 +193,7 @@ public SplitPlacementResult computeAssignments(Set splits) } @Override - public void lockDownNodes() - { - } + public void lockDownNodes() {} @Override public List allNodes() diff --git a/core/trino-main/src/main/java/io/trino/execution/scheduler/TaskLifecycleListener.java b/core/trino-main/src/main/java/io/trino/execution/scheduler/TaskLifecycleListener.java index 999eede414e2..28d59f6fe3be 100644 --- a/core/trino-main/src/main/java/io/trino/execution/scheduler/TaskLifecycleListener.java +++ b/core/trino-main/src/main/java/io/trino/execution/scheduler/TaskLifecycleListener.java @@ -25,13 +25,9 @@ public interface TaskLifecycleListener TaskLifecycleListener NO_OP = new TaskLifecycleListener() { @Override - public void taskCreated(PlanFragmentId fragmentId, RemoteTask task) - { - } + public void taskCreated(PlanFragmentId fragmentId, RemoteTask task) {} @Override - public void noMoreTasks(PlanFragmentId fragmentId) - { - } + public void noMoreTasks(PlanFragmentId fragmentId) {} }; } diff --git a/core/trino-main/src/main/java/io/trino/operator/DeduplicatingDirectExchangeBuffer.java b/core/trino-main/src/main/java/io/trino/operator/DeduplicatingDirectExchangeBuffer.java index 72592974755d..8b6108fe31e8 100644 --- a/core/trino-main/src/main/java/io/trino/operator/DeduplicatingDirectExchangeBuffer.java +++ b/core/trino-main/src/main/java/io/trino/operator/DeduplicatingDirectExchangeBuffer.java @@ -803,9 +803,7 @@ public long getRetainedSizeInBytes() } @Override - public void close() - { - } + public void close() {} } @NotThreadSafe diff --git a/core/trino-main/src/main/java/io/trino/operator/DevNullOperator.java b/core/trino-main/src/main/java/io/trino/operator/DevNullOperator.java index 297be0f6385a..01a6b6035ef8 100644 --- a/core/trino-main/src/main/java/io/trino/operator/DevNullOperator.java +++ b/core/trino-main/src/main/java/io/trino/operator/DevNullOperator.java @@ -40,9 +40,7 @@ public Operator createOperator(DriverContext driverContext) } @Override - public void noMoreOperators() - { - } + public void noMoreOperators() {} @Override public OperatorFactory duplicate() @@ -72,9 +70,7 @@ public boolean needsInput() } @Override - public void addInput(Page page) - { - } + public void addInput(Page page) {} @Override public Page getOutput() diff --git a/core/trino-main/src/main/java/io/trino/operator/FinishedOperator.java b/core/trino-main/src/main/java/io/trino/operator/FinishedOperator.java index d606eae24453..48519c46b01f 100644 --- a/core/trino-main/src/main/java/io/trino/operator/FinishedOperator.java +++ b/core/trino-main/src/main/java/io/trino/operator/FinishedOperator.java @@ -34,9 +34,7 @@ public OperatorContext getOperatorContext() } @Override - public void finish() - { - } + public void finish() {} @Override public boolean isFinished() diff --git a/core/trino-main/src/main/java/io/trino/operator/Operator.java b/core/trino-main/src/main/java/io/trino/operator/Operator.java index fc36a77ba2b4..876d606d0e76 100644 --- a/core/trino-main/src/main/java/io/trino/operator/Operator.java +++ b/core/trino-main/src/main/java/io/trino/operator/Operator.java @@ -78,9 +78,7 @@ default ListenableFuture startMemoryRevoke() * Clean up and release resources after completed memory revoking. Called by driver * once future returned by startMemoryRevoke is completed. */ - default void finishMemoryRevoke() - { - } + default void finishMemoryRevoke() {} /** * Notifies the operator that no more pages will be added and the diff --git a/core/trino-main/src/main/java/io/trino/operator/PositionSearcher.java b/core/trino-main/src/main/java/io/trino/operator/PositionSearcher.java index 5fe80ca10915..191e945be128 100644 --- a/core/trino-main/src/main/java/io/trino/operator/PositionSearcher.java +++ b/core/trino-main/src/main/java/io/trino/operator/PositionSearcher.java @@ -19,9 +19,7 @@ public class PositionSearcher { - private PositionSearcher() - { - } + private PositionSearcher() {} /** * @param startPosition - inclusive diff --git a/core/trino-main/src/main/java/io/trino/operator/RefreshMaterializedViewOperator.java b/core/trino-main/src/main/java/io/trino/operator/RefreshMaterializedViewOperator.java index 6a17fb3c92f3..a61fe3f35ce1 100644 --- a/core/trino-main/src/main/java/io/trino/operator/RefreshMaterializedViewOperator.java +++ b/core/trino-main/src/main/java/io/trino/operator/RefreshMaterializedViewOperator.java @@ -114,9 +114,7 @@ public Page getOutput() } @Override - public void finish() - { - } + public void finish() {} @Override public void close() diff --git a/core/trino-main/src/main/java/io/trino/operator/aggregation/DoubleHistogramAggregation.java b/core/trino-main/src/main/java/io/trino/operator/aggregation/DoubleHistogramAggregation.java index fd40d4d35c5f..ab13b51349f7 100644 --- a/core/trino-main/src/main/java/io/trino/operator/aggregation/DoubleHistogramAggregation.java +++ b/core/trino-main/src/main/java/io/trino/operator/aggregation/DoubleHistogramAggregation.java @@ -39,9 +39,7 @@ public final class DoubleHistogramAggregation { public static final int ENTRY_BUFFER_SIZE = 100; - private DoubleHistogramAggregation() - { - } + private DoubleHistogramAggregation() {} @AccumulatorStateMetadata(stateSerializerClass = DoubleHistogramStateSerializer.class, stateFactoryClass = NumericHistogramStateFactory.class) public interface State diff --git a/core/trino-main/src/main/java/io/trino/operator/aggregation/partial/SkipAggregationBuilder.java b/core/trino-main/src/main/java/io/trino/operator/aggregation/partial/SkipAggregationBuilder.java index 8c2891459b04..d7fcdab86695 100644 --- a/core/trino-main/src/main/java/io/trino/operator/aggregation/partial/SkipAggregationBuilder.java +++ b/core/trino-main/src/main/java/io/trino/operator/aggregation/partial/SkipAggregationBuilder.java @@ -97,9 +97,7 @@ public void updateMemory() } @Override - public void close() - { - } + public void close() {} @Override public ListenableFuture startMemoryRevoke() diff --git a/core/trino-main/src/main/java/io/trino/operator/function/RegularTableFunctionPartition.java b/core/trino-main/src/main/java/io/trino/operator/function/RegularTableFunctionPartition.java index 5b7c57f47877..5658ac514a8a 100644 --- a/core/trino-main/src/main/java/io/trino/operator/function/RegularTableFunctionPartition.java +++ b/core/trino-main/src/main/java/io/trino/operator/function/RegularTableFunctionPartition.java @@ -329,9 +329,7 @@ private int findFirstNullPosition(int markerChannel) return end; } - public record PassThroughColumnSpecification(boolean isPartitioningColumn, int inputChannel, int indexChannel) - { - } + public record PassThroughColumnSpecification(boolean isPartitioningColumn, int inputChannel, int indexChannel) {} private PassThroughColumnProvider createColumnProvider(PassThroughColumnSpecification specification) { diff --git a/core/trino-main/src/main/java/io/trino/operator/index/IndexLoader.java b/core/trino-main/src/main/java/io/trino/operator/index/IndexLoader.java index 049c7f92dbdb..3a7bb3e5e997 100644 --- a/core/trino-main/src/main/java/io/trino/operator/index/IndexLoader.java +++ b/core/trino-main/src/main/java/io/trino/operator/index/IndexLoader.java @@ -428,8 +428,6 @@ public void appendTo(long position, PageBuilder pageBuilder, int outputChannelOf } @Override - public void close() - { - } + public void close() {} } } diff --git a/core/trino-main/src/main/java/io/trino/operator/index/IndexSnapshot.java b/core/trino-main/src/main/java/io/trino/operator/index/IndexSnapshot.java index 2bbace6222f0..79f07d885ab5 100644 --- a/core/trino-main/src/main/java/io/trino/operator/index/IndexSnapshot.java +++ b/core/trino-main/src/main/java/io/trino/operator/index/IndexSnapshot.java @@ -61,7 +61,5 @@ public void appendTo(long position, PageBuilder pageBuilder, int outputChannelOf } @Override - public void close() - { - } + public void close() {} } diff --git a/core/trino-main/src/main/java/io/trino/operator/index/PageBufferOperator.java b/core/trino-main/src/main/java/io/trino/operator/index/PageBufferOperator.java index 65995a44a505..6bdd3ed7ff82 100644 --- a/core/trino-main/src/main/java/io/trino/operator/index/PageBufferOperator.java +++ b/core/trino-main/src/main/java/io/trino/operator/index/PageBufferOperator.java @@ -51,9 +51,7 @@ public Operator createOperator(DriverContext driverContext) } @Override - public void noMoreOperators() - { - } + public void noMoreOperators() {} @Override public OperatorFactory duplicate() diff --git a/core/trino-main/src/main/java/io/trino/operator/index/PageRecordSet.java b/core/trino-main/src/main/java/io/trino/operator/index/PageRecordSet.java index 3b0c50cdc186..130e3e6d8022 100644 --- a/core/trino-main/src/main/java/io/trino/operator/index/PageRecordSet.java +++ b/core/trino-main/src/main/java/io/trino/operator/index/PageRecordSet.java @@ -144,8 +144,6 @@ public boolean isNull(int field) } @Override - public void close() - { - } + public void close() {} } } diff --git a/core/trino-main/src/main/java/io/trino/operator/join/JoinHash.java b/core/trino-main/src/main/java/io/trino/operator/join/JoinHash.java index d146772d829c..a687131dc706 100644 --- a/core/trino-main/src/main/java/io/trino/operator/join/JoinHash.java +++ b/core/trino-main/src/main/java/io/trino/operator/join/JoinHash.java @@ -163,7 +163,5 @@ public void appendTo(long position, PageBuilder pageBuilder, int outputChannelOf } @Override - public void close() - { - } + public void close() {} } diff --git a/core/trino-main/src/main/java/io/trino/operator/join/PartitionedLookupSourceFactory.java b/core/trino-main/src/main/java/io/trino/operator/join/PartitionedLookupSourceFactory.java index 2b99e73cf4e9..d207e5200069 100644 --- a/core/trino-main/src/main/java/io/trino/operator/join/PartitionedLookupSourceFactory.java +++ b/core/trino-main/src/main/java/io/trino/operator/join/PartitionedLookupSourceFactory.java @@ -571,9 +571,7 @@ public boolean isJoinPositionEligible(long currentJoinPosition, int probePositio } @Override - public void close() - { - } + public void close() {} } @Immutable diff --git a/core/trino-main/src/main/java/io/trino/operator/output/TaskOutputOperator.java b/core/trino-main/src/main/java/io/trino/operator/output/TaskOutputOperator.java index b687ed09ac74..fcb1692b1d6d 100644 --- a/core/trino-main/src/main/java/io/trino/operator/output/TaskOutputOperator.java +++ b/core/trino-main/src/main/java/io/trino/operator/output/TaskOutputOperator.java @@ -83,9 +83,7 @@ public Operator createOperator(DriverContext driverContext) } @Override - public void noMoreOperators() - { - } + public void noMoreOperators() {} @Override public OperatorFactory duplicate() diff --git a/core/trino-main/src/main/java/io/trino/operator/scalar/JsonOperators.java b/core/trino-main/src/main/java/io/trino/operator/scalar/JsonOperators.java index a513c09478d5..bf436ad0b2c0 100644 --- a/core/trino-main/src/main/java/io/trino/operator/scalar/JsonOperators.java +++ b/core/trino-main/src/main/java/io/trino/operator/scalar/JsonOperators.java @@ -62,9 +62,7 @@ public final class JsonOperators { private static final JsonFactory JSON_FACTORY = createJsonFactory(); - private JsonOperators() - { - } + private JsonOperators() {} @ScalarOperator(CAST) @SqlNullable diff --git a/core/trino-main/src/main/java/io/trino/operator/table/json/execution/ExecutionPlanner.java b/core/trino-main/src/main/java/io/trino/operator/table/json/execution/ExecutionPlanner.java index 72f8d9160adb..432938215d7f 100644 --- a/core/trino-main/src/main/java/io/trino/operator/table/json/execution/ExecutionPlanner.java +++ b/core/trino-main/src/main/java/io/trino/operator/table/json/execution/ExecutionPlanner.java @@ -41,9 +41,7 @@ public class ExecutionPlanner { - private ExecutionPlanner() - { - } + private ExecutionPlanner() {} public static JsonTableProcessingFragment getExecutionPlan( JsonTablePlanNode plan, diff --git a/core/trino-main/src/main/java/io/trino/operator/table/json/execution/SequenceEvaluator.java b/core/trino-main/src/main/java/io/trino/operator/table/json/execution/SequenceEvaluator.java index 32b4fe0b9389..7109a679d729 100644 --- a/core/trino-main/src/main/java/io/trino/operator/table/json/execution/SequenceEvaluator.java +++ b/core/trino-main/src/main/java/io/trino/operator/table/json/execution/SequenceEvaluator.java @@ -30,9 +30,7 @@ public class SequenceEvaluator { - private SequenceEvaluator() - { - } + private SequenceEvaluator() {} // creates a sequence of JSON items, and applies error handling public static List getSequence(JsonNode item, Object[] pathParameters, JsonPathEvaluator pathEvaluator, boolean errorOnError) diff --git a/core/trino-main/src/main/java/io/trino/sql/gen/Bootstrap.java b/core/trino-main/src/main/java/io/trino/sql/gen/Bootstrap.java index fbb1e90df027..54f003828ecb 100644 --- a/core/trino-main/src/main/java/io/trino/sql/gen/Bootstrap.java +++ b/core/trino-main/src/main/java/io/trino/sql/gen/Bootstrap.java @@ -37,9 +37,7 @@ public final class Bootstrap } } - private Bootstrap() - { - } + private Bootstrap() {} public static CallSite bootstrap(MethodHandles.Lookup callerLookup, String name, MethodType type, long bindingId) { diff --git a/core/trino-main/src/main/java/io/trino/sql/gen/LambdaCapture.java b/core/trino-main/src/main/java/io/trino/sql/gen/LambdaCapture.java index cecf2404988a..3e0a9fe9d9e7 100644 --- a/core/trino-main/src/main/java/io/trino/sql/gen/LambdaCapture.java +++ b/core/trino-main/src/main/java/io/trino/sql/gen/LambdaCapture.java @@ -34,9 +34,7 @@ public final class LambdaCapture } } - private LambdaCapture() - { - } + private LambdaCapture() {} public static CallSite lambdaCapture( MethodHandles.Lookup callerLookup, diff --git a/core/trino-main/src/main/java/io/trino/sql/planner/ExpressionExtractor.java b/core/trino-main/src/main/java/io/trino/sql/planner/ExpressionExtractor.java index 36172e7f3d4d..04342961b649 100644 --- a/core/trino-main/src/main/java/io/trino/sql/planner/ExpressionExtractor.java +++ b/core/trino-main/src/main/java/io/trino/sql/planner/ExpressionExtractor.java @@ -60,9 +60,7 @@ public static void forEachExpression(PlanNode plan, Consumer express plan.accept(new Visitor(expressionConsumer, true, noLookup()), null); } - private ExpressionExtractor() - { - } + private ExpressionExtractor() {} private static class Visitor extends SimplePlanVisitor diff --git a/core/trino-main/src/main/java/io/trino/sql/planner/IrTypeAnalyzer.java b/core/trino-main/src/main/java/io/trino/sql/planner/IrTypeAnalyzer.java index 2ec90b570bbc..c17aca9a8b1f 100644 --- a/core/trino-main/src/main/java/io/trino/sql/planner/IrTypeAnalyzer.java +++ b/core/trino-main/src/main/java/io/trino/sql/planner/IrTypeAnalyzer.java @@ -20,7 +20,5 @@ */ public class IrTypeAnalyzer { - public IrTypeAnalyzer() - { - } + public IrTypeAnalyzer() {} } diff --git a/core/trino-main/src/main/java/io/trino/sql/planner/iterative/rule/Util.java b/core/trino-main/src/main/java/io/trino/sql/planner/iterative/rule/Util.java index fe65395031fe..4ec59d8aca6b 100644 --- a/core/trino-main/src/main/java/io/trino/sql/planner/iterative/rule/Util.java +++ b/core/trino-main/src/main/java/io/trino/sql/planner/iterative/rule/Util.java @@ -45,9 +45,7 @@ final class Util private static final CatalogSchemaFunctionName ROW_NUMBER_NAME = builtinFunctionName("row_number"); private static final CatalogSchemaFunctionName RANK_NAME = builtinFunctionName("rank"); - private Util() - { - } + private Util() {} /** * Prune the set of available inputs to those required by the given expressions. diff --git a/core/trino-main/src/main/java/io/trino/testing/NullOutputOperator.java b/core/trino-main/src/main/java/io/trino/testing/NullOutputOperator.java index d7fd40ebb7bf..5cd8c4fb98e6 100644 --- a/core/trino-main/src/main/java/io/trino/testing/NullOutputOperator.java +++ b/core/trino-main/src/main/java/io/trino/testing/NullOutputOperator.java @@ -61,9 +61,7 @@ public Operator createOperator(DriverContext driverContext) } @Override - public void noMoreOperators() - { - } + public void noMoreOperators() {} @Override public OperatorFactory duplicate() diff --git a/core/trino-main/src/main/java/io/trino/type/ArrayParametricType.java b/core/trino-main/src/main/java/io/trino/type/ArrayParametricType.java index e6bb7dd37387..bf137a9c29cd 100644 --- a/core/trino-main/src/main/java/io/trino/type/ArrayParametricType.java +++ b/core/trino-main/src/main/java/io/trino/type/ArrayParametricType.java @@ -30,9 +30,7 @@ public final class ArrayParametricType { public static final ArrayParametricType ARRAY = new ArrayParametricType(); - private ArrayParametricType() - { - } + private ArrayParametricType() {} @Override public String getName() diff --git a/core/trino-main/src/main/java/io/trino/type/BooleanOperators.java b/core/trino-main/src/main/java/io/trino/type/BooleanOperators.java index f2efd5227bb3..a9750e6fa569 100644 --- a/core/trino-main/src/main/java/io/trino/type/BooleanOperators.java +++ b/core/trino-main/src/main/java/io/trino/type/BooleanOperators.java @@ -30,9 +30,7 @@ public final class BooleanOperators private static final Slice TRUE = Slices.copiedBuffer("true", US_ASCII); private static final Slice FALSE = Slices.copiedBuffer("false", US_ASCII); - private BooleanOperators() - { - } + private BooleanOperators() {} @ScalarOperator(CAST) @SqlType(StandardTypes.DOUBLE) diff --git a/core/trino-main/src/main/java/io/trino/type/DateTimeOperators.java b/core/trino-main/src/main/java/io/trino/type/DateTimeOperators.java index 26a14fd4bc49..0e29ca77e450 100644 --- a/core/trino-main/src/main/java/io/trino/type/DateTimeOperators.java +++ b/core/trino-main/src/main/java/io/trino/type/DateTimeOperators.java @@ -31,9 +31,7 @@ public final class DateTimeOperators private static final DateTimeField MILLIS_OF_DAY = ISOChronology.getInstanceUTC().millisOfDay(); private static final DateTimeField MONTH_OF_YEAR_UTC = ISOChronology.getInstanceUTC().monthOfYear(); - private DateTimeOperators() - { - } + private DateTimeOperators() {} @ScalarOperator(ADD) @SqlType(StandardTypes.DATE) diff --git a/core/trino-main/src/main/java/io/trino/type/DecimalOperators.java b/core/trino-main/src/main/java/io/trino/type/DecimalOperators.java index de6d36137234..a4bb6a336611 100644 --- a/core/trino-main/src/main/java/io/trino/type/DecimalOperators.java +++ b/core/trino-main/src/main/java/io/trino/type/DecimalOperators.java @@ -61,9 +61,7 @@ public final class DecimalOperators public static final SqlScalarFunction DECIMAL_DIVIDE_OPERATOR = decimalDivideOperator(); public static final SqlScalarFunction DECIMAL_MODULUS_OPERATOR = decimalModulusOperator(); - private DecimalOperators() - { - } + private DecimalOperators() {} private static SqlScalarFunction decimalAddOperator() { diff --git a/core/trino-main/src/main/java/io/trino/type/DoubleOperators.java b/core/trino-main/src/main/java/io/trino/type/DoubleOperators.java index e4ff585b49a3..d71c0bffdd9a 100644 --- a/core/trino-main/src/main/java/io/trino/type/DoubleOperators.java +++ b/core/trino-main/src/main/java/io/trino/type/DoubleOperators.java @@ -59,9 +59,7 @@ public final class DoubleOperators private static final ThreadLocal FORMAT = ThreadLocal.withInitial(() -> new DecimalFormat("0.0###################E0", new DecimalFormatSymbols(ENGLISH))); - private DoubleOperators() - { - } + private DoubleOperators() {} @ScalarOperator(ADD) @SqlType(StandardTypes.DOUBLE) diff --git a/core/trino-main/src/main/java/io/trino/type/FunctionParametricType.java b/core/trino-main/src/main/java/io/trino/type/FunctionParametricType.java index 6d54d40713c7..ef3ba7f83934 100644 --- a/core/trino-main/src/main/java/io/trino/type/FunctionParametricType.java +++ b/core/trino-main/src/main/java/io/trino/type/FunctionParametricType.java @@ -29,9 +29,7 @@ public final class FunctionParametricType { public static final FunctionParametricType FUNCTION = new FunctionParametricType(); - private FunctionParametricType() - { - } + private FunctionParametricType() {} @Override public String getName() diff --git a/core/trino-main/src/main/java/io/trino/type/RealOperators.java b/core/trino-main/src/main/java/io/trino/type/RealOperators.java index 4617dd291d6f..9a8c86b3791c 100644 --- a/core/trino-main/src/main/java/io/trino/type/RealOperators.java +++ b/core/trino-main/src/main/java/io/trino/type/RealOperators.java @@ -55,9 +55,7 @@ public final class RealOperators private static final ThreadLocal FORMAT = ThreadLocal.withInitial(() -> new DecimalFormat("0.0#####E0", new DecimalFormatSymbols(ENGLISH))); - private RealOperators() - { - } + private RealOperators() {} @ScalarOperator(ADD) @SqlType(StandardTypes.REAL) diff --git a/core/trino-main/src/main/java/io/trino/type/RowParametricType.java b/core/trino-main/src/main/java/io/trino/type/RowParametricType.java index d56472fb01d8..0f76f26c3d6e 100644 --- a/core/trino-main/src/main/java/io/trino/type/RowParametricType.java +++ b/core/trino-main/src/main/java/io/trino/type/RowParametricType.java @@ -35,9 +35,7 @@ public final class RowParametricType { public static final RowParametricType ROW = new RowParametricType(); - private RowParametricType() - { - } + private RowParametricType() {} @Override public String getName() diff --git a/core/trino-main/src/main/java/io/trino/type/TypeUtils.java b/core/trino-main/src/main/java/io/trino/type/TypeUtils.java index 1c7737f759e3..f13ba444504b 100644 --- a/core/trino-main/src/main/java/io/trino/type/TypeUtils.java +++ b/core/trino-main/src/main/java/io/trino/type/TypeUtils.java @@ -37,9 +37,7 @@ public final class TypeUtils { public static final int NULL_HASH_CODE = 0; - private TypeUtils() - { - } + private TypeUtils() {} public static int expectedValueSize(Type type, int defaultSize) { diff --git a/core/trino-main/src/main/java/io/trino/type/setdigest/SetDigestFunctions.java b/core/trino-main/src/main/java/io/trino/type/setdigest/SetDigestFunctions.java index a76e21be35fe..48b5667d43a6 100644 --- a/core/trino-main/src/main/java/io/trino/type/setdigest/SetDigestFunctions.java +++ b/core/trino-main/src/main/java/io/trino/type/setdigest/SetDigestFunctions.java @@ -30,9 +30,7 @@ public final class SetDigestFunctions { - private SetDigestFunctions() - { - } + private SetDigestFunctions() {} @ScalarFunction @SqlType(StandardTypes.BIGINT) diff --git a/core/trino-main/src/main/java/io/trino/util/Long2LongOpenBigHashMap.java b/core/trino-main/src/main/java/io/trino/util/Long2LongOpenBigHashMap.java index aefaddb1390e..344a5122bb0a 100644 --- a/core/trino-main/src/main/java/io/trino/util/Long2LongOpenBigHashMap.java +++ b/core/trino-main/src/main/java/io/trino/util/Long2LongOpenBigHashMap.java @@ -788,9 +788,7 @@ final class MapEntry this.index = index; } - MapEntry() - { - } + MapEntry() {} @Override public long getLongKey() @@ -1468,7 +1466,5 @@ protected void rehash(final long newN) this.value = newValue; } - private void checkTable() - { - } + private void checkTable() {} } diff --git a/core/trino-main/src/main/java/io/trino/util/LongLong2LongOpenCustomBigHashMap.java b/core/trino-main/src/main/java/io/trino/util/LongLong2LongOpenCustomBigHashMap.java index 5b92ef5c1363..994cba401b03 100644 --- a/core/trino-main/src/main/java/io/trino/util/LongLong2LongOpenCustomBigHashMap.java +++ b/core/trino-main/src/main/java/io/trino/util/LongLong2LongOpenCustomBigHashMap.java @@ -817,7 +817,5 @@ protected void rehash(final long newN) this.value = newValue; } - private void checkTable() - { - } + private void checkTable() {} } diff --git a/core/trino-main/src/main/java/io/trino/util/PowerOfTwoValidator.java b/core/trino-main/src/main/java/io/trino/util/PowerOfTwoValidator.java index 44559702dade..61b7e5456806 100644 --- a/core/trino-main/src/main/java/io/trino/util/PowerOfTwoValidator.java +++ b/core/trino-main/src/main/java/io/trino/util/PowerOfTwoValidator.java @@ -20,9 +20,7 @@ public class PowerOfTwoValidator implements ConstraintValidator { @Override - public void initialize(PowerOfTwo powerOfTwo) - { - } + public void initialize(PowerOfTwo powerOfTwo) {} @Override public boolean isValid(Integer value, ConstraintValidatorContext context) diff --git a/core/trino-main/src/test/java/io/trino/SessionTestUtils.java b/core/trino-main/src/test/java/io/trino/SessionTestUtils.java index ca2943976adf..e08675c0310f 100644 --- a/core/trino-main/src/test/java/io/trino/SessionTestUtils.java +++ b/core/trino-main/src/test/java/io/trino/SessionTestUtils.java @@ -30,7 +30,5 @@ public final class SessionTestUtils .collect(toImmutableSet())) .build(); - private SessionTestUtils() - { - } + private SessionTestUtils() {} } diff --git a/core/trino-main/src/test/java/io/trino/execution/buffer/BenchmarkDataGenerator.java b/core/trino-main/src/test/java/io/trino/execution/buffer/BenchmarkDataGenerator.java index c12fd9455194..da965b5df4af 100644 --- a/core/trino-main/src/test/java/io/trino/execution/buffer/BenchmarkDataGenerator.java +++ b/core/trino-main/src/test/java/io/trino/execution/buffer/BenchmarkDataGenerator.java @@ -35,9 +35,7 @@ public class BenchmarkDataGenerator public static final int LONG_DECIMAL_PRECISION = 30; public static final int LONG_DECIMAL_SCALE = 5; - private BenchmarkDataGenerator() - { - } + private BenchmarkDataGenerator() {} public static Iterator createValues(int size, Function valueGenerator, double nullChance) { diff --git a/core/trino-main/src/test/java/io/trino/execution/buffer/TestSpoolingExchangeOutputBuffer.java b/core/trino-main/src/test/java/io/trino/execution/buffer/TestSpoolingExchangeOutputBuffer.java index f047c2dc17fb..8292ada11b3d 100644 --- a/core/trino-main/src/test/java/io/trino/execution/buffer/TestSpoolingExchangeOutputBuffer.java +++ b/core/trino-main/src/test/java/io/trino/execution/buffer/TestSpoolingExchangeOutputBuffer.java @@ -423,8 +423,6 @@ public boolean trySetBytes(long bytes) } @Override - public void close() - { - } + public void close() {} } } diff --git a/core/trino-main/src/test/java/io/trino/execution/executor/timesharing/SimulationSplit.java b/core/trino-main/src/test/java/io/trino/execution/executor/timesharing/SimulationSplit.java index f0438a39dcd5..47b2870ffd57 100644 --- a/core/trino-main/src/test/java/io/trino/execution/executor/timesharing/SimulationSplit.java +++ b/core/trino-main/src/test/java/io/trino/execution/executor/timesharing/SimulationSplit.java @@ -104,9 +104,7 @@ public boolean isFinished() } @Override - public void close() - { - } + public void close() {} abstract boolean process(); diff --git a/core/trino-main/src/test/java/io/trino/execution/executor/timesharing/TestTimeSharingTaskExecutor.java b/core/trino-main/src/test/java/io/trino/execution/executor/timesharing/TestTimeSharingTaskExecutor.java index 889ade45be3f..3242857199ac 100644 --- a/core/trino-main/src/test/java/io/trino/execution/executor/timesharing/TestTimeSharingTaskExecutor.java +++ b/core/trino-main/src/test/java/io/trino/execution/executor/timesharing/TestTimeSharingTaskExecutor.java @@ -654,9 +654,7 @@ public boolean isStarted() } @Override - public void close() - { - } + public void close() {} public Future getCompletedFuture() { diff --git a/core/trino-main/src/test/java/io/trino/execution/scheduler/TestSourcePartitionedScheduler.java b/core/trino-main/src/test/java/io/trino/execution/scheduler/TestSourcePartitionedScheduler.java index e7d8a46ec557..dbbb58dde434 100644 --- a/core/trino-main/src/test/java/io/trino/execution/scheduler/TestSourcePartitionedScheduler.java +++ b/core/trino-main/src/test/java/io/trino/execution/scheduler/TestSourcePartitionedScheduler.java @@ -730,9 +730,7 @@ public CompletableFuture getNextBatch(int maxSize) } @Override - public void close() - { - } + public void close() {} @Override public boolean isFinished() diff --git a/core/trino-main/src/test/java/io/trino/operator/OperatorAssertion.java b/core/trino-main/src/test/java/io/trino/operator/OperatorAssertion.java index a87abafe9ed8..639c5d4d961d 100644 --- a/core/trino-main/src/test/java/io/trino/operator/OperatorAssertion.java +++ b/core/trino-main/src/test/java/io/trino/operator/OperatorAssertion.java @@ -54,9 +54,7 @@ public final class OperatorAssertion private static final Duration BLOCKED_DEFAULT_TIMEOUT = new Duration(10, MILLISECONDS); private static final Duration UNBLOCKED_DEFAULT_TIMEOUT = new Duration(1, SECONDS); - private OperatorAssertion() - { - } + private OperatorAssertion() {} public static List toPages(Operator operator, Iterator input) { diff --git a/core/trino-main/src/test/java/io/trino/operator/TestDirectExchangeClient.java b/core/trino-main/src/test/java/io/trino/operator/TestDirectExchangeClient.java index f1ed6498a5da..054678e1d1bc 100644 --- a/core/trino-main/src/test/java/io/trino/operator/TestDirectExchangeClient.java +++ b/core/trino-main/src/test/java/io/trino/operator/TestDirectExchangeClient.java @@ -1167,18 +1167,12 @@ public boolean addPages(HttpPageBufferClient client, List pages) } @Override - public void requestComplete(HttpPageBufferClient client) - { - } + public void requestComplete(HttpPageBufferClient client) {} @Override - public void clientFinished(HttpPageBufferClient client) - { - } + public void clientFinished(HttpPageBufferClient client) {} @Override - public void clientFailed(HttpPageBufferClient client, Throwable cause) - { - } + public void clientFailed(HttpPageBufferClient client, Throwable cause) {} } } diff --git a/core/trino-main/src/test/java/io/trino/operator/TestHashAggregationOperator.java b/core/trino-main/src/test/java/io/trino/operator/TestHashAggregationOperator.java index 78f1e87c7ec0..52f6b8e89a28 100644 --- a/core/trino-main/src/test/java/io/trino/operator/TestHashAggregationOperator.java +++ b/core/trino-main/src/test/java/io/trino/operator/TestHashAggregationOperator.java @@ -986,9 +986,7 @@ public List> getSpills() } @Override - public void close() - { - } + public void close() {} }; } } diff --git a/core/trino-main/src/test/java/io/trino/operator/TestTableWriterOperator.java b/core/trino-main/src/test/java/io/trino/operator/TestTableWriterOperator.java index 14b25a08fbc0..1f04eb67ace9 100644 --- a/core/trino-main/src/test/java/io/trino/operator/TestTableWriterOperator.java +++ b/core/trino-main/src/test/java/io/trino/operator/TestTableWriterOperator.java @@ -354,9 +354,7 @@ public CompletableFuture> finish() } @Override - public void abort() - { - } + public void abort() {} void complete() { diff --git a/core/trino-main/src/test/java/io/trino/operator/join/TestLookupJoinPageBuilder.java b/core/trino-main/src/test/java/io/trino/operator/join/TestLookupJoinPageBuilder.java index 0c86867d7306..00ef3c21858e 100644 --- a/core/trino-main/src/test/java/io/trino/operator/join/TestLookupJoinPageBuilder.java +++ b/core/trino-main/src/test/java/io/trino/operator/join/TestLookupJoinPageBuilder.java @@ -243,8 +243,6 @@ public void appendTo(long position, PageBuilder pageBuilder, int outputChannelOf } @Override - public void close() - { - } + public void close() {} } } diff --git a/core/trino-main/src/test/java/io/trino/operator/join/unspilled/TestLookupJoinPageBuilder.java b/core/trino-main/src/test/java/io/trino/operator/join/unspilled/TestLookupJoinPageBuilder.java index 1cfce284634b..7795a0d011c5 100644 --- a/core/trino-main/src/test/java/io/trino/operator/join/unspilled/TestLookupJoinPageBuilder.java +++ b/core/trino-main/src/test/java/io/trino/operator/join/unspilled/TestLookupJoinPageBuilder.java @@ -244,8 +244,6 @@ public void appendTo(long position, PageBuilder pageBuilder, int outputChannelOf } @Override - public void close() - { - } + public void close() {} } } diff --git a/core/trino-main/src/test/java/io/trino/operator/output/TestPagePartitioner.java b/core/trino-main/src/test/java/io/trino/operator/output/TestPagePartitioner.java index f4188053833f..3d6b8f7f0711 100644 --- a/core/trino-main/src/test/java/io/trino/operator/output/TestPagePartitioner.java +++ b/core/trino-main/src/test/java/io/trino/operator/output/TestPagePartitioner.java @@ -907,14 +907,10 @@ public OutputBufferStatus getStatus() } @Override - public void addStateChangeListener(StateMachine.StateChangeListener stateChangeListener) - { - } + public void addStateChangeListener(StateMachine.StateChangeListener stateChangeListener) {} @Override - public void setOutputBuffers(OutputBuffers newOutputBuffers) - { - } + public void setOutputBuffers(OutputBuffers newOutputBuffers) {} @Override public ListenableFuture get(OutputBufferId bufferId, long token, DataSize maxSize) @@ -923,14 +919,10 @@ public ListenableFuture get(OutputBufferId bufferId, long token, D } @Override - public void acknowledge(OutputBufferId bufferId, long token) - { - } + public void acknowledge(OutputBufferId bufferId, long token) {} @Override - public void destroy(OutputBufferId bufferId) - { - } + public void destroy(OutputBufferId bufferId) {} @Override public ListenableFuture isFull() @@ -939,24 +931,16 @@ public ListenableFuture isFull() } @Override - public void enqueue(List pages) - { - } + public void enqueue(List pages) {} @Override - public void setNoMorePages() - { - } + public void setNoMorePages() {} @Override - public void destroy() - { - } + public void destroy() {} @Override - public void abort() - { - } + public void abort() {} @Override public long getPeakMemoryUsage() diff --git a/core/trino-main/src/test/java/io/trino/security/TestAccessControlManager.java b/core/trino-main/src/test/java/io/trino/security/TestAccessControlManager.java index 43661100c2d7..9480a5410712 100644 --- a/core/trino-main/src/test/java/io/trino/security/TestAccessControlManager.java +++ b/core/trino-main/src/test/java/io/trino/security/TestAccessControlManager.java @@ -427,9 +427,7 @@ public SystemAccessControl create(Map config) return new SystemAccessControl() { @Override - public void checkCanSetSystemSessionProperty(Identity identity, QueryId queryId, String propertyName) - { - } + public void checkCanSetSystemSessionProperty(Identity identity, QueryId queryId, String propertyName) {} @Override public Iterable getEventListeners() diff --git a/core/trino-main/src/test/java/io/trino/server/security/TestResourceSecurity.java b/core/trino-main/src/test/java/io/trino/server/security/TestResourceSecurity.java index b7c68c12c66b..75158ea18bd3 100644 --- a/core/trino-main/src/test/java/io/trino/server/security/TestResourceSecurity.java +++ b/core/trino-main/src/test/java/io/trino/server/security/TestResourceSecurity.java @@ -863,9 +863,7 @@ private void testOAuth2Groups(Optional> groups) .cookieJar(new CookieJar() { @Override - public void saveFromResponse(HttpUrl url, List cookies) - { - } + public void saveFromResponse(HttpUrl url, List cookies) {} @Override public List loadForRequest(HttpUrl url) @@ -1092,9 +1090,7 @@ public OAuth2Client getOAuth2Client() return new OAuth2Client() { @Override - public void load() - { - } + public void load() {} @Override public Request createAuthorizationRequest(String state, URI callbackUri) diff --git a/core/trino-main/src/test/java/io/trino/server/security/oauth2/BaseOAuth2WebUiAuthenticationFilterTest.java b/core/trino-main/src/test/java/io/trino/server/security/oauth2/BaseOAuth2WebUiAuthenticationFilterTest.java index 2d7a0e78fd26..83faab7b3793 100644 --- a/core/trino-main/src/test/java/io/trino/server/security/oauth2/BaseOAuth2WebUiAuthenticationFilterTest.java +++ b/core/trino-main/src/test/java/io/trino/server/security/oauth2/BaseOAuth2WebUiAuthenticationFilterTest.java @@ -401,9 +401,7 @@ private OkHttpClient httpClientWithOAuth2Cookie(String cookieValue, boolean foll httpClientBuilder.cookieJar(new CookieJar() { @Override - public void saveFromResponse(HttpUrl url, List cookies) - { - } + public void saveFromResponse(HttpUrl url, List cookies) {} @Override public List loadForRequest(HttpUrl url) diff --git a/core/trino-main/src/test/java/io/trino/server/security/oauth2/TestJweTokenSerializer.java b/core/trino-main/src/test/java/io/trino/server/security/oauth2/TestJweTokenSerializer.java index 918cd48e784e..2c456e4d42a7 100644 --- a/core/trino-main/src/test/java/io/trino/server/security/oauth2/TestJweTokenSerializer.java +++ b/core/trino-main/src/test/java/io/trino/server/security/oauth2/TestJweTokenSerializer.java @@ -202,9 +202,7 @@ static class Oauth2ClientStub .build(); @Override - public void load() - { - } + public void load() {} @Override public Request createAuthorizationRequest(String state, URI callbackUri) diff --git a/core/trino-main/src/test/java/io/trino/server/ui/TestWebUi.java b/core/trino-main/src/test/java/io/trino/server/ui/TestWebUi.java index 7f3b1be47b90..b929cf9e33c7 100644 --- a/core/trino-main/src/test/java/io/trino/server/ui/TestWebUi.java +++ b/core/trino-main/src/test/java/io/trino/server/ui/TestWebUi.java @@ -1308,9 +1308,7 @@ public OAuth2ClientStub(Map additionalClaims, Duration accessTok } @Override - public void load() - { - } + public void load() {} @Override public Request createAuthorizationRequest(String state, URI callbackUri) diff --git a/core/trino-main/src/test/java/io/trino/split/MockSplitSource.java b/core/trino-main/src/test/java/io/trino/split/MockSplitSource.java index 68b953c9c828..a3eb250d4c73 100644 --- a/core/trino-main/src/test/java/io/trino/split/MockSplitSource.java +++ b/core/trino-main/src/test/java/io/trino/split/MockSplitSource.java @@ -56,9 +56,7 @@ public class MockSplitSource private SettableFuture> nextBatchFuture = COMPLETED_FUTURE; private int nextBatchMaxSize; - public MockSplitSource() - { - } + public MockSplitSource() {} public synchronized MockSplitSource setBatchSize(int batchSize) { @@ -129,9 +127,7 @@ public synchronized ListenableFuture getNextBatch(int maxSize) } @Override - public void close() - { - } + public void close() {} @Override public synchronized boolean isFinished() diff --git a/core/trino-main/src/test/java/io/trino/type/TestLongTimestampType.java b/core/trino-main/src/test/java/io/trino/type/TestLongTimestampType.java index 7998b6568200..427583e0c8a7 100644 --- a/core/trino-main/src/test/java/io/trino/type/TestLongTimestampType.java +++ b/core/trino-main/src/test/java/io/trino/type/TestLongTimestampType.java @@ -102,7 +102,5 @@ public void testNextValue() .isEmpty(); } - record MaxPrecision(int precision, LongTimestamp expectedMax) - { - } + record MaxPrecision(int precision, LongTimestamp expectedMax) {} } diff --git a/core/trino-server-rpm/src/test/java/io/trino/server/rpm/TestDummy.java b/core/trino-server-rpm/src/test/java/io/trino/server/rpm/TestDummy.java index f98ad46118fb..1060243e3bdb 100644 --- a/core/trino-server-rpm/src/test/java/io/trino/server/rpm/TestDummy.java +++ b/core/trino-server-rpm/src/test/java/io/trino/server/rpm/TestDummy.java @@ -18,7 +18,5 @@ public class TestDummy { @Test - public void dummyTest() - { - } + public void dummyTest() {} } diff --git a/core/trino-spi/src/main/java/io/trino/spi/block/BlockUtil.java b/core/trino-spi/src/main/java/io/trino/spi/block/BlockUtil.java index 5adb6c927ae5..20aff985df90 100644 --- a/core/trino-spi/src/main/java/io/trino/spi/block/BlockUtil.java +++ b/core/trino-spi/src/main/java/io/trino/spi/block/BlockUtil.java @@ -33,9 +33,7 @@ final class BlockUtil // Two additional positions are reserved for a spare null position and offset position static final int MAX_ARRAY_SIZE = Integer.MAX_VALUE - 8 - 2; - private BlockUtil() - { - } + private BlockUtil() {} static void checkArrayRange(int[] array, int offset, int length) { diff --git a/core/trino-spi/src/main/java/io/trino/spi/block/EncoderUtil.java b/core/trino-spi/src/main/java/io/trino/spi/block/EncoderUtil.java index 5f415a25e5c5..cdcd39ee2f24 100644 --- a/core/trino-spi/src/main/java/io/trino/spi/block/EncoderUtil.java +++ b/core/trino-spi/src/main/java/io/trino/spi/block/EncoderUtil.java @@ -23,9 +23,7 @@ final class EncoderUtil { - private EncoderUtil() - { - } + private EncoderUtil() {} /** * Append null values for the block as a stream of bits. diff --git a/core/trino-spi/src/main/java/io/trino/spi/connector/FixedSplitSource.java b/core/trino-spi/src/main/java/io/trino/spi/connector/FixedSplitSource.java index 7d35fc706f18..e626129a1c10 100644 --- a/core/trino-spi/src/main/java/io/trino/spi/connector/FixedSplitSource.java +++ b/core/trino-spi/src/main/java/io/trino/spi/connector/FixedSplitSource.java @@ -81,7 +81,5 @@ public Optional> getTableExecuteSplitsInfo() } @Override - public void close() - { - } + public void close() {} } diff --git a/core/trino-spi/src/main/java/io/trino/spi/connector/SchemaUtil.java b/core/trino-spi/src/main/java/io/trino/spi/connector/SchemaUtil.java index 3a45e5e85726..5a5089f93c9c 100644 --- a/core/trino-spi/src/main/java/io/trino/spi/connector/SchemaUtil.java +++ b/core/trino-spi/src/main/java/io/trino/spi/connector/SchemaUtil.java @@ -15,9 +15,7 @@ final class SchemaUtil { - private SchemaUtil() - { - } + private SchemaUtil() {} static String checkNotEmpty(String value, String name) { diff --git a/core/trino-spi/src/main/java/io/trino/spi/eventlistener/EventListener.java b/core/trino-spi/src/main/java/io/trino/spi/eventlistener/EventListener.java index 9044f75ed5dc..dc261e3e81fc 100644 --- a/core/trino-spi/src/main/java/io/trino/spi/eventlistener/EventListener.java +++ b/core/trino-spi/src/main/java/io/trino/spi/eventlistener/EventListener.java @@ -15,17 +15,11 @@ public interface EventListener { - default void queryCreated(QueryCreatedEvent queryCreatedEvent) - { - } + default void queryCreated(QueryCreatedEvent queryCreatedEvent) {} - default void queryCompleted(QueryCompletedEvent queryCompletedEvent) - { - } + default void queryCompleted(QueryCompletedEvent queryCompletedEvent) {} - default void splitCompleted(SplitCompletedEvent splitCompletedEvent) - { - } + default void splitCompleted(SplitCompletedEvent splitCompletedEvent) {} /** * Specify whether the plan included in QueryCompletedEvent should be anonymized or not @@ -40,7 +34,5 @@ default boolean requiresAnonymizedPlan() * threads, sockets, etc. After this method is called, * no methods will be called on the event listener. */ - default void shutdown() - { - } + default void shutdown() {} } diff --git a/core/trino-spi/src/main/java/io/trino/spi/metrics/Metrics.java b/core/trino-spi/src/main/java/io/trino/spi/metrics/Metrics.java index 8253ef167f3f..ad749aee7415 100644 --- a/core/trino-spi/src/main/java/io/trino/spi/metrics/Metrics.java +++ b/core/trino-spi/src/main/java/io/trino/spi/metrics/Metrics.java @@ -89,9 +89,7 @@ public static class Accumulator { private final Map>> groupedMetrics = new HashMap<>(); - private Accumulator() - { - } + private Accumulator() {} public Accumulator add(Metrics metrics) { diff --git a/core/trino-spi/src/main/java/io/trino/spi/type/TypeUtils.java b/core/trino-spi/src/main/java/io/trino/spi/type/TypeUtils.java index 7e5cd97a39ed..e1bd15e49797 100644 --- a/core/trino-spi/src/main/java/io/trino/spi/type/TypeUtils.java +++ b/core/trino-spi/src/main/java/io/trino/spi/type/TypeUtils.java @@ -32,9 +32,7 @@ public final class TypeUtils { public static final int NULL_HASH_CODE = 0; - private TypeUtils() - { - } + private TypeUtils() {} /** * Get the native value as an object in the value at {@code position} of {@code block}. diff --git a/lib/trino-filesystem-cache-alluxio/src/test/java/io/trino/filesystem/alluxio/TestFuzzAlluxioCacheFileSystem.java b/lib/trino-filesystem-cache-alluxio/src/test/java/io/trino/filesystem/alluxio/TestFuzzAlluxioCacheFileSystem.java index fd64558ec0ae..9bc483a86906 100644 --- a/lib/trino-filesystem-cache-alluxio/src/test/java/io/trino/filesystem/alluxio/TestFuzzAlluxioCacheFileSystem.java +++ b/lib/trino-filesystem-cache-alluxio/src/test/java/io/trino/filesystem/alluxio/TestFuzzAlluxioCacheFileSystem.java @@ -163,9 +163,7 @@ public Location tempLocation() } @Override - public void close() - { - } + public void close() {} } private static class TestAlluxioFileSystem diff --git a/lib/trino-filesystem-s3/src/main/java/io/trino/filesystem/s3/S3FileSystemStats.java b/lib/trino-filesystem-s3/src/main/java/io/trino/filesystem/s3/S3FileSystemStats.java index 3ddbc2aea058..a2604240ce70 100644 --- a/lib/trino-filesystem-s3/src/main/java/io/trino/filesystem/s3/S3FileSystemStats.java +++ b/lib/trino-filesystem-s3/src/main/java/io/trino/filesystem/s3/S3FileSystemStats.java @@ -217,9 +217,7 @@ else if (value.equals(SERVER_ERROR.toString())) { } @Override - public void close() - { - } + public void close() {} private AwsSdkV2ApiCallStats getApiCallStats(String operationName) { diff --git a/lib/trino-hdfs/src/test/java/io/trino/hdfs/s3/MockAmazonS3.java b/lib/trino-hdfs/src/test/java/io/trino/hdfs/s3/MockAmazonS3.java index 0f68f3ba9659..c8b011b3fdb6 100644 --- a/lib/trino-hdfs/src/test/java/io/trino/hdfs/s3/MockAmazonS3.java +++ b/lib/trino-hdfs/src/test/java/io/trino/hdfs/s3/MockAmazonS3.java @@ -213,7 +213,5 @@ public void abortMultipartUpload(AbortMultipartUploadRequest request) } @Override - public void shutdown() - { - } + public void shutdown() {} } diff --git a/lib/trino-hdfs/src/test/java/io/trino/hdfs/s3/TestTrinoS3FileSystem.java b/lib/trino-hdfs/src/test/java/io/trino/hdfs/s3/TestTrinoS3FileSystem.java index 9f69273f902c..23444224d8a3 100644 --- a/lib/trino-hdfs/src/test/java/io/trino/hdfs/s3/TestTrinoS3FileSystem.java +++ b/lib/trino-hdfs/src/test/java/io/trino/hdfs/s3/TestTrinoS3FileSystem.java @@ -799,9 +799,7 @@ public TestEncryptionMaterialsProvider() } @Override - public void refresh() - { - } + public void refresh() {} @Override public EncryptionMaterials getEncryptionMaterials(Map materialsDescription) diff --git a/lib/trino-metastore/src/main/java/io/trino/metastore/Storage.java b/lib/trino-metastore/src/main/java/io/trino/metastore/Storage.java index 91911def5962..149ce380fccb 100644 --- a/lib/trino-metastore/src/main/java/io/trino/metastore/Storage.java +++ b/lib/trino-metastore/src/main/java/io/trino/metastore/Storage.java @@ -142,9 +142,7 @@ public static class Builder private boolean skewed; private Map serdeParameters = ImmutableMap.of(); - private Builder() - { - } + private Builder() {} private Builder(Storage storage) { diff --git a/lib/trino-orc/src/main/java/io/trino/orc/reader/SliceDirectColumnReader.java b/lib/trino-orc/src/main/java/io/trino/orc/reader/SliceDirectColumnReader.java index cda63c3a9b3a..08b82d649bd4 100644 --- a/lib/trino-orc/src/main/java/io/trino/orc/reader/SliceDirectColumnReader.java +++ b/lib/trino-orc/src/main/java/io/trino/orc/reader/SliceDirectColumnReader.java @@ -287,9 +287,7 @@ public String toString() } @Override - public void close() - { - } + public void close() {} @Override public long getRetainedSizeInBytes() diff --git a/lib/trino-orc/src/main/java/io/trino/orc/reader/UuidColumnReader.java b/lib/trino-orc/src/main/java/io/trino/orc/reader/UuidColumnReader.java index 738f5f37bb74..b223c13b91e6 100644 --- a/lib/trino-orc/src/main/java/io/trino/orc/reader/UuidColumnReader.java +++ b/lib/trino-orc/src/main/java/io/trino/orc/reader/UuidColumnReader.java @@ -187,9 +187,7 @@ public String toString() } @Override - public void close() - { - } + public void close() {} @Override public long getRetainedSizeInBytes() diff --git a/lib/trino-orc/src/test/java/io/trino/orc/TestingOrcPredicate.java b/lib/trino-orc/src/test/java/io/trino/orc/TestingOrcPredicate.java index 1e1246b0960f..96d541d5249a 100644 --- a/lib/trino-orc/src/test/java/io/trino/orc/TestingOrcPredicate.java +++ b/lib/trino-orc/src/test/java/io/trino/orc/TestingOrcPredicate.java @@ -72,9 +72,7 @@ public final class TestingOrcPredicate public static final int ORC_STRIPE_SIZE = 30_000; public static final int ORC_ROW_GROUP_SIZE = 10_000; - private TestingOrcPredicate() - { - } + private TestingOrcPredicate() {} public static OrcPredicate createOrcPredicate(Type type, Iterable values) { diff --git a/lib/trino-orc/src/test/java/io/trino/orc/stream/TestDecimalStream.java b/lib/trino-orc/src/test/java/io/trino/orc/stream/TestDecimalStream.java index a1f05ed01044..709506ec21b1 100644 --- a/lib/trino-orc/src/test/java/io/trino/orc/stream/TestDecimalStream.java +++ b/lib/trino-orc/src/test/java/io/trino/orc/stream/TestDecimalStream.java @@ -307,8 +307,6 @@ public long getLastCheckpoint() } @Override - public void seekToCheckpoint(long checkpoint) - { - } + public void seekToCheckpoint(long checkpoint) {} } } diff --git a/lib/trino-parquet/src/main/java/io/trino/parquet/predicate/TupleDomainParquetPredicate.java b/lib/trino-parquet/src/main/java/io/trino/parquet/predicate/TupleDomainParquetPredicate.java index a881975a3186..a0154281af2e 100644 --- a/lib/trino-parquet/src/main/java/io/trino/parquet/predicate/TupleDomainParquetPredicate.java +++ b/lib/trino-parquet/src/main/java/io/trino/parquet/predicate/TupleDomainParquetPredicate.java @@ -780,9 +780,7 @@ public String toString() private static class ColumnIndexValueConverter { - private ColumnIndexValueConverter() - { - } + private ColumnIndexValueConverter() {} private Function getConverter(PrimitiveType primitiveType) { diff --git a/lib/trino-parquet/src/main/java/io/trino/parquet/reader/decoders/ByteBitUnpackers.java b/lib/trino-parquet/src/main/java/io/trino/parquet/reader/decoders/ByteBitUnpackers.java index d9d5397e2872..3c292fe054ab 100644 --- a/lib/trino-parquet/src/main/java/io/trino/parquet/reader/decoders/ByteBitUnpackers.java +++ b/lib/trino-parquet/src/main/java/io/trino/parquet/reader/decoders/ByteBitUnpackers.java @@ -55,9 +55,7 @@ public static ByteBitUnpacker getByteBitUnpacker(int bitWidth) return UNPACKERS[bitWidth - 1]; } - private ByteBitUnpackers() - { - } + private ByteBitUnpackers() {} private static final class Unpacker1 implements ByteBitUnpacker diff --git a/lib/trino-parquet/src/main/java/io/trino/parquet/reader/decoders/IntBitUnpackers.java b/lib/trino-parquet/src/main/java/io/trino/parquet/reader/decoders/IntBitUnpackers.java index e65418bd2190..656c9d273378 100644 --- a/lib/trino-parquet/src/main/java/io/trino/parquet/reader/decoders/IntBitUnpackers.java +++ b/lib/trino-parquet/src/main/java/io/trino/parquet/reader/decoders/IntBitUnpackers.java @@ -57,9 +57,7 @@ public static IntBitUnpacker getIntBitUnpacker(int bitWidth) return UNPACKERS[bitWidth]; } - private IntBitUnpackers() - { - } + private IntBitUnpackers() {} private static final class Unpacker0 implements IntBitUnpacker diff --git a/lib/trino-parquet/src/main/java/io/trino/parquet/reader/decoders/LongBitUnpackers.java b/lib/trino-parquet/src/main/java/io/trino/parquet/reader/decoders/LongBitUnpackers.java index 2a9da799ebdf..105ef5ba7d1b 100644 --- a/lib/trino-parquet/src/main/java/io/trino/parquet/reader/decoders/LongBitUnpackers.java +++ b/lib/trino-parquet/src/main/java/io/trino/parquet/reader/decoders/LongBitUnpackers.java @@ -91,9 +91,7 @@ public static LongBitUnpacker getLongBitUnpacker(int bitWidth) return UNPACKERS[bitWidth - 1]; } - private LongBitUnpackers() - { - } + private LongBitUnpackers() {} private static final class Unpacker1 implements LongBitUnpacker diff --git a/lib/trino-parquet/src/main/java/io/trino/parquet/reader/decoders/VectorIntBitUnpackers.java b/lib/trino-parquet/src/main/java/io/trino/parquet/reader/decoders/VectorIntBitUnpackers.java index 1e4595f9d8f5..c8aa8f39c8c6 100644 --- a/lib/trino-parquet/src/main/java/io/trino/parquet/reader/decoders/VectorIntBitUnpackers.java +++ b/lib/trino-parquet/src/main/java/io/trino/parquet/reader/decoders/VectorIntBitUnpackers.java @@ -59,9 +59,7 @@ public static IntBitUnpacker getVectorIntBitUnpacker(int bitWidth) return UNPACKERS[bitWidth]; } - private VectorIntBitUnpackers() - { - } + private VectorIntBitUnpackers() {} private static final class Unpacker0 implements IntBitUnpacker diff --git a/lib/trino-parquet/src/main/java/io/trino/parquet/writer/repdef/DefLevelWriterProvider.java b/lib/trino-parquet/src/main/java/io/trino/parquet/writer/repdef/DefLevelWriterProvider.java index 3eb3fe979f01..447f7275d364 100644 --- a/lib/trino-parquet/src/main/java/io/trino/parquet/writer/repdef/DefLevelWriterProvider.java +++ b/lib/trino-parquet/src/main/java/io/trino/parquet/writer/repdef/DefLevelWriterProvider.java @@ -30,9 +30,7 @@ interface DefinitionLevelWriter ValuesCount writeDefinitionLevels(); } - record ValuesCount(int totalValuesCount, int maxDefinitionLevelValuesCount) - { - } + record ValuesCount(int totalValuesCount, int maxDefinitionLevelValuesCount) {} static DefinitionLevelWriter getRootDefinitionLevelWriter(List defLevelWriterProviders, ColumnDescriptorValuesWriter encoder) { diff --git a/lib/trino-parquet/src/test/java/io/trino/parquet/reader/flat/BenchmarkFlatDefinitionLevelDecoder.java b/lib/trino-parquet/src/test/java/io/trino/parquet/reader/flat/BenchmarkFlatDefinitionLevelDecoder.java index c138af519bf7..1d1590574583 100644 --- a/lib/trino-parquet/src/test/java/io/trino/parquet/reader/flat/BenchmarkFlatDefinitionLevelDecoder.java +++ b/lib/trino-parquet/src/test/java/io/trino/parquet/reader/flat/BenchmarkFlatDefinitionLevelDecoder.java @@ -158,9 +158,7 @@ public byte[] getData(int size) return encoder.toBytes().toByteArray(); } - DataGenerator() - { - } + DataGenerator() {} } public static void main(String[] args) diff --git a/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/TemporaryTables.java b/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/TemporaryTables.java index e2270d416d72..2cd3fbc73a5b 100644 --- a/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/TemporaryTables.java +++ b/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/TemporaryTables.java @@ -43,7 +43,5 @@ public static String generateTemporaryTableName(ConnectorSession session) return generateTemporaryTableName(session.getQueryId()); } - private TemporaryTables() - { - } + private TemporaryTables() {} } diff --git a/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/aggregation/AggregateFunctionPatterns.java b/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/aggregation/AggregateFunctionPatterns.java index 57fe94a72daf..c0380178be65 100644 --- a/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/aggregation/AggregateFunctionPatterns.java +++ b/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/aggregation/AggregateFunctionPatterns.java @@ -99,9 +99,7 @@ public Stream accept(Object object, Captures captures, C context) } @Override - public void accept(PatternVisitor patternVisitor) - { - } + public void accept(PatternVisitor patternVisitor) {} }; } } diff --git a/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/authentication/KerberosTicketUtils.java b/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/authentication/KerberosTicketUtils.java index 18c453362634..1319cfe2b015 100644 --- a/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/authentication/KerberosTicketUtils.java +++ b/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/authentication/KerberosTicketUtils.java @@ -23,9 +23,7 @@ public final class KerberosTicketUtils { private static final float TICKET_RENEW_WINDOW = 0.80f; - private KerberosTicketUtils() - { - } + private KerberosTicketUtils() {} public static KerberosTicket getTicketGrantingTicket(Subject subject) { diff --git a/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/security/FileBasedAccessControl.java b/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/security/FileBasedAccessControl.java index b0cb827d5f0b..ea43e5de875a 100644 --- a/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/security/FileBasedAccessControl.java +++ b/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/security/FileBasedAccessControl.java @@ -189,9 +189,7 @@ public void checkCanSetSchemaAuthorization(ConnectorSecurityContext context, Str } @Override - public void checkCanShowSchemas(ConnectorSecurityContext context) - { - } + public void checkCanShowSchemas(ConnectorSecurityContext context) {} @Override public Set filterSchemas(ConnectorSecurityContext context, Set schemaNames) @@ -650,9 +648,7 @@ public void checkCanExecuteProcedure(ConnectorSecurityContext context, SchemaRou } @Override - public void checkCanExecuteTableProcedure(ConnectorSecurityContext context, SchemaTableName tableName, String procedure) - { - } + public void checkCanExecuteTableProcedure(ConnectorSecurityContext context, SchemaTableName tableName, String procedure) {} @Override public boolean canExecuteFunction(ConnectorSecurityContext context, SchemaRoutineName function) diff --git a/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/security/FileBasedSystemAccessControl.java b/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/security/FileBasedSystemAccessControl.java index 0ba4ff1d2ead..53a42f958d73 100644 --- a/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/security/FileBasedSystemAccessControl.java +++ b/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/security/FileBasedSystemAccessControl.java @@ -994,9 +994,7 @@ public boolean canCreateViewWithExecuteFunction(SystemSecurityContext systemSecu } @Override - public void checkCanExecuteTableProcedure(SystemSecurityContext systemSecurityContext, CatalogSchemaTableName table, String procedure) - { - } + public void checkCanExecuteTableProcedure(SystemSecurityContext systemSecurityContext, CatalogSchemaTableName table, String procedure) {} @Override public void checkCanShowFunctions(SystemSecurityContext context, CatalogSchemaName schema) diff --git a/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/security/ReadOnlyAccessControl.java b/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/security/ReadOnlyAccessControl.java index 0803a719ed50..fa59bfd5e44f 100644 --- a/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/security/ReadOnlyAccessControl.java +++ b/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/security/ReadOnlyAccessControl.java @@ -52,9 +52,7 @@ public class ReadOnlyAccessControl implements ConnectorAccessControl { @Override - public void checkCanShowSchemas(ConnectorSecurityContext context) - { - } + public void checkCanShowSchemas(ConnectorSecurityContext context) {} @Override public Set filterSchemas(ConnectorSecurityContext context, Set schemaNames) @@ -75,14 +73,10 @@ public void checkCanDropColumn(ConnectorSecurityContext context, SchemaTableName } @Override - public void checkCanShowCreateSchema(ConnectorSecurityContext context, String schemaName) - { - } + public void checkCanShowCreateSchema(ConnectorSecurityContext context, String schemaName) {} @Override - public void checkCanShowCreateTable(ConnectorSecurityContext context, SchemaTableName tableName) - { - } + public void checkCanShowCreateTable(ConnectorSecurityContext context, SchemaTableName tableName) {} @Override public void checkCanCreateTable(ConnectorSecurityContext context, SchemaTableName tableName, Map properties) @@ -121,9 +115,7 @@ public void checkCanSetViewComment(ConnectorSecurityContext context, SchemaTable } @Override - public void checkCanShowTables(ConnectorSecurityContext context, String schemaName) - { - } + public void checkCanShowTables(ConnectorSecurityContext context, String schemaName) {} @Override public void checkCanSetColumnComment(ConnectorSecurityContext context, SchemaTableName tableName) diff --git a/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/security/ReadOnlySystemAccessControl.java b/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/security/ReadOnlySystemAccessControl.java index 042e5a867b0a..454b7f6e6ef1 100644 --- a/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/security/ReadOnlySystemAccessControl.java +++ b/lib/trino-plugin-toolkit/src/main/java/io/trino/plugin/base/security/ReadOnlySystemAccessControl.java @@ -57,19 +57,13 @@ public SystemAccessControl create(Map config) } @Override - public void checkCanSetUser(Optional principal, String userName) - { - } + public void checkCanSetUser(Optional principal, String userName) {} @Override - public void checkCanExecuteQuery(Identity identity, QueryId queryId) - { - } + public void checkCanExecuteQuery(Identity identity, QueryId queryId) {} @Override - public void checkCanViewQueryOwnedBy(Identity identity, Identity queryOwner) - { - } + public void checkCanViewQueryOwnedBy(Identity identity, Identity queryOwner) {} @Override public Collection filterViewQueryOwnedBy(Identity identity, Collection queryOwners) @@ -78,14 +72,10 @@ public Collection filterViewQueryOwnedBy(Identity identity, Collection } @Override - public void checkCanSetSystemSessionProperty(Identity identity, QueryId queryId, String propertyName) - { - } + public void checkCanSetSystemSessionProperty(Identity identity, QueryId queryId, String propertyName) {} @Override - public void checkCanSelectFromColumns(SystemSecurityContext context, CatalogSchemaTableName table, Set columns) - { - } + public void checkCanSelectFromColumns(SystemSecurityContext context, CatalogSchemaTableName table, Set columns) {} @Override public boolean canAccessCatalog(SystemSecurityContext context, String catalogName) @@ -94,14 +84,10 @@ public boolean canAccessCatalog(SystemSecurityContext context, String catalogNam } @Override - public void checkCanSetCatalogSessionProperty(SystemSecurityContext context, String catalogName, String propertyName) - { - } + public void checkCanSetCatalogSessionProperty(SystemSecurityContext context, String catalogName, String propertyName) {} @Override - public void checkCanCreateViewWithSelectFromColumns(SystemSecurityContext context, CatalogSchemaTableName table, Set columns) - { - } + public void checkCanCreateViewWithSelectFromColumns(SystemSecurityContext context, CatalogSchemaTableName table, Set columns) {} @Override public Set filterCatalogs(SystemSecurityContext context, Set catalogs) @@ -122,9 +108,7 @@ public Set filterTables(SystemSecurityContext context, String c } @Override - public void checkCanShowColumns(SystemSecurityContext context, CatalogSchemaTableName table) - { - } + public void checkCanShowColumns(SystemSecurityContext context, CatalogSchemaTableName table) {} @Override public Set filterColumns(SystemSecurityContext context, CatalogSchemaTableName tableName, Set columns) @@ -139,24 +123,16 @@ public Map> filterColumns(SystemSecurityContext con } @Override - public void checkCanShowSchemas(SystemSecurityContext context, String catalogName) - { - } + public void checkCanShowSchemas(SystemSecurityContext context, String catalogName) {} @Override - public void checkCanShowTables(SystemSecurityContext context, CatalogSchemaName schema) - { - } + public void checkCanShowTables(SystemSecurityContext context, CatalogSchemaName schema) {} @Override - public void checkCanShowRoles(SystemSecurityContext context) - { - } + public void checkCanShowRoles(SystemSecurityContext context) {} @Override - public void checkCanShowCurrentRoles(SystemSecurityContext context) - { - } + public void checkCanShowCurrentRoles(SystemSecurityContext context) {} @Override public boolean canExecuteFunction(SystemSecurityContext systemSecurityContext, CatalogSchemaRoutineName functionName) @@ -176,9 +152,7 @@ private static boolean isSystemBuiltinSchema(CatalogSchemaRoutineName functionNa } @Override - public void checkCanShowFunctions(SystemSecurityContext context, CatalogSchemaName schema) - { - } + public void checkCanShowFunctions(SystemSecurityContext context, CatalogSchemaName schema) {} @Override public Set filterFunctions(SystemSecurityContext context, String catalogName, Set functionNames) diff --git a/plugin/trino-blackhole/src/main/java/io/trino/plugin/blackhole/BlackHoleMetadata.java b/plugin/trino-blackhole/src/main/java/io/trino/plugin/blackhole/BlackHoleMetadata.java index 23c233ff88df..ece7a0f39afc 100644 --- a/plugin/trino-blackhole/src/main/java/io/trino/plugin/blackhole/BlackHoleMetadata.java +++ b/plugin/trino-blackhole/src/main/java/io/trino/plugin/blackhole/BlackHoleMetadata.java @@ -136,9 +136,7 @@ public ConnectorTableHandle beginStatisticsCollection(ConnectorSession session, } @Override - public void finishStatisticsCollection(ConnectorSession session, ConnectorTableHandle tableHandle, Collection computedStatistics) - { - } + public void finishStatisticsCollection(ConnectorSession session, ConnectorTableHandle tableHandle, Collection computedStatistics) {} @Override public ConnectorTableMetadata getTableMetadata(ConnectorSession session, ConnectorTableHandle tableHandle) diff --git a/plugin/trino-cassandra/src/main/java/io/trino/plugin/cassandra/CassandraRecordCursor.java b/plugin/trino-cassandra/src/main/java/io/trino/plugin/cassandra/CassandraRecordCursor.java index 6743937f1b75..e7ae13e5be2d 100644 --- a/plugin/trino-cassandra/src/main/java/io/trino/plugin/cassandra/CassandraRecordCursor.java +++ b/plugin/trino-cassandra/src/main/java/io/trino/plugin/cassandra/CassandraRecordCursor.java @@ -64,9 +64,7 @@ public boolean advanceNextPosition() } @Override - public void close() - { - } + public void close() {} @Override public boolean getBoolean(int i) diff --git a/plugin/trino-clickhouse/src/main/java/io/trino/plugin/clickhouse/ClickHouseConnectionFactory.java b/plugin/trino-clickhouse/src/main/java/io/trino/plugin/clickhouse/ClickHouseConnectionFactory.java index 36638eb7a6fa..bdb6515f7251 100644 --- a/plugin/trino-clickhouse/src/main/java/io/trino/plugin/clickhouse/ClickHouseConnectionFactory.java +++ b/plugin/trino-clickhouse/src/main/java/io/trino/plugin/clickhouse/ClickHouseConnectionFactory.java @@ -49,19 +49,13 @@ protected Connection delegate() // Since https://github.com/ClickHouse/clickhouse-jdbc/commit/259682eaa8d5af741e4df57ca745f21ae3ae574c setAutoCommit(false) will fail @Override - public void setAutoCommit(boolean autoCommit) - { - } + public void setAutoCommit(boolean autoCommit) {} @Override - public void commit() - { - } + public void commit() {} @Override - public void rollback() - { - } + public void rollback() {} }; } diff --git a/plugin/trino-clickhouse/src/test/java/io/trino/plugin/clickhouse/TestClickHouseConnectorTest.java b/plugin/trino-clickhouse/src/test/java/io/trino/plugin/clickhouse/TestClickHouseConnectorTest.java index 74439b2a99e1..565ecba0fbe0 100644 --- a/plugin/trino-clickhouse/src/test/java/io/trino/plugin/clickhouse/TestClickHouseConnectorTest.java +++ b/plugin/trino-clickhouse/src/test/java/io/trino/plugin/clickhouse/TestClickHouseConnectorTest.java @@ -168,9 +168,7 @@ protected String createTableSqlForAddingAndDroppingColumn(String tableName, Stri @Test @Disabled @Override - public void testRenameColumnName() - { - } + public void testRenameColumnName() {} @Override protected Optional filterColumnNameTestData(String columnName) diff --git a/plugin/trino-elasticsearch/src/main/java/io/trino/plugin/elasticsearch/CountQueryPageSource.java b/plugin/trino-elasticsearch/src/main/java/io/trino/plugin/elasticsearch/CountQueryPageSource.java index 00e1bb9ef58f..aa68fbbf2060 100644 --- a/plugin/trino-elasticsearch/src/main/java/io/trino/plugin/elasticsearch/CountQueryPageSource.java +++ b/plugin/trino-elasticsearch/src/main/java/io/trino/plugin/elasticsearch/CountQueryPageSource.java @@ -87,7 +87,5 @@ public long getMemoryUsage() } @Override - public void close() - { - } + public void close() {} } diff --git a/plugin/trino-example-http/src/main/java/io/trino/plugin/example/ExampleRecordCursor.java b/plugin/trino-example-http/src/main/java/io/trino/plugin/example/ExampleRecordCursor.java index 5a2278f76b6a..99c310509141 100644 --- a/plugin/trino-example-http/src/main/java/io/trino/plugin/example/ExampleRecordCursor.java +++ b/plugin/trino-example-http/src/main/java/io/trino/plugin/example/ExampleRecordCursor.java @@ -154,7 +154,5 @@ private void checkFieldType(int field, Type expected) } @Override - public void close() - { - } + public void close() {} } diff --git a/plugin/trino-exchange-filesystem/src/main/java/io/trino/plugin/exchange/filesystem/local/LocalFileSystemExchangeStorage.java b/plugin/trino-exchange-filesystem/src/main/java/io/trino/plugin/exchange/filesystem/local/LocalFileSystemExchangeStorage.java index dadfce41898c..8cbcd7516f9d 100644 --- a/plugin/trino-exchange-filesystem/src/main/java/io/trino/plugin/exchange/filesystem/local/LocalFileSystemExchangeStorage.java +++ b/plugin/trino-exchange-filesystem/src/main/java/io/trino/plugin/exchange/filesystem/local/LocalFileSystemExchangeStorage.java @@ -131,9 +131,7 @@ public int getWriteBufferSize() } @Override - public void close() - { - } + public void close() {} @ThreadSafe private static class LocalExchangeStorageReader diff --git a/plugin/trino-exchange-hdfs/src/main/java/io/trino/plugin/exchange/hdfs/HadoopFileSystemExchangeStorage.java b/plugin/trino-exchange-hdfs/src/main/java/io/trino/plugin/exchange/hdfs/HadoopFileSystemExchangeStorage.java index fa508e811b5d..122cbd06edeb 100644 --- a/plugin/trino-exchange-hdfs/src/main/java/io/trino/plugin/exchange/hdfs/HadoopFileSystemExchangeStorage.java +++ b/plugin/trino-exchange-hdfs/src/main/java/io/trino/plugin/exchange/hdfs/HadoopFileSystemExchangeStorage.java @@ -141,9 +141,7 @@ public int getWriteBufferSize() } @Override - public void close() - { - } + public void close() {} private static Configuration newEmptyConfiguration() { diff --git a/plugin/trino-google-sheets/src/main/java/io/trino/plugin/google/sheets/SheetsRecordCursor.java b/plugin/trino-google-sheets/src/main/java/io/trino/plugin/google/sheets/SheetsRecordCursor.java index bf32b2efe8a2..3320466b94cd 100644 --- a/plugin/trino-google-sheets/src/main/java/io/trino/plugin/google/sheets/SheetsRecordCursor.java +++ b/plugin/trino-google-sheets/src/main/java/io/trino/plugin/google/sheets/SheetsRecordCursor.java @@ -154,7 +154,5 @@ private void checkFieldType(int field, Type expected) } @Override - public void close() - { - } + public void close() {} } diff --git a/plugin/trino-hive/src/main/java/io/trino/plugin/hive/coercions/DoubleToVarcharCoercers.java b/plugin/trino-hive/src/main/java/io/trino/plugin/hive/coercions/DoubleToVarcharCoercers.java index 83c5a8709392..d44641812012 100644 --- a/plugin/trino-hive/src/main/java/io/trino/plugin/hive/coercions/DoubleToVarcharCoercers.java +++ b/plugin/trino-hive/src/main/java/io/trino/plugin/hive/coercions/DoubleToVarcharCoercers.java @@ -28,9 +28,7 @@ public final class DoubleToVarcharCoercers { - private DoubleToVarcharCoercers() - { - } + private DoubleToVarcharCoercers() {} public static TypeCoercer createDoubleToVarcharCoercer(VarcharType toType, boolean isOrcFile) { diff --git a/plugin/trino-hive/src/main/java/io/trino/plugin/hive/coercions/VarcharToIntegralNumericCoercers.java b/plugin/trino-hive/src/main/java/io/trino/plugin/hive/coercions/VarcharToIntegralNumericCoercers.java index 47630593a327..7f17de30847d 100644 --- a/plugin/trino-hive/src/main/java/io/trino/plugin/hive/coercions/VarcharToIntegralNumericCoercers.java +++ b/plugin/trino-hive/src/main/java/io/trino/plugin/hive/coercions/VarcharToIntegralNumericCoercers.java @@ -30,9 +30,7 @@ public final class VarcharToIntegralNumericCoercers { - private VarcharToIntegralNumericCoercers() - { - } + private VarcharToIntegralNumericCoercers() {} public static TypeCoercer createVarcharToIntegerNumberCoercer(VarcharType fromType, Type toType, boolean isOrcFile) { diff --git a/plugin/trino-hive/src/main/java/io/trino/plugin/hive/security/SqlStandardAccessControl.java b/plugin/trino-hive/src/main/java/io/trino/plugin/hive/security/SqlStandardAccessControl.java index 51ae942207dc..a8cf4eb942c5 100644 --- a/plugin/trino-hive/src/main/java/io/trino/plugin/hive/security/SqlStandardAccessControl.java +++ b/plugin/trino-hive/src/main/java/io/trino/plugin/hive/security/SqlStandardAccessControl.java @@ -163,9 +163,7 @@ public void checkCanSetSchemaAuthorization(ConnectorSecurityContext context, Str } @Override - public void checkCanShowSchemas(ConnectorSecurityContext context) - { - } + public void checkCanShowSchemas(ConnectorSecurityContext context) {} @Override public Set filterSchemas(ConnectorSecurityContext context, Set schemaNames) @@ -247,9 +245,7 @@ public void checkCanSetColumnComment(ConnectorSecurityContext context, SchemaTab } @Override - public void checkCanShowTables(ConnectorSecurityContext context, String schemaName) - { - } + public void checkCanShowTables(ConnectorSecurityContext context, String schemaName) {} @Override public Set filterTables(ConnectorSecurityContext context, Set tableNames) @@ -571,19 +567,13 @@ public void checkCanShowRoles(ConnectorSecurityContext context) } @Override - public void checkCanShowCurrentRoles(ConnectorSecurityContext context) - { - } + public void checkCanShowCurrentRoles(ConnectorSecurityContext context) {} @Override - public void checkCanShowRoleGrants(ConnectorSecurityContext context) - { - } + public void checkCanShowRoleGrants(ConnectorSecurityContext context) {} @Override - public void checkCanExecuteProcedure(ConnectorSecurityContext context, SchemaRoutineName procedure) - { - } + public void checkCanExecuteProcedure(ConnectorSecurityContext context, SchemaRoutineName procedure) {} @Override public void checkCanExecuteTableProcedure(ConnectorSecurityContext context, SchemaTableName tableName, String procedure) @@ -606,9 +596,7 @@ public boolean canCreateViewWithExecuteFunction(ConnectorSecurityContext context } @Override - public void checkCanShowFunctions(ConnectorSecurityContext context, String schemaName) - { - } + public void checkCanShowFunctions(ConnectorSecurityContext context, String schemaName) {} @Override public Set filterFunctions(ConnectorSecurityContext context, Set functionNames) diff --git a/plugin/trino-hive/src/main/java/io/trino/plugin/hive/util/HiveUtil.java b/plugin/trino-hive/src/main/java/io/trino/plugin/hive/util/HiveUtil.java index 0ec3ca3e21ed..a4cf437aa3b4 100644 --- a/plugin/trino-hive/src/main/java/io/trino/plugin/hive/util/HiveUtil.java +++ b/plugin/trino-hive/src/main/java/io/trino/plugin/hive/util/HiveUtil.java @@ -184,9 +184,7 @@ public static String splitError(Throwable t, Location location, long start, long HIVE_DATE_PARSER = new DateTimeFormatterBuilder().append(timestampWithoutTimeZonePrinter, timestampWithoutTimeZoneParser).toFormatter().withZoneUTC(); } - private HiveUtil() - { - } + private HiveUtil() {} public static Optional getInputFormatName(Map schema) { diff --git a/plugin/trino-hive/src/main/java/io/trino/plugin/hive/util/HiveWriteUtils.java b/plugin/trino-hive/src/main/java/io/trino/plugin/hive/util/HiveWriteUtils.java index 9e08a183b890..8744cc44283c 100644 --- a/plugin/trino-hive/src/main/java/io/trino/plugin/hive/util/HiveWriteUtils.java +++ b/plugin/trino-hive/src/main/java/io/trino/plugin/hive/util/HiveWriteUtils.java @@ -90,9 +90,7 @@ public final class HiveWriteUtils .optionalStart().appendFraction(ChronoField.NANO_OF_SECOND, 0, 9, true).optionalEnd() .toFormatter(); - private HiveWriteUtils() - { - } + private HiveWriteUtils() {} public static List createPartitionValues(List partitionColumnTypes, Page partitionColumns, int position) { diff --git a/plugin/trino-hive/src/test/java/io/trino/plugin/hive/TestHiveSplitSource.java b/plugin/trino-hive/src/test/java/io/trino/plugin/hive/TestHiveSplitSource.java index 95f629147881..f378c55d1088 100644 --- a/plugin/trino-hive/src/test/java/io/trino/plugin/hive/TestHiveSplitSource.java +++ b/plugin/trino-hive/src/test/java/io/trino/plugin/hive/TestHiveSplitSource.java @@ -289,14 +289,10 @@ private static class TestingHiveSplitLoader implements HiveSplitLoader { @Override - public void start(HiveSplitSource splitSource) - { - } + public void start(HiveSplitSource splitSource) {} @Override - public void stop() - { - } + public void stop() {} } private static class TestSplit diff --git a/plugin/trino-hive/src/test/java/io/trino/plugin/hive/fs/TestTransactionScopeCachingDirectoryLister.java b/plugin/trino-hive/src/test/java/io/trino/plugin/hive/fs/TestTransactionScopeCachingDirectoryLister.java index a6eefeae1126..2621fec56cfc 100644 --- a/plugin/trino-hive/src/test/java/io/trino/plugin/hive/fs/TestTransactionScopeCachingDirectoryLister.java +++ b/plugin/trino-hive/src/test/java/io/trino/plugin/hive/fs/TestTransactionScopeCachingDirectoryLister.java @@ -186,14 +186,10 @@ public int getListCount() } @Override - public void invalidate(Partition partition) - { - } + public void invalidate(Partition partition) {} @Override - public void invalidate(Table table) - { - } + public void invalidate(Table table) {} } static RemoteIterator throwingRemoteIterator(List files, boolean throwException) diff --git a/plugin/trino-hive/src/test/java/org/apache/parquet/hadoop/DisabledMemoryManager.java b/plugin/trino-hive/src/test/java/org/apache/parquet/hadoop/DisabledMemoryManager.java index ac9a9b65ee67..656ead702dea 100644 --- a/plugin/trino-hive/src/test/java/org/apache/parquet/hadoop/DisabledMemoryManager.java +++ b/plugin/trino-hive/src/test/java/org/apache/parquet/hadoop/DisabledMemoryManager.java @@ -22,12 +22,8 @@ public DisabledMemoryManager() } @Override - synchronized void addWriter(InternalParquetRecordWriter writer, Long allocation) - { - } + synchronized void addWriter(InternalParquetRecordWriter writer, Long allocation) {} @Override - synchronized void removeWriter(InternalParquetRecordWriter writer) - { - } + synchronized void removeWriter(InternalParquetRecordWriter writer) {} } diff --git a/plugin/trino-hudi/src/main/java/io/trino/plugin/hudi/compaction/HudiCompactionOperation.java b/plugin/trino-hudi/src/main/java/io/trino/plugin/hudi/compaction/HudiCompactionOperation.java index 8f4fa2051d4c..f6da0b070c09 100644 --- a/plugin/trino-hudi/src/main/java/io/trino/plugin/hudi/compaction/HudiCompactionOperation.java +++ b/plugin/trino-hudi/src/main/java/io/trino/plugin/hudi/compaction/HudiCompactionOperation.java @@ -171,9 +171,7 @@ public static class Builder private Map metrics; private String bootstrapFilePath; - private Builder() - { - } + private Builder() {} public HudiCompactionOperation.Builder setBaseInstantTime(String baseInstantTime) { diff --git a/plugin/trino-hudi/src/main/java/io/trino/plugin/hudi/files/FSUtils.java b/plugin/trino-hudi/src/main/java/io/trino/plugin/hudi/files/FSUtils.java index 6d6422a86da7..e97962e38d7c 100644 --- a/plugin/trino-hudi/src/main/java/io/trino/plugin/hudi/files/FSUtils.java +++ b/plugin/trino-hudi/src/main/java/io/trino/plugin/hudi/files/FSUtils.java @@ -25,9 +25,7 @@ public final class FSUtils { - private FSUtils() - { - } + private FSUtils() {} public static final Pattern LOG_FILE_PATTERN = Pattern.compile("\\.(.*)_(.*)\\.(.*)\\.([0-9]*)(_(([0-9]*)-([0-9]*)-([0-9]*)))?"); diff --git a/plugin/trino-hudi/src/main/java/io/trino/plugin/hudi/timeline/HudiActiveTimeline.java b/plugin/trino-hudi/src/main/java/io/trino/plugin/hudi/timeline/HudiActiveTimeline.java index afd1b15e51c5..93b0ab8a41c1 100644 --- a/plugin/trino-hudi/src/main/java/io/trino/plugin/hudi/timeline/HudiActiveTimeline.java +++ b/plugin/trino-hudi/src/main/java/io/trino/plugin/hudi/timeline/HudiActiveTimeline.java @@ -58,9 +58,7 @@ public HudiActiveTimeline(HudiTableMetaClient metaClient) } @Deprecated - public HudiActiveTimeline() - { - } + public HudiActiveTimeline() {} @Override public Optional getInstantDetails(HudiInstant instant) diff --git a/plugin/trino-hudi/src/main/java/io/trino/plugin/hudi/timeline/HudiDefaultTimeline.java b/plugin/trino-hudi/src/main/java/io/trino/plugin/hudi/timeline/HudiDefaultTimeline.java index 09381a8a7f79..1ad6309aa962 100644 --- a/plugin/trino-hudi/src/main/java/io/trino/plugin/hudi/timeline/HudiDefaultTimeline.java +++ b/plugin/trino-hudi/src/main/java/io/trino/plugin/hudi/timeline/HudiDefaultTimeline.java @@ -44,9 +44,7 @@ public void setInstants(List instants) this.instants = ImmutableList.copyOf(instants); } - public HudiDefaultTimeline() - { - } + public HudiDefaultTimeline() {} @Override public HudiTimeline filterCompletedInstants() diff --git a/plugin/trino-kafka-event-listener/src/test/java/io/trino/plugin/eventlistener/kafka/TestUtils.java b/plugin/trino-kafka-event-listener/src/test/java/io/trino/plugin/eventlistener/kafka/TestUtils.java index 17a1de7b574e..70c8264fbd6b 100644 --- a/plugin/trino-kafka-event-listener/src/test/java/io/trino/plugin/eventlistener/kafka/TestUtils.java +++ b/plugin/trino-kafka-event-listener/src/test/java/io/trino/plugin/eventlistener/kafka/TestUtils.java @@ -60,9 +60,7 @@ public final class TestUtils static final QueryCreatedEvent queryCreatedEvent; static final QueryCompletedEvent queryCompletedEvent; - private TestUtils() - { - } + private TestUtils() {} static { queryIOMetadata = new QueryIOMetadata(Collections.emptyList(), Optional.empty()); diff --git a/plugin/trino-kudu/src/main/java/io/trino/plugin/kudu/KuduConnectorFactory.java b/plugin/trino-kudu/src/main/java/io/trino/plugin/kudu/KuduConnectorFactory.java index cde54af3b6e6..70c22d7ba76c 100755 --- a/plugin/trino-kudu/src/main/java/io/trino/plugin/kudu/KuduConnectorFactory.java +++ b/plugin/trino-kudu/src/main/java/io/trino/plugin/kudu/KuduConnectorFactory.java @@ -28,9 +28,7 @@ public class KuduConnectorFactory implements ConnectorFactory { - public KuduConnectorFactory() - { - } + public KuduConnectorFactory() {} @Override public String getName() diff --git a/plugin/trino-kudu/src/main/java/io/trino/plugin/kudu/KuduPageSink.java b/plugin/trino-kudu/src/main/java/io/trino/plugin/kudu/KuduPageSink.java index 0c71ee27c2e4..c802041b74d3 100644 --- a/plugin/trino-kudu/src/main/java/io/trino/plugin/kudu/KuduPageSink.java +++ b/plugin/trino-kudu/src/main/java/io/trino/plugin/kudu/KuduPageSink.java @@ -272,7 +272,5 @@ public CompletableFuture> finish() } @Override - public void abort() - { - } + public void abort() {} } diff --git a/plugin/trino-kudu/src/main/java/io/trino/plugin/kudu/KuduSecurityModule.java b/plugin/trino-kudu/src/main/java/io/trino/plugin/kudu/KuduSecurityModule.java index 1d875eec5c20..fcf5a5599fad 100644 --- a/plugin/trino-kudu/src/main/java/io/trino/plugin/kudu/KuduSecurityModule.java +++ b/plugin/trino-kudu/src/main/java/io/trino/plugin/kudu/KuduSecurityModule.java @@ -57,9 +57,7 @@ private static class NoneAuthenticationModule extends AbstractConfigurationAwareModule { @Override - public void setup(Binder binder) - { - } + public void setup(Binder binder) {} @Provides @Singleton diff --git a/plugin/trino-kudu/src/test/java/io/trino/plugin/kudu/TestKuduConnectorTest.java b/plugin/trino-kudu/src/test/java/io/trino/plugin/kudu/TestKuduConnectorTest.java index 69b55b719ce6..48d6ab37471b 100644 --- a/plugin/trino-kudu/src/test/java/io/trino/plugin/kudu/TestKuduConnectorTest.java +++ b/plugin/trino-kudu/src/test/java/io/trino/plugin/kudu/TestKuduConnectorTest.java @@ -153,16 +153,12 @@ public void testRenameTableToUnqualifiedPreservesSchema() @Test @Disabled @Override - public void testAddAndDropColumnName() - { - } + public void testAddAndDropColumnName() {} @Test @Disabled @Override - public void testRenameColumnName() - { - } + public void testRenameColumnName() {} @Override protected MaterializedResult getDescribeOrdersResult() diff --git a/plugin/trino-memory/src/main/java/io/trino/plugin/memory/MemoryPageSinkProvider.java b/plugin/trino-memory/src/main/java/io/trino/plugin/memory/MemoryPageSinkProvider.java index 3526b2303767..f930e33047bf 100644 --- a/plugin/trino-memory/src/main/java/io/trino/plugin/memory/MemoryPageSinkProvider.java +++ b/plugin/trino-memory/src/main/java/io/trino/plugin/memory/MemoryPageSinkProvider.java @@ -121,8 +121,6 @@ public CompletableFuture> finish() } @Override - public void abort() - { - } + public void abort() {} } } diff --git a/plugin/trino-ml/src/main/java/io/trino/plugin/ml/MLFunctions.java b/plugin/trino-ml/src/main/java/io/trino/plugin/ml/MLFunctions.java index b1e1a1fedcdb..266ffd4fb208 100644 --- a/plugin/trino-ml/src/main/java/io/trino/plugin/ml/MLFunctions.java +++ b/plugin/trino-ml/src/main/java/io/trino/plugin/ml/MLFunctions.java @@ -36,9 +36,7 @@ public final class MLFunctions private static final NonEvictableCache MODEL_CACHE = buildNonEvictableCache(CacheBuilder.newBuilder().maximumSize(5)); private static final String MAP_BIGINT_DOUBLE = "map(bigint,double)"; - private MLFunctions() - { - } + private MLFunctions() {} @ScalarFunction("classify") @SqlType(StandardTypes.VARCHAR) diff --git a/plugin/trino-ml/src/main/java/io/trino/plugin/ml/ModelUtils.java b/plugin/trino-ml/src/main/java/io/trino/plugin/ml/ModelUtils.java index 197975fb3545..30bfe3c8934f 100644 --- a/plugin/trino-ml/src/main/java/io/trino/plugin/ml/ModelUtils.java +++ b/plugin/trino-ml/src/main/java/io/trino/plugin/ml/ModelUtils.java @@ -67,9 +67,7 @@ public final class ModelUtils MODEL_SERIALIZATION_IDS = builder.build(); } - private ModelUtils() - { - } + private ModelUtils() {} /** * Serializes the model using the following format diff --git a/plugin/trino-mongodb/src/main/java/io/trino/plugin/mongodb/MongoPageSink.java b/plugin/trino-mongodb/src/main/java/io/trino/plugin/mongodb/MongoPageSink.java index 750dbeedbd07..06496aac7b09 100644 --- a/plugin/trino-mongodb/src/main/java/io/trino/plugin/mongodb/MongoPageSink.java +++ b/plugin/trino-mongodb/src/main/java/io/trino/plugin/mongodb/MongoPageSink.java @@ -283,7 +283,5 @@ public CompletableFuture> finish() } @Override - public void abort() - { - } + public void abort() {} } diff --git a/plugin/trino-opensearch/src/main/java/io/trino/plugin/opensearch/CountQueryPageSource.java b/plugin/trino-opensearch/src/main/java/io/trino/plugin/opensearch/CountQueryPageSource.java index b01cc0da6aba..aeacfd87e313 100644 --- a/plugin/trino-opensearch/src/main/java/io/trino/plugin/opensearch/CountQueryPageSource.java +++ b/plugin/trino-opensearch/src/main/java/io/trino/plugin/opensearch/CountQueryPageSource.java @@ -86,7 +86,5 @@ public long getMemoryUsage() } @Override - public void close() - { - } + public void close() {} } diff --git a/plugin/trino-phoenix5/src/main/java/io/trino/plugin/phoenix5/PhoenixMetadata.java b/plugin/trino-phoenix5/src/main/java/io/trino/plugin/phoenix5/PhoenixMetadata.java index 18538ad1ff22..035064ae8f1c 100644 --- a/plugin/trino-phoenix5/src/main/java/io/trino/plugin/phoenix5/PhoenixMetadata.java +++ b/plugin/trino-phoenix5/src/main/java/io/trino/plugin/phoenix5/PhoenixMetadata.java @@ -363,8 +363,7 @@ public void finishMerge( List sourceTableHandles, Collection fragments, Collection computedStatistics) - { - } + {} @Override public void truncateTable(ConnectorSession session, ConnectorTableHandle tableHandle) diff --git a/plugin/trino-phoenix5/src/test/java/io/trino/plugin/phoenix5/PhoenixQueryRunner.java b/plugin/trino-phoenix5/src/test/java/io/trino/plugin/phoenix5/PhoenixQueryRunner.java index 0d27b0f2e6ac..df1fdbc254de 100644 --- a/plugin/trino-phoenix5/src/test/java/io/trino/plugin/phoenix5/PhoenixQueryRunner.java +++ b/plugin/trino-phoenix5/src/test/java/io/trino/plugin/phoenix5/PhoenixQueryRunner.java @@ -49,9 +49,7 @@ public final class PhoenixQueryRunner private static final Logger LOG = Logger.get(PhoenixQueryRunner.class); private static final String TPCH_SCHEMA = "tpch"; - private PhoenixQueryRunner() - { - } + private PhoenixQueryRunner() {} public static Builder builder(TestingPhoenixServer phoenixServer) { diff --git a/plugin/trino-pinot/src/main/java/io/trino/plugin/pinot/auth/PinotAuthenticationModule.java b/plugin/trino-pinot/src/main/java/io/trino/plugin/pinot/auth/PinotAuthenticationModule.java index d3eede22fd9e..8c9b827efd71 100644 --- a/plugin/trino-pinot/src/main/java/io/trino/plugin/pinot/auth/PinotAuthenticationModule.java +++ b/plugin/trino-pinot/src/main/java/io/trino/plugin/pinot/auth/PinotAuthenticationModule.java @@ -60,9 +60,7 @@ private static class PinotNoneControllerAuthenticationProviderModule implements Module { @Override - public void configure(Binder binder) - { - } + public void configure(Binder binder) {} @Provides @Singleton @@ -76,9 +74,7 @@ private static class PinotNoneBrokerAuthenticationProviderModule implements Module { @Override - public void configure(Binder binder) - { - } + public void configure(Binder binder) {} @Provides @Singleton diff --git a/plugin/trino-pinot/src/main/java/io/trino/plugin/pinot/decoders/DecoderFactory.java b/plugin/trino-pinot/src/main/java/io/trino/plugin/pinot/decoders/DecoderFactory.java index 52a52578ebcf..1b1819ab7174 100644 --- a/plugin/trino-pinot/src/main/java/io/trino/plugin/pinot/decoders/DecoderFactory.java +++ b/plugin/trino-pinot/src/main/java/io/trino/plugin/pinot/decoders/DecoderFactory.java @@ -34,9 +34,7 @@ public class DecoderFactory { - private DecoderFactory() - { - } + private DecoderFactory() {} public static Decoder createDecoder(Type type) { diff --git a/plugin/trino-pinot/src/main/java/io/trino/plugin/pinot/query/DynamicTableBuilder.java b/plugin/trino-pinot/src/main/java/io/trino/plugin/pinot/query/DynamicTableBuilder.java index bef425ea183a..678e6a3f7f9c 100755 --- a/plugin/trino-pinot/src/main/java/io/trino/plugin/pinot/query/DynamicTableBuilder.java +++ b/plugin/trino-pinot/src/main/java/io/trino/plugin/pinot/query/DynamicTableBuilder.java @@ -65,9 +65,7 @@ public final class DynamicTableBuilder public static final String REALTIME_SUFFIX = "_REALTIME"; private static final Set NON_NULL_ON_EMPTY_AGGREGATIONS = EnumSet.of(COUNT, DISTINCTCOUNT, DISTINCTCOUNTHLL); - private DynamicTableBuilder() - { - } + private DynamicTableBuilder() {} public static DynamicTable buildFromPql(PinotMetadata pinotMetadata, SchemaTableName schemaTableName, PinotClient pinotClient, PinotTypeConverter typeConverter) { diff --git a/plugin/trino-pinot/src/main/java/io/trino/plugin/pinot/query/DynamicTablePqlExtractor.java b/plugin/trino-pinot/src/main/java/io/trino/plugin/pinot/query/DynamicTablePqlExtractor.java index 3eb3a2a02046..e5c6aa3f07e0 100755 --- a/plugin/trino-pinot/src/main/java/io/trino/plugin/pinot/query/DynamicTablePqlExtractor.java +++ b/plugin/trino-pinot/src/main/java/io/trino/plugin/pinot/query/DynamicTablePqlExtractor.java @@ -27,9 +27,7 @@ public final class DynamicTablePqlExtractor { - private DynamicTablePqlExtractor() - { - } + private DynamicTablePqlExtractor() {} public static String extractPql(DynamicTable table, TupleDomain tupleDomain) { diff --git a/plugin/trino-pinot/src/main/java/io/trino/plugin/pinot/query/PinotQueryBuilder.java b/plugin/trino-pinot/src/main/java/io/trino/plugin/pinot/query/PinotQueryBuilder.java index 864e71db4766..ebdfb66431da 100755 --- a/plugin/trino-pinot/src/main/java/io/trino/plugin/pinot/query/PinotQueryBuilder.java +++ b/plugin/trino-pinot/src/main/java/io/trino/plugin/pinot/query/PinotQueryBuilder.java @@ -49,9 +49,7 @@ public final class PinotQueryBuilder { - private PinotQueryBuilder() - { - } + private PinotQueryBuilder() {} public static String generatePql(PinotTableHandle tableHandle, List columnHandles, Optional tableNameSuffix, Optional timePredicate, int limitForSegmentQueries) { diff --git a/plugin/trino-pinot/src/test/java/io/trino/plugin/pinot/MetadataUtil.java b/plugin/trino-pinot/src/test/java/io/trino/plugin/pinot/MetadataUtil.java index ea1d4d37aa90..b7489bf3705e 100755 --- a/plugin/trino-pinot/src/test/java/io/trino/plugin/pinot/MetadataUtil.java +++ b/plugin/trino-pinot/src/test/java/io/trino/plugin/pinot/MetadataUtil.java @@ -45,9 +45,7 @@ public class MetadataUtil public static final JsonCodec BROKER_RESPONSE_NATIVE_JSON_CODEC; public static final String TEST_TABLE = "airlineStats"; - private MetadataUtil() - { - } + private MetadataUtil() {} public static final class TestingTypeDeserializer extends FromStringDeserializer diff --git a/plugin/trino-redis/src/main/java/io/trino/plugin/redis/RedisRecordCursor.java b/plugin/trino-redis/src/main/java/io/trino/plugin/redis/RedisRecordCursor.java index 448ea3a10d4c..dafcee12f7ea 100644 --- a/plugin/trino-redis/src/main/java/io/trino/plugin/redis/RedisRecordCursor.java +++ b/plugin/trino-redis/src/main/java/io/trino/plugin/redis/RedisRecordCursor.java @@ -331,9 +331,7 @@ private void checkFieldType(int field, Class expected) } @Override - public void close() - { - } + public void close() {} private ScanParams setScanParams() { diff --git a/plugin/trino-redshift/src/test/java/io/trino/plugin/redshift/TestRedshiftAutomaticJoinPushdown.java b/plugin/trino-redshift/src/test/java/io/trino/plugin/redshift/TestRedshiftAutomaticJoinPushdown.java index a77a784d9ecb..7c6dd07ed080 100644 --- a/plugin/trino-redshift/src/test/java/io/trino/plugin/redshift/TestRedshiftAutomaticJoinPushdown.java +++ b/plugin/trino-redshift/src/test/java/io/trino/plugin/redshift/TestRedshiftAutomaticJoinPushdown.java @@ -37,9 +37,7 @@ protected QueryRunner createQueryRunner() @Test @Override @Disabled - public void testJoinPushdownWithEmptyStatsInitially() - { - } + public void testJoinPushdownWithEmptyStatsInitially() {} @Override protected void gatherStats(String tableName) diff --git a/plugin/trino-resource-group-managers/src/main/java/io/trino/plugin/resourcegroups/db/FlywayMigration.java b/plugin/trino-resource-group-managers/src/main/java/io/trino/plugin/resourcegroups/db/FlywayMigration.java index b96cd938de5d..64a25292e131 100644 --- a/plugin/trino-resource-group-managers/src/main/java/io/trino/plugin/resourcegroups/db/FlywayMigration.java +++ b/plugin/trino-resource-group-managers/src/main/java/io/trino/plugin/resourcegroups/db/FlywayMigration.java @@ -23,9 +23,7 @@ public class FlywayMigration { private static final Logger log = Logger.get(FlywayMigration.class); - private FlywayMigration() - { - } + private FlywayMigration() {} private static String getLocation(String configDbUrl) { diff --git a/plugin/trino-teradata-functions/src/main/java/io/trino/plugin/teradata/functions/TeradataDateFunctions.java b/plugin/trino-teradata-functions/src/main/java/io/trino/plugin/teradata/functions/TeradataDateFunctions.java index b7e3b774c6be..61c8dabdd201 100644 --- a/plugin/trino-teradata-functions/src/main/java/io/trino/plugin/teradata/functions/TeradataDateFunctions.java +++ b/plugin/trino-teradata-functions/src/main/java/io/trino/plugin/teradata/functions/TeradataDateFunctions.java @@ -57,9 +57,7 @@ public final class TeradataDateFunctions } } - private TeradataDateFunctions() - { - } + private TeradataDateFunctions() {} @Description("Converts a string to a DATE data type") @ScalarFunction("to_date") diff --git a/plugin/trino-thrift-api/src/main/java/io/trino/plugin/thrift/api/datatypes/TrinoThriftTypeUtils.java b/plugin/trino-thrift-api/src/main/java/io/trino/plugin/thrift/api/datatypes/TrinoThriftTypeUtils.java index 7d7d2125388d..9edeacc6fcb9 100644 --- a/plugin/trino-thrift-api/src/main/java/io/trino/plugin/thrift/api/datatypes/TrinoThriftTypeUtils.java +++ b/plugin/trino-thrift-api/src/main/java/io/trino/plugin/thrift/api/datatypes/TrinoThriftTypeUtils.java @@ -25,9 +25,7 @@ final class TrinoThriftTypeUtils { - private TrinoThriftTypeUtils() - { - } + private TrinoThriftTypeUtils() {} public static TrinoThriftBlock fromLongBasedBlock(Block block, Type type, BiFunction result) { diff --git a/plugin/trino-thrift-testing-server/src/main/java/io/trino/plugin/thrift/server/ListBasedRecordSet.java b/plugin/trino-thrift-testing-server/src/main/java/io/trino/plugin/thrift/server/ListBasedRecordSet.java index b30b00b55623..3f1acc14dc63 100644 --- a/plugin/trino-thrift-testing-server/src/main/java/io/trino/plugin/thrift/server/ListBasedRecordSet.java +++ b/plugin/trino-thrift-testing-server/src/main/java/io/trino/plugin/thrift/server/ListBasedRecordSet.java @@ -104,9 +104,7 @@ public long getReadTimeNanos() } @Override - public void close() - { - } + public void close() {} @Override public boolean getBoolean(int field) diff --git a/plugin/trino-tpch/src/main/java/io/trino/plugin/tpch/TpchTables.java b/plugin/trino-tpch/src/main/java/io/trino/plugin/tpch/TpchTables.java index 549f62a2a642..c8f67320c509 100644 --- a/plugin/trino-tpch/src/main/java/io/trino/plugin/tpch/TpchTables.java +++ b/plugin/trino-tpch/src/main/java/io/trino/plugin/tpch/TpchTables.java @@ -29,9 +29,7 @@ public final class TpchTables { - private TpchTables() - { - } + private TpchTables() {} public static List getTableColumns(String tableName, DecimalTypeMapping decimalTypeMapping) { diff --git a/testing/trino-product-tests-launcher/src/main/java/io/trino/tests/product/launcher/env/ContainerListener.java b/testing/trino-product-tests-launcher/src/main/java/io/trino/tests/product/launcher/env/ContainerListener.java index 4a68e506bd04..245ca67057b3 100644 --- a/testing/trino-product-tests-launcher/src/main/java/io/trino/tests/product/launcher/env/ContainerListener.java +++ b/testing/trino-product-tests-launcher/src/main/java/io/trino/tests/product/launcher/env/ContainerListener.java @@ -17,19 +17,11 @@ public interface ContainerListener { - default void containerStarting(DockerContainer container, InspectContainerResponse response) - { - } + default void containerStarting(DockerContainer container, InspectContainerResponse response) {} - default void containerStarted(DockerContainer container, InspectContainerResponse containerInfo) - { - } + default void containerStarted(DockerContainer container, InspectContainerResponse containerInfo) {} - default void containerStopping(DockerContainer container, InspectContainerResponse response) - { - } + default void containerStopping(DockerContainer container, InspectContainerResponse response) {} - default void containerStopped(DockerContainer container, InspectContainerResponse response) - { - } + default void containerStopped(DockerContainer container, InspectContainerResponse response) {} } diff --git a/testing/trino-product-tests-launcher/src/main/java/io/trino/tests/product/launcher/env/EnvironmentListener.java b/testing/trino-product-tests-launcher/src/main/java/io/trino/tests/product/launcher/env/EnvironmentListener.java index 5731f3a44c1e..7e3435b0f687 100644 --- a/testing/trino-product-tests-launcher/src/main/java/io/trino/tests/product/launcher/env/EnvironmentListener.java +++ b/testing/trino-product-tests-launcher/src/main/java/io/trino/tests/product/launcher/env/EnvironmentListener.java @@ -44,25 +44,15 @@ public interface EnvironmentListener { Logger log = Logger.get(EnvironmentListener.class); - EnvironmentListener NOOP = new EnvironmentListener() - { - }; + EnvironmentListener NOOP = new EnvironmentListener() {}; - default void environmentStarting(Environment environment) - { - } + default void environmentStarting(Environment environment) {} - default void environmentStarted(Environment environment) - { - } + default void environmentStarted(Environment environment) {} - default void environmentStopped(Environment environment) - { - } + default void environmentStopped(Environment environment) {} - default void environmentStopping(Environment environment) - { - } + default void environmentStopping(Environment environment) {} static void tryInvokeListener(FailsafeExecutor executor, Consumer call, EnvironmentListener... listeners) { diff --git a/testing/trino-product-tests/src/main/java/io/trino/tests/product/TpcTestUtils.java b/testing/trino-product-tests/src/main/java/io/trino/tests/product/TpcTestUtils.java index ac1db384fc0b..7450507bfb7e 100644 --- a/testing/trino-product-tests/src/main/java/io/trino/tests/product/TpcTestUtils.java +++ b/testing/trino-product-tests/src/main/java/io/trino/tests/product/TpcTestUtils.java @@ -71,9 +71,7 @@ public final class TpcTestUtils "orders", "lineitem"}; - private TpcTestUtils() - { - } + private TpcTestUtils() {} public static void createTpchDataset(String catalog) { diff --git a/testing/trino-product-tests/src/main/java/io/trino/tests/product/TpchTableResults.java b/testing/trino-product-tests/src/main/java/io/trino/tests/product/TpchTableResults.java index 81a6767619dd..e9ef80335dff 100644 --- a/testing/trino-product-tests/src/main/java/io/trino/tests/product/TpchTableResults.java +++ b/testing/trino-product-tests/src/main/java/io/trino/tests/product/TpchTableResults.java @@ -21,7 +21,5 @@ public final class TpchTableResults { public static final SqlResultDescriptor TRINO_NATION_RESULT = sqlResultDescriptorForResource("table-results/trino-nation.result"); - private TpchTableResults() - { - } + private TpchTableResults() {} } diff --git a/testing/trino-product-tests/src/main/java/io/trino/tests/product/hive/HiveTableDefinitions.java b/testing/trino-product-tests/src/main/java/io/trino/tests/product/hive/HiveTableDefinitions.java index 64f72884f23f..3bfa19b1ddc4 100644 --- a/testing/trino-product-tests/src/main/java/io/trino/tests/product/hive/HiveTableDefinitions.java +++ b/testing/trino-product-tests/src/main/java/io/trino/tests/product/hive/HiveTableDefinitions.java @@ -81,7 +81,5 @@ private static String partitionDataFileResource(String key, String partition) return format("io/trino/tests/product/hive/data/partitioned_nation_%s/nation_region_%s.textfile", key, partition); } - private HiveTableDefinitions() - { - } + private HiveTableDefinitions() {} } diff --git a/testing/trino-product-tests/src/main/java/io/trino/tests/product/hive/util/TableLocationUtils.java b/testing/trino-product-tests/src/main/java/io/trino/tests/product/hive/util/TableLocationUtils.java index 5155f81ecdc9..37a49d8fb433 100644 --- a/testing/trino-product-tests/src/main/java/io/trino/tests/product/hive/util/TableLocationUtils.java +++ b/testing/trino-product-tests/src/main/java/io/trino/tests/product/hive/util/TableLocationUtils.java @@ -25,9 +25,7 @@ public final class TableLocationUtils { private static final Pattern ACID_LOCATION_PATTERN = Pattern.compile("(.*)/delta_[^/]+"); - private TableLocationUtils() - { - } + private TableLocationUtils() {} public static String getTableLocation(String tableName) { diff --git a/testing/trino-testing-kafka/src/main/java/io/trino/testing/kafka/JsonSerializer.java b/testing/trino-testing-kafka/src/main/java/io/trino/testing/kafka/JsonSerializer.java index fe832c81a04f..6981bacc2b61 100644 --- a/testing/trino-testing-kafka/src/main/java/io/trino/testing/kafka/JsonSerializer.java +++ b/testing/trino-testing-kafka/src/main/java/io/trino/testing/kafka/JsonSerializer.java @@ -25,9 +25,7 @@ public class JsonSerializer private final ObjectMapper objectMapper = new ObjectMapper(); @Override - public void configure(Map props, boolean isKey) - { - } + public void configure(Map props, boolean isKey) {} @Override public byte[] serialize(String topic, Object data) @@ -41,7 +39,5 @@ public byte[] serialize(String topic, Object data) } @Override - public void close() - { - } + public void close() {} } diff --git a/testing/trino-testing-services/src/main/java/io/trino/testng/services/ReportInnerTestClasses.java b/testing/trino-testing-services/src/main/java/io/trino/testng/services/ReportInnerTestClasses.java index 09f4f3e870ff..6ac132df7fac 100644 --- a/testing/trino-testing-services/src/main/java/io/trino/testng/services/ReportInnerTestClasses.java +++ b/testing/trino-testing-services/src/main/java/io/trino/testng/services/ReportInnerTestClasses.java @@ -61,7 +61,5 @@ private void reportInnerTestClasses(ITestClass testClass) } @Override - public void onAfterClass(ITestClass iTestClass) - { - } + public void onAfterClass(ITestClass iTestClass) {} } diff --git a/testing/trino-testing/src/main/java/io/trino/testing/QueryAssertions.java b/testing/trino-testing/src/main/java/io/trino/testing/QueryAssertions.java index c240b9863498..81f620546ef3 100644 --- a/testing/trino-testing/src/main/java/io/trino/testing/QueryAssertions.java +++ b/testing/trino-testing/src/main/java/io/trino/testing/QueryAssertions.java @@ -52,9 +52,7 @@ public final class QueryAssertions { private static final Logger log = Logger.get(QueryAssertions.class); - private QueryAssertions() - { - } + private QueryAssertions() {} public static void assertUpdate(QueryRunner queryRunner, Session session, @Language("SQL") String sql, OptionalLong count, Optional> planAssertion) { diff --git a/testing/trino-testing/src/main/java/io/trino/testing/ResultsSession.java b/testing/trino-testing/src/main/java/io/trino/testing/ResultsSession.java index 8073351d1e1a..2d99f072fd55 100644 --- a/testing/trino-testing/src/main/java/io/trino/testing/ResultsSession.java +++ b/testing/trino-testing/src/main/java/io/trino/testing/ResultsSession.java @@ -40,9 +40,7 @@ default void setStatementStats(StatementStats statementStats) {} void addResults(QueryStatusInfo statusInfo, ResultRows access); - default void setQueryDataEncoding(String encoding) - { - } + default void setQueryDataEncoding(String encoding) {} T build(Map setSessionProperties, Set resetSessionProperties); } diff --git a/testing/trino-testing/src/main/java/io/trino/testing/tpch/MaterializedTupleRecordSet.java b/testing/trino-testing/src/main/java/io/trino/testing/tpch/MaterializedTupleRecordSet.java index 71ce38190170..c75ae21d72ee 100644 --- a/testing/trino-testing/src/main/java/io/trino/testing/tpch/MaterializedTupleRecordSet.java +++ b/testing/trino-testing/src/main/java/io/trino/testing/tpch/MaterializedTupleRecordSet.java @@ -128,8 +128,6 @@ public boolean isNull(int field) } @Override - public void close() - { - } + public void close() {} } } diff --git a/testing/trino-tests/src/test/java/io/trino/execution/AbstractTestCoordinatorDynamicFiltering.java b/testing/trino-tests/src/test/java/io/trino/execution/AbstractTestCoordinatorDynamicFiltering.java index 358c1d64efd2..f1e6a5ae40db 100644 --- a/testing/trino-tests/src/test/java/io/trino/execution/AbstractTestCoordinatorDynamicFiltering.java +++ b/testing/trino-tests/src/test/java/io/trino/execution/AbstractTestCoordinatorDynamicFiltering.java @@ -587,9 +587,7 @@ public CompletableFuture getNextBatch(int maxSize) } @Override - public void close() - { - } + public void close() {} @Override public boolean isFinished() diff --git a/testing/trino-tests/src/test/java/io/trino/execution/TestDeprecatedFunctionWarning.java b/testing/trino-tests/src/test/java/io/trino/execution/TestDeprecatedFunctionWarning.java index 84d6d304dee2..9059a2ca1a91 100644 --- a/testing/trino-tests/src/test/java/io/trino/execution/TestDeprecatedFunctionWarning.java +++ b/testing/trino-tests/src/test/java/io/trino/execution/TestDeprecatedFunctionWarning.java @@ -240,14 +240,10 @@ public static boolean deprecatedParametericScalaLong(@SqlNullable @SqlType("T") public static class TestDeprecatedAggregation { @InputFunction - public static void input(LongAndDoubleState state, @SqlType(StandardTypes.DOUBLE) double value) - { - } + public static void input(LongAndDoubleState state, @SqlType(StandardTypes.DOUBLE) double value) {} @CombineFunction - public static void combine(LongAndDoubleState state, LongAndDoubleState otherState) - { - } + public static void combine(LongAndDoubleState state, LongAndDoubleState otherState) {} @OutputFunction(StandardTypes.DOUBLE) public static void output(LongAndDoubleState state, BlockBuilder out) @@ -260,14 +256,10 @@ public static void output(LongAndDoubleState state, BlockBuilder out) public static class TestNonDeprecatedAggregation { @InputFunction - public static void input(LongAndDoubleState state, @SqlType(StandardTypes.DOUBLE) double value) - { - } + public static void input(LongAndDoubleState state, @SqlType(StandardTypes.DOUBLE) double value) {} @CombineFunction - public static void combine(LongAndDoubleState state, LongAndDoubleState otherState) - { - } + public static void combine(LongAndDoubleState state, LongAndDoubleState otherState) {} @OutputFunction(StandardTypes.DOUBLE) public static void output(LongAndDoubleState state, BlockBuilder out) diff --git a/testing/trino-tests/src/test/java/io/trino/security/TestAccessControlTableRedirection.java b/testing/trino-tests/src/test/java/io/trino/security/TestAccessControlTableRedirection.java index a6e87ebd1cbe..9824a7298248 100644 --- a/testing/trino-tests/src/test/java/io/trino/security/TestAccessControlTableRedirection.java +++ b/testing/trino-tests/src/test/java/io/trino/security/TestAccessControlTableRedirection.java @@ -95,14 +95,10 @@ protected QueryRunner createQueryRunner() .toInstance(new DisabledSystemSecurityMetadata() { @Override - public void grantTablePrivileges(Session session, QualifiedObjectName tableName, Set privileges, TrinoPrincipal grantee, boolean grantOption) - { - } + public void grantTablePrivileges(Session session, QualifiedObjectName tableName, Set privileges, TrinoPrincipal grantee, boolean grantOption) {} @Override - public void revokeTablePrivileges(Session session, QualifiedObjectName tableName, Set privileges, TrinoPrincipal grantee, boolean grantOption) - { - } + public void revokeTablePrivileges(Session session, QualifiedObjectName tableName, Set privileges, TrinoPrincipal grantee, boolean grantOption) {} @Override public boolean roleExists(Session session, String role) @@ -111,14 +107,10 @@ public boolean roleExists(Session session, String role) } @Override - public void setTableOwner(Session session, CatalogSchemaTableName table, TrinoPrincipal principal) - { - } + public void setTableOwner(Session session, CatalogSchemaTableName table, TrinoPrincipal principal) {} @Override - public void denyTablePrivileges(Session session, QualifiedObjectName tableName, Set privileges, TrinoPrincipal grantee) - { - } + public void denyTablePrivileges(Session session, QualifiedObjectName tableName, Set privileges, TrinoPrincipal grantee) {} }); }) .build(); diff --git a/testing/trino-tests/src/test/java/io/trino/tests/TestQueryPlanDeterminism.java b/testing/trino-tests/src/test/java/io/trino/tests/TestQueryPlanDeterminism.java index 28ed9a58c06f..106cd9db852e 100644 --- a/testing/trino-tests/src/test/java/io/trino/tests/TestQueryPlanDeterminism.java +++ b/testing/trino-tests/src/test/java/io/trino/tests/TestQueryPlanDeterminism.java @@ -182,29 +182,19 @@ protected void assertQueryFails(Session session, @Language("SQL") String sql, @L } @Override - protected void assertAccessAllowed(@Language("SQL") String sql, TestingPrivilege... deniedPrivileges) - { - } + protected void assertAccessAllowed(@Language("SQL") String sql, TestingPrivilege... deniedPrivileges) {} @Override - protected void assertAccessAllowed(Session session, @Language("SQL") String sql, TestingPrivilege... deniedPrivileges) - { - } + protected void assertAccessAllowed(Session session, @Language("SQL") String sql, TestingPrivilege... deniedPrivileges) {} @Override - protected void assertAccessDenied(@Language("SQL") String sql, @Language("RegExp") String exceptionsMessageRegExp, TestingPrivilege... deniedPrivileges) - { - } + protected void assertAccessDenied(@Language("SQL") String sql, @Language("RegExp") String exceptionsMessageRegExp, TestingPrivilege... deniedPrivileges) {} @Override - protected void assertAccessDenied(Session session, @Language("SQL") String sql, @Language("RegExp") String exceptionsMessageRegExp, TestingPrivilege... deniedPrivileges) - { - } + protected void assertAccessDenied(Session session, @Language("SQL") String sql, @Language("RegExp") String exceptionsMessageRegExp, TestingPrivilege... deniedPrivileges) {} @Override - protected void assertTableColumnNames(String tableName, String... columnNames) - { - } + protected void assertTableColumnNames(String tableName, String... columnNames) {} @Override protected MaterializedResult computeExpected(@Language("SQL") String sql, List resultTypes)