Thursday, February 20, 2014

java.lang.OutOfMemoryError: Java heap space when Jdeveloper integrated with SVN

When we have jdeveloper integrated with SVN, jdeveloper requires more heap space and below error might occur.

Uncaught exception
java.lang.OutOfMemoryError: Java heap space
  j.util.Arrays.copyOf(Arrays.java:2882)
  j.lang.AbstractStringBuilder.expandCapacity(AbstractStringBuilder.java:100)
  j.lang.AbstractStringBuilder.append(AbstractStringBuilder.java:390)
  j.lang.StringBuffer.append(StringBuffer.java:224)
  org.tmatesoft.svn.core.SVNErrorMessage.getFullMessage(SVNErrorMessage.java:257)
  org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:58)
  org.tmatesoft.svn.core.internal.wc.admin.SVNAdminAreaFactory.open(SVNAdminAreaFactory.java:163)
  org.tmatesoft.svn.core.internal.wc.admin.SVNWCAccess.doOpen(SVNWCAccess.java:364)
  org.tmatesoft.svn.core.internal.wc.admin.SVNWCAccess.open(SVNWCAccess.java:272)
  org.tmatesoft.svn.core.internal.wc.admin.SVNWCAccess.open(SVNWCAccess.java:265)
  org.tmatesoft.svn.core.internal.wc.admin.SVNWCAccess.openAnchor(SVNWCAccess.java:145)
  org.tmatesoft.svn.core.wc.SVNStatusClient.doStatus(SVNStatusClient.java:320)
  org.tmatesoft.svn.core.javahl.SVNClientImpl.status(SVNClientImpl.java:296)
  org.tmatesoft.svn.core.javahl.SVNClientImpl.status(SVNClientImpl.java:278)
  org.tigris.subversion.svnclientadapter.javahl.AbstractJhlClientAdapter.getStatus(AbstractJhlClientAdapter.java:480)
  org.tigris.subversion.svnclientadapter.svnkit.SvnKitClientAdapter.getStatus(SvnKitClientAdapter.java:141)
  org.tigris.subversion.svnclientadapter.javahl.AbstractJhlClientAdapter.getStatus(AbstractJhlClientAdapter.java:466)
  o.ji.vcs.svn.SVNURLInfoCacheSimpleStrategy.getURLInfo(SVNURLInfoCacheSimpleStrategy.java:79)
  o.ji.vcs.svn.SVNURLInfoCache.getLastChangedRevision(SVNURLInfoCache.java:69)
  o.ji.vcs.svn.SVNOverlayProducer.createTooltip(SVNOverlayProducer.java:240)
  o.ji.vcs.svn.SVNOverlayProducer.getDecoratedOverlay(SVNOverlayProducer.java:144)
  o.ji.vcs.svn.SVNOverlayProducer.produceOverlay(SVNOverlayProducer.java:113)
  o.j.vcs.spi.VCSOverlayItemProducer.produceOverlays(VCSOverlayItemProducer.java:83)
  o.j.vcs.spi.VCSOverlayItemProducer.getOverlayItems(VCSOverlayItemProducer.java:65)
  o.j.vcs.spi.VCSNodeOverlayTracker.getOverlays(VCSNodeOverlayTracker.java:288)
  o.i.explorer.IconOverlayTracker.processPendingNodes(IconOverlayTracker.java:574)
  o.i.explorer.IconOverlayTracker.access$1400(IconOverlayTracker.java:69)
  o.i.explorer.IconOverlayTracker$7.run(IconOverlayTracker.java:487)
  j.util.TimerThread.mainLoop(Timer.java:512)
  j.util.TimerThread.run(Timer.java:462)





The heap space can be increased for JDeveloper by modifying the ide.conf and jdev.conf files of your jdeveloper installation and below is a sample value.
$installationdir\jdeveloper\ide\bin\ide.conf 

AddVMOption  -Xmx1024M
AddVMOption  -Xms128M
$installationdir\jdeveloper\jdev\bin\jdev.conf

AddVMOption  -XX:MaxPermSize=1024M

The maximum size depends on the operating system and if the errors still persist we can disable the SVN connection.

 JDeveloper > Choose Versioning>Configure  and Uncheck 'Versioning support for Subversion'



Tools like Tortoise SVN can be used to do the version control.



No comments:

Post a Comment