[modules-dev] [Fwd: Review request: 6589789, JRepo support for module install, uninstall]

Dave Bristor David.Bristor at Sun.COM
Fri Aug 24 16:43:54 PDT 2007


Hi folks,

Any comments on this one?  I haven't heard anything yet.  I've updated the 
webrev after integrating changes putback while I was away.

Thanks,
	Dave

-------- Original Message --------
Subject: Review request: 6589789, JRepo support for module install, uninstall
Date: Fri, 10 Aug 2007 18:59:43 -0700
From: Dave Bristor <david.bristor at sun.com>
To: modules-dev at openjdk.java.net

Building on top of 6563535 which I checked in this week, here is support for
installing and uninstalling modules using JRepo.  The usage becomes:

Usage: jrepo <command>, where command is follows one of the patterns below
	list [-v] [-p] [-r repositoryLocation] moduleName
	install [-v] -r repositoryLocation jamFile | jamURL
	uninstall [-v] [-f | -i] -r repositoryLocation moduleName [moduleVersion]
[modulePlatformBinding]

webrev: http://analemma.sfbay.sun.com/java/jdk/ws/libs/rev/6589789/
bugster: http://monaco.sfbay/detail.jsf?cr=6589789

A test is included; all tests pass on Solaris and Windows and I'm firing up a
JPRT run just now...

Some comments on the changes:

ExpandedJamRepository now removes files, as well as in-memory contents: this
effectively fixes 6574242 as well, which when this 5689789 is integrated, I
will close.  This removal of files was necessary for uninstall to work in the
tests.

Most of the individual tests are on a LocalRepository.  A few are added on a
URLRepository to be sure this works also.

Here's some sample output from using uninstall with -i (interactive):

% jrepo list -v -r repo
Repository file:/data/ws/jam-install/test/sun/module/tools/repo/
Name                 Version              Platform  Arch    Modified
Filename
JRepoModuleA         1.0                  SunOS     x86     8/9/07 4:20 PM
/data/ws/jam-install/test/sun/module/tools/repo/JRepoModuleA-1.0.jam-expanded
JRepoModuleB         1.0                  SunOS     x86     8/10/07 3:40 PM
/data/ws/jam-install/test/sun/module/tools/repo/JRepoModuleB-1.0.jam-expanded
JRepoModuleB         2.0                  SunOS     x86     8/10/07 6:50 PM
/data/ws/jam-install/test/sun/module/tools/repo/JRepoModuleB-2.0.jam-expanded
%
% jrepo uninstall -v -i -r repo JRepoModuleB
Multiple matches for module found.  Choose one of the below by index:
  0 JRepoModuleB         1.0                  SunOS     x86     8/10/07 3:40
PM   /data/ws/jam-install/test/sun/module/tools/repo/JRepoModuleB-1.0.jam-expanded
  1 JRepoModuleB         2.0                  SunOS     x86     8/10/07 6:50
PM   /data/ws/jam-install/test/sun/module/tools/repo/JRepoModuleB-2.0.jam-expanded

Index? 0
Uninstalled JRepoModuleB         1.0                  SunOS     x86
8/10/07 3:40 PM
/data/ws/jam-install/test/sun/module/tools/repo/JRepoModuleB-1.0.jam-expanded

If the user types any value outside the range of the indexes shown, they get:

     Invalid input <input>; try again

and the listing and prompting are repeated.

Thanks,
	Dave




More information about the modules-dev mailing list