geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ga...@apache.org
Subject svn commit: r588005 - /geronimo/server/trunk/plugins/console/console-base-portlets/src/main/java/org/apache/geronimo/console/apache/jk/BaseApacheHandler.java
Date Wed, 24 Oct 2007 20:28:09 GMT
Author: gawor
Date: Wed Oct 24 13:28:08 2007
New Revision: 588005

URL: http://svn.apache.org/viewvc?rev=588005&view=rev
Log:
removed the encoding of colons and slashes as it causes problems and pluto seems to be handling
this correctly now

Modified:
    geronimo/server/trunk/plugins/console/console-base-portlets/src/main/java/org/apache/geronimo/console/apache/jk/BaseApacheHandler.java

Modified: geronimo/server/trunk/plugins/console/console-base-portlets/src/main/java/org/apache/geronimo/console/apache/jk/BaseApacheHandler.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/console/console-base-portlets/src/main/java/org/apache/geronimo/console/apache/jk/BaseApacheHandler.java?rev=588005&r1=588004&r2=588005&view=diff
==============================================================================
--- geronimo/server/trunk/plugins/console/console-base-portlets/src/main/java/org/apache/geronimo/console/apache/jk/BaseApacheHandler.java
(original)
+++ geronimo/server/trunk/plugins/console/console-base-portlets/src/main/java/org/apache/geronimo/console/apache/jk/BaseApacheHandler.java
Wed Oct 24 13:28:08 2007
@@ -160,21 +160,19 @@
         private String logFilePath;
         private String workersPath;
         private List webApps = new ArrayList();
-        // list of encodings for special chars
-        private String[][] ENCODINGS = {{":", "0x0"},{"\\", "0x1"}};
 
         public ApacheModel(PortletRequest request) {
             Map map = request.getParameterMap();
             os = request.getParameter("os");
             // logFilePath and workersPath need to be encoded before saving
             // and decoded after fetching
-            logFilePath = encodePath(request.getParameter("logFilePath"));
+            logFilePath = request.getParameter("logFilePath");
             if(logFilePath == null) {
-                logFilePath = encodePath(PortletManager.getCurrentServer(request).getServerInfo().resolve("var/log/apache_mod_jk.log").getPath());
+                logFilePath = PortletManager.getCurrentServer(request).getServerInfo().resolve("var/log/apache_mod_jk.log").getPath();
             }
-            workersPath = encodePath(request.getParameter("workersPath"));
+            workersPath = request.getParameter("workersPath");
             if(workersPath == null) {
-                workersPath = encodePath(PortletManager.getCurrentServer(request).getServerInfo().resolve("var/config/workers.properties").getPath());
+                workersPath = PortletManager.getCurrentServer(request).getServerInfo().resolve("var/config/workers.properties").getPath();
             }
             String ajp = request.getParameter("addAjpPort");
             if(!isEmpty(ajp)) addAjpPort = new Integer(ajp);
@@ -206,30 +204,6 @@
                 session.setAttribute(WEB_APP_SESSION_KEY, webApps);
             }
         }
-
-        private String encodePath(String value) {
-            if(value == null) {
-                return value;
-            }
-            for(int i = 0; i < ENCODINGS.length; i++) {
-                if(value.contains(ENCODINGS[i][0])) {
-                    value = value.replace(ENCODINGS[i][0], ENCODINGS[i][1]);
-                }
-            }
-            return value;
-        }
-        
-        private String decodePath(String value) {
-            if(value == null) {
-                return value;
-            }
-            for(int i = 0; i < ENCODINGS.length; i++) {
-                if(value.contains(ENCODINGS[i][1])) {
-                    value = value.replace(ENCODINGS[i][1], ENCODINGS[i][0]);
-                }
-            }
-            return value;
-        }
         
         public String getOs() {
             return os;
@@ -248,7 +222,7 @@
         }
 
         public String getLogFilePath() {
-            return decodePath(logFilePath);
+            return logFilePath;
         }
 
         public void setLogFilePath(String logFilePath) {
@@ -256,7 +230,7 @@
         }
 
         public String getWorkersPath() {
-            return decodePath(workersPath);
+            return workersPath;
         }
 
         public void setWorkersPath(String workersPath) {



Mime
View raw message