Search code examples
log4jred5

red5 v0.9: how can i log information to log file?


I'm reading this tutorial on how to build my project project using eclipse with the red5 eclipse plugin. the problem is that this tutorial is for version 0.6 and i have version 0.9.

the tutorial is at: http://www.actionscript.org/resources/articles/615/1/Getting-started-with-red5-server/Page1.html

On page 2 that tutorial explains about logging information to the log file using the following imported classes:

import org.apache.commons.logging.Log; 
import org.apache.commons.logging.LogFactory; 

then the tutorial explains to add the jar red5/lib/commons-logging-1.1.jar to the build path of eclipse but the problem is that this file does not exist.

the only jar files that contain the word log are:

  1. log4j-over-slf4j-1.5.8.jar
  2. logback-classic-0.9.17.jar
  3. logback-core-0.9.17.jar

what exactly do i do to log using red5 0.9 ? thanks!


Solution

  • ok red5 0.9 just uses log4j. needed to import import org.apache.log4j.Logger; after adding log4j-over-slf4j-1.5.8.jar to the external jars list in eclipse.

    good log4j tutorial: http://www.laliluna.de/log4j-tutorial.html