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 145089 - java.io.FileNotFoundException on running completion unit tests
Summary: java.io.FileNotFoundException on running completion unit tests
Status: RESOLVED FIXED
Alias: None
Product: cnd
Classification: Unclassified
Component: -- Other -- (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: Alexander Simon
URL:
Keywords: RANDOM
Depends on:
Blocks:
 
Reported: 2008-08-26 06:16 UTC by Vladimir Voskresensky
Modified: 2008-09-04 06:02 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
other log (6.14 KB, text/plain)
2008-09-02 10:07 UTC, Alexander Simon
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Vladimir Voskresensky 2008-08-26 06:16:55 UTC
Today I've got during running completion's unit tests:
java.io.FileNotFoundException: /tmp/vv159170-cnd65-caches-0/DummyProjectN/cache-0-data (No such file or directory)
        at java.io.RandomAccessFile.open(Native Method)
        at java.io.RandomAccessFile.<init>(RandomAccessFile.java:212)
        at org.netbeans.modules.cnd.repository.sfs.BufferedRWAccess.<init>(BufferedRWAccess.java:94)
        at org.netbeans.modules.cnd.repository.sfs.IndexedStorageFile.createFileRWAccess(IndexedStorageFile.java:325)
        at org.netbeans.modules.cnd.repository.sfs.IndexedStorageFile.<init>(IndexedStorageFile.java:91)
        at org.netbeans.modules.cnd.repository.sfs.DoubleFileStorage.<init>(DoubleFileStorage.java:103)
        at org.netbeans.modules.cnd.repository.sfs.DoubleFileStorage.<init>(DoubleFileStorage.java:91)
        at org.netbeans.modules.cnd.repository.sfs.FileStorage.create(FileStorage.java:56)
        at org.netbeans.modules.cnd.repository.disk.UnitImpl.<init>(UnitImpl.java:67)
        at org.netbeans.modules.cnd.repository.disk.DiskRepositoryManager.getCreateUnit(DiskRepositoryManager.java:127)
        at org.netbeans.modules.cnd.repository.disk.DiskRepositoryManager.getCreateUnit(DiskRepositoryManager.java:112)
        at org.netbeans.modules.cnd.repository.disk.DiskRepositoryManager.tryGet(DiskRepositoryManager.java:183)
        at org.netbeans.modules.cnd.repository.impl.DelegateRepository.tryGet(DelegateRepository.java:99)
        at org.netbeans.modules.cnd.modelimpl.repository.RepositoryUtils.tryGet(RepositoryUtils.java:89)
        at org.netbeans.modules.cnd.modelimpl.csm.core.ProjectComponent.setStable(ProjectComponent.java:107)
        at org.netbeans.modules.cnd.modelimpl.csm.core.ProjectBase.onParseFinish(ProjectBase.java:1508)
        at org.netbeans.modules.cnd.modelimpl.csm.core.ParserQueue.onFileParsingFinished(ParserQueue.java:587)
        at org.netbeans.modules.cnd.modelimpl.csm.core.ParserThread.run(ParserThread.java:99)
        at org.netbeans.modules.cnd.modelimpl.csm.core.ParserThreadManager$Wrapper.run(ParserThreadManager.java:82)
        at java.lang.Thread.run(Thread.java:595)
Comment 1 Alexander Simon 2008-09-02 10:07:03 UTC
Created attachment 68838 [details]
other log
Comment 2 Alexander Simon 2008-09-03 14:43:50 UTC
It seems the method TraceModelBase.shutdown() works incorrectly.
It does not wait for finishing of model/parser tasks.
So repository can be disposed before other model tasks are finished.
As result the model tasks can throw a range of random exceptions.
This exceptions do not harm test because the main test algorithm have finished by exception time.
I added in the  TraceModelBase.shutdown() two waiting for:
- empty model tasks queue.
- empty parser queue.
- move library opening event in the model process.

fixed, change set:
http://hg.netbeans.org/main/rev/639e7b61e33c
Comment 3 Alexander Simon 2008-09-03 14:44:27 UTC
.
Comment 4 Quality Engineering 2008-09-04 06:02:11 UTC
Integrated into 'main-golden', will be available in build *200809040201* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/639e7b61e33c
User: Alexander Simon <alexvsimon@netbeans.org>
Log: fixed: IZ#145089:java.io.FileNotFoundException on running completion unit tests