Summary: | Install/ delete (cleanup after [Cancel]) order | ||
---|---|---|---|
Product: | [Eclipse Project] Platform | Reporter: | Vlad Klicnik <klicnik> |
Component: | Update (deprecated - use Eclipse>Equinox>p2) | Assignee: | Christophe Elek <celek> |
Status: | RESOLVED FIXED | QA Contact: | |
Severity: | normal | ||
Priority: | P1 | ||
Version: | 2.0 | ||
Target Milestone: | 2.0 F2 | ||
Hardware: | PC | ||
OS: | Windows 2000 | ||
Whiteboard: | |||
Bug Depends on: | 17756 | ||
Bug Blocks: |
Description
Vlad Klicnik
2002-05-22 15:46:35 EDT
When deleting, we must first delete the feature.xml/ plugin.xml/ fragment.xml file BEFORE we attempt to delete the corresponding directories. boolean delete; if (xmlFile.exists()) { delete = xmlFile.delete(); } else { delete = true; } if (delete) { // delete the dir } We should try to delete as much as we can (ie. log ioexceptions and continue). Need to verify that when we reverse the install/ delete strategy, that we can in fact come up without problems with features that are missing plugins, or nested features that are missing children. Changed the way install closes. FeatureExecutableContentConsumer now doesn't close the SitePluginEntryContentConsumer but calls SiteFileContentConsumer.close() Which 1) renames feature.xml 2) close SitePluginEntryContentConsumer 3) returns a FeatureReference FeatureExecutableContentConsumer now closes the SiteFileContentConsumer, then closes teh children features tehn returns the featureReference from the root SiteFileContentConsumer. The log shows: install buttom up, rename top down LogEntry.0=START_INSTALL_LOG LogEntry.1=PLUGIN c:\oti\source-code\plugins\my.alphabet.round.letters_1.0.1\plugin1022354695014.xml LogEntry.2=PLUGIN c:\oti\source-code\plugins\my.alphabet.letter.b_1.0.1\plugin1022354695054.xml LogEntry.3=PLUGIN c:\oti\source-code\plugins\my.alphabet.letter.c_1.0.1\plugin1022354695114.xml LogEntry.4=FEATURE c:\oti\source-code\features\my.alphabet.round.letters_1.0.1\feature1022354695575.xml LogEntry.5=PLUGIN c:\oti\source-code\plugins\my.alphabet.straight.letters_1.0.1\plugin1022354696476.xml LogEntry.6=PLUGIN c:\oti\source-code\plugins\my.alphabet.letter.a_1.0.1\plugin1022354696516.xml LogEntry.7=PLUGIN c:\oti\source-code\plugins\my.alphabet.letter.e_1.0.1\plugin1022354696566.xml LogEntry.8=FEATURE c:\oti\source-code\features\my.alphabet.straight.letters_1.0.1\feature1022354696677.xml LogEntry.9=PLUGIN c:\oti\source-code\plugins\my.alphabet_1.0.1\plugin1022354696947.xml LogEntry.10=FEATURE c:\oti\source-code\features\my.alphabet_1.0.1\feature1022354697137.xml LogEntry.11=ALL_FEATURES_INSTALLED LogEntry.12=RENAME c:\oti\source-code\features\my.alphabet_1.0.1\feature1022354697137.xml LogEntry.13=RENAME c:\oti\source-code\plugins\my.alphabet_1.0.1\plugin1022354696947.xml LogEntry.14=RENAME c:\oti\source-code\features\my.alphabet.round.letters_1.0.1\feature1022354695575.xml LogEntry.15=RENAME c:\oti\source-code\plugins\my.alphabet.round.letters_1.0.1\plugin1022354695014.xml LogEntry.16=RENAME c:\oti\source-code\plugins\my.alphabet.letter.b_1.0.1\plugin1022354695054.xml LogEntry.17=RENAME c:\oti\source-code\plugins\my.alphabet.letter.c_1.0.1\plugin1022354695114.xml LogEntry.18=RENAME c:\oti\source-code\features\my.alphabet.straight.letters_1.0.1\feature1022354696677.xml LogEntry.19=RENAME c:\oti\source-code\plugins\my.alphabet.straight.letters_1.0.1\plugin1022354696476.xml LogEntry.20=RENAME c:\oti\source-code\plugins\my.alphabet.letter.a_1.0.1\plugin1022354696516.xml LogEntry.21=RENAME c:\oti\source-code\plugins\my.alphabet.letter.e_1.0.1\plugin1022354696566.xml LogEntry.22=END_INSTALL_LOG eof=eof SitePluginEntryContentConsumer.abort SiteFileContentConsumer.abort now delete the 'oldPath' (i.e before rename so feature.xml, plugin.xml or fragment.xml) before deleting the file it installed (even overrided file will be deleted) and deleting empty directories. The delete is buttom up LogEntry.0=START_INSTALL_LOG LogEntry.1=PLUGIN c:\oti\source-code\plugins\my.alphabet.round.letters_1.0.0\plugin1022360385887.xml LogEntry.2=PLUGIN c:\oti\source-code\plugins\my.alphabet.letter.b_1.0.0\plugin1022360385927.xml LogEntry.3=PLUGIN c:\oti\source-code\plugins\my.alphabet.letter.c_1.0.0\plugin1022360385967.xml LogEntry.4=FEATURE c:\oti\source-code\features\my.alphabet.round.letters_1.0.0\feature1022360386017.xml LogEntry.5=PLUGIN c:\oti\source-code\plugins\my.alphabet.straight.letters_1.0.0\plugin1022360386879.xml LogEntry.6=PLUGIN c:\oti\source-code\plugins\my.alphabet.letter.a_1.0.0\plugin1022360386929.xml LogEntry.7=DELETE c:/oti/source-code/plugins/my.alphabet.straight.letters_1.0.0/plugin.xml LogEntry.8=DELETE c:/oti/source-code/plugins/my.alphabet.letter.a_1.0.0/plugin.xml LogEntry.9=DELETE c:/oti/source-code/plugins/my.alphabet.round.letters_1.0.0/plugin.xml LogEntry.10=DELETE c:/oti/source-code/plugins/my.alphabet.letter.b_1.0.0/plugin.xml LogEntry.11=DELETE c:/oti/source-code/plugins/my.alphabet.letter.c_1.0.0/plugin.xml LogEntry.12=DELETE c:/oti/source-code/features/my.alphabet.round.letters_1.0.0/feature.xml Will release in version v20020525_17021 Verified 0528 |