#2289 new
yuan

a random ConcurrentModificationException in Play framework 1.2.7.2

Reported by yuan | December 25th, 2018 @ 02:35 PM

I'm a user of Play framework of 1.2.7.2.
I have met an error when i do stress testing in Jmeter, the server is tomcat 6/7, java 7/8, almost of the result is correct, but few of result is http 500, this error result is aboult 0.05%.

Could I do any workaround or config to avoid this error?

Framework version:
1.2.7.2

Platform you're using:
Centos 7, tomcat 6/7, java 7/8

Reproduction steps:

Details:

in the tomcat log:

Internal Server Error (500)

Oops: ConcurrentModificationException
An unexpected error occured caused by exception ConcurrentModificationException: null

play.exceptions.UnexpectedException: Unexpected Error
at play.mvc.ActionInvoker.invoke(ActionInvoker.java:264) at play.server.ServletWrapper$ServletInvocation.execute(ServletWrapper.java:574) at play.Invoker$Invocation.run(Invoker.java:278) at play.server.ServletWrapper$ServletInvocation.run(ServletWrapper.java:565) at play.Invoker.invokeInThread(Invoker.java:68) at play.server.ServletWrapper.service(ServletWrapper.java:143) at javax.servlet.http.HttpServlet.service(HttpServlet.java:803) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:228) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:212) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844) at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:634) at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:445) at java.lang.Thread.run(Thread.java:748) Caused by: java.util.ConcurrentModificationException
at java.util.ArrayList$Itr.checkForComodification(ArrayList.java:909) at java.util.ArrayList$Itr.next(ArrayList.java:859) at play.mvc.ActionInvoker.handleBefores(ActionInvoker.java:302) at play.mvc.ActionInvoker.invoke(ActionInvoker.java:142) ... 18 more 2018.12.25 14:29:58 ERROR play(602):?

Oops: ConcurrentModificationException
An unexpected error occured caused by exception ConcurrentModificationException: null

play.exceptions.UnexpectedException: Exception while doing @Finally
at play.mvc.ActionInvoker.handleFinallies(ActionInvoker.java:445) at play.mvc.ActionInvoker.invoke(ActionInvoker.java:257) at play.server.ServletWrapper$ServletInvocation.execute(ServletWrapper.java:574) at play.Invoker$Invocation.run(Invoker.java:278) at play.server.ServletWrapper$ServletInvocation.run(ServletWrapper.java:565) at play.Invoker.invokeInThread(Invoker.java:68) at play.server.ServletWrapper.service(ServletWrapper.java:143) at javax.servlet.http.HttpServlet.service(HttpServlet.java:731) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:218) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:110) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:506) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:169) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103) at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:962) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:445) at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1087) at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:637) at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:318) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.lang.Thread.run(Thread.java:748) Caused by: java.util.ConcurrentModificationException
at java.util.ArrayList.sort(ArrayList.java:1464) at java.util.Collections.sort(Collections.java:175) at play.mvc.ActionInvoker.handleFinallies(ActionInvoker.java:391) ... 27 more

Internal Server Error (500)

Oops: ConcurrentModificationException
An unexpected error occured caused by exception ConcurrentModificationException: null

play.exceptions.UnexpectedException: Unexpected Error
at play.mvc.ActionInvoker.invoke(ActionInvoker.java:264) at play.server.ServletWrapper$ServletInvocation.execute(ServletWrapper.java:574) at play.Invoker$Invocation.run(Invoker.java:278) at play.server.ServletWrapper$ServletInvocation.run(ServletWrapper.java:565) at play.Invoker.invokeInThread(Invoker.java:68) at play.server.ServletWrapper.service(ServletWrapper.java:143) at javax.servlet.http.HttpServlet.service(HttpServlet.java:731) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:218) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:110) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:506) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:169) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103) at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:962) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:445) at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1087) at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:637) at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:318) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.lang.Thread.run(Thread.java:748) Caused by: java.util.ConcurrentModificationException
at java.util.ArrayList.sort(ArrayList.java:1464) at java.util.Collections.sort(Collections.java:175) at play.mvc.ActionInvoker.handleAfters(ActionInvoker.java:335) at play.mvc.ActionInvoker.invoke(ActionInvoker.java:210) ... 26 more

Comments and changes to this ticket

  • peter
  • advseouk

    advseouk January 29th, 2019 @ 09:38 AM

    Open a shell and go to the ceylon-herd directory you just cloned
    Run play dependencies to setup the required modules
    Note: the play script requires Python 2, but runs on /usr/bin/env python, which may default to Python 3 depending on your system. If you get an error like this:

    File "/tmp/play-1.2.7.2/play", line 50 print r"~ _ _ " ^ SyntaxError: Missing parentheses in call to 'print'
    then change the first line of the script to

    #!/usr/bin/env python2 Note 2: This will pretend to fail due to not being able to find db but in fact they are already there. This is due to Play apparently having removed their Maven repo online. Those two modules have been added to our Git repo so we have them, but this step is still necessary in order to set up the secure module which comes from the Play distribution itself. Ignore the two errors and move on: it should work.

    Create your Postgres DB
    sudo su - postgres
    createuser -PSRD ceylon-herd
    enter ceylon-herd as password when prompted
    createdb -O ceylon-herd -E utf8 ceylon-herd
    exit
    Run the application if still face problem contact me in my website hotmail hacked account

  • kevinpeter

    kevinpeter February 9th, 2019 @ 06:09 PM

    The Model is that the domain-specific illustration of the data on that the applying operates. Domain logic adds ‘meaning’ to information (e.g., hard if nowadays is that the user’s birthday, or the totals, taxes, and shipping charges for a looking cart). Most applications use a persistent storage mechanism like a information to store knowledge. MVC doesn't specifically mention the information access layer as a result of it's understood to be beneath, or encapsulated by, the Model.
    The read renders the model into a type appropriate for interactions, usually a computer program. Multiple views will exist for one model, for various functions. during a net application the read is sometimes rendered during a ‘Web format’ like hypertext markup language, XML or JSON. but there area unit some cases wherever the read may be expressed during a binary type, e.g. dynamically rendered chart diagrams.
    The Controller responds to events (typically user actions) and processes them, and should additionally invoke changes on the model. during a net application, events area unit usually protocol requests: a Controller listens for protocol requests, extracts relevant knowledge from the ‘event’, like question string parameters, request headers... And applies changes on the underlying model objects. you can also contact me on alexa support this is my website you can contact me know more

  • Leo ONeill

    Leo ONeill February 10th, 2019 @ 09:21 AM

    Tweakbox App Download the latest version of Tweakbox APK and test your Android apps with policy controller.

  • cekisis

    cekisis February 19th, 2019 @ 09:58 AM

    How to easily watch Airtel tv on IPL 12

  • Himanshu mishra

    Himanshu mishra June 18th, 2019 @ 10:11 AM

    Hey I have a question in my mind that how to put icons desktop in windows 10 operating system easily without facing any trouble.

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2>Play framework</h2>

Play makes it easier to build Web applications with Java. It is a clean alternative to bloated Enterprise Java stacks. It focuses on developer productivity and targets RESTful architectures. Learn more on the <a href="http://www.playframework.org">http://www.playframework.org</a> website.<br><br>

<h2>Source code is hosted on github</h2>Check out our repository at <a href="http://github.com/playframework/play">http://github.com/playframework/play</a><br><br>

<h2>Contributing, creating a patch</h2> Please read the <a href="http://play.lighthouseapp.com/projects/57987/contributor-guide">contributor guide</a><br><br>

<h2>Reporting Security Vulnerabilities</h2> Since all bug reports are public, please report any security vulnerability directly to <em>guillaume dot bort at gmail dot com</em>.<br><br>

<h2>Creating a bug report</h2> Bug reports are incredibly helpful, so take time to report bugs and request features in our ticket tracker. We’re always grateful for patches to Play’s code. Indeed, bug reports with attached patches will get fixed far quickly than those without any.<br><br>

Please include as much relevant information as possible including the exact framework version you're using and a code snippet that reproduces the problem.<br><br>

Don't have too much expectations. Unless the bug is really a serious "everything is broken" thing, you're creating a ticket to start a discussion. Having a patch (or a branch on Github we can pull from) is better, but then again we'll only pull high quality branches that make sense to be in the core of Play.

Pages