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.
Scenario: "some_tests" is folder name on remote machine. Folder has been renamed via "Rename..." context menu item in Favorites tab. We did not see the same exception before today. >Log Session: Wednesday, August 7, 2013 12:27:05 PM MSK >System Info: Product Version = NetBeans IDE 7.3 (Build 201306052037) (#93e87decaddf) Operating System = Windows 7 version 6.1 running on x86 Java; VM; Vendor = 1.7.0_21; Java HotSpot(TM) Client VM 23.21-b01; Oracle Corporation Runtime = Java(TM) SE Runtime Environment 1.7.0_21-b11 Java Home = C:\Program Files (x86)\Java\jdk1.7.0_21\jre System Locale; Encoding = en_US (nb); Cp1252 SEVERE: Can not rename to some_tests java.io.IOException: Can not rename to some_tests at org.netbeans.modules.remote.impl.fs.RemoteFileObjectBase.renameImpl(RemoteFileObjectBase.java:630) at org.netbeans.modules.remote.impl.fs.RemoteFileObjectBase.rename(RemoteFileObjectBase.java:607) at org.netbeans.modules.remote.impl.fs.RemoteFileObject.rename(RemoteFileObject.java:255) at org.openide.loaders.FileEntry$Folder.rename(FileEntry.java:444) at org.openide.loaders.MultiDataObject.handleRename(MultiDataObject.java:637) at org.openide.loaders.DataFolder.handleRename(DataFolder.java:690) at org.openide.loaders.DataObject$1Op.run(DataObject.java:721) at org.openide.loaders.DataObject$1WrapRun.run(DataObject.java:919) at org.openide.filesystems.EventControl.runAtomicAction(EventControl.java:127) at org.openide.filesystems.FileSystem.runAtomicAction(FileSystem.java:609) at org.openide.loaders.DataObjectPool.runAtomicActionSimple(DataObjectPool.java:229) at org.openide.loaders.DataObject.invokeAtomicAction(DataObject.java:936) at org.openide.loaders.DataObject.rename(DataObject.java:736) [catch] at org.netbeans.modules.refactoring.impl.FolderRenameHandlerImpl.handleRename(FolderRenameHandlerImpl.java:87) at org.openide.loaders.DataFolder$FolderNode.setName(DataFolder.java:1362) at org.openide.nodes.FilterNode.setName(FilterNode.java:487) at org.openide.nodes.FilterNode.setName(FilterNode.java:487) at org.netbeans.modules.favorites.FavoritesNode$ProjectFilterNode.setName(FavoritesNode.java:440) at org.openide.actions.RenameAction.performAction(RenameAction.java:102) at org.openide.util.actions.NodeAction$DelegateAction$1.run(NodeAction.java:586) at org.openide.util.actions.ActionInvoker$1.run(ActionInvoker.java:95) at org.openide.util.actions.ActionInvoker.doPerformAction(ActionInvoker.java:116) at org.openide.util.actions.ActionInvoker.invokeAction(ActionInvoker.java:99) at org.openide.util.actions.NodeAction$DelegateAction.actionPerformed(NodeAction.java:583) at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:2018) at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2341) at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:402) at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:259) at javax.swing.AbstractButton.doClick(AbstractButton.java:376) at javax.swing.plaf.basic.BasicMenuItemUI.doClick(BasicMenuItemUI.java:833) at javax.swing.plaf.basic.BasicMenuItemUI$Handler.mouseReleased(BasicMenuItemUI.java:877) at java.awt.Component.processMouseEvent(Component.java:6505) at javax.swing.JComponent.processMouseEvent(JComponent.java:3321) at java.awt.Component.processEvent(Component.java:6270) at java.awt.Container.processEvent(Container.java:2229) at java.awt.Component.dispatchEventImpl(Component.java:4861) at java.awt.Container.dispatchEventImpl(Container.java:2287) at java.awt.Component.dispatchEvent(Component.java:4687) at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4832) at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4492) at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4422) at java.awt.Container.dispatchEventImpl(Container.java:2273) at java.awt.Window.dispatchEventImpl(Window.java:2719) at java.awt.Component.dispatchEvent(Component.java:4687) at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:729) at java.awt.EventQueue.access$200(EventQueue.java:103) at java.awt.EventQueue$3.run(EventQueue.java:688) at java.awt.EventQueue$3.run(EventQueue.java:686) at java.security.AccessController.doPrivileged(Native Method) at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76) at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:87) at java.awt.EventQueue$4.run(EventQueue.java:702) at java.awt.EventQueue$4.run(EventQueue.java:700) at java.security.AccessController.doPrivileged(Native Method) at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76) at java.awt.EventQueue.dispatchEvent(EventQueue.java:699) at org.netbeans.core.TimableEventQueue.dispatchEvent(TimableEventQueue.java:159) at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:242) at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:161) at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:150) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:146) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:138) at java.awt.EventDispatchThread.run(EventDispatchThread.java:91)
I can't reproduce it manually. I also don't see it in the most recent test log. It might be fixed already. Does it repeat?
> Does it repeat? It is very very seldom exception in NetBeans 7.3.
This exception happens exactly when remote file system realises that a file with such name already exists in its parent. In other words, if you try renaming a file object to the same name twice, the second attempt will throw such exception. I also noticed that when you rename a node in explorer (in place), this is done in a separate thread and no visible effect until rename is complete. I would guess that the reason was that the file was being renamed in parallel from different threads; the thread that came second threw this exception. However I wasn't able to reproduce this even via setting breakpoints in debugger: code that I suspected (in-place renaming, renaming via "Rename to..." menu item) seems to have synchronization and check enough to not try renaming the file if it is just renamed. Anyhow, remote file system works as it should in this case, the issue is somewhere in callers.
fixed: http://hg.netbeans.org/cnd-main/rev/9892d1712e51