Bug 210313 - Removing JPA facet does not clean up resources
Summary: Removing JPA facet does not clean up resources
Status: NEW
Alias: None
Product: Dali JPA Tools
Classification: WebTools
Component: JPA (show other bugs)
Version: 1.0.1   Edit
Hardware: PC Windows XP
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Neil Hauge CLA
QA Contact:
URL:
Whiteboard:
Keywords: helpwanted
Depends on:
Blocks:
 
Reported: 2007-11-19 18:13 EST by Tom Mutdosch CLA
Modified: 2011-07-01 16:24 EDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tom Mutdosch CLA 2007-11-19 18:13:40 EST
One of our users noted that if you add the JPA facet to a project it adds the persistence.xml and orm.xml files at that time.  But if you later remove the JPA facet, those resources are left around.  

I'm not sure what the general behavior for most facets is in the similar circumstance.  It might make sense that the artifacts should be cleaned up when the facet is removed.  I guess it depends on what the user would intend by removing the facet - if they no longer wanted JPA support in the application and removed the facet, when they ran on the server all of the JPA artifacts would still be loaded/executed which might no longer be intended.
Comment 1 Paul Fullbright CLA 2007-11-19 18:35:54 EST
Yes, this was intended behavior.  We didn't feel comfortable *deleting* resources when the facet was removed, especially because some users prefer to keep editing their JPA resources without our facet present.

Marking this as an enhancement.
Comment 2 Neil Hauge CLA 2008-07-10 13:13:52 EDT
I think in order to implement this there would need to be an additional step on Facet removal that allowed for a decision to be made by the user.  I'm not sure if there is any support for this in the facet framework at this time, but it is something that could be looked into.
Comment 3 Neil Hauge CLA 2011-07-01 16:24:43 EDT
Moving JPA specific bugs to new JPA component in bugzilla.