After importing Flex 3 projects into FlashBuilder 4 and working succesfully for a while - 30 minutes or so - FB4 gets into a bad state where it does not recover. It starts to hang for minutes at a time, and is generally unresponsive. If I restart FB4, it comes up with the error "Could not create the view: Could not initialize class com.adobe.flexbuilder.util.logging.GlobalLog", leaving FB4 in an unusable state.

I've seen the problem described at http://uicomponent.com/blog/?p=292 . I tried the solution also described at that url, but it didn't work for me. I also tried uninstalling then reinstalling FB4, but I end up with the same problem. How do I recover from this?

!ENTRY org.eclipse.ui 4 0 2010-10-19 14:47:18.677!MESSAGE Unhandled event loop exception!STACK 0org.eclipse.swt.SWTException: Failed to execute runnable (java.lang.NoClassDefFoundError: Could not initialize class com.adobe.flexbuilder.util.logging.GlobalLog) at org.eclipse.swt.SWT.error(SWT.java:3884) at org.eclipse.swt.SWT.error(SWT.java:3799) at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:137) at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:3855) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3476) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2405) at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2369) at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2221) at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:500) at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:493) at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149) at com.adobe.flexbuilder.standalone.FlexBuilderApplication.start(FlexBuilderApplication.java :109) at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:194) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLau ncher.java:110) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.jav a:79) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:368) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179) 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:559) at org.eclipse.equinox.launcher.Main.basicRun(Main.java:514) at org.eclipse.equinox.launcher.Main.run(Main.java:1311)Caused by: 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.project.ui.decorators.ActionScriptApplicationBasicDecorator.getActi onScriptProject(ActionScriptApplicationBasicDecorator.java:123) at com.adobe.flexbuilder.project.ui.decorators.ActionScriptApplicationBasicDecorator.getProj ectDecoratedImage(ActionScriptApplicationBasicDecorator.java:172) at com.adobe.flexbuilder.editorcore.editor.CodeAndDesignEditor.getProjectDecoratedTitleImage (CodeAndDesignEditor.java:1288) at com.adobe.flexbuilder.editorcore.editor.CodeAndDesignEditor$5.run(CodeAndDesignEditor.jav a:1265) at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35) at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:134) ... 22 more

I regret to see FlashBuilder in such unfortuante situation. Did you try deleting (have a backup) the .metadata folder from your workspace location and then try starting FlashBuilder using -clean option? At instances, when the workspace messed up, Eclipse might fail in locating the bundles.

FlashBuilder.exe -clean

Please post your results after trying the above steps. Also, provide the .log file from the workspace/.metadata location after the crash.

Tried clearing the metadata files. That doesn't work. FB4 may come up without the error, but with no projects. If I add the projects back into my workspace, the whole cycle of problems occurs again.

If I create small test apps from scratch, FB4 works flawlessly. The problem occurs only when I import my existing Flex Builder 3 projects. So my guess is that I could probably fix the problem if I recreate all projects from scratch. But we have a large project with 6 swcs and over a dozen swfs. I was hoping I could just import my existing projects.

For what it's worth, I'm not trying to use version 4 sdk. Just trying to use FB4 in sdk 3 mode. I'd like to use FB4 for now if only because of the number of little things it adds like conditional breakpoints & type assist (statement completion), etc.

I resolved the issue I was having. If you are seeing the same behavior, try this out.

The problem was that FlashBuilder 4 could not handle the "path" property of libraryPathEntry tags in my .actionScripProperties file if the "path" was set to "libs". When Flash Builder 4 sees this, it chokes badly. My solution was to go through all my Flex Builder 3 projects' .actionScripProperties files and manually replaced this:

<libraryPathEntry kind="1" linkType="1" path="libs"/>

with this:

<libraryPathEntry kine="1" linkType="1" path="${myLibs}"/>

... or something like this. I then added the library setting "${myLibs"} to Flash Builder 4, THEN imported the Flex Builder 3 projects. Then At this point, everything went smoothly. Strange that Flex Builder 3 uses the "libs" value, but Flash Builder 4 can not handle it.

This is a continuation of log file H:\FINALWORKSPACE\.metadata\.bak_0.logCreated Time: 2011-02-14 11:32:38.880

!ENTRY org.eclipse.core.resources 4 2 2011-02-14 11:32:38.880!MESSAGE Problems occurred when invoking code from plug-in: "org.eclipse.core.resources".!STACK 0java.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.actionscript.ActionScriptCore.getAllProjects(ActionScriptCo re.java:806) at com.adobe.flexbuilder.project.actionscript.ActionScriptCore.getAllProjects(ActionScriptCo re.java:826) at com.adobe.flexbuilder.codemodel.common.CMFactory.preloadAllProjects(CMFactory.java:109) at com.adobe.flexbuilder.codemodel.common.CMFactory.getLockObject(CMFactory.java:82) at com.adobe.flexbuilder.codemodel.internal.project.EclipseProjectListener$ResourceChangeLis tener.resourceChanged(EclipseProjectListener.java:152) at org.eclipse.core.internal.events.NotificationManager$2.run(NotificationManager.java:291) at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42) at org.eclipse.core.internal.events.NotificationManager.notify(NotificationManager.java:285) at org.eclipse.core.internal.events.NotificationManager.broadcastChanges(NotificationManager .java:149) at org.eclipse.core.internal.resources.Workspace.broadcastPostChange(Workspace.java:313) at org.eclipse.core.internal.resources.Workspace.endOperation(Workspace.java:1022) at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:1809) at com.adobe.flexbuilder.project.FlexWorkspaceRunner.run(FlexWorkspaceRunner.java:61) at com.adobe.flexbuilder.debug.breakpoints.FlexBreakpoint.run(FlexBreakpoint.java:157) at com.adobe.flexbuilder.debug.breakpoints.FlexLineBreakpoint.resetTransientMarkerAttributes (FlexLineBreakpoint.java:237) at com.adobe.flexbuilder.debug.breakpoints.FlexLineBreakpoint.setMarker(FlexLineBreakpoint.j ava:216) at org.eclipse.debug.internal.core.BreakpointManager.createBreakpoint(BreakpointManager.java :533) at org.eclipse.debug.internal.core.BreakpointManager.loadBreakpoints(BreakpointManager.java: 267) at org.eclipse.debug.internal.core.BreakpointManager.initializeBreakpoints(BreakpointManager .java:434) at org.eclipse.debug.internal.core.BreakpointManager.getBreakpoints0(BreakpointManager.java: 403) at org.eclipse.debug.internal.core.BreakpointManager.hasBreakpoints(BreakpointManager.java:8 79) at org.eclipse.debug.internal.ui.actions.breakpoints.RemoveAllBreakpointsAction.isEnabled(Re moveAllBreakpointsAction.java:44) at org.eclipse.debug.internal.ui.actions.AbstractRemoveAllActionDelegate.update(AbstractRemo veAllActionDelegate.java:100) at org.eclipse.debug.internal.ui.actions.AbstractRemoveAllActionDelegate.init(AbstractRemove AllActionDelegate.java:86) at org.eclipse.ui.internal.WWinPluginAction.initDelegate(WWinPluginAction.java:189) at org.eclipse.ui.internal.PluginAction.createDelegate(PluginAction.java:125) at org.eclipse.ui.internal.PluginAction.selectionChanged(PluginAction.java:275) at org.eclipse.ui.internal.WWinPluginAction.refreshSelection(WWinPluginAction.java:275) at org.eclipse.ui.internal.WWinPluginAction.<init>(WWinPluginAction.java:121) at org.eclipse.ui.internal.ActionDescriptor.createAction(ActionDescriptor.java:265) at org.eclipse.ui.internal.ActionDescriptor.<init>(ActionDescriptor.java:176) at org.eclipse.ui.internal.PluginActionSetBuilder.createActionDescriptor(PluginActionSetBuil der.java:141) at org.eclipse.ui.internal.PluginActionBuilder.readElement(PluginActionBuilder.java:161) at org.eclipse.ui.internal.registry.RegistryReader.readElements(RegistryReader.java:144) at org.eclipse.ui.internal.registry.RegistryReader.readElementChildren(RegistryReader.java:1 33) at org.eclipse.ui.internal.PluginActionBuilder.readElement(PluginActionBuilder.java:144) at org.eclipse.ui.internal.registry.RegistryReader.readElements(RegistryReader.java:144) at org.eclipse.ui.internal.PluginActionSetBuilder.readActionExtensions(PluginActionSetBuilde r.java:268) at org.eclipse.ui.internal.PluginActionSetBuilder.processActionSets(PluginActionSetBuilder.j ava:230) at org.eclipse.ui.internal.ActionPresentation.setActionSets(ActionPresentation.java:184) at org.eclipse.ui.internal.WorkbenchWindow.updateActionSets(WorkbenchWindow.java:3234) at org.eclipse.ui.internal.WorkbenchWindow$27.run(WorkbenchWindow.java:2985) at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:70) at org.eclipse.ui.internal.WorkbenchWindow.setActivePage(WorkbenchWindow.java:2946) at org.eclipse.ui.internal.WorkbenchWindow$21.runWithException(WorkbenchWindow.java:2263) at org.eclipse.ui.internal.StartupThreading$StartupRunnable.run(StartupThreading.java:31) at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35) at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:134) at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:3855) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3476) at org.eclipse.ui.application.WorkbenchAdvisor.openWindows(WorkbenchAdvisor.java:803) at org.eclipse.ui.internal.Workbench$28.runWithException(Workbench.java:1384) at org.eclipse.ui.internal.StartupThreading$StartupRunnable.run(StartupThreading.java:31) at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35) at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:134) at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:3855) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3476) at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2316) at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2221) at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:500) at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:493) at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149) at com.adobe.flexbuilder.standalone.FlexBuilderApplication.start(FlexBuilderApplication.java :109) at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:194) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLau ncher.java:110) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.jav a:79) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:368) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179) 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:559) at org.eclipse.equinox.launcher.Main.basicRun(Main.java:514) at org.eclipse.equinox.launcher.Main.run(Main.java:1311)

For me, the problem seemed to be caused by the fact that a project I was importing was using a linked folder in the value of a libraryPathEntry. The post above seems to imply that a reference to a path relative to the project (inside it) was the problem - though I can't tell where "libs" really is in the post above.

For example, I had set up a variable in FB/Eclipse named "TOOLS" that pointed to a folder external to my project, and then created a linked folder inside the project that used that variable. ("File->New->Folder->Advanced->Linked Folder" in Eclipse) This resulted in the following as part of my .project file:

This all worked fine, until I migrated from FB4 to FB4.5. To migrate, I had to use a new Eclipse workspace, and had to import my existing projects into the new workspace. Importing a project with entries like above caused the errors mentioned in earlier posts. I found that if I first removed the references to these linked folders from my .actionScriptProperties and .project files, the import worked fine. Then, I had to re-create the linked folder, and add the library path swc folder back into the project manually from within FB - annoying, but not difficult.

I have found that using a linked resource/folder for a swc folder or source folder in the build path of a Flex or Flex Library project just doesn't work. When I originally set it up, it seems to work, but when I shutdown and re-start Eclipse/FB, or close and re-open the project, I run into the same problem again - FB can't open the project that uses the linked resource, and basically makes Eclipse/FB unusable. The reported error is the one mentioned above several times: can't find class com.adobe.flexbuilder.util.logging.GlobalLog, but I don't think that's a very accurate indication of the problem. If I remove the linked resource, and instead use a hard-coded path to the folder, things are okay.

I use linked resources the same way in Java projects, with no problems.

But if I import a project withOUT linked folders, and then add them, I still have the problem. So I don't think it's related to how I imported the project, I think it's related to the use of linked folders. But I'm open to suggestions.

I have the same problem with my Flash Builder 4.6 in one workspace, if I change workspace it works fine.

If I clear the .metadata folder and import all project again it works fine, untill I restart the computer. Then it happens again, it is specific one project that gives me a problem when I improt it so I guess it is the sinner. If I delete it and create this project lib again fra versioning system it works (untill next rebot).

Error message in Package exploror:

Could not create the view: Could not initialize class com.adobe.flexbuilder.util.logging.GlobalLog

java.lang.NoClassDefFoundError: Could not initialize class com.adobe.flexbuilder.util.logging.GlobalLog

at com.adobe.flexbuilder.project.actionscript.ActionScriptCore.getProject(ActionScriptCore.j ava:444)

at com.adobe.flexbuilder.project.FlexProjectManager.getActionScriptOrFlexProject(FlexProject Manager.java:739)

at com.adobe.flexbuilder.as.editor.ui.packageexplorer.content.FlexPackageExplorerContentMana ger.getSourceRoot(FlexPackageExplorerContentManager.java:642)

at com.adobe.flexbuilder.as.editor.ui.packageexplorer.FlexPackageExplorerContentProvider.get WorkspaceRootChildren(FlexPackageExplorerContentProvider.java:152)

at com.adobe.flexbuilder.as.editor.ui.packageexplorer.FlexPackageExplorerContentProvider.get Children(FlexPackageExplorerContentProvider.java:80)

at com.adobe.flexbuilder.as.editor.ui.packageexplorer.FlexPackageExplorerContentProvider.inp utChanged(FlexPackageExplorerContentProvider.java:449)

at org.eclipse.jface.viewers.ContentViewer.setInput(ContentViewer.java:276)

at org.eclipse.jface.viewers.StructuredViewer.setInput(StructuredViewer.java:1690)

at org.eclipse.ui.views.navigator.ResourceNavigator.createPartControl(ResourceNavigator.java :318)

at com.adobe.flexbuilder.as.editor.ui.packageexplorer.FlexPackageExplorer.createPartControl( FlexPackageExplorer.java:306)

at org.eclipse.ui.internal.ViewReference.createPartHelper(ViewReference.java:375)

at org.eclipse.ui.internal.ViewReference.createPart(ViewReference.java:229)

at org.eclipse.ui.internal.WorkbenchPartReference.getPart(WorkbenchPartReference.java:595)

at org.eclipse.ui.internal.WorkbenchPage$ActivationList.setActive(WorkbenchPage.java:4317)

at org.eclipse.ui.internal.WorkbenchPage$18.runWithException(WorkbenchPage.java:3359)

at org.eclipse.ui.internal.StartupThreading$StartupRunnable.run(StartupThreading.java:31)

at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35)

at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:135)

at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:4140)

at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3757)

at org.eclipse.ui.application.WorkbenchAdvisor.openWindows(WorkbenchAdvisor.java:803)

at org.eclipse.ui.internal.Workbench$33.runWithException(Workbench.java:1595)

at org.eclipse.ui.internal.StartupThreading$StartupRunnable.run(StartupThreading.java:31)

at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35)

at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:135)

at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:4140)

at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3757)

at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2604)

at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2494)

at org.eclipse.ui.internal.Workbench$7.run(Workbench.java:674)

at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)

at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:667)

at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)

at com.adobe.flexbuilder.standalone.FlashBuilderApplication.start(FlashBuilderApplication.ja va:108)

at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)

at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLau ncher.java:110)

at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.jav a:79)

at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:344)

at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)

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:622)

at org.eclipse.equinox.launcher.Main.basicRun(Main.java:577)

at org.eclipse.equinox.launcher.Main.run(Main.java:1410)

Error message in code:

Could not open the editor: Editor could not be initialized.

Why is it there is so many bugs in flash builder. I seems like a really buggy program, and bug in previous version are not fixed in the newer versions. Maybe because it is build upon third party software?