This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 55417 - Detect previously installed profiler cluster and prompt the user
Summary: Detect previously installed profiler cluster and prompt the user
Status: RESOLVED FIXED
Alias: None
Product: installer
Classification: Unclassified
Component: Code (show other bugs)
Version: 4.x
Hardware: All All
: P3 blocker (vote)
Assignee: mslama
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-02-23 14:28 UTC by iformanek
Modified: 2005-09-05 10:00 UTC (History)
0 users

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description iformanek 2005-02-23 14:28:36 UTC
Since the installer does nto support upgrade, it 
should at least detect a previous installation of 
the profiler cluster and prompt the user to 
uninstall (or even launch the uninstallation when 
the user wants it, if possible).
Comment 1 iformanek 2005-02-23 14:30:42 UTC
Changed subcomponent to profiler
Comment 2 mslama 2005-06-14 10:17:11 UTC
Fixed first part. Checks selected destination if it is valid and empty:
/cvs/installer/profiler/src/org/netbeans/installer/cluster/Bundle.properties
new revision: 1.7; previous revision: 1.6

/cvs/installer/profiler/src/org/netbeans/installer/cluster/NetBeansDirChooserPanel.java
new revision: 1.2; previous revision: 1.1
Comment 3 mslama 2005-06-22 13:59:55 UTC
Implemented in main trunk. Dependency on shared library is added as profiler
installer uses now some shared classes.

Version ordering (necessary to detect if previous installation is older, the
same or newer) is defined as follows. Product UID (defined in Bundle.properties)
is 32 chars long. Last 6 chars is reserved for versioning. First 3 chars of
these reserved 6 chars contains major,minor and maintenance version of NetBeans
IDE. Ordering is defined by simple <,==,> operators on String or compareTo
method. Last 3 chars can be used to distinguish profiler versions. Their order
is defined in Bundle.properties. Current example is 
Order.length=2
Order.0=0de
Order.1=000
where "0de" is development version and "000" is FCS. FCS is greater or newer
version in this definition. You can add eg.milestone 7 as follows:
Order.length=3
Order.0=0de
Order.1=070
Order.1=000

If you have questions let me know. I can prepare testing builds with diferrent
versions to test it.

If older version of profiler is detected user can select uninstallation of
previous version. Uninstaller is run in separate thread to avoid blocking AWT
thread in installer and installer's UI is blocked.

Perhaps messages for all possibilities could be improved. This is just
implementation of logic.

Modified:
/cvs/installer/profiler/build.xml
new revision: 1.4; previous revision: 1.3

/cvs/installer/profiler/nbproject/project.xml
new revision: 1.3; previous revision: 1.2

/cvs/installer/profiler/src/org/netbeans/installer/cluster/Bundle.properties
new revision: 1.9; previous revision: 1.8

/cvs/installer/profiler/src/org/netbeans/installer/cluster/NetBeansDirChooserPanel.java
new revision: 1.3; previous revision: 1.2

/cvs/installer/profiler/src/org/netbeans/installer/cluster/SetSystemPropertiesAction.java
new revision: 1.2; previous revision: 1.1
Comment 4 mslama 2005-06-22 14:01:38 UTC
Sorry typo in previous example. Correct is:
Order.length=3
Order.0=0de
Order.1=070
Order.2=000