Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 349874 - IRs are being cached in two places
Summary: IRs are being cached in two places
Status: CLOSED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: EDT (show other bugs)
Version: unspecified   Edit
Hardware: PC Linux
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Justin Spadea CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-06-20 17:12 EDT by Justin Spadea CLA
Modified: 2017-02-23 14:14 EST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Justin Spadea CLA 2011-06-20 17:12:55 EDT
There are places that call IEnvironment.save() with the serialize flag set to false, meaning "cache the IR but don't write to disk". Unfortunately with the current API this propagates to another save() method with the boolean flag gone, and in its place is an IObjectStore. If the store is null, then we just cache it, otherwise we write to disk using the store.

The problem is that the builder has object stores that hold onto their own caches. We need the store so that we can tell it to cache the part. Otherwise it gets cached in the map from AbstractEnvironment. However we don't want the store to write it to disk. One thought is maybe we could use the key to locate the appropriate store - and if no stores "own" that part, then it would fall back on super's implementation.
Comment 1 Justin Spadea CLA 2011-08-23 12:53:44 EDT
Fixed the following files:

IFileSystemObjectStore.java
ProjectBuildPathEntry.java
ProjectIREnvironment.java
AbstractEnvironment.java
CachingObjectStore.java
ZipFileObjectStore.java
Comment 2 Justin Spadea CLA 2011-09-08 14:36:17 EDT
Verified