4 Replies Latest reply on Feb 1, 2011 5:47 AM by Anirudh Sasikumar

    FB4 constantly crashes

    Wayne Christian

      Between these three exceptions (with FB3 and FB4) I've had a really hard time getting any work done.  Are people seeing these and

      have fixes?  FB4 crashes almost every other clean/build cycle for me.

      I've used many different permutations of values for Xmx and XX:MaxPermSize to no avail.  Currently they are set at

      -clean
      -nl
      en_US
      -startup
      plugins/org.eclipse.equinox.launcher_1.0.201.R35x_v20090715.jar
      --launcher.library
      plugins/org.eclipse.equinox.launcher.win32.win32.x86_1.0.200.v20090519
      -vmargs
      -Xms150m
      -Xmx1000m
      -XX:MaxPermSize=168m
      -XX:PermSize=96m
      -Xss256k
      -Djava.net.preferIPv4Stack=true
      -Dorg.eclipse.equinox.p2.reconciler.dropins.directory=dropins

      java.lang.OutOfMemoryError: unable to create new native thread
      at java.lang.Thread.start0(Native Method)
      at java.lang.Thread.start(Unknown Source)
      at org.eclipse.core.internal.jobs.WorkerPool.jobQueued(WorkerPool.java:145)
      at org.eclipse.core.internal.jobs.JobManager.schedule(JobManager.java:1001)
      at org.eclipse.core.internal.jobs.InternalJob.schedule(InternalJob.java:391)

       

      java.lang.NoClassDefFoundError: Could not initialize class com.adobe.flexbuilder.util.logging.GlobalLog
      at com.adobe.flexbuilder.project.actionscript.ActionScriptCore.getProject(ActionScriptCore.j ava:443)
      at com.adobe.flexbuilder.project.FlexProjectManager.getActionScriptOrFlexProject(FlexProject Manager.java:642)
      at com.adobe.flexbuilder.flashbridge.actions.FlashAction.readSelection(FlashAction.java:88)

       

      java.lang.StackOverflowError
      at java.lang.ClassLoader.defineClass1(Native Method)
      at java.lang.ClassLoader.defineClass(Unknown Source)
      at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.defineClass(DefaultClassLoader.j ava:183)
      at org.eclipse.osgi.baseadaptor.loader.ClasspathManager.defineClass(ClasspathManager.java:57 6)

        • 1. Re: FB4 constantly crashes
          TomBurgundy Level 1

          Hi

           

          My settings are (these are install defaults):

           

          eclipse.vmargs=-Xms256m

          -Xmx512m

          -XX:MaxPermSize=256m

          -XX:PermSize=64m

          Good luck

          • 2. Re: FB4 constantly crashes
            Balaji Sridhar Level 2

            Hi,

             

            Are you using Flash Builder 4 release?

             

            Is it a Stand Alone or Plugin Configuration?

             

            Does this happen only on the current system or across other systems too?

             

            Thanks,

            Balaji

            • 3. Re: FB4 constantly crashes
              Wayne Christian Level 1

              I'm using FB4, not the plug-in.  I was able to reduce the number of crashes by separating my library projects from my application projects.

              I'm not sure what you mean by 'across other systems'.  If you mean operating system, I've been running on Windows 7 using java jdk 1.6.0_18-b07

               

              Just before I replied, I got another (different) crash

               

              -clean
              -nl
              en_US
              -startup
              plugins/org.eclipse.equinox.launcher_1.0.201.R35x_v20090715.jar
              --launcher.library
              plugins/org.eclipse.equinox.launcher.win32.win32.x86_1.0.200.v20090519
              -vmargs
              -Xms150m
              -Xmx1024m
              -XX:MaxPermSize=256m
              -XX:PermSize=96m
              -Djava.net.preferIPv4Stack=true
              -Dorg.eclipse.equinox.p2.reconciler.dropins.directory=dropins

              I've had similar problems with different values for the settings...

               

              java.lang.OutOfMemoryError: Java heap space
              at java.util.HashMap.<init>(Unknown Source)
              at flex2.compiler.swc.SwcDependencySet.<init>(SwcDependencySet.java:66)
              at flex2.compiler.swc.catalog.CatalogReader$ScriptReader.clear(CatalogReader.java:400)
              at flex2.compiler.swc.catalog.CatalogReader$ScriptReader.endElement(CatalogReader.java:391)
              at flex2.compiler.swc.catalog.CatalogHandler.endElement(CatalogHandler.java:56)
              at org.apache.xerces.parsers.AbstractSAXParserMMImpl.endElement(AbstractSAXParserMMImpl.java :581)
              at org.apache.xerces.impl.XMLNSDocumentScannerMMImpl.scanEndElement(XMLNSDocumentScannerMMIm pl.java:550)
              at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch( Unknown Source)
              at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
              at org.apache.xerces.parsers.XML11ConfigurationMMImpl.parse(XML11ConfigurationMMImpl.java:23 0)
              at org.apache.xerces.parsers.DTDConfiguration.parse(Unknown Source)
              at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
              at org.apache.xerces.parsers.AbstractSAXParserMMImpl.parse(AbstractSAXParserMMImpl.java:1172 )
              at javax.xml.parsers.SAXParser.parse(Unknown Source)
              at javax.xml.parsers.SAXParser.parse(Unknown Source)
              at flex2.compiler.swc.catalog.CatalogReader.read(CatalogReader.java:89)
              at flex2.compiler.swc.Swc.read(Swc.java:428)
              at flex2.compiler.swc.Swc.<init>(Swc.java:91)
              at flex2.compiler.swc.SwcCache.getSwc(SwcCache.java:224)
              at flex2.compiler.swc.SwcCache.getSwcs(SwcCache.java:190)
              at flex2.compiler.swc.SwcCache.getSwcGroup(SwcCache.java:86)
              at flex2.compiler.swc.SwcCache.getSwcGroup(SwcCache.java:75)
              at flex2.compiler.CompilerSwcContext.load(CompilerSwcContext.java:81)
              at flex2.tools.oem.Library.compile(Library.java:1276)
              at flex2.tools.flexbuilder.BuilderLibrary.compile(BuilderLibrary.java:341)
              at com.adobe.flexbuilder.multisdk.compiler.internal.FlexLibraryBuilder$MyLibrary.mybuild(Fle xLibraryBuilder.java:282)
              at com.adobe.flexbuilder.multisdk.compiler.internal.FlexLibraryBuilder.build(FlexLibraryBuil der.java:117)
              at com.adobe.flexbuilder.multisdk.compiler.internal.ASBuilder.build(ASBuilder.java:190)
              at com.adobe.flexbuilder.project.compiler.internal.FlexProjectBuilder.buildItem(FlexProjectB uilder.java:480)
              at com.adobe.flexbuilder.project.compiler.internal.FlexProjectBuilder.build(FlexProjectBuild er.java:301)
              at com.adobe.flexbuilder.project.compiler.internal.FlexIncrementalBuilder.build(FlexIncremen talBuilder.java:157)
              at org.eclipse.core.internal.events.BuildManager$2.run(BuildManager.java:627)
              !

              • 4. Re: FB4 constantly crashes
                Anirudh Sasikumar Adobe Employee

                Some memory leaks have been fixed in the upcoming version of Flex SDK compiler. I believe those will resolve the issues you are facing.

                 

                For now, I'd suggest the following for large projects like yours which runs into out of memory errors frequently:

                 

                * Keep the amount of projects open at one point to a bare minimum. You can use absolute path to the SWC in the bin directory instead of the project in Properties -> Flex Build Path.

                * Move embedded assets into a runtime CSS file if possible. Runtime CSS files are compiled separately and only when you change the CSS file.