Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 357558

Summary: FacetProjectCreationDataModelProvider creates listeners that are not cleaned up in the dispose method
Product: [WebTools] WTP Common Tools Reporter: Roberto Sanchez Herrera <shr31223>
Component: wst.commonAssignee: Roberto Sanchez Herrera <shr31223>
Status: RESOLVED FIXED QA Contact: Carl Anderson <ccc>
Severity: normal    
Priority: P3 Flags: ccc: review+
Version: 3.2.4   
Target Milestone: 3.2.5   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Bug Depends on:    
Bug Blocks: 357846    
Attachments:
Description Flags
Proposed patch none

Description Roberto Sanchez Herrera CLA 2011-09-13 16:42:17 EDT
The class org.eclipse.wst.common.componentcore.datamodel.FacetProjectCreationDataModelProvider creates listeners (IFacetedProjectListener and IDataModelListener) that are not cleaned up in the dispose method. This can cause problem in case other classes are using the data model after the provider is disposed. In fact, the provider should not act on the model if it has been already disposed.
Comment 1 Roberto Sanchez Herrera CLA 2011-09-13 17:12:11 EDT
Created attachment 203304 [details]
Proposed patch

Patch to remove the listeners on dispose. The model is set to null as well, given that this class should not act on the model after being disposed.
Comment 2 Carl Anderson CLA 2011-09-14 23:45:21 EDT
Committed to R3_2_maintenance for WTP 3.2.5.

I am leaving this open to get it into 3.3.2 and 3.4.0.
Comment 3 Roberto Sanchez Herrera CLA 2011-09-15 13:33:51 EDT
Bug 357846 created for 3.3.2 and HEAD. Resolving this defect
Comment 4 Roberto Sanchez Herrera CLA 2011-09-15 13:34:02 EDT
Bug 357846 created for 3.3.2 and HEAD. Resolving this defect