• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Devaka Cooray
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Knute Snortum
  • Bear Bibeault
Saloon Keepers:
  • Ron McLeod
  • Tim Moores
  • Stephan van Hulst
  • Piet Souris
  • Ganesh Patekar
Bartenders:
  • Frits Walraven
  • Carey Brown
  • Tim Holloway

log4j

 
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
log4j did't work before I move log4j.xml file from /WEB-INF/ to /WEB-INF/classes/ and fix this path in sources.

stdout_20060818.log before moving:
log4j:WARN No appenders could be found for logger (org.apache.catalina.startup.TldConfig).
log4j:WARN Please initialize the log4j system properly.

After moving all work properly:
17:34:59 INFO TilesPlugin Tiles definition factory loaded for module ''.
17:36:21 INFO TilesRequestProcessor Tiles definition factory found for request processor ''.


Win2k AS SP4, Tomcat 5.5.17, MySQL 5.0.22.
[originally posted on jforum.net by VVD]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
confirmed.

I added the following in the build.xml file.

original:

<target name="compile" description="Compiles the source code">
<mkdir dir="${classes}"/>

<!-- Compile the java code from ${src} into ${classes} -->
<javac srcdir="${src}" destdir="${classes}" <br /> debug="${compile.debug}" deprecation="${compile.deprecation}" <br /> source="${compile.source}" target="${compile.target}" optimize="${compile.optimize}">
<classpath>
<path refid="base.path"/>
</classpath>
</javac>

</target>



Changed to:

<target name="compile" description="Compiles the source code">
<mkdir dir="${classes}"/>

<!-- Compile the java code from ${src} into ${classes} -->
<javac srcdir="${src}" destdir="${classes}" <br /> debug="${compile.debug}" deprecation="${compile.deprecation}" <br /> source="${compile.source}" target="${compile.target}" optimize="${compile.optimize}">
<classpath>
<path refid="base.path"/>
</classpath>
</javac>

<!-- copy log4j.xml into ${classes} -->
<copy file="WEB-INF/log4j.xml" todir="${classes}"/>


</target>



[originally posted on jforum.net by roach]
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!