From acf144717bd85d2486cc33fbb0e3622b06c66717 Mon Sep 17 00:00:00 2001 From: Duo Zhang Date: Tue, 19 Jul 2022 09:59:22 +0800 Subject: [PATCH] HBASE-27220 Apply the spotless format change in HBASE-27208 to our code base Signed-off-by: Andrew Purtell --- .../hbase/io/asyncfs/AsyncFSOutput.java | 4 +- .../hbase/util/RecoverLeaseFSUtils.java | 4 +- .../balancer/FavoredStochasticBalancer.java | 4 +- .../hadoop/hbase/CatalogFamilyFormat.java | 4 +- .../hadoop/hbase/ClientMetaTableAccessor.java | 4 +- .../org/apache/hadoop/hbase/ClusterId.java | 8 +- .../apache/hadoop/hbase/ClusterMetrics.java | 32 ++--- .../hadoop/hbase/CoprocessorEnvironment.java | 14 +-- .../hadoop/hbase/HBaseServerException.java | 4 +- .../apache/hadoop/hbase/RegionMetrics.java | 92 ++++---------- .../apache/hadoop/hbase/ServerMetrics.java | 48 ++------ .../java/org/apache/hadoop/hbase/Size.java | 4 +- .../org/apache/hadoop/hbase/UserMetrics.java | 24 +--- .../org/apache/hadoop/hbase/client/Admin.java | 8 +- .../apache/hadoop/hbase/client/Append.java | 4 +- .../hadoop/hbase/client/AsyncAdmin.java | 24 +--- .../hadoop/hbase/client/CheckAndMutate.java | 36 ++---- .../hbase/client/CheckAndMutateResult.java | 8 +- .../hbase/client/ClientIdGenerator.java | 4 +- .../hbase/client/ColumnFamilyDescriptor.java | 96 ++++----------- .../hadoop/hbase/client/Connection.java | 8 +- .../client/ConnectionRegistryFactory.java | 4 +- .../hbase/client/CoprocessorDescriptor.java | 14 +-- .../apache/hadoop/hbase/client/Increment.java | 4 +- .../hadoop/hbase/client/MultiResponse.java | 8 +- .../hbase/client/MutableRegionInfo.java | 20 ++- .../apache/hadoop/hbase/client/Mutation.java | 24 +--- .../hadoop/hbase/client/NonceGenerator.java | 4 +- .../org/apache/hadoop/hbase/client/Query.java | 12 +- .../hadoop/hbase/client/RegionInfo.java | 66 +++------- .../hbase/client/RegionReplicaUtil.java | 4 +- .../hbase/client/RequestController.java | 8 +- .../apache/hadoop/hbase/client/Result.java | 4 +- .../hadoop/hbase/client/ResultScanner.java | 4 +- .../org/apache/hadoop/hbase/client/Row.java | 4 +- .../apache/hadoop/hbase/client/RowAccess.java | 8 +- .../hadoop/hbase/client/RowMutations.java | 4 +- .../org/apache/hadoop/hbase/client/Scan.java | 68 +++------- .../hadoop/hbase/client/TableDescriptor.java | 12 +- .../hbase/client/TableDescriptorBuilder.java | 20 +-- .../hadoop/hbase/client/TableState.java | 28 ++--- .../client/backoff/ClientBackoffPolicy.java | 4 +- .../PreemptiveFastFailException.java | 20 +-- .../hbase/filter/BigDecimalComparator.java | 4 +- .../hadoop/hbase/filter/BinaryComparator.java | 4 +- .../filter/BinaryComponentComparator.java | 4 +- .../hbase/filter/BinaryPrefixComparator.java | 4 +- .../hadoop/hbase/filter/BitComparator.java | 8 +- .../hbase/filter/ColumnCountGetFilter.java | 4 +- .../hbase/filter/ColumnPaginationFilter.java | 4 +- .../hbase/filter/ColumnPrefixFilter.java | 4 +- .../hbase/filter/ColumnRangeFilter.java | 28 ++--- .../hbase/filter/ColumnValueFilter.java | 16 +-- .../hadoop/hbase/filter/CompareFilter.java | 8 +- .../hbase/filter/DependentColumnFilter.java | 16 +-- .../hadoop/hbase/filter/FamilyFilter.java | 4 +- .../hadoop/hbase/filter/FilterList.java | 4 +- .../hbase/filter/FirstKeyOnlyFilter.java | 8 +- .../hadoop/hbase/filter/FuzzyRowFilter.java | 4 +- .../hbase/filter/InclusiveStopFilter.java | 4 +- .../hadoop/hbase/filter/KeyOnlyFilter.java | 4 +- .../hadoop/hbase/filter/LongComparator.java | 4 +- .../hbase/filter/MultiRowRangeFilter.java | 12 +- .../filter/MultipleColumnPrefixFilter.java | 4 +- .../hadoop/hbase/filter/NullComparator.java | 4 +- .../hadoop/hbase/filter/PageFilter.java | 4 +- .../hadoop/hbase/filter/PrefixFilter.java | 4 +- .../hadoop/hbase/filter/QualifierFilter.java | 4 +- .../hadoop/hbase/filter/RandomRowFilter.java | 8 +- .../hbase/filter/RegexStringComparator.java | 4 +- .../apache/hadoop/hbase/filter/RowFilter.java | 4 +- .../SingleColumnValueExcludeFilter.java | 4 +- .../hbase/filter/SingleColumnValueFilter.java | 16 +-- .../hadoop/hbase/filter/SkipFilter.java | 4 +- .../hbase/filter/SubstringComparator.java | 4 +- .../hadoop/hbase/filter/TimestampsFilter.java | 8 +- .../hadoop/hbase/filter/ValueFilter.java | 4 +- .../hadoop/hbase/filter/WhileMatchFilter.java | 4 +- .../hadoop/hbase/ipc/HBaseRpcController.java | 12 +- .../hbase/ipc/HBaseRpcControllerImpl.java | 4 +- .../org/apache/hadoop/hbase/ipc/IPCUtil.java | 8 +- .../hbase/ipc/RemoteWithExtrasException.java | 16 +-- .../hadoop/hbase/protobuf/ProtobufMagic.java | 4 +- .../hadoop/hbase/quotas/QuotaFilter.java | 12 +- .../hbase/quotas/SpaceQuotaSnapshot.java | 4 +- .../hbase/quotas/SpaceQuotaSnapshotView.java | 4 +- .../hbase/security/access/Permission.java | 2 +- .../security/visibility/CellVisibility.java | 4 +- .../hbase/shaded/protobuf/ProtobufUtil.java | 8 +- .../shaded/protobuf/RequestConverter.java | 4 +- .../snapshot/HBaseSnapshotException.java | 4 +- .../hadoop/hbase/zookeeper/ZNodePaths.java | 12 +- .../apache/hadoop/hbase/ArrayBackedTag.java | 16 +-- .../hadoop/hbase/ByteBufferExtendedCell.java | 40 ++---- .../java/org/apache/hadoop/hbase/Cell.java | 36 ++---- .../apache/hadoop/hbase/CellScannable.java | 4 +- .../org/apache/hadoop/hbase/CellScanner.java | 4 +- .../org/apache/hadoop/hbase/CellUtil.java | 12 +- .../org/apache/hadoop/hbase/ChoreService.java | 20 +-- .../org/apache/hadoop/hbase/ExtendedCell.java | 12 +- .../hadoop/hbase/HBaseConfiguration.java | 4 +- .../hadoop/hbase/HDFSBlocksDistribution.java | 20 +-- .../org/apache/hadoop/hbase/KeyValue.java | 94 ++++---------- .../apache/hadoop/hbase/PrivateCellUtil.java | 16 +-- .../java/org/apache/hadoop/hbase/RawCell.java | 4 +- .../hadoop/hbase/RawCellBuilderFactory.java | 4 +- .../apache/hadoop/hbase/ScheduledChore.java | 24 +--- .../org/apache/hadoop/hbase/ServerName.java | 4 +- .../org/apache/hadoop/hbase/Stoppable.java | 4 +- .../org/apache/hadoop/hbase/TableName.java | 8 +- .../java/org/apache/hadoop/hbase/Tag.java | 16 +-- .../java/org/apache/hadoop/hbase/TagUtil.java | 8 +- .../apache/hadoop/hbase/codec/CellCodec.java | 4 +- .../hadoop/hbase/codec/CellCodecWithTags.java | 4 +- .../hbase/conf/ConfigurationManager.java | 8 +- .../hbase/filter/ByteArrayComparable.java | 4 +- .../hbase/io/ByteArrayOutputStream.java | 8 +- .../hbase/io/ImmutableBytesWritable.java | 4 +- .../org/apache/hadoop/hbase/io/TimeRange.java | 8 +- .../io/encoding/BufferedDataBlockEncoder.java | 4 +- .../hbase/io/encoding/DataBlockEncoder.java | 4 +- .../hbase/io/encoding/DataBlockEncoding.java | 8 +- .../hbase/io/encoding/EncodedDataBlock.java | 2 +- .../encoding/HFileBlockDecodingContext.java | 4 +- .../encoding/HFileBlockEncodingContext.java | 16 +-- .../hadoop/hbase/io/hfile/BlockType.java | 4 +- .../hadoop/hbase/io/hfile/HFileContext.java | 4 +- .../org/apache/hadoop/hbase/nio/ByteBuff.java | 20 +-- .../hadoop/hbase/nio/MultiByteBuff.java | 12 +- .../apache/hadoop/hbase/security/User.java | 4 +- .../hadoop/hbase/security/UserProvider.java | 4 +- .../hadoop/hbase/util/AbstractByteRange.java | 4 +- .../apache/hadoop/hbase/util/ByteRange.java | 4 +- .../org/apache/hadoop/hbase/util/Bytes.java | 4 +- .../hadoop/hbase/util/ExceptionUtil.java | 8 +- .../org/apache/hadoop/hbase/util/HashKey.java | 4 +- .../org/apache/hadoop/hbase/util/Sleeper.java | 4 +- .../hbase/util/WindowMovingAverage.java | 8 +- .../hadoop/hbase/net/BoundSocketMaker.java | 4 +- .../MetricsAssignmentManagerSource.java | 32 ++--- .../hbase/master/MetricsMasterSource.java | 4 +- .../MetricsRegionServerWrapper.java | 46 ++----- .../regionserver/MetricsRegionWrapper.java | 32 ++--- .../MetricsTableWrapperAggregate.java | 24 +--- .../metrics2/lib/DynamicMetricsRegistry.java | 4 +- .../apache/hadoop/hbase/util/JSONBean.java | 4 +- .../hbase/IntegrationTestBackupRestore.java | 4 +- .../hbase/IntegrationTestMobCompaction.java | 4 +- .../hadoop/hbase/mapred/TableSplit.java | 10 +- .../hadoop/hbase/mapreduce/CellCreator.java | 4 +- .../hadoop/hbase/PerformanceEvaluation.java | 8 +- .../TestRoundRobinTableInputFormat.java | 4 +- .../hadoop/hbase/procedure2/LockAndQueue.java | 12 +- .../hadoop/hbase/procedure2/Procedure.java | 28 ++--- .../hbase/procedure2/ProcedureEvent.java | 2 +- .../hbase/procedure2/ProcedureExecutor.java | 12 +- .../hbase/procedure2/ProcedureMetrics.java | 10 +- .../hbase/procedure2/ProcedureScheduler.java | 4 +- .../procedure2/store/ProcedureStore.java | 8 +- .../procedure2/store/wal/BitSetNode.java | 20 +-- .../store/wal/ProcedureStoreTracker.java | 4 +- .../hbase/procedure2/util/DelayedUtil.java | 8 +- .../hbase/rest/ProtobufMessageHandler.java | 4 +- .../apache/hadoop/hbase/rest/RESTServlet.java | 8 +- .../hadoop/hbase/rest/TableResource.java | 6 +- .../hadoop/hbase/rest/client/Client.java | 8 +- .../hadoop/hbase/rest/client/Cluster.java | 4 +- .../hadoop/hbase/rest/client/Response.java | 20 +-- .../hadoop/hbase/rest/model/CellModel.java | 16 +-- .../hadoop/hbase/rest/model/CellSetModel.java | 4 +- .../hbase/rest/model/ColumnSchemaModel.java | 36 ++---- .../rest/model/NamespacesInstanceModel.java | 4 +- .../hbase/rest/model/NamespacesModel.java | 4 +- .../hadoop/hbase/rest/model/RowModel.java | 8 +- .../hadoop/hbase/rest/model/ScannerModel.java | 52 ++------ .../rest/model/StorageClusterStatusModel.java | 96 ++++----------- .../model/StorageClusterVersionModel.java | 4 +- .../hbase/rest/model/TableInfoModel.java | 8 +- .../hbase/rest/model/TableListModel.java | 4 +- .../hadoop/hbase/rest/model/TableModel.java | 4 +- .../hbase/rest/model/TableRegionModel.java | 20 +-- .../hbase/rest/model/TableSchemaModel.java | 28 ++--- .../hadoop/hbase/rest/model/VersionModel.java | 20 +-- .../apache/hadoop/hbase/HBaseServerBase.java | 24 +--- .../hadoop/hbase/LocalHBaseCluster.java | 16 +-- .../hadoop/hbase/MetaRegionLocationCache.java | 4 +- .../hadoop/hbase/MetaTableAccessor.java | 8 +- .../java/org/apache/hadoop/hbase/Server.java | 16 +-- .../apache/hadoop/hbase/TableDescriptors.java | 8 +- .../hadoop/hbase/backup/HFileArchiver.java | 16 +-- .../example/TableHFileArchiveTracker.java | 4 +- .../hadoop/hbase/client/VersionInfoUtil.java | 4 +- .../hbase/client/locking/EntityLock.java | 4 +- .../SplitLogManagerCoordination.java | 16 +-- .../SplitLogWorkerCoordination.java | 8 +- .../ZkSplitLogWorkerCoordination.java | 4 +- .../hbase/coprocessor/BaseEnvironment.java | 4 +- .../hbase/coprocessor/HasMasterServices.java | 4 +- .../coprocessor/HasRegionServerServices.java | 4 +- .../MasterCoprocessorEnvironment.java | 4 +- .../RegionCoprocessorEnvironment.java | 14 +-- .../RegionServerCoprocessorEnvironment.java | 8 +- .../WALCoprocessorEnvironment.java | 2 +- .../hadoop/hbase/executor/EventHandler.java | 4 +- .../hbase/executor/ExecutorService.java | 2 +- .../hadoop/hbase/executor/ExecutorType.java | 4 +- .../hadoop/hbase/filter/FilterWrapper.java | 4 +- .../hbase/io/FSDataInputStreamWrapper.java | 4 +- .../org/apache/hadoop/hbase/io/FileLink.java | 12 +- .../org/apache/hadoop/hbase/io/HFileLink.java | 12 +- .../hadoop/hbase/io/hfile/BlockCache.java | 8 +- .../hadoop/hbase/io/hfile/BlockCacheKey.java | 4 +- .../hadoop/hbase/io/hfile/BlockCacheUtil.java | 24 +--- .../hadoop/hbase/io/hfile/CacheConfig.java | 22 +--- .../hadoop/hbase/io/hfile/Cacheable.java | 4 +- .../apache/hadoop/hbase/io/hfile/HFile.java | 2 +- .../hadoop/hbase/io/hfile/HFileBlock.java | 28 ++--- .../hbase/io/hfile/HFileBlockIndex.java | 28 ++--- .../hbase/io/hfile/HFileDataBlockEncoder.java | 2 +- .../hbase/io/hfile/HFileReaderImpl.java | 12 +- .../hadoop/hbase/io/hfile/HFileScanner.java | 12 +- .../hbase/io/hfile/HFileWriterImpl.java | 4 +- .../hbase/io/hfile/InlineBlockWriter.java | 4 +- .../hadoop/hbase/io/hfile/LruCachedBlock.java | 4 +- .../hbase/io/hfile/LruCachedBlockQueue.java | 8 +- .../io/hfile/bucket/CachedEntryQueue.java | 8 +- .../hbase/io/hfile/bucket/IOEngine.java | 4 +- .../hadoop/hbase/io/util/MemorySizeUtil.java | 4 +- .../ipc/FastPathBalancedQueueRpcExecutor.java | 4 +- .../hadoop/hbase/ipc/QueueBalancer.java | 4 +- .../org/apache/hadoop/hbase/ipc/RpcCall.java | 44 ++----- .../hadoop/hbase/ipc/RpcCallContext.java | 12 +- .../apache/hadoop/hbase/ipc/RpcHandler.java | 4 +- .../apache/hadoop/hbase/ipc/RpcServer.java | 4 +- .../hbase/master/ActiveMasterManager.java | 8 +- .../apache/hadoop/hbase/master/HMaster.java | 48 ++------ .../hadoop/hbase/master/MasterFileSystem.java | 20 +-- .../hbase/master/MasterRpcServices.java | 4 +- .../hadoop/hbase/master/MasterServices.java | 108 ++++------------ .../hadoop/hbase/master/MasterWalManager.java | 6 +- .../master/MetricsAssignmentManager.java | 32 ++--- .../hadoop/hbase/master/MetricsMaster.java | 4 +- .../master/RegionPlacementMaintainer.java | 4 +- .../hadoop/hbase/master/ServerManager.java | 18 +-- .../hadoop/hbase/master/SnapshotSentinel.java | 8 +- .../master/assignment/AssignmentManager.java | 4 +- .../MergeTableRegionsProcedure.java | 4 +- .../master/assignment/RegionStateStore.java | 2 +- .../hbase/master/assignment/RegionStates.java | 20 +-- .../master/assignment/UnassignProcedure.java | 2 +- .../hadoop/hbase/master/hbck/HbckChore.java | 2 +- .../hbase/master/janitor/CatalogJanitor.java | 4 +- .../master/janitor/CatalogJanitorReport.java | 4 +- .../master/janitor/ReportMakingVisitor.java | 8 +- .../master/normalizer/NormalizationPlan.java | 4 +- .../normalizer/SimpleRegionNormalizer.java | 4 +- .../AbstractStateMachineRegionProcedure.java | 4 +- .../procedure/EnableTableProcedure.java | 4 +- .../procedure/ServerCrashProcedure.java | 4 +- .../procedure/ServerProcedureInterface.java | 8 +- .../procedure/TableProcedureInterface.java | 4 +- .../replication/ReplicationPeerManager.java | 4 +- .../master/snapshot/SnapshotFileCache.java | 4 +- .../master/snapshot/SnapshotManager.java | 4 +- .../hbase/master/zksyncer/ClientZKSyncer.java | 4 +- .../hadoop/hbase/procedure/Procedure.java | 2 +- .../hbase/procedure/ProcedureCoordinator.java | 8 +- .../hbase/quotas/MasterQuotaManager.java | 4 +- .../hadoop/hbase/quotas/OperationQuota.java | 2 +- .../hadoop/hbase/quotas/QuotaLimiter.java | 6 +- .../hadoop/hbase/quotas/QuotaState.java | 4 +- .../hadoop/hbase/quotas/RateLimiter.java | 6 +- .../quotas/RegionServerSpaceQuotaManager.java | 4 +- .../hadoop/hbase/quotas/UserQuotaState.java | 4 +- .../hbase/regionserver/AbstractMemStore.java | 10 +- .../regionserver/ChangedReadersObserver.java | 4 +- .../hadoop/hbase/regionserver/Chunk.java | 4 +- .../hbase/regionserver/CompactSplit.java | 12 +- .../CompositeImmutableSegment.java | 20 +-- .../ConstantSizeRegionSplitPolicy.java | 4 +- .../FlushNonSloppyStoresFirstPolicy.java | 4 +- .../hbase/regionserver/FlushPolicy.java | 4 +- .../hadoop/hbase/regionserver/HRegion.java | 78 ++++-------- .../hbase/regionserver/HRegionFileSystem.java | 14 +-- .../hbase/regionserver/HRegionServer.java | 34 ++--- .../hadoop/hbase/regionserver/HStore.java | 20 +-- .../hadoop/hbase/regionserver/HStoreFile.java | 4 +- .../hbase/regionserver/HeapMemoryManager.java | 4 +- ...creasingToUpperBoundRegionSplitPolicy.java | 4 +- .../hbase/regionserver/KeyValueHeap.java | 4 +- .../hbase/regionserver/KeyValueScanner.java | 4 +- .../hbase/regionserver/LeaseManager.java | 6 +- .../hadoop/hbase/regionserver/MemStore.java | 4 +- .../hbase/regionserver/MemStoreFlusher.java | 16 +-- .../hbase/regionserver/MemStoreSizing.java | 8 +- .../hbase/regionserver/MemStoreSnapshot.java | 16 +-- .../regionserver/MetricsUserAggregate.java | 4 +- .../MiniBatchOperationInProgress.java | 4 +- .../hbase/regionserver/RSRpcServices.java | 16 +-- .../hadoop/hbase/regionserver/Region.java | 42 +++---- .../regionserver/RegionCoprocessorHost.java | 2 +- .../hbase/regionserver/RegionScanner.java | 8 +- .../hbase/regionserver/RegionScannerImpl.java | 12 +- .../regionserver/RegionServerAccounting.java | 16 +-- .../regionserver/RegionServerServices.java | 72 +++-------- .../hbase/regionserver/RegionSplitPolicy.java | 8 +- .../hbase/regionserver/ScannerContext.java | 12 +- .../hadoop/hbase/regionserver/Segment.java | 8 +- .../hbase/regionserver/SegmentScanner.java | 4 +- .../hbase/regionserver/SplitLogWorker.java | 4 +- .../hadoop/hbase/regionserver/Store.java | 116 +++++------------- .../regionserver/StoreConfigInformation.java | 8 +- .../hbase/regionserver/StoreEngine.java | 16 +-- .../hadoop/hbase/regionserver/StoreFile.java | 36 ++---- .../hbase/regionserver/StoreFileInfo.java | 18 ++- .../hbase/regionserver/StoreFileManager.java | 4 +- .../hbase/regionserver/StoreFlushContext.java | 4 +- .../hbase/regionserver/StoreScanner.java | 8 +- .../regionserver/StripeStoreFileManager.java | 4 +- .../hbase/regionserver/TimeRangeTracker.java | 12 +- .../compactions/CompactionConfiguration.java | 28 ++--- .../compactions/CompactionPolicy.java | 4 +- .../compactions/CompactionProgress.java | 12 +- .../compactions/CompactionRequest.java | 28 ++--- .../DateTieredCompactionPolicy.java | 2 +- .../compactions/OffPeakHours.java | 8 +- .../compactions/StripeCompactionPolicy.java | 16 +-- .../handler/OpenRegionHandler.java | 8 +- .../querymatcher/ColumnCount.java | 12 +- .../querymatcher/ColumnTracker.java | 4 +- .../querymatcher/DeleteTracker.java | 4 +- .../querymatcher/ScanQueryMatcher.java | 16 +-- .../hbase/regionserver/wal/AbstractFSWAL.java | 14 +-- .../hadoop/hbase/regionserver/wal/FSHLog.java | 16 +-- .../hbase/regionserver/wal/FSWALEntry.java | 8 +- .../hbase/regionserver/wal/ReaderBase.java | 16 +-- .../regionserver/wal/RingBufferTruck.java | 4 +- .../replication/ReplicationEndpoint.java | 4 +- .../regionserver/ReplicationSink.java | 4 +- .../ReplicationSourceInterface.java | 36 ++---- .../ReplicationSourceWALReader.java | 4 +- .../regionserver/WALEntryBatch.java | 36 ++---- .../regionserver/WALEntryStream.java | 12 +- .../hbase/rsgroup/RSGroupInfoManagerImpl.java | 8 +- .../security/access/AccessControlFilter.java | 4 +- .../hbase/security/access/AuthResult.java | 4 +- .../security/token/FsDelegationToken.java | 8 +- .../visibility/VisibilityLabelsCache.java | 4 +- .../hbase/snapshot/RestoreSnapshotHelper.java | 20 +-- .../hadoop/hbase/snapshot/SnapshotInfo.java | 40 +++--- .../hadoop/hbase/tool/BulkLoadHFiles.java | 4 +- .../apache/hadoop/hbase/tool/CanaryTool.java | 4 +- .../hadoop/hbase/util/BloomFilterBase.java | 12 +- .../hadoop/hbase/util/BloomFilterFactory.java | 20 +-- .../hadoop/hbase/util/ConnectionCache.java | 4 +- .../hadoop/hbase/util/DirectMemoryUtils.java | 8 +- .../org/apache/hadoop/hbase/util/FSUtils.java | 8 +- .../apache/hadoop/hbase/util/HBaseFsck.java | 16 +-- .../hadoop/hbase/util/HbckTableInfo.java | 4 +- .../hadoop/hbase/util/JVMClusterUtil.java | 4 +- .../hadoop/hbase/util/RegionSplitter.java | 4 +- .../hbase/util/RollingStatCalculator.java | 8 +- .../hbase/util/ServerRegionReplicaUtil.java | 16 +-- .../hbase/util/YammerHistogramUtils.java | 6 +- .../util/hbck/HFileCorruptionChecker.java | 32 ++--- .../hbase/wal/AbstractFSWALProvider.java | 4 +- .../wal/AbstractRecoveredEditsOutputSink.java | 4 +- .../hadoop/hbase/wal/AbstractWALRoller.java | 4 +- .../apache/hadoop/hbase/wal/EntryBuffers.java | 4 +- .../apache/hadoop/hbase/wal/OutputSink.java | 12 +- .../java/org/apache/hadoop/hbase/wal/WAL.java | 4 +- .../org/apache/hadoop/hbase/wal/WALEdit.java | 4 +- .../org/apache/hadoop/hbase/wal/WALKey.java | 20 +-- .../apache/hadoop/hbase/wal/WALKeyImpl.java | 16 +-- .../apache/hadoop/hbase/wal/WALProvider.java | 4 +- .../io/hfile/TestHFileDataBlockEncoder.java | 4 +- .../assignment/TestRaceBetweenSCPAndDTP.java | 4 +- .../hbase/master/procedure/TestHBCKSCP.java | 4 +- .../hbase/regionserver/TestHRegion.java | 4 +- .../regionserver/TestRecoveredEdits.java | 4 +- .../wal/TestLogRollingNoCluster.java | 4 +- .../TestMetaRegionReplicaReplication.java | 4 +- .../TestReplicationSourceManager.java | 4 +- .../hbase/util/HFileArchiveTestingUtil.java | 4 +- .../hbase/util/MultiThreadedAction.java | 2 +- .../util/test/LoadTestDataGenerator.java | 4 +- .../hbase/client/AbstractTestShell.java | 8 +- .../hbase/HBaseCommonTestingUtility.java | 8 +- .../hadoop/hbase/HBaseZKTestingUtility.java | 4 +- .../apache/hadoop/hbase/MiniHBaseCluster.java | 16 +-- .../hadoop/hbase/StartMiniClusterOption.java | 4 +- .../apache/hadoop/hbase/thrift/ImplType.java | 4 +- .../thrift/ThriftHBaseServiceHandler.java | 2 +- .../hadoop/hbase/thrift/TestThriftServer.java | 4 +- .../hbase/thrift/ThriftServerRunner.java | 4 +- .../hbase/zookeeper/ClusterStatusTracker.java | 4 +- .../hbase/zookeeper/MiniZooKeeperCluster.java | 4 +- .../hadoop/hbase/zookeeper/ZKListener.java | 4 +- .../apache/hadoop/hbase/zookeeper/ZKUtil.java | 20 +-- .../hadoop/hbase/zookeeper/ZKWatcher.java | 4 +- 400 files changed, 1225 insertions(+), 3365 deletions(-) diff --git a/hbase-asyncfs/src/main/java/org/apache/hadoop/hbase/io/asyncfs/AsyncFSOutput.java b/hbase-asyncfs/src/main/java/org/apache/hadoop/hbase/io/asyncfs/AsyncFSOutput.java index b88b32bdb81..cd186f904a9 100644 --- a/hbase-asyncfs/src/main/java/org/apache/hadoop/hbase/io/asyncfs/AsyncFSOutput.java +++ b/hbase-asyncfs/src/main/java/org/apache/hadoop/hbase/io/asyncfs/AsyncFSOutput.java @@ -89,8 +89,6 @@ public interface AsyncFSOutput extends Closeable { @Override void close() throws IOException; - /** - * @return byteSize success synced to underlying filesystem. - */ + /** Returns byteSize success synced to underlying filesystem. */ long getSyncedLength(); } diff --git a/hbase-asyncfs/src/main/java/org/apache/hadoop/hbase/util/RecoverLeaseFSUtils.java b/hbase-asyncfs/src/main/java/org/apache/hadoop/hbase/util/RecoverLeaseFSUtils.java index e4a410aa9c3..0014185b85c 100644 --- a/hbase-asyncfs/src/main/java/org/apache/hadoop/hbase/util/RecoverLeaseFSUtils.java +++ b/hbase-asyncfs/src/main/java/org/apache/hadoop/hbase/util/RecoverLeaseFSUtils.java @@ -186,9 +186,7 @@ public final class RecoverLeaseFSUtils { return recovered; } - /** - * @return Detail to append to any log message around lease recovering. - */ + /** Returns Detail to append to any log message around lease recovering. */ private static String getLogMessageDetail(final int nbAttempt, final Path p, final long startWaiting) { return "attempt=" + nbAttempt + " on file=" + p + " after " diff --git a/hbase-balancer/src/main/java/org/apache/hadoop/hbase/master/balancer/FavoredStochasticBalancer.java b/hbase-balancer/src/main/java/org/apache/hadoop/hbase/master/balancer/FavoredStochasticBalancer.java index 3b91bec03ec..fbe91a921da 100644 --- a/hbase-balancer/src/main/java/org/apache/hadoop/hbase/master/balancer/FavoredStochasticBalancer.java +++ b/hbase-balancer/src/main/java/org/apache/hadoop/hbase/master/balancer/FavoredStochasticBalancer.java @@ -87,9 +87,7 @@ public class FavoredStochasticBalancer extends StochasticLoadBalancer return fnPickers; } - /** - * @return any candidate generator in random - */ + /** Returns any candidate generator in random */ @Override protected CandidateGenerator getRandomGenerator() { return candidateGenerators.get(ThreadLocalRandom.current().nextInt(candidateGenerators.size())); diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/CatalogFamilyFormat.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/CatalogFamilyFormat.java index 6ad1a18e83d..d714c47359b 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/CatalogFamilyFormat.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/CatalogFamilyFormat.java @@ -398,9 +398,7 @@ public class CatalogFamilyFormat { return false; } - /** - * @return True if the column in cell matches the regex 'info:merge.*'. - */ + /** Returns True if the column in cell matches the regex 'info:merge.*'. */ public static boolean isMergeQualifierPrefix(Cell cell) { // Check to see if has family and that qualifier starts with the merge qualifier 'merge' return CellUtil.matchingFamily(cell, HConstants.CATALOG_FAMILY) diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/ClientMetaTableAccessor.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/ClientMetaTableAccessor.java index e948048325f..b75398dd1cf 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/ClientMetaTableAccessor.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/ClientMetaTableAccessor.java @@ -382,9 +382,7 @@ public final class ClientMetaTableAccessor { abstract void add(Result r); - /** - * @return Collected results; wait till visits complete to collect all possible results - */ + /** Returns Collected results; wait till visits complete to collect all possible results */ List getResults() { return this.results; } diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/ClusterId.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/ClusterId.java index e769e80847f..9b7a5de19bd 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/ClusterId.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/ClusterId.java @@ -45,9 +45,7 @@ public class ClusterId { this.id = uuid; } - /** - * @return The clusterid serialized using pb w/ pb magic prefix - */ + /** Returns The clusterid serialized using pb w/ pb magic prefix */ public byte[] toByteArray() { return ProtobufUtil.prependPBMagic(convert().toByteArray()); } @@ -74,9 +72,7 @@ public class ClusterId { } } - /** - * @return A pb instance to represent this instance. - */ + /** Returns A pb instance to represent this instance. */ public ClusterIdProtos.ClusterId convert() { ClusterIdProtos.ClusterId.Builder builder = ClusterIdProtos.ClusterId.newBuilder(); return builder.setClusterId(this.id).build(); diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/ClusterMetrics.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/ClusterMetrics.java index e36010c424c..7c4f2c823d1 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/ClusterMetrics.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/ClusterMetrics.java @@ -69,38 +69,26 @@ import org.apache.yetus.audience.InterfaceAudience; @InterfaceAudience.Public public interface ClusterMetrics { - /** - * @return the HBase version string as reported by the HMaster - */ + /** Returns the HBase version string as reported by the HMaster */ @Nullable String getHBaseVersion(); - /** - * @return the names of region servers on the dead list - */ + /** Returns the names of region servers on the dead list */ List getDeadServerNames(); - /** - * @return the names of region servers on the decommissioned list - */ + /** Returns the names of region servers on the decommissioned list */ List getDecommissionedServerNames(); - /** - * @return the names of region servers on the live list - */ + /** Returns the names of region servers on the live list */ Map getLiveServerMetrics(); - /** - * @return the number of regions deployed on the cluster - */ + /** Returns the number of regions deployed on the cluster */ default int getRegionCount() { return getLiveServerMetrics().entrySet().stream() .mapToInt(v -> v.getValue().getRegionMetrics().size()).sum(); } - /** - * @return the number of requests since last report - */ + /** Returns the number of requests since last report */ default long getRequestCount() { return getLiveServerMetrics().entrySet().stream() .flatMap(v -> v.getValue().getRegionMetrics().values().stream()) @@ -114,9 +102,7 @@ public interface ClusterMetrics { @Nullable ServerName getMasterName(); - /** - * @return the names of backup masters - */ + /** Returns the names of backup masters */ List getBackupMasterNames(); @InterfaceAudience.Private @@ -147,9 +133,7 @@ public interface ClusterMetrics { List getServersName(); - /** - * @return the average cluster load - */ + /** Returns the average cluster load */ default double getAverageLoad() { int serverSize = getLiveServerMetrics().size(); if (serverSize == 0) { diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/CoprocessorEnvironment.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/CoprocessorEnvironment.java index edbc5f479d6..94909f1c14e 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/CoprocessorEnvironment.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/CoprocessorEnvironment.java @@ -28,19 +28,19 @@ import org.apache.yetus.audience.InterfaceStability; @InterfaceStability.Evolving public interface CoprocessorEnvironment { - /** @return the Coprocessor interface version */ + /** Returns the Coprocessor interface version */ int getVersion(); - /** @return the HBase version as a string (e.g. "0.21.0") */ + /** Returns the HBase version as a string (e.g. "0.21.0") */ String getHBaseVersion(); - /** @return the loaded coprocessor instance */ + /** Returns the loaded coprocessor instance */ C getInstance(); - /** @return the priority assigned to the loaded coprocessor */ + /** Returns the priority assigned to the loaded coprocessor */ int getPriority(); - /** @return the load sequence number */ + /** Returns the load sequence number */ int getLoadSequence(); /** @@ -49,8 +49,6 @@ public interface CoprocessorEnvironment { */ Configuration getConfiguration(); - /** - * @return the classloader for the loaded coprocessor instance - */ + /** Returns the classloader for the loaded coprocessor instance */ ClassLoader getClassLoader(); } diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/HBaseServerException.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/HBaseServerException.java index 2e4ebbd0baa..3484995c1bf 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/HBaseServerException.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/HBaseServerException.java @@ -63,9 +63,7 @@ public class HBaseServerException extends HBaseIOException { this.serverOverloaded = serverOverloaded; } - /** - * @return True if server was considered overloaded when exception was thrown - */ + /** Returns True if server was considered overloaded when exception was thrown */ public boolean isServerOverloaded() { return serverOverloaded; } diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/RegionMetrics.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/RegionMetrics.java index d873c4bc1cb..88527e86442 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/RegionMetrics.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/RegionMetrics.java @@ -28,44 +28,28 @@ import org.apache.yetus.audience.InterfaceAudience; @InterfaceAudience.Public public interface RegionMetrics { - /** - * @return the region name - */ + /** Returns the region name */ byte[] getRegionName(); - /** - * @return the number of stores - */ + /** Returns the number of stores */ int getStoreCount(); - /** - * @return the number of storefiles - */ + /** Returns the number of storefiles */ int getStoreFileCount(); - /** - * @return the total size of the storefiles - */ + /** Returns the total size of the storefiles */ Size getStoreFileSize(); - /** - * @return the memstore size - */ + /** Returns the memstore size */ Size getMemStoreSize(); - /** - * @return the number of read requests made to region - */ + /** Returns the number of read requests made to region */ long getReadRequestCount(); - /** - * @return the number of write requests made to region - */ + /** Returns the number of write requests made to region */ long getWriteRequestCount(); - /** - * @return the number of coprocessor service requests made to region - */ + /** Returns the number of coprocessor service requests made to region */ public long getCpRequestCount(); /** @@ -76,16 +60,12 @@ public interface RegionMetrics { return getReadRequestCount() + getWriteRequestCount() + getCpRequestCount(); } - /** - * @return the region name as a string - */ + /** Returns the region name as a string */ default String getNameAsString() { return Bytes.toStringBinary(getRegionName()); } - /** - * @return the number of filtered read requests made to region - */ + /** Returns the number of filtered read requests made to region */ long getFilteredReadRequestCount(); /** @@ -96,29 +76,19 @@ public interface RegionMetrics { */ Size getStoreFileIndexSize(); - /** - * @return The current total size of root-level indexes for the region - */ + /** Returns The current total size of root-level indexes for the region */ Size getStoreFileRootLevelIndexSize(); - /** - * @return The total size of all index blocks, not just the root level - */ + /** Returns The total size of all index blocks, not just the root level */ Size getStoreFileUncompressedDataIndexSize(); - /** - * @return The total size of all Bloom filter blocks, not just loaded into the block cache - */ + /** Returns The total size of all Bloom filter blocks, not just loaded into the block cache */ Size getBloomFilterSize(); - /** - * @return the total number of cells in current compaction - */ + /** Returns the total number of cells in current compaction */ long getCompactingCellCount(); - /** - * @return the number of already compacted kvs in current compaction - */ + /** Returns the number of already compacted kvs in current compaction */ long getCompactedCellCount(); /** @@ -127,29 +97,19 @@ public interface RegionMetrics { */ long getCompletedSequenceId(); - /** - * @return completed sequence id per store. - */ + /** Returns completed sequence id per store. */ Map getStoreSequenceId(); - /** - * @return the uncompressed size of the storefiles - */ + /** Returns the uncompressed size of the storefiles */ Size getUncompressedStoreFileSize(); - /** - * @return the data locality of region in the regionserver. - */ + /** Returns the data locality of region in the regionserver. */ float getDataLocality(); - /** - * @return the timestamp of the oldest hfile for any store of this region. - */ + /** Returns the timestamp of the oldest hfile for any store of this region. */ long getLastMajorCompactionTimestamp(); - /** - * @return the reference count for the stores of this region - */ + /** Returns the reference count for the stores of this region */ int getStoreRefCount(); /** @@ -164,9 +124,7 @@ public interface RegionMetrics { */ float getDataLocalityForSsd(); - /** - * @return the data at local weight of this region in the regionserver - */ + /** Returns the data at local weight of this region in the regionserver */ long getBlocksLocalWeight(); /** @@ -175,13 +133,9 @@ public interface RegionMetrics { */ long getBlocksLocalWithSsdWeight(); - /** - * @return the block total weight of this region - */ + /** Returns the block total weight of this region */ long getBlocksTotalWeight(); - /** - * @return the compaction state of this region - */ + /** Returns the compaction state of this region */ CompactionState getCompactionState(); } diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/ServerMetrics.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/ServerMetrics.java index 38286afa2d1..e0c408781f8 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/ServerMetrics.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/ServerMetrics.java @@ -33,48 +33,32 @@ public interface ServerMetrics { ServerName getServerName(); - /** - * @return the version number of a regionserver. - */ + /** Returns the version number of a regionserver. */ default int getVersionNumber() { return 0; } - /** - * @return the string type version of a regionserver. - */ + /** Returns the string type version of a regionserver. */ default String getVersion() { return "0.0.0"; } - /** - * @return the number of requests per second. - */ + /** Returns the number of requests per second. */ long getRequestCountPerSecond(); - /** - * @return total Number of requests from the start of the region server. - */ + /** Returns total Number of requests from the start of the region server. */ long getRequestCount(); - /** - * @return total Number of read requests from the start of the region server. - */ + /** Returns total Number of read requests from the start of the region server. */ long getReadRequestsCount(); - /** - * @return total Number of write requests from the start of the region server. - */ + /** Returns total Number of write requests from the start of the region server. */ long getWriteRequestsCount(); - /** - * @return the amount of used heap - */ + /** Returns the amount of used heap */ Size getUsedHeapSize(); - /** - * @return the maximum allowable size of the heap - */ + /** Returns the maximum allowable size of the heap */ Size getMaxHeapSize(); int getInfoServerPort(); @@ -97,14 +81,10 @@ public interface ServerMetrics { @Nullable ReplicationLoadSink getReplicationLoadSink(); - /** - * @return region load metrics - */ + /** Returns region load metrics */ Map getRegionMetrics(); - /** - * @return metrics per user - */ + /** Returns metrics per user */ Map getUserMetrics(); /** @@ -113,14 +93,10 @@ public interface ServerMetrics { */ Set getCoprocessorNames(); - /** - * @return the timestamp (server side) of generating this metrics - */ + /** Returns the timestamp (server side) of generating this metrics */ long getReportTimestamp(); - /** - * @return the last timestamp (server side) of generating this metrics - */ + /** Returns the last timestamp (server side) of generating this metrics */ long getLastReportTimestamp(); /** diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/Size.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/Size.java index c248849e363..99062635f77 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/Size.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/Size.java @@ -69,9 +69,7 @@ public final class Size implements Comparable { this.unit = Preconditions.checkNotNull(unit); } - /** - * @return size unit - */ + /** Returns size unit */ public Unit getUnit() { return unit; } diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/UserMetrics.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/UserMetrics.java index 2710aa9be27..05108c70e74 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/UserMetrics.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/UserMetrics.java @@ -40,19 +40,13 @@ public interface UserMetrics { long getFilteredReadRequestsCount(); } - /** - * @return the user name - */ + /** Returns the user name */ byte[] getUserName(); - /** - * @return the number of read requests made by user - */ + /** Returns the number of read requests made by user */ long getReadRequestCount(); - /** - * @return the number of write requests made by user - */ + /** Returns the number of write requests made by user */ long getWriteRequestCount(); /** @@ -63,20 +57,14 @@ public interface UserMetrics { return getReadRequestCount() + getWriteRequestCount(); } - /** - * @return the user name as a string - */ + /** Returns the user name as a string */ default String getNameAsString() { return Bytes.toStringBinary(getUserName()); } - /** - * @return metrics per client(hostname) - */ + /** Returns metrics per client(hostname) */ Map getClientMetrics(); - /** - * @return count of filtered read requests for a user - */ + /** Returns count of filtered read requests for a user */ long getFilteredReadRequests(); } diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/Admin.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/Admin.java index d2b57476128..96923ae8462 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/Admin.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/Admin.java @@ -111,9 +111,7 @@ public interface Admin extends Abortable, Closeable { @Override boolean isAborted(); - /** - * @return Connection used by this object. - */ + /** Returns Connection used by this object. */ Connection getConnection(); /** @@ -1162,9 +1160,7 @@ public interface Admin extends Abortable, Closeable { List getRegionMetrics(ServerName serverName, TableName tableName) throws IOException; - /** - * @return Configuration used by the instance. - */ + /** Returns Configuration used by the instance. */ Configuration getConfiguration(); /** diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/Append.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/Append.java index 59c90382ab2..76e923d3986 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/Append.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/Append.java @@ -92,9 +92,7 @@ public class Append extends Mutation { return this; } - /** - * @return current setting for returnResults - */ + /** Returns current setting for returnResults */ // This method makes public the superclasses's protected method. @Override public boolean isReturnResults() { diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/AsyncAdmin.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/AsyncAdmin.java index e0a254bb2aa..996410d26f5 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/AsyncAdmin.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/AsyncAdmin.java @@ -1073,34 +1073,24 @@ public interface AsyncAdmin { CompletableFuture recommissionRegionServer(ServerName server, List encodedRegionNames); - /** - * @return cluster status wrapped by {@link CompletableFuture} - */ + /** Returns cluster status wrapped by {@link CompletableFuture} */ CompletableFuture getClusterMetrics(); - /** - * @return cluster status wrapped by {@link CompletableFuture} - */ + /** Returns cluster status wrapped by {@link CompletableFuture} */ CompletableFuture getClusterMetrics(EnumSet