This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 251464

Summary: IllegalThreadStateException: Should never be called from AWT thread
Product: versioncontrol Reporter: Alexander Simon <alexvsimon>
Component: CodeAssignee: Ondrej Vrabec <ovrabec>
Status: REOPENED ---    
Severity: normal CC: issues
Priority: P3    
Version: 8.1   
Hardware: All   
OS: All   
Issue Type: DEFECT Exception Reporter: 216403
Attachments: stacktrace

Description Alexander Simon 2015-03-27 17:09:08 UTC
Build: NetBeans IDE Dev (Build 20150327-185375e39672)
VM: Java HotSpot(TM) 64-Bit Server VM, 25.40-b25, Java(TM) SE Runtime Environment, 1.8.0_40-b26
OS: SunOS

User Comments:
alexvsimon: start IDE with opened remote files




Stacktrace: 
java.lang.IllegalThreadStateException: Should never be called from AWT thread
   at org.netbeans.modules.nativeexecution.api.util.MacroExpanderFactory.getExpander(MacroExpanderFactory.java:88)
   at org.netbeans.modules.nativeexecution.api.util.MacroExpanderFactory.getExpander(MacroExpanderFactory.java:70)
   at org.netbeans.modules.remote.impl.fs.server.FSSDispatcher.getOriginalFSServerPath(FSSDispatcher.java:441)
   at org.netbeans.modules.remote.impl.fs.server.FSSDispatcher.checkServerSetup(FSSDispatcher.java:474)
   at org.netbeans.modules.remote.impl.fs.server.FSSDispatcher.getOrCreateServer(FSSDispatcher.java:522)
   at org.netbeans.modules.remote.impl.fs.server.FSSDispatcher.dispatch(FSSDispatcher.java:363)
Comment 1 Alexander Simon 2015-03-27 17:09:09 UTC
Created attachment 152889 [details]
stacktrace
Comment 2 Vladimir Kvashin 2015-08-09 21:04:02 UTC
http://hg.netbeans.org/cnd-main/rev/1042264ca164
Comment 3 Vladimir Kvashin 2015-08-10 10:01:42 UTC
Please disregard my previous comment, it was intended for another bug.
Comment 4 Vladimir Kvashin 2016-03-23 20:34:27 UTC
This happened many times.
Version
getMenuPresenters()

createMenu()
Comment 5 Vladimir Kvashin 2016-03-23 20:39:20 UTC
(In reply to Vladimir Kvashin from comment #4)
Sorry, I occasuonaly added not yet complete comment.
What I wanted to say is:
- it happens many times
- it is also connected with long UI freezes
I think the issue is that VersioningMainMenu.getMenuPresenters() calls VersioningMainMenu.createMenu() which in turn calls VersioningManager.getOwners().

The latter is obviously a long operation - even on "local" directories (for example NFS mounts, but not necessarily).

So this should be taken out of UI thread.