Last change
on this file since 31962 was 31962, checked in by rmw36, 7 years ago |
Macronizer changes: 1. adding an ethical disclaimer to the main web page (temporarily still in English for the Maori jsp file too, but Te Taka will be translating this.) 2. Adding more logging to the macronizer. This required setting up a log4j.properties file (and adding its jar file copied from GS3), and modifying the existing java code DirectInput and FileUpload to make calls to logger. Modifications to build.xml to copy the new template log4j.properties.in file into web/WEB-INF/classes where the log4j.props needs to live. 3. Corrected the svn mime-type property on build.xml so that it's no longer mistaken for a binary file
|
File size:
1.3 KB
|
Line | |
---|
1 | # See for basic example https://stackoverflow.com/questions/125 32339/no-appenders-could-be-found-for-loggerlog4j
|
---|
2 | # For better examples, see /greenstone/greenstone3/web/WEB-INF/classes/log4j.properties
|
---|
3 |
|
---|
4 | #######################
|
---|
5 |
|
---|
6 | # define some reusable properties
|
---|
7 | macronizer.home=/greenstone/macron-restoration
|
---|
8 | macronizer.logplace=${macronizer.home}/web/logs
|
---|
9 |
|
---|
10 | # Let's log everything from the most basic DEBUG msgs on (so INFO, WARN, ERROR too)
|
---|
11 | log4j.rootCategory=DEBUG, macronlog
|
---|
12 |
|
---|
13 | # copied from GS3
|
---|
14 | log4j.category.web.servlets.DirectInput=INFO, macronlog
|
---|
15 | log4j.additivity.web.servlets.DirectInput=false
|
---|
16 |
|
---|
17 | # We're saying our log "macronlog" is some file that gets appended to,
|
---|
18 | # and it will write it out to "macron.log" located in whatever we defined the "logplace" to be
|
---|
19 | log4j.appender.macronlog=org.apache.log4j.RollingFileAppender
|
---|
20 | log4j.appender.macronlog.File=${macronizer.logplace}/macron.log
|
---|
21 |
|
---|
22 | # if you have more logs, define rootcategory, appender and appender.File for it as above
|
---|
23 | # for each log also set the format of the output as below, after setting the layout to use PatternLayout class to parse the format
|
---|
24 |
|
---|
25 | log4j.appender.macronlog.layout=org.apache.log4j.PatternLayout
|
---|
26 | log4j.appender.macronlog.layout.ConversionPattern=%-5p: [%d{yyyy-MM-dd hh:mm:ss}] %C{1}.%M()%n %m%n
|
---|
27 |
|
---|
28 | #######################
|
---|
Note:
See
TracBrowser
for help on using the repository browser.