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 240120 - Long taking FS operation blocks scan.
Summary: Long taking FS operation blocks scan.
Status: RESOLVED FIXED
Alias: None
Product: platform
Classification: Unclassified
Component: Filesystems (show other bugs)
Version: 8.0
Hardware: All All
: P3 normal (vote)
Assignee: Jaroslav Havlin
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-01-08 14:43 UTC by Tomas Zezula
Modified: 2014-01-11 04:47 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tomas Zezula 2014-01-08 14:43:59 UTC
http://statistics.netbeans.org/exceptions/messageslog?id=704869 - blocked in masterfs:

java.io.WinNTFileSystem.canonicalize0(Native Method)
	java.io.Win32FileSystem.canonicalize(Win32FileSystem.java:414)
	java.io.File.getCanonicalPath(File.java:618)
	java.io.File.getCanonicalFile(File.java:643)
	org.netbeans.modules.masterfs.filebasedfs.fileobjects.FileObjectKeeper.isCyclicSymlink
Comment 1 Jaroslav Havlin 2014-01-10 14:14:14 UTC
http://hg.netbeans.org/core-main/rev/625d71a3acf3

I'm sorry, but I'm not sure this method can be significantly faster.
At least the value of canonical file path is now stored, so it isn't computed repeatedly for each path component with the same name (as the file name), but this is a minor improvement.

Anyway, calling the method on Windows was quite useless, because File.getCanonicalFile doesn't resolve symbolic links on this OS. The code now uses Java 7 NIO API, which should work properly on all operating systems.

If you have any idea how to improve the performance, please let me know.

Thank you for reporting, Tomas.
Comment 2 Quality Engineering 2014-01-11 04:47:16 UTC
Integrated into 'main-silver', will be available in build *201401110002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/625d71a3acf3
User: Jaroslav Havlin <jhavlin@netbeans.org>
Log: #240120: Do not resolve real path of a file repeatedly + fix FileObjectKeeper.isCyclicSymlink on Windows