Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 39C2E200C6A for ; Wed, 19 Apr 2017 20:04:53 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 385D6160B94; Wed, 19 Apr 2017 18:04:53 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 0B94B160BAA for ; Wed, 19 Apr 2017 20:04:51 +0200 (CEST) Received: (qmail 70549 invoked by uid 500); 19 Apr 2017 18:04:51 -0000 Mailing-List: contact common-issues-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list common-issues@hadoop.apache.org Received: (qmail 70537 invoked by uid 99); 19 Apr 2017 18:04:51 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 19 Apr 2017 18:04:51 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id BE0ECC0F8E for ; Wed, 19 Apr 2017 18:04:50 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -100.001 X-Spam-Level: X-Spam-Status: No, score=-100.001 tagged_above=-999 required=6.31 tests=[RP_MATCHES_RCVD=-0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001, USER_IN_WHITELIST=-100] autolearn=disabled Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id BJDM79ZKPNvW for ; Wed, 19 Apr 2017 18:04:47 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTP id B09D861A0B for ; Wed, 19 Apr 2017 18:04:43 +0000 (UTC) Received: from jira-lw-us.apache.org (unknown [207.244.88.139]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id 04F53E0D4A for ; Wed, 19 Apr 2017 18:04:43 +0000 (UTC) Received: from jira-lw-us.apache.org (localhost [127.0.0.1]) by jira-lw-us.apache.org (ASF Mail Server at jira-lw-us.apache.org) with ESMTP id 7213721B53 for ; Wed, 19 Apr 2017 18:04:42 +0000 (UTC) Date: Wed, 19 Apr 2017 18:04:42 +0000 (UTC) From: "Allen Wittenauer (JIRA)" To: common-issues@hadoop.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (HADOOP-14316) Switch from FindBugs to Spotbugs MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Wed, 19 Apr 2017 18:04:53 -0000 [ https://issues.apache.org/jira/browse/HADOOP-14316?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15975188#comment-15975188 ] Allen Wittenauer commented on HADOOP-14316: ------------------------------------------- | Reason | Tests| | FindBugs | module:hadoop-common-project/hadoop-minikdc | | | Possible null pointer dereference in org.apache.hadoop.minikdc.MiniKdc.delete(File) due to return value of called method Dereferenced at MiniKdc.java:org.apache.hadoop.minikdc.MiniKdc.delete(File) due to return value of called method Dereferenced at MiniKdc.java:[line 368] | | FindBugs | module:hadoop-common-project/hadoop-auth | | | org.apache.hadoop.security.authentication.server.MultiSchemeAuthenticationHandler.authenticate(HttpServletRequest, HttpServletResponse) makes inefficient use of keySet iterator instead of entrySet iterator At MultiSchemeAuthenticationHandler.java:of keySet iterator instead of entrySet iterator At MultiSchemeAuthenticationHandler.java:[line 192] | | FindBugs | module:hadoop-common-project/hadoop-common | | | org.apache.hadoop.crypto.CipherSuite.setUnknownValue(int) unconditionally sets the field unknownValue At CipherSuite.java:unknownValue At CipherSuite.java:[line 44] | | | org.apache.hadoop.crypto.CryptoProtocolVersion.setUnknownValue(int) unconditionally sets the field unknownValue At CryptoProtocolVersion.java:unknownValue At CryptoProtocolVersion.java:[line 67] | | | Possible null pointer dereference in org.apache.hadoop.fs.FileUtil.fullyDeleteOnExit(File) due to return value of called method Dereferenced at FileUtil.java:org.apache.hadoop.fs.FileUtil.fullyDeleteOnExit(File) due to return value of called method Dereferenced at FileUtil.java:[line 118] | | | Possible null pointer dereference in org.apache.hadoop.fs.RawLocalFileSystem.handleEmptyDstDirectoryOnWindows(Path, File, Path, File) due to return value of called method Dereferenced at RawLocalFileSystem.java:org.apache.hadoop.fs.RawLocalFileSystem.handleEmptyDstDirectoryOnWindows(Path, File, Path, File) due to return value of called method Dereferenced at RawLocalFileSystem.java:[line 387] | | | Return value of org.apache.hadoop.fs.permission.FsAction.or(FsAction) ignored, but method has no side effect At FTPFileSystem.java:but method has no side effect At FTPFileSystem.java:[line 421] | | | Useless condition:lazyPersist == true at this point At CommandWithDestination.java:[line 502] | | | org.apache.hadoop.io.DoubleWritable.compareTo(DoubleWritable) incorrectly handles double value At DoubleWritable.java: At DoubleWritable.java:[line 78] | | | org.apache.hadoop.io.DoubleWritable$Comparator.compare(byte[], int, int, byte[], int, int) incorrectly handles double value At DoubleWritable.java:int) incorrectly handles double value At DoubleWritable.java:[line 97] | | | org.apache.hadoop.io.FloatWritable.compareTo(FloatWritable) incorrectly handles float value At FloatWritable.java: At FloatWritable.java:[line 71] | | | org.apache.hadoop.io.FloatWritable$Comparator.compare(byte[], int, int, byte[], int, int) incorrectly handles float value At FloatWritable.java:int) incorrectly handles float value At FloatWritable.java:[line 89] | | | Possible null pointer dereference in org.apache.hadoop.io.IOUtils.listDirectory(File, FilenameFilter) due to return value of called method Dereferenced at IOUtils.java:org.apache.hadoop.io.IOUtils.listDirectory(File, FilenameFilter) due to return value of called method Dereferenced at IOUtils.java:[line 350] | | | org.apache.hadoop.io.erasurecode.ECSchema.toString() makes inefficient use of keySet iterator instead of entrySet iterator At ECSchema.java:keySet iterator instead of entrySet iterator At ECSchema.java:[line 191] | | | Possible bad parsing of shift operation in org.apache.hadoop.io.file.tfile.Utils$Version.hashCode() At Utils.java:operation in org.apache.hadoop.io.file.tfile.Utils$Version.hashCode() At Utils.java:[line 398] | | | org.apache.hadoop.metrics2.lib.DefaultMetricsFactory.setInstance(MutableMetricsFactory) unconditionally sets the field mmfImpl At DefaultMetricsFactory.java:mmfImpl At DefaultMetricsFactory.java:[line 49] | | | org.apache.hadoop.metrics2.lib.DefaultMetricsSystem.setMiniClusterMode(boolean) unconditionally sets the field miniClusterMode At DefaultMetricsSystem.java:miniClusterMode At DefaultMetricsSystem.java:[line 100] | | | Useless object stored in variable seqOs of method org.apache.hadoop.security.token.delegation.ZKDelegationTokenSecretManager.addOrUpdateToken(AbstractDelegationTokenIdentifier, AbstractDelegationTokenSecretManager$DelegationTokenInformation, boolean) At ZKDelegationTokenSecretManager.java:seqOs of method org.apache.hadoop.security.token.delegation.ZKDelegationTokenSecretManager.addOrUpdateToken(AbstractDelegationTokenIdentifier, AbstractDelegationTokenSecretManager$DelegationTokenInformation, boolean) At ZKDelegationTokenSecretManager.java:[line 886] | | | Bad comparison of nonnegative value with 0 in org.apache.hadoop.tracing.TraceAdmin.run(String[]) At TraceAdmin.java:with 0 in org.apache.hadoop.tracing.TraceAdmin.run(String[]) At TraceAdmin.java:[line 169] | | FindBugs | module:hadoop-hdfs-project/hadoop-hdfs-client | | | Possible exposure of partially initialized object in org.apache.hadoop.hdfs.DFSClient.initThreadsNumForStripedReads(int) At DFSClient.java:object in org.apache.hadoop.hdfs.DFSClient.initThreadsNumForStripedReads(int) At DFSClient.java:[line 2856] | | | org.apache.hadoop.hdfs.server.protocol.SlowDiskReports.equals(Object) makes inefficient use of keySet iterator instead of entrySet iterator At SlowDiskReports.java:keySet iterator instead of entrySet iterator At SlowDiskReports.java:[line 105] | | FindBugs | module:hadoop-hdfs-project/hadoop-hdfs | | | Possible null pointer dereference in org.apache.hadoop.hdfs.qjournal.server.JournalNode.getJournalsStatus() due to return value of called method Dereferenced at JournalNode.java:org.apache.hadoop.hdfs.qjournal.server.JournalNode.getJournalsStatus() due to return value of called method Dereferenced at JournalNode.java:[line 300] | | | org.apache.hadoop.hdfs.server.common.HdfsServerConstants$StartupOption.setClusterId(String) unconditionally sets the field clusterId At HdfsServerConstants.java:clusterId At HdfsServerConstants.java:[line 193] | | | org.apache.hadoop.hdfs.server.common.HdfsServerConstants$StartupOption.setForce(int) unconditionally sets the field force At HdfsServerConstants.java:force At HdfsServerConstants.java:[line 217] | | | org.apache.hadoop.hdfs.server.common.HdfsServerConstants$StartupOption.setForceFormat(boolean) unconditionally sets the field isForceFormat At HdfsServerConstants.java:isForceFormat At HdfsServerConstants.java:[line 229] | | | org.apache.hadoop.hdfs.server.common.HdfsServerConstants$StartupOption.setInteractiveFormat(boolean) unconditionally sets the field isInteractiveFormat At HdfsServerConstants.java:isInteractiveFormat At HdfsServerConstants.java:[line 237] | | | Possible null pointer dereference in org.apache.hadoop.hdfs.server.datanode.DataStorage.linkBlocksHelper(File, File, int, HardLink, boolean, File, List) due to return value of called method Dereferenced at DataStorage.java:org.apache.hadoop.hdfs.server.datanode.DataStorage.linkBlocksHelper(File, File, int, HardLink, boolean, File, List) due to return value of called method Dereferenced at DataStorage.java:[line 1333] | | | Possible null pointer dereference in org.apache.hadoop.hdfs.server.namenode.NNStorageRetentionManager.purgeOldLegacyOIVImages(String, long) due to return value of called method Dereferenced at NNStorageRetentionManager.java:org.apache.hadoop.hdfs.server.namenode.NNStorageRetentionManager.purgeOldLegacyOIVImages(String, long) due to return value of called method Dereferenced at NNStorageRetentionManager.java:[line 258] | | | Possible null pointer dereference in org.apache.hadoop.hdfs.server.namenode.NNUpgradeUtil$1.visitFile(Path, BasicFileAttributes) due to return value of called method Dereferenced at NNUpgradeUtil.java:org.apache.hadoop.hdfs.server.namenode.NNUpgradeUtil$1.visitFile(Path, BasicFileAttributes) due to return value of called method Dereferenced at NNUpgradeUtil.java:[line 133] | | | Useless condition:argv.length >= 1 at this point At DFSAdmin.java:[line 2010] | | | Useless condition:numBlocks == -1 at this point At ImageLoaderCurrent.java:[line 727] | | FindBugs | module:hadoop-yarn-project/hadoop-yarn/hadoop-yarn-common | | | Possible null pointer dereference in org.apache.hadoop.yarn.logaggregation.AggregatedLogFormat$LogValue.getPendingLogFilesToUpload(File) due to return value of called method Method invoked at AggregatedLogFormat.java:org.apache.hadoop.yarn.logaggregation.AggregatedLogFormat$LogValue.getPendingLogFilesToUpload(File) due to return value of called method Method invoked at AggregatedLogFormat.java:[line 314] | | | Possible null pointer dereference in org.apache.hadoop.yarn.util.ProcfsBasedProcessTree.getProcessList() due to return value of called method Dereferenced at ProcfsBasedProcessTree.java:org.apache.hadoop.yarn.util.ProcfsBasedProcessTree.getProcessList() due to return value of called method Dereferenced at ProcfsBasedProcessTree.java:[line 499] | | FindBugs | module:hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager | | | Useless object stored in variable removedNullContainers of method org.apache.hadoop.yarn.server.nodemanager.NodeStatusUpdaterImpl.removeOrTrackCompletedContainersFromContext(List) At NodeStatusUpdaterImpl.java:removedNullContainers of method org.apache.hadoop.yarn.server.nodemanager.NodeStatusUpdaterImpl.removeOrTrackCompletedContainersFromContext(List) At NodeStatusUpdaterImpl.java:[line 644] | | | org.apache.hadoop.yarn.server.nodemanager.NodeStatusUpdaterImpl.removeVeryOldStoppedContainersFromCache() makes inefficient use of keySet iterator instead of entrySet iterator At NodeStatusUpdaterImpl.java:keySet iterator instead of entrySet iterator At NodeStatusUpdaterImpl.java:[line 721] | | | Hard coded reference to an absolute pathname in org.apache.hadoop.yarn.server.nodemanager.containermanager.linux.runtime.DockerLinuxContainerRuntime.launchContainer(ContainerRuntimeContext) At DockerLinuxContainerRuntime.java:absolute pathname in org.apache.hadoop.yarn.server.nodemanager.containermanager.linux.runtime.DockerLinuxContainerRuntime.launchContainer(ContainerRuntimeContext) At DockerLinuxContainerRuntime.java:[line 455] | | | org.apache.hadoop.yarn.server.nodemanager.containermanager.localizer.ContainerLocalizer.createStatus() makes inefficient use of keySet iterator instead of entrySet iterator At ContainerLocalizer.java:keySet iterator instead of entrySet iterator At ContainerLocalizer.java:[line 334] | | | org.apache.hadoop.yarn.server.nodemanager.containermanager.monitor.ContainerMetrics.usageMetrics is a mutable collection which should be package protected At ContainerMetrics.java:which should be package protected At ContainerMetrics.java:[line 134] | | FindBugs | module:hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-timelineservice | | | Possible null pointer dereference in org.apache.hadoop.yarn.server.timelineservice.storage.FileSystemTimelineReaderImpl.getEntities(File, String, TimelineEntityFilters, TimelineDataToRetrieve) due to return value of called method Dereferenced at FileSystemTimelineReaderImpl.java:org.apache.hadoop.yarn.server.timelineservice.storage.FileSystemTimelineReaderImpl.getEntities(File, String, TimelineEntityFilters, TimelineDataToRetrieve) due to return value of called method Dereferenced at FileSystemTimelineReaderImpl.java:[line 281] | | FindBugs | module:hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager | | | org.apache.hadoop.yarn.server.resourcemanager.ApplicationMasterService.EMPTY_CONTAINER_LIST is a mutable collection which should be package protected At ApplicationMasterService.java:which should be package protected At ApplicationMasterService.java:[line 396] | | | org.apache.hadoop.yarn.server.resourcemanager.monitor.capacity.ProportionalCapacityPreemptionPolicy.cleanupStaledPreemptionCandidates(long) makes inefficient use of keySet iterator instead of entrySet iterator At ProportionalCapacityPreemptionPolicy.java:keySet iterator instead of entrySet iterator At ProportionalCapacityPreemptionPolicy.java:[line 315] | | | org.apache.hadoop.yarn.server.resourcemanager.rmapp.attempt.RMAppAttemptImpl.transferStateFromAttempt(RMAppAttempt) makes inefficient use of keySet iterator instead of entrySet iterator At RMAppAttemptImpl.java:keySet iterator instead of entrySet iterator At RMAppAttemptImpl.java:[line 1005] | | | org.apache.hadoop.yarn.server.resourcemanager.scheduler.AbstractYarnScheduler.EMPTY_CONTAINER_LIST is a mutable collection which should be package protected At AbstractYarnScheduler.java:which should be package protected At AbstractYarnScheduler.java:[line 135] | | | org.apache.hadoop.yarn.server.resourcemanager.scheduler.NodeType.index field is public and mutable In NodeType.java:mutable In NodeType.java | | | org.apache.hadoop.yarn.server.resourcemanager.scheduler.QueueMetrics.queueMetrics is a mutable collection At QueueMetrics.java: At QueueMetrics.java:[line 151] | | | org.apache.hadoop.yarn.server.resourcemanager.scheduler.capacity.CapacitySchedulerQueueManager$1.compare(CSQueue, CSQueue) incorrectly handles float value At CapacitySchedulerQueueManager.java:value At CapacitySchedulerQueueManager.java:[line 74] | | | org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FSSchedulerNode.cleanupPreemptionList() makes inefficient use of keySet iterator instead of entrySet iterator At FSSchedulerNode.java:keySet iterator instead of entrySet iterator At FSSchedulerNode.java:[line 165] | | FindBugs | module:hadoop-yarn-project/hadoop-yarn/hadoop-yarn-client | | | Possible exposure of partially initialized object in org.apache.hadoop.yarn.client.api.impl.YarnClientImpl.getTimelineDelegationToken() At YarnClientImpl.java:object in org.apache.hadoop.yarn.client.api.impl.YarnClientImpl.getTimelineDelegationToken() At YarnClientImpl.java:[line 371] | | | Useless condition:isAppFinished == false at this point At LogsCLI.java:[line 999] | | FindBugs | module:hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core | | | Primitive is boxed to call Long.compareTo(Long):Long.compareTo(Long): use Long.compare(long, long) instead At JVMId.java:[line 101] | | | org.apache.hadoop.mapred.Operation.jobACLNeeded field is public and mutable In Operation.java:mutable In Operation.java | | | org.apache.hadoop.mapred.Operation.qACLNeeded field is public and mutable In Operation.java:mutable In Operation.java | | FindBugs | module:hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-app | | | Possible null pointer dereference in new org.apache.hadoop.mapred.LocalContainerLauncher(AppContext, TaskUmbilicalProtocol, ClassLoader) due to return value of called method Dereferenced at LocalContainerLauncher.java:new org.apache.hadoop.mapred.LocalContainerLauncher(AppContext, TaskUmbilicalProtocol, ClassLoader) due to return value of called method Dereferenced at LocalContainerLauncher.java:[line 124] | | | Possible null pointer dereference in org.apache.hadoop.mapred.LocalContainerLauncher$EventHandler.relocalize() due to return value of called method Dereferenced at LocalContainerLauncher.java:org.apache.hadoop.mapred.LocalContainerLauncher$EventHandler.relocalize() due to return value of called method Dereferenced at LocalContainerLauncher.java:[line 524] | | | Possible null pointer dereference in org.apache.hadoop.mapreduce.v2.app.MRAppMaster.isJobNamePatternMatch(JobConf, String) due to return value of called method Dereferenced at MRAppMaster.java:org.apache.hadoop.mapreduce.v2.app.MRAppMaster.isJobNamePatternMatch(JobConf, String) due to return value of called method Dereferenced at MRAppMaster.java:[line 577] | | FindBugs | module:hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-hs | | | Useless object stored in variable paths of method org.apache.hadoop.mapreduce.v2.hs.HistoryFileManager$HistoryFileInfo.moveToDone() At HistoryFileManager.java:paths of method org.apache.hadoop.mapreduce.v2.hs.HistoryFileManager$HistoryFileInfo.moveToDone() At HistoryFileManager.java:[line 410] | | FindBugs | module:hadoop-mapreduce-project/hadoop-mapreduce-examples | | | Possible null pointer dereference in org.apache.hadoop.examples.pi.Parser.parse(File, Map) due to return value of called method Dereferenced at Parser.java:org.apache.hadoop.examples.pi.Parser.parse(File, Map) due to return value of called method Dereferenced at Parser.java:[line 70] | | FindBugs | module:hadoop-tools/hadoop-rumen | | | Return value of new org.apache.hadoop.tools.rumen.datatypes.DefaultDataType(String) ignored, but method has no side effect At MapReduceJobPropertiesParser.java:ignored, but method has no side effect At MapReduceJobPropertiesParser.java:[line 211] | | FindBugs | module:hadoop-tools/hadoop-gridmix | | | org.apache.hadoop.mapred.gridmix.InputStriper$1.compare(Map$Entry, Map$Entry) incorrectly handles double value At InputStriper.java:value At InputStriper.java:[line 136] | | | org.apache.hadoop.mapred.gridmix.emulators.resourceusage.TotalHeapUsageEmulatorPlugin$DefaultHeapUsageEmulator.heapSpace is a mutable collection which should be package protected At TotalHeapUsageEmulatorPlugin.java:which should be package protected At TotalHeapUsageEmulatorPlugin.java:[line 132] | | FindBugs | module:hadoop-tools/hadoop-azure | | | Useless object stored in variable keysToUpdateAsFolder of method org.apache.hadoop.fs.azure.NativeAzureFileSystem.mkdirs(Path, FsPermission, boolean) At NativeAzureFileSystem.java:keysToUpdateAsFolder of method org.apache.hadoop.fs.azure.NativeAzureFileSystem.mkdirs(Path, FsPermission, boolean) At NativeAzureFileSystem.java:[line 2454] | | FindBugs | module:hadoop-tools/hadoop-sls | | | org.apache.hadoop.yarn.sls.SLSRunner.simulateInfoMap is a mutable collection At SLSRunner.java: At SLSRunner.java:[line 103] | | > Switch from FindBugs to Spotbugs > --------------------------------- > > Key: HADOOP-14316 > URL: https://issues.apache.org/jira/browse/HADOOP-14316 > Project: Hadoop Common > Issue Type: Improvement > Components: build > Affects Versions: 3.0.0-alpha3 > Reporter: Allen Wittenauer > Assignee: Allen Wittenauer > Attachments: HADOOP-14316.00.patch > > > Findbugs hasn't gotten a decent update in a few years. The community has since forked it and created https://github.com/spotbugs/spotbugs . Running the RC1 on trunk has pointed out some definite problem areas. I think it would be to our benefit to switch trunk over sooner rather than later, even though it's still in RC status. -- This message was sent by Atlassian JIRA (v6.3.15#6346) --------------------------------------------------------------------- To unsubscribe, e-mail: common-issues-unsubscribe@hadoop.apache.org For additional commands, e-mail: common-issues-help@hadoop.apache.org