From issues-return-70244-archive-asf-public=cust-asf.ponee.io@commons.apache.org Sat Oct 13 19:49:05 2018 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx-eu-01.ponee.io (Postfix) with SMTP id B687E18067A for ; Sat, 13 Oct 2018 19:49:04 +0200 (CEST) Received: (qmail 9049 invoked by uid 500); 13 Oct 2018 17:49:03 -0000 Mailing-List: contact issues-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: issues@commons.apache.org Delivered-To: mailing list issues@commons.apache.org Received: (qmail 9034 invoked by uid 99); 13 Oct 2018 17:49:03 -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; Sat, 13 Oct 2018 17:49:03 +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 42BC2C0158 for ; Sat, 13 Oct 2018 17:49:03 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -109.251 X-Spam-Level: X-Spam-Status: No, score=-109.251 tagged_above=-999 required=6.31 tests=[ENV_AND_HDR_SPF_MATCH=-0.5, KAM_ASCII_DIVIDERS=0.8, KAM_LOTSOFHASH=0.25, RCVD_IN_DNSWL_MED=-2.3, SPF_PASS=-0.001, USER_IN_DEF_SPF_WL=-7.5, 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 xkFU_CUue26m for ; Sat, 13 Oct 2018 17:49:01 +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 7346E5F43B for ; Sat, 13 Oct 2018 17:49:01 +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 D12CFE0E3E for ; Sat, 13 Oct 2018 17:49:00 +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 6E11124DDC for ; Sat, 13 Oct 2018 17:49:00 +0000 (UTC) Date: Sat, 13 Oct 2018 17:49:00 +0000 (UTC) From: "Gary Gregory (JIRA)" To: issues@commons.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (BEANUTILS-509) WeakHashmap enters into infinite loop in WrapDynaClass.java MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/BEANUTILS-509?page=3Dcom.atlass= ian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=3D1= 6649046#comment-16649046 ]=20 Gary Gregory commented on BEANUTILS-509: ---------------------------------------- For now, I can see that wrapping the weak map into a synchronized map may h= elp but this causes the build to fail, not because any unit tests fail, but= because the Maven Surefire plugin that runs the tests blows up: {noformat} [WARNING] Tests run: 1279, Failures: 0, Errors: 0, Skipped: 3 [INFO] [INFO] --------------------------------------------------------------------= ---- [INFO] BUILD FAILURE [INFO] --------------------------------------------------------------------= ---- [INFO] Total time: 06:15 min [INFO] Finished at: 2018-10-13T11:28:38-06:00 [INFO] --------------------------------------------------------------------= ---- [ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plug= in:2.22.1:test (default-test) on project commons-beanutils2: There are test= failures. [ERROR] [ERROR] Please refer to C:\vcs\svn\apache\commons\trunks-proper\beanutils\t= arget\surefire-reports for the individual test results. [ERROR] Please refer to dump files (if any exist) [date].dump, [date]-jvmRu= n[N].dump and [date].dumpstream. [ERROR] ExecutionException The forked VM terminated without properly saying= goodbye. VM crash or System.exit called? [ERROR] Command was cmd.exe /X /C ""C:\Program Files\Java\jdk1.8.0_181\jre\= bin\java" -Xmx56M -javaagent:C:\\Users\\ggregory\\.m2\\repository\\org\\jac= oco\\org.jacoco.agent\\0.8.2\\org.jacoco.agent-0.8.2-runtime.jar=3Ddestfile= =3DC:\\vcs\\svn\\apache\\commons\\trunks-proper\\beanutils\\target\\jacoco.= exec -jar C:\Users\ggregory\AppData\Local\Temp\surefire4491303226062350457\= surefirebooter7341664506376672162.jar C:\Users\ggregory\AppData\Local\Temp\= surefire4491303226062350457 2018-10-13T11-22-41_548-jvmRun1 surefire7040480= 156590727732tmp surefire_356812217102022201471tmp" [ERROR] Error occurred in starting fork, check output in log [ERROR] Process Exit Code: 1 [ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: Execu= tionException The forked VM terminated without properly saying goodbye. VM = crash or System.exit called? [ERROR] Command was cmd.exe /X /C ""C:\Program Files\Java\jdk1.8.0_181\jre\= bin\java" -Xmx56M -javaagent:C:\\Users\\ggregory\\.m2\\repository\\org\\jac= oco\\org.jacoco.agent\\0.8.2\\org.jacoco.agent-0.8.2-runtime.jar=3Ddestfile= =3DC:\\vcs\\svn\\apache\\commons\\trunks-proper\\beanutils\\target\\jacoco.= exec -jar C:\Users\ggregory\AppData\Local\Temp\surefire4491303226062350457\= surefirebooter7341664506376672162.jar C:\Users\ggregory\AppData\Local\Temp\= surefire4491303226062350457 2018-10-13T11-22-41_548-jvmRun1 surefire7040480= 156590727732tmp surefire_356812217102022201471tmp" [ERROR] Error occurred in starting fork, check output in log [ERROR] Process Exit Code: 1 [ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarte= r.awaitResultsDone(ForkStarter.java:510) [ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarte= r.runSuitesForkPerTestSet(ForkStarter.java:457) [ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarte= r.run(ForkStarter.java:298) [ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarte= r.run(ForkStarter.java:246) [ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.ex= ecuteProvider(AbstractSurefireMojo.java:1183) [ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.ex= ecuteAfterPreconditionsChecked(AbstractSurefireMojo.java:1011) [ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.ex= ecute(AbstractSurefireMojo.java:857) [ERROR] at org.apache.maven.plugin.DefaultBuildPluginManager.execut= eMojo(DefaultBuildPluginManager.java:137) [ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute= (MojoExecutor.java:208) [ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute= (MojoExecutor.java:154) [ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute= (MojoExecutor.java:146) [ERROR] at org.apache.maven.lifecycle.internal.LifecycleModuleBuild= er.buildProject(LifecycleModuleBuilder.java:117) [ERROR] at org.apache.maven.lifecycle.internal.LifecycleModuleBuild= er.buildProject(LifecycleModuleBuilder.java:81) [ERROR] at org.apache.maven.lifecycle.internal.builder.singlethread= ed.SingleThreadedBuilder.build(SingleThreadedBuilder.java:56) [ERROR] at org.apache.maven.lifecycle.internal.LifecycleStarter.exe= cute(LifecycleStarter.java:128) [ERROR] at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.jav= a:305) [ERROR] at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.jav= a:192) [ERROR] at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:= 105) [ERROR] at org.apache.maven.cli.MavenCli.execute(MavenCli.java:954) [ERROR] at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:288) [ERROR] at org.apache.maven.cli.MavenCli.main(MavenCli.java:192) [ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Meth= od) [ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethod= AccessorImpl.java:62) [ERROR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Delegati= ngMethodAccessorImpl.java:43) [ERROR] at java.lang.reflect.Method.invoke(Method.java:498) [ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.launch= Enhanced(Launcher.java:289) [ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.launch= (Launcher.java:229) [ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.mainWi= thExitCode(Launcher.java:415) [ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.main(L= auncher.java:356) [ERROR] Caused by: org.apache.maven.surefire.booter.SurefireBooterForkExcep= tion: The forked VM terminated without properly saying goodbye. VM crash or= System.exit called? [ERROR] Command was cmd.exe /X /C ""C:\Program Files\Java\jdk1.8.0_181\jre\= bin\java" -Xmx56M -javaagent:C:\\Users\\ggregory\\.m2\\repository\\org\\jac= oco\\org.jacoco.agent\\0.8.2\\org.jacoco.agent-0.8.2-runtime.jar=3Ddestfile= =3DC:\\vcs\\svn\\apache\\commons\\trunks-proper\\beanutils\\target\\jacoco.= exec -jar C:\Users\ggregory\AppData\Local\Temp\surefire4491303226062350457\= surefirebooter7341664506376672162.jar C:\Users\ggregory\AppData\Local\Temp\= surefire4491303226062350457 2018-10-13T11-22-41_548-jvmRun1 surefire7040480= 156590727732tmp surefire_356812217102022201471tmp" [ERROR] Error occurred in starting fork, check output in log [ERROR] Process Exit Code: 1 [ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarte= r.fork(ForkStarter.java:669) [ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarte= r.access$600(ForkStarter.java:115) [ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarte= r$2.call(ForkStarter.java:444) [ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarte= r$2.call(ForkStarter.java:420) [ERROR] at java.util.concurrent.FutureTask.run(FutureTask.java:266) [ERROR] at java.util.concurrent.ThreadPoolExecutor.runWorker(Thread= PoolExecutor.java:1149) [ERROR] at java.util.concurrent.ThreadPoolExecutor$Worker.run(Threa= dPoolExecutor.java:624) [ERROR] at java.lang.Thread.run(Thread.java:748) [ERROR] [ERROR] -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e= switch. [ERROR] Re-run Maven using the -X switch to enable full debug logging. [ERROR] [ERROR] For more information about the errors and possible solutions, pleas= e read the following articles: [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecu= tionException {noformat} I am using 'mvn clean test' with: {noformat} Apache Maven 3.5.4 (1edded0938998edf8bf061f1ceb3cfdeccf443fe; 2018-06-17T12= :33:14-06:00) Maven home: C:\Java\apache-maven-3.5.4\bin\.. Java version: 1.8.0_181, vendor: Oracle Corporation, runtime: C:\Program Fi= les\Java\jdk1.8.0_181\jre Default locale: en_US, platform encoding: Cp1252 OS name: "windows 10", version: "10.0", arch: "amd64", family: "windows" {noformat} There is obviously something stuck, hanging or crashing. [~akshaygehi] or anyone: Can you reproduce this? My attached patch updates Surefire and Jacoco to their respective current v= ersions, to no avail. Thank you, Gary > WeakHashmap enters into infinite loop in WrapDynaClass.java > ----------------------------------------------------------- > > Key: BEANUTILS-509 > URL: https://issues.apache.org/jira/browse/BEANUTILS-509 > Project: Commons BeanUtils > Issue Type: Bug > Components: DynaBean > Affects Versions: 1.8.2 > Reporter: sunil > Priority: Major > Attachments: WrapDynaCache.patch, WrapDynaCache_after_svn_commit.= patch, console.log.backup > > > We noticed that our application was using too much of CPU , all the 6 cor= es were used.=C2=A0 > On capturing the thread dump we saw that large number of threads were in = the running state and in : > at java.util.WeakHashMap.get(WeakHashMap.java:403) > at org.apache.commons.beanutils.WrapDynaClass.createDynaClass(WrapDynaCl= ass.java:425) > =C2=A0 > So we are suspecting that the thread has entered into indefinite while lo= op and hogging all the CPU resources. > I have attached the thread dump for reference.=C2=A0=C2=A0 > =C2=A0 > what is the solution for this issue? -- This message was sent by Atlassian JIRA (v7.6.3#76005)