Please use the Apache issue tracking system for new NetBeans issues ( !!
Bug 234377 - Can not rename to ... (rename in Favorites tab) Can not rename to ... (rename in Favorites tab)
Product: cnd
Classification: Unclassified
Component: Remote
PC Windows 7
: P3 (vote)
: 8.0
Assigned To: Vladimir Kvashin
Depends on:
  Show dependency treegraph
Reported: 2013-08-14 11:50 UTC by soldatov
Modified: 2013-12-24 10:31 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT


Note You need to log in before you can comment on or make changes to this bug.
Description soldatov 2013-08-14 11:50:27 UTC
"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 Can not rename to some_tests
    at org.netbeans.modules.remote.impl.fs.RemoteFileObjectBase.renameImpl(
    at org.netbeans.modules.remote.impl.fs.RemoteFileObjectBase.rename(
    at org.netbeans.modules.remote.impl.fs.RemoteFileObject.rename(
    at org.openide.loaders.FileEntry$Folder.rename(
    at org.openide.loaders.MultiDataObject.handleRename(
    at org.openide.loaders.DataFolder.handleRename(
    at org.openide.loaders.DataObject$
    at org.openide.loaders.DataObject$
    at org.openide.filesystems.EventControl.runAtomicAction(
    at org.openide.filesystems.FileSystem.runAtomicAction(
    at org.openide.loaders.DataObjectPool.runAtomicActionSimple(
    at org.openide.loaders.DataObject.invokeAtomicAction(
    at org.openide.loaders.DataObject.rename(
[catch] at org.netbeans.modules.refactoring.impl.FolderRenameHandlerImpl.handleRename(
    at org.openide.loaders.DataFolder$FolderNode.setName(
    at org.openide.nodes.FilterNode.setName(
    at org.openide.nodes.FilterNode.setName(
    at org.netbeans.modules.favorites.FavoritesNode$ProjectFilterNode.setName(
    at org.openide.actions.RenameAction.performAction(
    at org.openide.util.actions.NodeAction$DelegateAction$
    at org.openide.util.actions.ActionInvoker$
    at org.openide.util.actions.ActionInvoker.doPerformAction(
    at org.openide.util.actions.ActionInvoker.invokeAction(
    at org.openide.util.actions.NodeAction$DelegateAction.actionPerformed(
    at javax.swing.AbstractButton.fireActionPerformed(
    at javax.swing.AbstractButton$Handler.actionPerformed(
    at javax.swing.DefaultButtonModel.fireActionPerformed(
    at javax.swing.DefaultButtonModel.setPressed(
    at javax.swing.AbstractButton.doClick(
    at javax.swing.plaf.basic.BasicMenuItemUI.doClick(
    at javax.swing.plaf.basic.BasicMenuItemUI$Handler.mouseReleased(
    at java.awt.Component.processMouseEvent(
    at javax.swing.JComponent.processMouseEvent(
    at java.awt.Component.processEvent(
    at java.awt.Container.processEvent(
    at java.awt.Component.dispatchEventImpl(
    at java.awt.Container.dispatchEventImpl(
    at java.awt.Component.dispatchEvent(
    at java.awt.LightweightDispatcher.retargetMouseEvent(
    at java.awt.LightweightDispatcher.processMouseEvent(
    at java.awt.LightweightDispatcher.dispatchEvent(
    at java.awt.Container.dispatchEventImpl(
    at java.awt.Window.dispatchEventImpl(
    at java.awt.Component.dispatchEvent(
    at java.awt.EventQueue.dispatchEventImpl(
    at java.awt.EventQueue.access$200(
    at java.awt.EventQueue$
    at java.awt.EventQueue$
    at Method)
    at java.awt.EventQueue$
    at java.awt.EventQueue$
    at Method)
    at java.awt.EventQueue.dispatchEvent(
    at org.netbeans.core.TimableEventQueue.dispatchEvent(
    at java.awt.EventDispatchThread.pumpOneEventForFilters(
    at java.awt.EventDispatchThread.pumpEventsForFilter(
    at java.awt.EventDispatchThread.pumpEventsForHierarchy(
    at java.awt.EventDispatchThread.pumpEvents(
    at java.awt.EventDispatchThread.pumpEvents(
Comment 1 Vladimir Kvashin 2013-08-19 10:25:15 UTC
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?
Comment 2 soldatov 2013-08-19 10:32:11 UTC
> Does it repeat?
It is very very seldom exception in NetBeans 7.3.
Comment 3 Vladimir Kvashin 2013-08-20 11:12:37 UTC
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.
Comment 4 Vladimir Kvashin 2013-12-24 10:31:58 UTC

By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2014, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo