Opened 13 years ago
Closed 13 years ago
#1636 closed task (fixed)
Test BASE with Tomcat 7
Reported by: | Nicklas Nordborg | Owned by: | Nicklas Nordborg |
---|---|---|---|
Priority: | major | Milestone: | BASE 3.0 |
Component: | web | Version: | |
Keywords: | Cc: |
Description
Check if BASE works with Tomcat 7 and if not, see if we can fix any problems.
Change History (9)
comment:1 by , 13 years ago
Owner: | changed from | to
---|---|
Status: | new → assigned |
comment:2 by , 13 years ago
comment:3 by , 13 years ago
There are four JSP files that can't be compiled (using the CompileAll
servlet):
- /admin/extensions/details.jsp (line: 291, column: 55) Attribute qualified names must be unique within an element
- /admin/services/services.jsp (line: 119, column: 58) Attribute qualified names must be unique within an element
- /biomaterials/biosources/edit_biosource.jsp (line: 177, column: 73) The JSP specification requires that an attribute name is preceded by whitespace
- /views/trashcan/list_trash.jsp (line: 214, column: 11) Attribute qualified names must be unique within an element
comment:4 by , 13 years ago
comment:5 by , 13 years ago
Milestone: | BASE 3.1 → BASE 3.0 |
---|
comment:6 by , 13 years ago
The extensions system seems to be working fine, except for the XJSP compiler (when testing the "Hello X-JSP world" example):
tried to access field org.apache.jasper.compiler.JDTCompiler.log from class net.sf.basedb.clients.web.extensions.XJspCompiler Stack trace java.lang.IllegalAccessError ...at net.sf.basedb.clients.web.extensions.XJspCompiler.generateClass(XJspCompiler.java:129) ...at org.apache.jasper.compiler.Compiler.compile(Compiler.java:378) ...at org.apache.jasper.compiler.Compiler.compile(Compiler.java:353) ...at org.apache.jasper.compiler.Compiler.compile(Compiler.java:340) ...at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:644) ...at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:358) ...at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:389) ...at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:333)
It seems like the JDTCompiler.log
field is now a private field, which can probably be fixed by creating our own logger.
comment:7 by , 13 years ago
comment:8 by , 13 years ago
The XJSP compiler still doesn't work:
org.apache.jasper.compiler.JspRuntimeContext.getParentClassLoader()Ljava/net/URLClassLoader; Stack trace java.lang.NoSuchMethodError ...at net.sf.basedb.clients.web.extensions.XJspCompiler.getWebAppClassLoader(XJspCompiler.java:209) ...at net.sf.basedb.clients.web.extensions.XJspCompiler.getPluginsDir(XJspCompiler.java:222) ...at net.sf.basedb.clients.web.extensions.XJspCompiler.init(XJspCompiler.java:117) ...at org.apache.jasper.JspCompilationContext.createCompiler(JspCompilationContext.java:228) ...at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:636) ...at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:358) ...at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:389) ...at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:333)
It seems like the JspRuntimeContext.getParentClassLoader()
now returns a ClassLoader
instead of a URLClassLoader
. The problem can be fixed by re-compiling the XJSP compiler against jasper.jar
that ships with Tomcat 7. No code changes are required. Unfortunately, this creates an XJSP compiler that is not compatible with Tomcat 6. No matter what we do we will need different versions for Tomcat 6 and 7. So, let's stick to Tomcat 6 for the moment. If anyone absolutely needs an XJSP compiler for Tomcat 7, it is relatively easy to compile BASE for that.
comment:9 by , 13 years ago
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
It seems to be working fairly good. Tomcat is able to start and it is possible to login to BASE. There is a warning message in
catalina.out
:After investigating this issue it seems like Tomcat is scanning all JAR files in
WEB-INF/lib
. To get rid of that thecatalina.properties
file must include a setting that lists which files to ignore. The debug message in the log says:So, it is nothing that we can control from the BASE side. It is probably not too important either...