java.lang.OutOfMemoryError

1
0
-1

Hi,

I got a big trouble with Bonita today. I was working normally in a process and suddenly I got a "Java heap size" error, I don't know where did it come from.

Then I close Bonita Studio and reboot my pc, then init Bonita again for working and see that it can't open my process.

I got a backup for my process but Bonita can't import it, I've change the JVM, change heap settings (Xms and Xmx args), reinstall bonita, try it in other pc but I can't recover my work.

I'm using Bonita 6.3.1 in a 6GB PC with more than 80% of memory free when Bonita is running, I use Windows Server 2012 R2, can anyone help me?

Thanks.

PD: Here is the bonita studio log:

!ENTRY org.bonitasoft.studio.engine.ex 1 0 2014-08-02 13:04:49.495
!INFO business_data.db.h2.db has been deleted successfuly
!SESSION 2014-08-02 13:10:08.683 -----------------------------------------------
eclipse.buildId=6.3.1.
java.version=1.7.0_65
java.vendor=Oracle Corporation
BootLoader constants: OS=win32, ARCH=x86_64, WS=win32, NL=es
Framework arguments:  --launcher.XXMaxPermSize2048m -groovy.compiler.level 18 -clearPersistedState
Command-line arguments:  -os win32 -ws win32 -arch x86_64 --launcher.XXMaxPermSize2048m -groovy.compiler.level 18 -clearPersistedState

!ENTRY org.eclipse.emf.ecore 2 0 2014-08-02 13:10:13.839
!WARNING Both 'org.bonitasoft.studio.configuration.ex' and 'org.bonitasoft.studio.jpdl' register an extension parser for 'xml'

!ENTRY org.bonitasoft.studio.application 1 0 2014-08-02 13:10:36.214
!INFO Startup duration : 00:00:23

!ENTRY org.bonitasoft.studio.actors 1 0 2014-08-02 13:11:33.777
!INFO Loading organization ACME in portal...

!ENTRY org.eclipse.ui 4 0 2014-08-02 13:12:21.011
!ERROR Unhandled event loop exception
!STACK 0
java.lang.OutOfMemoryError: Java heap space
        at com.sun.org.apache.xerces.internal.util.XMLStringBuffer.append(Unknown Source)
        at com.sun.org.apache.xerces.internal.util.XMLStringBuffer.append(Unknown Source)
        at com.sun.org.apache.xerces.internal.impl.XMLScanner.scanAttributeValue(Unknown Source)
        at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanAttribute(Unknown Source)
        at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanStartElement(Unknown Source)
        at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(Unknown Source)
        at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(Unknown Source)
        at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
        at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)
        at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)
        at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(Unknown Source)
        at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(Unknown Source)
        at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source)
        at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl.parse(Unknown Source)
        at org.eclipse.emf.ecore.xmi.impl.XMLLoadImpl.load(XMLLoadImpl.java:175)
        at org.eclipse.gmf.runtime.emf.core.resources.GMFLoad.load(GMFLoad.java:51)
        at org.eclipse.emf.ecore.xmi.impl.XMLResourceImpl.doLoad(XMLResourceImpl.java:253)
        at org.eclipse.emf.ecore.resource.impl.ResourceImpl.load(ResourceImpl.java:1518)
        at org.eclipse.emf.ecore.resource.impl.ResourceImpl.load(ResourceImpl.java:1297)
        at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLoad(ResourceSetImpl.java:259)
        at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLoadHelper(ResourceSetImpl.java:274)
        at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.getResource(ResourceSetImpl.java:406)
        at org.bonitasoft.studio.common.repository.filestore.EMFFileStore.doCreateEMFResource(EMFFileStore.java:54)
        at org.bonitasoft.studio.common.repository.filestore.EMFFileStore.getEMFResource(EMFFileStore.java:123)
        at org.bonitasoft.studio.diagram.custom.repository.DiagramFileStore.getEMFResource(DiagramFileStore.java:144)
        at org.bonitasoft.studio.common.repository.filestore.EMFFileStore.getContent(EMFFileStore.java:73)
        at org.bonitasoft.studio.diagram.custom.repository.DiagramFileStore.getContent(DiagramFileStore.java:92)
        at org.bonitasoft.studio.diagram.custom.repository.DiagramFileStore.closeEditorIfAlreadyOpened(DiagramFileStore.java:285)
        at org.bonitasoft.studio.diagram.custom.repository.DiagramFileStore.doOpen(DiagramFileStore.java:238)
        at org.bonitasoft.studio.common.repository.filestore.AbstractFileStore$2$1.run(AbstractFileStore.java:168)
        at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:70)
        at org.bonitasoft.studio.common.repository.filestore.AbstractFileStore$2.run(AbstractFileStore.java:164)

!ENTRY org.eclipse.ui 4 0 2014-08-02 13:12:35.590
!ERROR Unhandled event loop exception
!STACK 0
org.eclipse.e4.core.di.InjectionException: java.lang.OutOfMemoryError: Java heap space
        at org.eclipse.e4.core.internal.di.MethodRequestor.execute(MethodRequestor.java:63)
        at org.eclipse.e4.core.internal.di.InjectorImpl.invokeUsingClass(InjectorImpl.java:243)
        at org.eclipse.e4.core.internal.di.InjectorImpl.invoke(InjectorImpl.java:224)
        at org.eclipse.e4.core.contexts.ContextInjectionFactory.invoke(ContextInjectionFactory.java:132)
        at org.eclipse.e4.core.commands.internal.HandlerServiceHandler.execute(HandlerServiceHandler.java:167)
        at org.eclipse.core.commands.Command.executeWithChecks(Command.java:499)
        at org.eclipse.core.commands.ParameterizedCommand.executeWithChecks(ParameterizedCommand.java:508)
        at org.eclipse.e4.core.commands.internal.HandlerServiceImpl.executeHandler(HandlerServiceImpl.java:213)
        at org.eclipse.e4.ui.workbench.renderers.swt.HandledContributionItem.executeItem(HandledContributionItem.java:850)
        at org.eclipse.e4.ui.workbench.renderers.swt.HandledContributionItem.handleWidgetSelection(HandledContributionItem.java:743)
        at org.eclipse.e4.ui.workbench.renderers.swt.HandledContributionItem.access$7(HandledContributionItem.java:727)
        at org.eclipse.e4.ui.workbench.renderers.swt.HandledContributionItem$4.handleEvent(HandledContributionItem.java:662)
        at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
        at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1057)
        at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:4170)
        at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3759)
        at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$9.run(PartRenderingEngine.java:1113)
        at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
        at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:997)
        at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:138)
        at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:610)
        at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
        at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:567)
        at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:150)
        at org.bonitasoft.studio.application.BonitaStudioApplication.start(BonitaStudioApplication.java:104)
        at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
        at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
        at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
        at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:354)
        at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:181)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
        at java.lang.reflect.Method.invoke(Unknown Source)
        at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:636)
        at org.eclipse.equinox.launcher.Main.basicRun(Main.java:591)
        at org.eclipse.equinox.launcher.Main.run(Main.java:1450)
        at org.eclipse.equinox.launcher.Main.main(Main.java:1426)
Caused by: java.lang.OutOfMemoryError: Java heap space
        at com.sun.org.apache.xerces.internal.util.XMLStringBuffer.append(Unknown Source)
        at com.sun.org.apache.xerces.internal.util.XMLStringBuffer.append(Unknown Source)
        at com.sun.org.apache.xerces.internal.impl.XMLScanner.scanAttributeValue(Unknown Source)
        at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanAttribute(Unknown Source)
        at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanStartElement(Unknown Source)
        at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(Unknown Source)
        at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(Unknown Source)
        at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
        at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)
        at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)
        at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(Unknown Source)
        at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(Unknown Source)
        at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source)
        at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl.parse(Unknown Source)
        at org.eclipse.emf.ecore.xmi.impl.XMLLoadImpl.load(XMLLoadImpl.java:175)
        at org.eclipse.gmf.runtime.emf.core.resources.GMFLoad.load(GMFLoad.java:51)
        at org.eclipse.emf.ecore.xmi.impl.XMLResourceImpl.doLoad(XMLResourceImpl.java:253)
        at org.eclipse.emf.ecore.resource.impl.ResourceImpl.load(ResourceImpl.java:1518)
        at org.eclipse.emf.ecore.resource.impl.ResourceImpl.load(ResourceImpl.java:1297)
        at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLoad(ResourceSetImpl.java:259)
        at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLoadHelper(ResourceSetImpl.java:274)
        at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.getResource(ResourceSetImpl.java:406)
        at org.bonitasoft.studio.common.repository.filestore.EMFFileStore.doCreateEMFResource(EMFFileStore.java:54)
        at org.bonitasoft.studio.common.repository.filestore.EMFFileStore.getEMFResource(EMFFileStore.java:123)
        at org.bonitasoft.studio.diagram.custom.repository.DiagramFileStore.getEMFResource(DiagramFileStore.java:144)
        at org.bonitasoft.studio.common.repository.filestore.EMFFileStore.getContent(EMFFileStore.java:73)
        at org.bonitasoft.studio.diagram.custom.repository.DiagramFileStore.getContent(DiagramFileStore.java:92)
        at org.bonitasoft.studio.diagram.custom.repository.DiagramFileStore.getContent(DiagramFileStore.java:1)
        at org.bonitasoft.studio.engine.ui.wizard.AbstractProcessContentProvider.getElements(AbstractProcessContentProvider.java:86)
        at org.eclipse.jface.viewers.StructuredViewer.getRawChildren(StructuredViewer.java:1010)
        at org.eclipse.jface.viewers.ColumnViewer.getRawChildren(ColumnViewer.java:721)
        at org.eclipse.jface.viewers.AbstractTreeViewer.getRawChildren(AbstractTreeViewer.java:1351)
2 answers

1
0
-1

Hi,

it seems that there is a strange content in the .proc file inside diagrams folder. Line 887, there are a lot of special characters (around 1000). It seems that the OOM occurs when we try tp read the content of the attribute with this value. Please try to edit this file and remove all these characters.

Regards,

1
0
-1

Hi,

What is the isseu with your process? What is happening when you are trying to opening it again? Also an OOM or "only" an error?

if it is an OOM, please try to add -XX:+HeapDumpOnOutmemoryError to the BonitaSutdio.ini file just after the -Xmx option (on a new line). then you will eb able to open a bug and provide the Heap Dump in orer that we can analyze it. Please also provide the process that you can't import anymore.

regards,

Comments

Submitted by dbravo on Mon, 08/11/2014 - 16:15

Hi, Thanks,

I've modified to the ini file but when the exception is thrown I can't find the Heap Dump, well, I can't put that arg after the -Xmx option on a new line because Bonita does not start.

I attach my bonita ini file and the .bos with the problem.

Thanks again.

The .bos file: http://1drv.ms/1r58xC5 * CAUTION: Please take care if you try to import the .bos file because it could damage your environment (losing ALL your work) and make your bonita useless, make a backup of your bonita workspace before import it. I'm not responsible for any losses that may occur. *, it sounds ugly, but that happens to me and I don't want it happens to you.

BonitaBPMSubscription.ini:

-startup
plugins/org.eclipse.equinox.launcher_1.3.0.v20130327-1440.jar
--launcher.library
plugins/org.eclipse.equinox.launcher.win32.win32.x86_64_1.1.200.v20130807-1835
--launcher.XXMaxPermSize512m
-groovy.compiler.level
18
-clearPersistedState
-vmargs
-Xmx512m
-Xms128m
-XX:MaxPermSize=256m
-Dbonita.client.home=lic_folder
-Dgreclipse.nonlocking=true
-Djava.endorsed.dirs=endorsed-XX:+HeapDumpOnOutmemoryError
Submitted by aurelien.pupier on Mon, 08/11/2014 - 16:19

Hi,

sorry I mispelled the Option, there is a capital letter that is missing :s

BonitaBPMSubscription.ini:

-startup
plugins/org.eclipse.equinox.launcher_1.3.0.v20130327-1440.jar
--launcher.library
plugins/org.eclipse.equinox.launcher.win32.win32.x86_64_1.1.200.v20130807-1835
--launcher.XXMaxPermSize512m
-groovy.compiler.level
18
-clearPersistedState
-vmargs
-Xmx512m
-Xms128m
-XX:MaxPermSize=256m
-Dbonita.client.home=lic_folder
-Dgreclipse.nonlocking=true
-Djava.endorsed.dirs=endorsed
-XX:+HeapDumpOnOutMemoryError
Submitted by dbravo on Mon, 08/11/2014 - 16:32

Thank but it didn't work, I mean, I didn't find the heap dump file, where is supposed it has to be?

Submitted by aurelien.pupier on Mon, 08/11/2014 - 16:40

it should be next to the executable from which it is launched. it is called something like java.hprof (it depends on the JVM implemntation)

You can add also -XX:HeapDumPath=C:\my.hprof in order to force where the file will be created. Documentaiton for this argument here: http://docs.oracle.com/cd/E15289_01/doc.40/e15062/optionxx.htm#BABIDFGC

Regards,

Submitted by dbravo on Mon, 08/11/2014 - 17:25

It didn't work yet, if I put those args to the ini Bonita can't start.

Screenshots: http://1drv.ms/1rihnaU

http://1drv.ms/1rihfIA
Notifications