background preloader

SLF4J

SLF4J

Log4j tutorial with Tomcat examples This tutorial explains how to set up log4j with email, files and stdout. It compares XML to properties configuration files, shows how to change LogLevels for a running application. Furthermore, we explain best practices on logging and exception handling. Author:Sebastian Hennebrueder Date: February, 22th, 2007 Used software and frameworks Tomcat 5.5 Log4j 1.2.14 PDF version of the tutorial: Source code You can download the current version of log4j from the project home page. Make sure that you use use md5sum to check that the downloaded file is not hacked. In a linux console you can type the following and compare the number to that from the home page: md5sum logging-log4j-1.2.14.zip There are md5sum tools for windows as well. log4j.properties example Create a Java project. Add the log4j.jar to the build path of the project. Create a class with the following content: to

World Wind Java Demo Applications and Applets The applications and applets here demonstrate some of World Wind’s rich capabilities. Also see World Wind Europa Challenge site for a collection of applications created by the World Wind Europa Challenge teams. Known Issues Running With Java 7 All Platforms World Wind applications and applets fail with a CertPathValidatorException with Java 7 update 9 and earlier. Mac OS X As of February 11, 2013 Apple has prevented Java Applets on Java 7 update 11 and earlier from running Mac OS X. World Wind Demo Applications Application Template Application Template This is the most basic usage of the SDK. > ApplicationTemplate.jnlp – launch with Java Web Start. KML Viewer KML Viewer Demonstrates loading, displaying, and interacting with KML content in World Wind. > KMLViewer.jnlp – launch with Java Web Start. WMS Layer Manager WMS Layer Manager This example application demonstrates the SDK WMS capabilities. To add a server, click on the “+” tab and enter the server url. EuroGEOSS Client Scankort Denmark Data Gaea+

Grails Logging Configuring logging in Grails is not as simple one would think. Grails uses Log4J as its logging framework. Log4J configuration is stored in the log4j.properties file. In Grails, this file is generated from Config.groovy source file. The official Grails Logging documentation says that if you want to have a different logging levels for let's say a specific controller, all controllers and the rest of your application, you should define the logging levels as: grails.' Yes, those ticks are required, otherwise you get an error message (No such property: context for class: java.lang.String). So that is what the official documentation and few blogs say. Grails allows you to configure your production, development and testing environments differently if required. But there is a solution to this problem after all. environments { development { ... log4j { appender.stdout = ... rootLogger="error,logfile,stdout" logger { grails { app { controller="debug" } } } } } production { ... }} This works.

Logging facade that allows various implementations to be used like log4j, java logging, commons logging. The chap that made this library has his own logging framework that is supported( by superunknown Apr 10

Related: