Raible's Wiki

Raible Designs
Wiki Home
News
Recent Changes

AppFuse

Homepage
  - Korean
  - Chinese
  - Italian
  - Japanese

QuickStart Guide
  - Chinese
  - French
  - German
  - Italian
  - Korean
  - Portuguese
  - Spanish
  - Japanese

User Guide
  - Korean
  - Chinese

Tutorials
  - Chinese
  - German
  - Italian
  - Korean
  - Portuguese
  - Spanish

FAQ
  - Korean

Latest Downloads

Other Applications

Struts Resume
Security Example
Struts Menu

Set your name in
UserPreferences


Referenced by
Main
Tomcat5Logging
Tomcat5Logging_ko




JSPWiki v2.2.33

[RSS]


Hide Menu

Tomcat5Upgrade


Difference between version 25 and version 14:

At line 23 added 13 lines.
!Solution:\\
This may be old news, but for the sake of solving the issue for future generations:\\
Change
{{{
<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core" %>
}}}
to
{{{
<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core_rt" %>
}}}
--[ScottDavis]
At line 41 changed 1 line.
__Later:__ I figured it out. I had to put log4j.jar in $CATALINA_HOME/common/lib and appfuse.xml in $CATALINA_HOME/conf/Catalina/localhost. So I guess the context.xml file must go in $CATALINA_HOME/conf/Catalina/localhost, rather than $CATALINA_HOME/webapps. Doh! Now I have to figure out a way to modify my "setup-tomcat" task to detect and deploy appropriately for Tomcat 5. Here is the relevant part:
__Update 1:__ I found that adding log4j.jar to $CATALINA_HOME/common/lib solved my problem, but now I get the following error when I start Tomcat and there is no logging to catalina.out:
At line 56 added 7 lines.
log4j:WARN No appenders could be found for logger (org.apache.catalina.startup.Embedded).
log4j:WARN Please initialize the log4j system properly.
}}}
;:''Solved no logging by adding my generated log4.properties file to $CATALINA_HOME/common/classes''
__Update 2:__ I had to put appfuse.xml in $CATALINA_HOME/conf/Catalina/localhost. So I guess the context.xml file must go in $CATALINA_HOME/conf/Catalina/localhost, rather than $CATALINA_HOME/webapps. Doh! Now I have to figure out a way to modify my "setup-tomcat" task to detect and deploy appropriately for Tomcat 5. Here is the relevant part:
{{{
At line 68 added 40 lines.
----
!!Tomcat 5.0.5 (July 28, 2003)
<a name="5.0.5a"></a>
Everything works the same as it did in Release 5.0.4 Alpha (above).
----
!!Tomcat 5.0.6 (August 4, 2003)
<a name="5.0.6a"></a>
Everything works the same as it did in Release 5.0.5 Alpha (above). A did get a new error about parsing struts-menu.tld, but after looking at the logs, I discovered it's solved by putting log4j.jar in $CATALINA_HOME/common/lib.
To summarize - to install [AppFuse] (or [StrutsResume]) on Tomcat 5.0.4+, perform the following steps:
* Run <code style="font-size: 1.1em; color: green; font-weight: bold">ant setup-tomcat</code>, then <code style="font-size: 1.1em; color: green; font-weight: bold">mv $CATALINA_HOME/webapps/appfuse.xml $CATALINA_HOME/conf/Catalina/localhost/.</code>
* <code style="font-size: 1.1em; color: green; font-weight: bold">cp lib/jakarta-log4j*/dist/lib/log4j*.jar $CATALINA_HOME/common/lib/.</code>
* <code style="font-size: 1.1em; color: green; font-weight: bold">cp build/appfuse/WEB-INF/classes/log4j.properties $CATALINA_HOME/common/classes/.</code>
__Later:__ I discovered (with [Remy's|http://jakarta.apache.org/site/whoweare.html] help) that if I removed ''privileged="true"'' from my &lt;Context&gt; definition - then my Log4j issues went away. I thought that parameter meant that the app used a Realm, but after reading [the documentation|http://jakarta.apache.org/tomcat/tomcat-5.0-doc/config/context.html] (Set to true to allow this context
to use container servlets, like the manager servlet), I realize that I'm using it incorrectly.
\\
\\
\\
\\
\\
\\
\\
\\
\\
\\
\\
\\
\\
\\
\\
\\
\\
\\
\\
\\
\\
\\

Back to Tomcat5Upgrade, or to the Page History.