[jboss-cvs] JBossAS SVN: r83692 - in projects/ejb3/trunk/installer/src/main: resources and 1 other directories.

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Fri Jan 30 10:40:55 EST 2009


Author: wolfc
Date: 2009-01-30 10:40:54 -0500 (Fri, 30 Jan 2009)
New Revision: 83692

Modified:
   projects/ejb3/trunk/installer/src/main/java/org/jboss/ejb3/installer/Installer.java
   projects/ejb3/trunk/installer/src/main/resources/build-install-ejb3-plugin.xml
   projects/ejb3/trunk/installer/src/main/resources/conf/jbossas-ejb3-files-to-place-in-deploy-unclustered.txt
Log:
EJBTHREE-1708: created a means to install simple packages

Modified: projects/ejb3/trunk/installer/src/main/java/org/jboss/ejb3/installer/Installer.java
===================================================================
--- projects/ejb3/trunk/installer/src/main/java/org/jboss/ejb3/installer/Installer.java	2009-01-30 15:25:07 UTC (rev 83691)
+++ projects/ejb3/trunk/installer/src/main/java/org/jboss/ejb3/installer/Installer.java	2009-01-30 15:40:54 UTC (rev 83692)
@@ -133,6 +133,8 @@
     * Pointer to the installer JAR file
     */
    private JarFile installerJarFile;
+   
+   private boolean cleanup;
 
    // Main
 
@@ -153,17 +155,18 @@
       }
 
       // Create Installer
-      Installer installer = new Installer(jbossDir);
+      Installer installer = new Installer(jbossDir, args.length == 1);
 
       // Install
       installer.install();
    }
 
    // Constructor
-   public Installer(String jbossAsInstallationDirectory)
+   public Installer(String jbossAsInstallationDirectory, boolean cleanup)
    {
       // Set JBoss AS Install Location
       this.setJbossAsInstallationDirectory(new File(jbossAsInstallationDirectory));
+      this.cleanup = cleanup;
    }
 
    /**
@@ -178,7 +181,8 @@
       this.getPrintStream().println("Installing EJB3 Libraries to Temp Directory...");
 
       // Add Shutdown Hook
-      Runtime.getRuntime().addShutdownHook(new Shutdown());
+      if(cleanup)
+         Runtime.getRuntime().addShutdownHook(new Shutdown());
 
       // Ensure Installation is clean
       this.cleanup();
@@ -200,6 +204,11 @@
          this.copyFileFromJarToDirectory(this.getInstallerJarFile(), conf, this.getInstallationDirectory());
       }
 
+      for(JarEntry pkg : getAllJarEntriesInDirectory("packages"))
+      {
+         copyFileFromJarToDirectory(this.getInstallerJarFile(), pkg, this.getInstallationDirectory());
+      }
+      
       // Copy the buildfile to the installer temp directory
       this.copyFileFromJarToDirectory(this.getInstallerJarFile(), this.getInstallerJarFile().getJarEntry(
             Installer.FILENAME_BUILDFILE), this.getInstallationDirectory());

Modified: projects/ejb3/trunk/installer/src/main/resources/build-install-ejb3-plugin.xml
===================================================================
--- projects/ejb3/trunk/installer/src/main/resources/build-install-ejb3-plugin.xml	2009-01-30 15:25:07 UTC (rev 83691)
+++ projects/ejb3/trunk/installer/src/main/resources/build-install-ejb3-plugin.xml	2009-01-30 15:40:54 UTC (rev 83692)
@@ -132,8 +132,18 @@
     <!-- Rebuild Client JARs -->
     <antcall target="rebuild-jboss-ejb3-client" />
 
+    <foreach target="install-package" param="package.file">
+      <path>
+      	<fileset dir="packages" includesfile="packages/package-list.txt" />
+      </path>
+    </foreach>
   </target>
 
+  <target name="install-package">
+    <echo message="Installing package ${package.file}"/>
+    <ant antfile="${package.file}" target="install"/>
+  </target>
+  
   <!-- 
   
   Cleans existing EJB3 Binaries from

Modified: projects/ejb3/trunk/installer/src/main/resources/conf/jbossas-ejb3-files-to-place-in-deploy-unclustered.txt
===================================================================
--- projects/ejb3/trunk/installer/src/main/resources/conf/jbossas-ejb3-files-to-place-in-deploy-unclustered.txt	2009-01-30 15:25:07 UTC (rev 83691)
+++ projects/ejb3/trunk/installer/src/main/resources/conf/jbossas-ejb3-files-to-place-in-deploy-unclustered.txt	2009-01-30 15:40:54 UTC (rev 83692)
@@ -1,4 +1,3 @@
 ejb3-connectors-service.xml
 ejb3-container-jboss-beans.xml
-ejb3-interceptors-aop.xml
-ejb3-timer-service.xml
\ No newline at end of file
+ejb3-interceptors-aop.xml
\ No newline at end of file




More information about the jboss-cvs-commits mailing list