Please use the Apache issue tracking system for new NetBeans issues (https://issues.apache.org/jira/projects/NETBEANS0/issues) !!
Bug 120742 - Error processing when opening persistence storage for a project should be improved
Error processing when opening persistence storage for a project should be imp...
Status: RESOLVED DUPLICATE of bug 158277
Product: cnd
Classification: Unclassified
Component: Code Model
6.x
Sun All
: P3 (vote)
: 6.x
Assigned To: Vladimir Kvashin
issues@cnd
repository
:
Depends on: 127727
Blocks:
  Show dependency treegraph
 
Reported: 2007-10-31 23:53 UTC by Vladimir Kvashin
Modified: 2009-05-05 11:41 UTC (History)
0 users

See Also:
Issue Type: DEFECT
:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Vladimir Kvashin 2007-10-31 23:53:11 UTC
This concerns situations when for some reason persistence data for a project is inconsistent.
(For example, index file exists, but data file does not, etc.)
Error processing for such situations should be improved.
There should be two different modes:
1) creating a set of persistence files 
2) opening a set of persistence files
In the 2-nd mode any inconsistence or IOException should be thrown and caught somewhere on upper level; in the case of
such exception, persistence for a project is considered corrupted, it's cleaned and created from scratch (via 1-st mode).

Unfortunately now it's not the case:
a) there are places where files are silently created if they don't exist (which breaks consistency in some cases)
b) return values are used instead of exceptions; in the situation of complex code this makes it error prone

All these should be refactored.
Comment 1 Jesse Grodnik 2007-12-19 22:51:25 UTC
This refactoring is planned for Netbeans 6.1.
Comment 2 Vladimir Kvashin 2008-03-28 16:35:52 UTC
The only known end-user consequence is that if user manually deletes some (but not all) persistence files
and then opens correspondent projects in the IDE,
he/she will get a lot of assertions and the language model will be broken.

But the described action is rather weird thing to do.

The workaround is - to delete the entire project storage (or all persistence data).

This still should be fixed; but it isn't a P2 defect.
Downgrading to P3.
Comment 3 Vladimir Voskresensky 2009-05-05 11:41:11 UTC

*** This issue has been marked as a duplicate of 158277 ***


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