shuber 2005/10/28 12:01:50 CEST
Modified files: (Branch: JAHIA-4-1-BRANCH)
src/java/org/jahia/bin JahiaConfigurationWizard.java
src/java/org/jahia/services/applications
ServletIncludeRequestWrapper.java
Log:
- Remove tests in configuration wizard that posed problems when Jahia was
installed in ROOT configuration
- Bugfix for JAHIA-366 Remove JSessionID from getPathInfo() parameter.
Revision Changes Path
1.55.2.2.2.7 +7 -2
jahia/src/java/org/jahia/bin/JahiaConfigurationWizard.java
http://jahia.mine.nu:8080/cgi-bin/cvsweb.cgi/jahia/src/java/org/jahia/bin/JahiaConfigurationWizard.java.diff?r1=1.55.2.2.2.6&r2=1.55.2.2.2.7&f=h
1.23.2.4.2.3 +13 -11
jahia/src/java/org/jahia/services/applications/ServletIncludeRequestWrapper.java
http://jahia.mine.nu:8080/cgi-bin/cvsweb.cgi/jahia/src/java/org/jahia/services/applications/ServletIncludeRequestWrapper.java.diff?r1=1.23.2.4.2.2&r2=1.23.2.4.2.3&f=h
Index: JahiaConfigurationWizard.java
===================================================================
RCS file:
/home/cvs/repository/jahia/src/java/org/jahia/bin/Attic/JahiaConfigurationWizard.java,v
retrieving revision 1.55.2.2.2.6
retrieving revision 1.55.2.2.2.7
diff -u -r1.55.2.2.2.6 -r1.55.2.2.2.7
--- JahiaConfigurationWizard.java 13 Sep 2005 09:33:51 -0000
1.55.2.2.2.6
+++ JahiaConfigurationWizard.java 28 Oct 2005 10:01:50 -0000
1.55.2.2.2.7
@@ -1,4 +1,4 @@
-// $Id: JahiaConfigurationWizard.java,v 1.55.2.2.2.6 2005/09/13 09:33:51
pvollenweider Exp $
+// $Id: JahiaConfigurationWizard.java,v 1.55.2.2.2.7 2005/10/28 10:01:50
shuber Exp $
//
// ____.
// __/\ ______| |__/\. _______
@@ -742,6 +742,10 @@
// try the servlet container home disk path...
tryServerHome();
+ /**
+ * Deactivated because :
+ * - it's specific to Tomcat
+ * - doesn't work when Jahia is installed in ROOT context.
if
(serverInfos.get("type").equals(JahiaConstants.SERVER_TOMCAT)) {
// try the host url connection...
tryHostURL();
@@ -749,6 +753,7 @@
// try the host url connection...
tryWebAppsDeployBaseURL();
}
+ */
// try the path to jahia files (permissions, etc)...
tryJahiaFilesPath();
@@ -1408,7 +1413,7 @@
istream.close();
} catch (Exception e) {
- logger.debug("Error while connecting to server URL " + url, e);
+ logger.error("Error while connecting to server URL " + url, e);
throw new Exception( "Cannot connect to your server URL at " +
url );
}
Index: ServletIncludeRequestWrapper.java
===================================================================
RCS file:
/home/cvs/repository/jahia/src/java/org/jahia/services/applications/Attic/ServletIncludeRequestWrapper.java,v
retrieving revision 1.23.2.4.2.2
retrieving revision 1.23.2.4.2.3
diff -u -r1.23.2.4.2.2 -r1.23.2.4.2.3
--- ServletIncludeRequestWrapper.java 13 Sep 2005 09:34:47 -0000
1.23.2.4.2.2
+++ ServletIncludeRequestWrapper.java 28 Oct 2005 10:01:50 -0000
1.23.2.4.2.3
@@ -339,16 +339,6 @@
this.emulatedPathInfo.substring(this.emulatedServletPath.length());
}
- if ( this.emulatedPathInfo != null ){
- // let's remove the session ID from the parameters if it
was attached.
- int sessionIDPos =
this.emulatedPathInfo.lastIndexOf(";jsessionid=");
- if ( sessionIDPos != -1 ){
- this.emulatedPathInfo =
this.emulatedPathInfo.substring(0,
- sessionIDPos);
- this.jSessionId =
this.emulatedPathInfo.substring(sessionIDPos);
- logger.debug("Removed session ID marker from end of
path info");
- }
- }
} else if ( servletMappingPattern.startsWith("*.") ){
// extension mapping
int pathSepPos = path.lastIndexOf("/");
@@ -399,6 +389,18 @@
this.emulatedServletPath = "";
this.emulatedPathInfo = "";
}
+
+ if ( this.emulatedPathInfo != null ){
+ // let's remove the session ID from the parameters if it was
attached.
+ int sessionIDPos =
this.emulatedPathInfo.lastIndexOf(";jsessionid=");
+ if ( sessionIDPos != -1 ){
+ this.jSessionId =
this.emulatedPathInfo.substring(sessionIDPos);
+ this.emulatedPathInfo = this.emulatedPathInfo.substring(0,
+ sessionIDPos);
+ logger.debug("Removed session ID marker from end of path
info");
+ }
+ }
+
logger.debug("url = [" + url + "]");
logger.debug("emulated servlet path = [" + this.emulatedServletPath
+ "]");
logger.debug("emulated path info = [" + this.emulatedPathInfo + "]");
@@ -898,7 +900,7 @@
}
requestURL += appRequest.getservletsrc();
}
- requestURL += this.jSessionId;
+ // requestURL += this.jSessionId;
logger.debug("emulated requestURI = [" + requestURL + "]");
//return getContextPath()+ "/" + appRequest.getServletName();