Details

    • Type: Bug
    • Status: Verified
    • Resolution: Unresolved
    • Affects Version/s: 6.2.0 CE GA1
    • Fix Version/s: None
    • Component/s: Core Infrastructure
    • Labels:
      None
    • Fix Priority:
      3
    • JDK:
      Oracle Sun JDK 6
    • Application Servers:
      Apache Tomcat 7.0.42
    • Databases:
      MySQL 5.5

      Description

      In the last months I am having a particular problem on a Liferay 6.2.0 GA1 installation that is running from about one year.
      The installation contains about 200 sites/subsites and it worked fine until a month ago.

      Today there are often a CPU overhead problems.
      In particular conditions some threads are in endless loop and CPU goes at 100%.
      With jstack I saw that the looped threads have all the following stacktrace:
      java.lang.Thread.State: RUNNABLE
      at java.util.HashMap.get(Unknown Source)
      at com.liferay.portal.kernel.util.UnicodeProperties.getProperty(UnicodeProperties.java:77)
      at com.liferay.portal.model.impl.LayoutSetImpl.getThemeSetting(LayoutSetImpl.java:154)
      at com.liferay.portal.model.impl.LayoutImpl.getThemeSetting(LayoutImpl.java:449)
      at com.liferay.portal.theme.ThemeDisplay.getThemeSetting(ThemeDisplay.java:488)

      In the velocity script of my theme I read some theme settings with $theme.getSetting("....") !
      It seems a concurrency problem and it's difficult to reproduce it.
      I launched a Jmeter testing but it didn't help me to reproduce it.
      I read this article "http://javaeesupportpatterns.blogspot.it/2012/08/java-7-hashmap-vs-concurrenthashmap.html" and a possibile solution could be to use ConcurrentHashMap in UnicodeProperties .
      I saw that it was done for other LR bugs ( LPS-50484)
      Another particular issue is resolved similary on JVM http://bugs.java.com/view_bug.do?bug_id=7027300

      Is it the right way ?

      I used the "concurrenthashmap" article for to write a sample class to reproduce the endless loop locally.

      Riccardo

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              support-lep@liferay.com SE Support
              Reporter:
              riccardo Riccardo Martini
              Participants of an Issue:
              Recent user:
              Esther Sanz
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Created:
                Updated:
                Days since last comment:
                3 years, 48 weeks, 2 days ago

                  Packages

                  Version Package