User: starksm
Date: 02/04/04 00:26:20
Modified: src/main/org/jboss/deployment Tag: Branch_2_4
LegacyInstaller.java LocalDirInstaller.java
Log:
Add support for setting the context-root of a standalone war and support
for setting the virtual host of the war.
Revision Changes Path
No revision
No revision
1.1.2.2 +4 -30 jboss/src/main/org/jboss/deployment/Attic/LegacyInstaller.java
Index: LegacyInstaller.java
===================================================================
RCS file:
/cvsroot/jboss/jboss/src/main/org/jboss/deployment/Attic/LegacyInstaller.java,v
retrieving revision 1.1.2.1
retrieving revision 1.1.2.2
diff -u -r1.1.2.1 -r1.1.2.2
--- LegacyInstaller.java 10 Dec 2001 02:35:37 -0000 1.1.2.1
+++ LegacyInstaller.java 4 Apr 2002 08:26:20 -0000 1.1.2.2
@@ -45,7 +45,7 @@
*
* @author <a href="mailto:[EMAIL PROTECTED]">Daniel Schulze</a>
* @author [EMAIL PROTECTED]
- * @version $Revision: 1.1.2.1 $
+ * @version $Revision: 1.1.2.2 $
*/
public class LegacyInstaller implements Installer
{
@@ -155,8 +155,7 @@
case Deployment.WAR_MODULE:
{
// just inflate the package and determine the context name
- String webContext = getWebContext(src.toString());
-
+ String webContext = null;
log.info("inflate and install WEB module "+d.name);
File f = installInflate(new FileInputStream(localCopy), "web");
// Check for libs declared int the WAR jar manifest
@@ -245,14 +244,6 @@
{
String name = mod.getFileName();
String webContext = mod.getWebContext();
- if (webContext == null)
- // this line here is not smart yet!!!
- webContext = name.substring(Math.max(0,
name.lastIndexOf("/")));
-
- // make sure the context starts with a slash
- if (!webContext.startsWith("/"))
- webContext = "/"+webContext;
-
log.info("inflate and install WEB module "+name);
try
{
@@ -505,25 +496,8 @@
result = result.substring(result.lastIndexOf("/") + 1);
return result;
- }
-
-
- /** Generates a webcontex for the given url
- * @param _url an URL or something like that
- */
- public String getWebContext(String _url)
- {
- String s = getName(_url);
-
- // truncate the file extension
- int p = s.lastIndexOf(".");
- if (p != -1)
- s = s.substring(0, p);
-
- return "/" + s.replace('.', '/');
- }
-
-
+ }
+
/**
* Get the copy buffer (create new if null)
*/
1.1.2.2 +1 -10 jboss/src/main/org/jboss/deployment/Attic/LocalDirInstaller.java
Index: LocalDirInstaller.java
===================================================================
RCS file:
/cvsroot/jboss/jboss/src/main/org/jboss/deployment/Attic/LocalDirInstaller.java,v
retrieving revision 1.1.2.1
retrieving revision 1.1.2.2
diff -u -r1.1.2.1 -r1.1.2.2
--- LocalDirInstaller.java 10 Dec 2001 02:35:37 -0000 1.1.2.1
+++ LocalDirInstaller.java 4 Apr 2002 08:26:20 -0000 1.1.2.2
@@ -90,8 +90,7 @@
case Deployment.WAR_MODULE:
{
- String webContext = Util.getWebContext(src.toString());
-
+ String webContext = null;
log.info("inflate and install WEB module "+d.name);
// Check for libs declared int the WAR jar manifest
URL[] libs = libs = resolveLibraries(localPkg);
@@ -151,14 +150,6 @@
{
String name = mod.getFileName();
String webContext = mod.getWebContext();
- if (webContext == null)
- // this line here is not smart yet!!!
- webContext = name.substring(Math.max(0,
name.lastIndexOf("/")));
-
- // make sure the context starts with a slash
- if (!webContext.startsWith("/"))
- webContext = "/"+webContext;
-
log.debug("Process WEB module "+name);
try
{
_______________________________________________
Jboss-development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-development