Skip to Content
author's profile photo Former Member
Former Member

Java Heap Space Error in Reporting Cockpit

Hello guys,

Hope you could help me on this one. I'm a in hybris , and I'm just working my way on learning this new technology.

Part of the task I need to work on is to create a report using Hybris Reporting Cockpit. After uploading the jrxml file in the reporting cockpit, a "Java Heap Space" dialog box occurred in the reporting cockpit page. All other cockpits are OK (Storefront, HAC, HMC), I can access them, made some changes in them, etc., and it looks like the error is only persisting in the Hybris Reporting Cockpit..

Thinking that this issue might be related to memory issue, I tried to restart the Hybris server and the physical server to see if it will work, but it did not. I also tried to remove the jrxml file I've uploaded by deleting the report on the media folder, and then execute an update on the HAC, but even that step didn't work. I'm still seeing the Java Heap Space dialog box each time I login in the Reporting cockpit. Even the logs didn't show much information, the logs I saw didn;'t have any Java Heap Space logs on the log file.

Please take note that prior to this event, I have tried to create a report using a different jrxml file, and I was able to create a report without these errors being thrown.

Can you please advice me what might be the cause of the issue?

I have here the screenshot of the jrxml.

alt text

Thanks!

Jake

3015-heapspace.jpg (19.3 kB)
Add a comment
10|10000 characters needed characters exceeded

Related questions

4 Answers

  • author's profile photo Former Member
    Former Member
    Posted on May 20, 2015 at 05:40 PM

    Hi guys,

    My reporting cockpit is now working. The java heap space pop up is no longer appearing on the Reporting Cockpit page and I was able to create and export reports now.

    In able for me to fix this issue here's what I did:

    1. Navigated to the media folder where the jasperreport folder is located

    2. Deleted the medias created since the time that the Java Heap Space error occurred (in my local build, the error started last 18 May 2015)

    3. Restarted the Hybris Server afterwards

    4. On startup, logged in to the reporting cockpit and see if dashboard is now accessible.

    We're thinking that the reason that the Java Heap Space error is prompting up is that one of the reports previously created might have some bad code inside it, causing the cockpit into some kind of loop.

    Thanks for all the help! Really appreciate it! :)

    Regards, Jake

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on May 19, 2015 at 06:49 PM

    Did you adjust the tomcat options for java VM in local.properties like this?

     tomcat.generaloptions=-Xmx2G -XX:MaxPermSize=300M -ea -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Dorg.tanukisoftware.wrapper.WrapperManager.mbean=true -Djava.endorsed.dirs="%CATALINA_HOME%/lib/endorsed" -Dcatalina.base=%CATALINA_BASE% -Dcatalina.home=%CATALINA_HOME% -Dfile.encoding=UTF-8 -Dlog4j.configuration=log4j_init_tomcat.properties -Djava.util.logging.config.file=jdk_logging.properties -Djava.io.tmpdir="${HYBRIS_TEMP_DIR}"    
    

    Especially this part is important: "-Xmx2G -XX:MaxPermSize=300M"

    More info on platform configuration here:

    https://wiki.hybris.com/display/release5/Configuration+Properties+Reference

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi Konrad,

      Thanks for the response

      Current setup of my JVM for local.properties is: -Xmx2G -XX:MaxPermSize=256M. I even tried to increase its current value to -Xmx4G -XX:MaxPermSize=512M but I'm still getting the Java Heap Space issue on the Reporting cockpit.

      Regards, Jake

  • author's profile photo Former Member
    Former Member
    Posted on May 20, 2015 at 12:19 PM

    Try this tomcat.generaloptions=-Xmx4096M -XX:-UseLoopPredicate -XX:MaxPermSize=512M -XX:+HeapDumpOnOutOfMemoryError -ea -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Dorg.tanukisoftware.wrapper.WrapperManager.mbean=true -Djava.endorsed.dirs="%CATALINA_HOME%/lib/endorsed" -Dcatalina.base=%CATALINA_BASE% -Dcatalina.home=%CATALINA_HOME% -Dfile.encoding=UTF-8 -Dlog4j.configuration=log4j_init_tomcat.properties -Djava.util.logging.config.file=jdk_logging.properties -Djava.io.tmpdir="${HYBRIS_TEMP_DIR}"

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on May 20, 2015 at 02:27 PM

    Hi Sunil,

    Thanks for the response!

    Tried to add those but I'm still getting the same Java Heap Space error on the reporting cockpit. In addition to those configurations, I also tried to clear the cache, updated the local properties file, click the garbage collect on the HAC, before adding the said configuration and restarted hybris, but still the error keeps prompting in the dashboard of the reporting cockpit page.

    Regards, Jake

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.