This page (revision-14) was last changed on 23-Apr-2022 17:06 by Harry Metske

This page was created on 23-Apr-2022 17:05 by Harry Metske

Only authorized users are allowed to rename pages.

Only authorized users are allowed to delete pages.

Page revision history

Version Date Modified Size Author Changes ... Change note
14 23-Apr-2022 17:06 2 KB Harry Metske to previous
13 23-Apr-2022 17:05 2 KB Harry Metske to previous | to last
12 23-Apr-2022 17:05 1 KB Harry Metske to previous | to last
11 23-Apr-2022 17:05 1 KB Harry Metske to previous | to last
10 23-Apr-2022 17:05 1 KB Harry Metske to previous | to last
9 23-Apr-2022 17:05 1 KB Harry Metske to previous | to last
8 23-Apr-2022 17:05 1 KB Harry Metske to previous | to last
7 23-Apr-2022 17:05 1 KB Harry Metske to previous | to last
6 23-Apr-2022 17:05 1 KB Harry Metske to previous | to last
5 23-Apr-2022 17:05 1 KB Harry Metske to previous | to last
4 23-Apr-2022 17:05 978 bytes Harry Metske to previous | to last
3 23-Apr-2022 17:05 790 bytes Harry Metske to previous | to last
2 23-Apr-2022 17:05 483 bytes Harry Metske to previous | to last
1 23-Apr-2022 17:05 442 bytes Harry Metske to last

Page References

Incoming links Outgoing links
Slf4j...nobody

Version management

Difference between version and

At line 7 changed 5 lines
# run the [slf4j migrator|http://www.slf4j.org/migrator.html]
# add the slf4j-log4j12.jar to the eclipse buildpath
# change build.xml so that slf4j-log4j12.jar is added to WEB-INF/lib
# test with tomcat
# test with WebSphere (old JSPWiki version and new (slf4j) JSPWiki version
# run the [slf4j migrator|http://www.slf4j.org/migrator.html] ==> migrates only java sources (not jsp's)
# allmost all JSP's have to be manually adjusted
# add slf4j-api-1.5.6.jar and slf4j-simple-1.5.6.jar in ./lib
# remove log4j-1.2.14.jar from the eclipse buildpath
# remove commons-logging-api.jar from lib
# add the slf4j-api-1.5.6.jar to the eclipse buildpath
# src change: ''log.fatal('' ==> ''log.error(''
# src change: slf4j log methods only accept Strings, so ''log.error(Exception)'' ==> ''log.error(Exception.toString())''
# remove all occurrences of ''PropertyConfigurator.configure(props)'' (mostly in tests) ==> move log4j properties from jspwiki.properties to separate log4j.properties ./classes directory
# NDC => MDC , these are only in the two ServletFilters,
# a strange log4j config manipulation in ProviderConverter (leaving untouched):
{{{
props.setProperty( "log4j.appender.outlog", "org.apache.log4j.ConsoleAppender" );
props.setProperty( "log4j.appender.outlog.layout", "org.apache.log4j.PatternLayout" );
props.setProperty( "jspwiki.useLucene", "false" );
props.setProperty( "log4j.rootCategory", "INFO,outlog" );
}}}
# run the tests and the web-tests
# test with tomcat
!! Findings
* non-core plugins also need adjustments, an example:
{{{
SEVERE: Exception starting filter WikiJSPFilter
java.lang.NoClassDefFoundError: org/apache/log4j/Logger
at org.goodjava.plugin.hitcounter.HitCounter.<clinit>(Unknown Source)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:186)
}}}
!! WebSphere
Initially we assumed that JSPWiki did not run "out of the box" on WebSphere. Well, this is not true anymore for WebSphere 6.1 upwards.
\\Up until WebSphere 6.0 the commons-logging-api.jar is shipped by default in the WebSphere lib directory, which is the root cause of the problem. For full details , see [http://www-01.ibm.com/support/docview.wss?uid=swg27004610&aid=1]
\\I just tested this morning a standard (log4j based) JSPWiki on WebSphere 6.1, and it runs fine without special tweaks to either JSPWiki or WebSphere (after pointing the pages and attachments directory to /tmp)