cocoon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ilgro...@apache.org
Subject svn commit: r1155368 [4/6] - in /cocoon/cocoon3/trunk: cocoon-all/src/main/groovy/ cocoon-archetype-block/src/main/resources/META-INF/ cocoon-archetype-block/src/main/resources/archetype-resources/ cocoon-archetype-block/src/main/resources/archetype-re...
Date Tue, 09 Aug 2011 13:56:43 GMT
Modified: cocoon/cocoon3/trunk/cocoon-sax/pom.xml
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-sax/pom.xml?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-sax/pom.xml (original)
+++ cocoon/cocoon3/trunk/cocoon-sax/pom.xml Tue Aug  9 13:56:40 2011
@@ -20,192 +20,201 @@
 <!-- $Id$ -->
 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
 
-  <modelVersion>4.0.0</modelVersion>
-  <packaging>jar</packaging>
+    <modelVersion>4.0.0</modelVersion>
+    <packaging>jar</packaging>
 
-  <parent>
-    <groupId>org.apache.cocoon.parent</groupId>
-    <artifactId>cocoon-parent</artifactId>
+    <parent>
+        <groupId>org.apache.cocoon.parent</groupId>
+        <artifactId>cocoon-parent</artifactId>
+        <version>3.0.0-beta-1-SNAPSHOT</version>
+        <relativePath>../parent</relativePath>
+    </parent>
+
+    <groupId>org.apache.cocoon.sax</groupId>
+    <artifactId>cocoon-sax</artifactId>
     <version>3.0.0-beta-1-SNAPSHOT</version>
-    <relativePath>../parent</relativePath>
-  </parent>
 
-  <groupId>org.apache.cocoon.sax</groupId>
-  <artifactId>cocoon-sax</artifactId>
-  <version>3.0.0-beta-1-SNAPSHOT</version>
-
-  <name>Apache Cocoon 3: SAX</name>
-  <description>Cocoon 3 SAX pipeline components.</description>
-
-  <dependencies>
-    <dependency>
-      <groupId>org.apache.cocoon.pipeline</groupId>
-      <artifactId>cocoon-pipeline</artifactId>
-    </dependency>
-    <dependency>
-      <groupId>org.apache.cocoon</groupId>
-      <artifactId>cocoon-xml</artifactId>
-    </dependency>
-    <dependency>
-      <groupId>commons-logging</groupId>
-      <artifactId>commons-logging</artifactId>
-      <exclusions>
-        <exclusion>
-          <artifactId>logkit</artifactId>
-          <groupId>logkit</groupId>
-        </exclusion>
-        <exclusion>
-          <artifactId>avalon-framework</artifactId>
-          <groupId>avalon-framework</groupId>
-        </exclusion>
-      </exclusions>
-    </dependency>
-
-    <dependency>
-      <groupId>junit</groupId>
-      <artifactId>junit</artifactId>
-      <scope>test</scope>
-    </dependency>
-    <dependency>
-      <groupId>xmlunit</groupId>
-      <artifactId>xmlunit</artifactId>
-      <scope>test</scope>
-    </dependency>
-    <dependency>
-      <groupId>xerces</groupId>
-      <artifactId>xercesImpl</artifactId>
-      <scope>test</scope>
-    </dependency>
-    <dependency>
-      <groupId>xalan</groupId>
-      <artifactId>xalan</artifactId>
-      <scope>test</scope>
-      <exclusions>
-        <exclusion>
-          <groupId>xml-apis</groupId>
-          <artifactId>xml-apis</artifactId>
-        </exclusion>
-      </exclusions>
-    </dependency>
-    <dependency>
-      <groupId>org.apache.bcel</groupId>
-      <artifactId>bcel</artifactId>
-      <scope>test</scope>
-    </dependency>
-  </dependencies>
-
-  <build>
-    <plugins>
-      <plugin>
-        <groupId>org.codehaus.mojo</groupId>
-        <artifactId>javacc-maven-plugin</artifactId>
-        <executions>
-          <execution>
-            <id>javacc</id>
-            <phase>generate-sources</phase>
-            <goals>
-              <goal>javacc</goal>
-            </goals>
-          </execution>
-        </executions>
-      </plugin>
-      <plugin>
-        <groupId>org.codehaus.mojo</groupId>
-        <artifactId>build-helper-maven-plugin</artifactId>
-        <executions>
-          <execution>
-            <id>add-source</id>
-            <phase>generate-sources</phase>
-            <goals>
-              <goal>add-source</goal>
-            </goals>
-            <configuration>
-              <sources>
-                <source>target/generated-sources/javacc</source>
-              </sources>
-            </configuration>
-          </execution>
-        </executions>
-      </plugin>
-      <plugin>
-        <groupId>org.codehaus.mojo</groupId>
-        <artifactId>exec-maven-plugin</artifactId>
-        <executions>
-          <execution>
-            <phase>test-compile</phase>
-            <goals>
-              <goal>exec</goal>
-            </goals>
-          </execution>
-        </executions>
-        <configuration>
-          <executable>java</executable>
-          <classpathScope>test</classpathScope>
-          <arguments>
-            <argument>-classpath</argument>
-            <classpath />
-            <argument>org.apache.xalan.xsltc.cmdline.Compile</argument>
-            <argument>-d</argument>
-            <argument>target/test-classes</argument>
-            <argument>-p</argument>
-            <argument>org.apache.cocoon.sax</argument>
-            <argument>-o</argument>
-            <argument>CompiledXslt</argument>
-            <argument>src/test/resources/test.xslt</argument>
-          </arguments>
-        </configuration>
-      </plugin>
-      <plugin>
-        <groupId>org.codehaus.mojo</groupId>
-        <artifactId>rat-maven-plugin</artifactId>
-        <configuration>
-          <excludes>
-            <exclude>src/test/resources/META-INF/services/javax.xml.transform.TransformerFactory</exclude>
-            <exclude>src/test/resources/just-text.txt</exclude>
-          </excludes>
-        </configuration>
-      </plugin>
-    </plugins>
-    <pluginManagement>
-      <plugins>
+    <name>Apache Cocoon 3: SAX</name>
+    <description>Cocoon 3 SAX pipeline components.</description>
+
+    <dependencies>
+        <dependency>
+            <groupId>org.apache.cocoon.pipeline</groupId>
+            <artifactId>cocoon-pipeline</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.cocoon</groupId>
+            <artifactId>cocoon-xml</artifactId>
+        </dependency>
+        
+        <!-- Logging -->
+        <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>slf4j-api</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>ch.qos.logback</groupId>
+            <artifactId>logback-core</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>ch.qos.logback</groupId>
+            <artifactId>logback-classic</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>commons-logging</groupId>
+            <artifactId>commons-logging</artifactId>
+            <scope>provided</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>jcl-over-slf4j</artifactId>
+        </dependency>
+
+        <dependency>
+            <groupId>junit</groupId>
+            <artifactId>junit</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>xmlunit</groupId>
+            <artifactId>xmlunit</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>xerces</groupId>
+            <artifactId>xercesImpl</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>xalan</groupId>
+            <artifactId>xalan</artifactId>
+            <scope>test</scope>
+            <exclusions>
+                <exclusion>
+                    <groupId>xml-apis</groupId>
+                    <artifactId>xml-apis</artifactId>
+                </exclusion>
+            </exclusions>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.bcel</groupId>
+            <artifactId>bcel</artifactId>
+            <scope>test</scope>
+        </dependency>
+    </dependencies>
+
+    <build>
+        <plugins>
+            <plugin>
+                <groupId>org.codehaus.mojo</groupId>
+                <artifactId>javacc-maven-plugin</artifactId>
+                <executions>
+                    <execution>
+                        <id>javacc</id>
+                        <phase>generate-sources</phase>
+                        <goals>
+                            <goal>javacc</goal>
+                        </goals>
+                    </execution>
+                </executions>
+            </plugin>
+            <plugin>
+                <groupId>org.codehaus.mojo</groupId>
+                <artifactId>build-helper-maven-plugin</artifactId>
+                <executions>
+                    <execution>
+                        <id>add-source</id>
+                        <phase>generate-sources</phase>
+                        <goals>
+                            <goal>add-source</goal>
+                        </goals>
+                        <configuration>
+                            <sources>
+                                <source>target/generated-sources/javacc</source>
+                            </sources>
+                        </configuration>
+                    </execution>
+                </executions>
+            </plugin>
+            <plugin>
+                <groupId>org.codehaus.mojo</groupId>
+                <artifactId>exec-maven-plugin</artifactId>
+                <executions>
+                    <execution>
+                        <phase>test-compile</phase>
+                        <goals>
+                            <goal>exec</goal>
+                        </goals>
+                    </execution>
+                </executions>
+                <configuration>
+                    <executable>java</executable>
+                    <classpathScope>test</classpathScope>
+                    <arguments>
+                        <argument>-classpath</argument>
+                        <classpath />
+                        <argument>org.apache.xalan.xsltc.cmdline.Compile</argument>
+                        <argument>-d</argument>
+                        <argument>target/test-classes</argument>
+                        <argument>-p</argument>
+                        <argument>org.apache.cocoon.sax</argument>
+                        <argument>-o</argument>
+                        <argument>CompiledXslt</argument>
+                        <argument>src/test/resources/test.xslt</argument>
+                    </arguments>
+                </configuration>
+            </plugin>
+            <plugin>
+                <groupId>org.codehaus.mojo</groupId>
+                <artifactId>rat-maven-plugin</artifactId>
+                <configuration>
+                    <excludes>
+                        <exclude>src/test/resources/META-INF/services/javax.xml.transform.TransformerFactory</exclude>
+                        <exclude>src/test/resources/just-text.txt</exclude>
+                    </excludes>
+                </configuration>
+            </plugin>
+        </plugins>
+        <pluginManagement>
+            <plugins>
         <!--This plugin's configuration is used to store Eclipse m2e settings 
           only. It has no influence on the Maven build itself
           (see http://wiki.eclipse.org/M2E_plugin_execution_not_covered). -->
-        <plugin>
-          <groupId>org.eclipse.m2e</groupId>
-          <artifactId>lifecycle-mapping</artifactId>
-          <version>1.0.0</version>
-          <configuration>
-            <lifecycleMappingMetadata>
-              <pluginExecutions>
-                <pluginExecution>
-                  <pluginExecutionFilter>
-                    <groupId>org.codehaus.mojo</groupId>
-                    <artifactId>exec-maven-plugin</artifactId>
-                    <versionRange>[1.1,)</versionRange>
-                    <goals>
-                      <goal>exec</goal>
-                    </goals>
-                  </pluginExecutionFilter>
-                  <action>
-                    <ignore/>
-                  </action>
-                </pluginExecution>
-              </pluginExecutions>
-            </lifecycleMappingMetadata>
-          </configuration>
-        </plugin>
-      </plugins>
-    </pluginManagement>
-  </build>
-
-  <reporting>
-    <plugins>
-      <plugin>
-        <groupId>org.codehaus.mojo</groupId>
-        <artifactId>javacc-maven-plugin</artifactId>
-        <version>2.6</version>
-      </plugin>
-    </plugins>
-  </reporting>
+                <plugin>
+                    <groupId>org.eclipse.m2e</groupId>
+                    <artifactId>lifecycle-mapping</artifactId>
+                    <version>1.0.0</version>
+                    <configuration>
+                        <lifecycleMappingMetadata>
+                            <pluginExecutions>
+                                <pluginExecution>
+                                    <pluginExecutionFilter>
+                                        <groupId>org.codehaus.mojo</groupId>
+                                        <artifactId>exec-maven-plugin</artifactId>
+                                        <versionRange>[1.1,)</versionRange>
+                                        <goals>
+                                            <goal>exec</goal>
+                                        </goals>
+                                    </pluginExecutionFilter>
+                                    <action>
+                                        <ignore/>
+                                    </action>
+                                </pluginExecution>
+                            </pluginExecutions>
+                        </lifecycleMappingMetadata>
+                    </configuration>
+                </plugin>
+            </plugins>
+        </pluginManagement>
+    </build>
+
+    <reporting>
+        <plugins>
+            <plugin>
+                <groupId>org.codehaus.mojo</groupId>
+                <artifactId>javacc-maven-plugin</artifactId>
+                <version>2.6</version>
+            </plugin>
+        </plugins>
+    </reporting>
 </project>

Modified: cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/AbstractLinkRewriterTransformer.java
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/AbstractLinkRewriterTransformer.java?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/AbstractLinkRewriterTransformer.java (original)
+++ cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/AbstractLinkRewriterTransformer.java Tue Aug  9 13:56:40 2011
@@ -26,8 +26,8 @@ import org.apache.cocoon.pipeline.cachin
 import org.apache.cocoon.pipeline.caching.SimpleCacheKey;
 import org.apache.cocoon.pipeline.component.CachingPipelineComponent;
 import org.apache.cocoon.sax.AbstractSAXTransformer;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 import org.xml.sax.Attributes;
 import org.xml.sax.SAXException;
 import org.xml.sax.helpers.AttributesImpl;
@@ -41,8 +41,11 @@ public abstract class AbstractLinkRewrit
 
     private static final String ELEMENT_PREFIX = "element";
 
-    protected static final Log LOG = LogFactory.getLog(
-            AbstractLinkRewriterTransformer.class);
+    /**
+     * Logger.
+     */
+    protected static final Logger LOG =
+            LoggerFactory.getLogger(AbstractLinkRewriterTransformer.class);
 
     private final Map<Element, Set<Element>> elements =
             new HashMap<Element, Set<Element>>();

Modified: cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/IncludeTransformer.java
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/IncludeTransformer.java?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/IncludeTransformer.java (original)
+++ cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/IncludeTransformer.java Tue Aug  9 13:56:40 2011
@@ -26,8 +26,8 @@ import org.apache.cocoon.pipeline.Proces
 import org.apache.cocoon.pipeline.util.StringRepresentation;
 import org.apache.cocoon.sax.AbstractSAXTransformer;
 import org.apache.cocoon.xml.sax.EmbeddedSAXPipe;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 import org.xml.sax.Attributes;
 import org.xml.sax.InputSource;
 import org.xml.sax.SAXException;
@@ -36,8 +36,12 @@ import org.xml.sax.helpers.XMLReaderFact
 
 public class IncludeTransformer extends AbstractSAXTransformer {
 
-    private final Log logger = LogFactory.getLog(this.getClass());
-
+    /**
+     * Logger.
+     */
+    private static final Logger LOG =
+            LoggerFactory.getLogger(IncludeTransformer.class);
+    
     private static final String INCLUDE_NS = "http://apache.org/cocoon/3.0/include";
 
     private static final String INCLUDE_EL = "include";
@@ -83,8 +87,8 @@ public class IncludeTransformer extends 
             } else {
                 source = new URL(this.baseUrl, sourceAtt);
             }
-            if (this.logger.isDebugEnabled()) {
-                this.logger.debug("Including source: " + source);
+            if (LOG.isDebugEnabled()) {
+                LOG.debug("Including source: " + source);
             }
 
             return source;

Modified: cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/LogAsXMLTransformer.java
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/LogAsXMLTransformer.java?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/LogAsXMLTransformer.java (original)
+++ cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/LogAsXMLTransformer.java Tue Aug  9 13:56:40 2011
@@ -25,11 +25,10 @@ import java.io.IOException;
 import java.io.OutputStream;
 import java.util.HashMap;
 import java.util.Map;
-
 import org.apache.cocoon.pipeline.SetupException;
 import org.apache.cocoon.sax.AbstractSAXTransformer;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 import org.xml.sax.Attributes;
 import org.xml.sax.Locator;
 import org.xml.sax.SAXException;
@@ -46,9 +45,10 @@ public final class LogAsXMLTransformer e
     private static final String LOG_FILE = "logfile";
 
     /**
-     * This class log.
+     * Logger.
      */
-    private static final Log LOG = LogFactory.getLog(LogAsXMLTransformer.class);
+    private static final Logger LOG =
+            LoggerFactory.getLogger(LogAsXMLTransformer.class);
 
     private final transient XMLSerializer xmlSerializer =
             XMLSerializer.createXMLSerializer();

Modified: cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/LogTransformer.java
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/LogTransformer.java?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/LogTransformer.java (original)
+++ cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/LogTransformer.java Tue Aug  9 13:56:40 2011
@@ -28,8 +28,8 @@ import java.util.Map;
 import org.apache.cocoon.pipeline.SetupException;
 import org.apache.cocoon.sax.AbstractSAXTransformer;
 import org.apache.cocoon.xml.sax.SAXBuffer;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 import org.xml.sax.Attributes;
 import org.xml.sax.Locator;
 import org.xml.sax.SAXException;
@@ -57,7 +57,8 @@ public final class LogTransformer extend
     /**
      * This class log.
      */
-    private static final Log LOG = LogFactory.getLog(LogTransformer.class);
+    private static final Logger LOG =
+            LoggerFactory.getLogger(LogTransformer.class);
 
     /**
      * The file where log will be stored.

Modified: cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/SchemaErrorHandler.java
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/SchemaErrorHandler.java?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/SchemaErrorHandler.java (original)
+++ cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/SchemaErrorHandler.java Tue Aug  9 13:56:40 2011
@@ -18,18 +18,18 @@
  */
 package org.apache.cocoon.sax.component;
 
-import org.apache.commons.logging.Log;
+import org.slf4j.Logger;
 import org.xml.sax.ErrorHandler;
 import org.xml.sax.SAXException;
 import org.xml.sax.SAXParseException;
 
 public final class SchemaErrorHandler implements ErrorHandler {
 
-    private final Log logger;
+    private final Logger logger;
 
     private final String schemaUri;
 
-    public SchemaErrorHandler(Log logger, String schemaUri) {
+    public SchemaErrorHandler(Logger logger, String schemaUri) {
         this.logger = logger;
         this.schemaUri = schemaUri;
     }

Modified: cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/SchemaProcessorTransformer.java
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/SchemaProcessorTransformer.java?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/SchemaProcessorTransformer.java (original)
+++ cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/SchemaProcessorTransformer.java Tue Aug  9 13:56:40 2011
@@ -35,14 +35,17 @@ import org.apache.cocoon.sax.SAXConsumer
 import org.apache.cocoon.sax.util.InMemoryLRUResourceCache;
 import org.apache.cocoon.sax.util.SAXConsumerAdapter;
 import org.apache.cocoon.sax.util.ValidityValue;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 import org.xml.sax.SAXException;
 
 public final class SchemaProcessorTransformer extends AbstractSAXTransformer {
 
-    private static final Log LOG = LogFactory.getLog(
-            SchemaProcessorTransformer.class);
+    /**
+     * Logger.
+     */
+    private static final Logger LOG =
+            LoggerFactory.getLogger(SchemaProcessorTransformer.class);
 
     private static final String SOURCE = "source";
 

Modified: cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/TraxErrorListener.java
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/TraxErrorListener.java?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/TraxErrorListener.java (original)
+++ cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/TraxErrorListener.java Tue Aug  9 13:56:40 2011
@@ -19,7 +19,7 @@ package org.apache.cocoon.sax.component;
 import javax.xml.transform.ErrorListener;
 import javax.xml.transform.TransformerException;
 
-import org.apache.commons.logging.Log;
+import org.slf4j.Logger;
 
 /**
  * A smart error listener for <code>javax.xml.tranform</code> that does its best to provide useful error messages.
@@ -30,12 +30,12 @@ public class TraxErrorListener implement
 
     /** The exception we had from error() or fatalError() */
     private TransformerException exception;
-    private final Log log;
+    private final Logger log;
     private String uri;
     /** The exception we had from warning() */
     private TransformerException warningEx;
 
-    public TraxErrorListener(Log log, String uri) {
+    public TraxErrorListener(Logger log, String uri) {
         this.log = log;
         this.uri = uri;
     }

Modified: cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/XIncludeTransformer.java
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/XIncludeTransformer.java?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/XIncludeTransformer.java (original)
+++ cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/XIncludeTransformer.java Tue Aug  9 13:56:40 2011
@@ -37,8 +37,8 @@ import org.apache.cocoon.sax.xpointer.Pa
 import org.apache.cocoon.sax.xpointer.XPointer;
 import org.apache.cocoon.sax.xpointer.XPointerContext;
 import org.apache.cocoon.sax.xpointer.XPointerFrameworkParser;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 import org.xml.sax.Attributes;
 import org.xml.sax.Locator;
 import org.xml.sax.SAXException;
@@ -84,8 +84,11 @@ public final class XIncludeTransformer e
 
     private static final String EMPTY = "";
 
-    private final Log logger = LogFactory.getLog(this.getClass());
-
+    /**
+     * Logger.
+     */
+    private static final Logger LOG =
+            LoggerFactory.getLogger(XIncludeTransformer.class);
     /**
      * The nesting level of xi:include elements that have been encountered.
      */
@@ -264,8 +267,8 @@ public final class XIncludeTransformer e
      */
     private void processXIncludeElement(String href, final String parse, String xpointer, String encoding,
             final String accept, final String acceptLanguage) throws SAXException {
-        if (this.logger.isDebugEnabled()) {
-            this.logger.debug("Processing XInclude element: href="
+        if (LOG.isDebugEnabled()) {
+            LOG.debug("Processing XInclude element: href="
                  + href
                  + ", parse="
                  + parse
@@ -281,8 +284,8 @@ public final class XIncludeTransformer e
 
         int fragmentIdentifierPos = href.indexOf('#');
         if (fragmentIdentifierPos != -1) {
-            if (this.logger.isWarnEnabled()) {
-                this.logger.warn("Fragment identifer found in 'href' attribute: "
+            if (LOG.isWarnEnabled()) {
+                LOG.warn("Fragment identifer found in 'href' attribute: "
                     + href
                     + "\nFragment identifiers are forbidden by the XInclude specification. "
                     + "They are still handled by XIncludeTransformer for backward "
@@ -306,12 +309,12 @@ public final class XIncludeTransformer e
             urlConnection = source.openConnection();
         } catch (IOException ioe) {
             this.useFallbackLevel++;
-            this.logger.error("Error including document: " + source, ioe);
+            LOG.error("Error including document: " + source, ioe);
         }
 
         if (urlConnection != null) {
-            if (this.logger.isDebugEnabled()) {
-                this.logger.debug("Parse type=" + parse);
+            if (LOG.isDebugEnabled()) {
+                LOG.debug("Parse type=" + parse);
             }
 
             if (XINCLUDE_PARSE_XML.equals(parse)) {
@@ -338,7 +341,7 @@ public final class XIncludeTransformer e
 
                         // initialize the XPointer handler by parsing the xpointer
                         XPointer xPointer = XPointerFrameworkParser.parse(xpointer);
-                        xPointer.setLog(this.logger);
+                        xPointer.setLog(LOG);
 
                         // setup components
                         xPointer.setUp(xPointerContext);
@@ -349,13 +352,13 @@ public final class XIncludeTransformer e
                     } catch (ParseException e) {
                         // this exception is thrown in case of an invalid xpointer expression
                         this.useFallbackLevel++;
-                        if (this.logger.isErrorEnabled()) {
-                            this.logger.error("Error parsing XPointer expression, will try to use fallback.", e);
+                        if (LOG.isErrorEnabled()) {
+                            LOG.error("Error parsing XPointer expression, will try to use fallback.", e);
                         }
                     } catch (IOException e) {
                         this.useFallbackLevel++;
-                        if (this.logger.isErrorEnabled()) {
-                            this.logger.error("Error processing an xInclude, will try to use fallback.", e);
+                        if (LOG.isErrorEnabled()) {
+                            LOG.error("Error processing an xInclude, will try to use fallback.", e);
                         }
                     }
                 } else {
@@ -414,8 +417,8 @@ public final class XIncludeTransformer e
                     }
                 } catch (IOException e) {
                     this.useFallbackLevel++;
-                    if (this.logger.isErrorEnabled()) {
-                        this.logger.error("Error including text: ", e);
+                    if (LOG.isErrorEnabled()) {
+                        LOG.error("Error including text: ", e);
                     }
                 } finally {
                     closeQuietly(reader);
@@ -444,15 +447,15 @@ public final class XIncludeTransformer e
             } else {
                 source = new URL(this.baseUrl, sourceAtt);
             }
-            if (this.logger.isDebugEnabled()) {
-                this.logger.debug("Including source: " + source);
+            if (LOG.isDebugEnabled()) {
+                LOG.debug("Including source: " + source);
             }
 
             return source;
         } catch (MalformedURLException e) {
             String message = "Can't parse URL " + sourceAtt;
-            if (this.logger.isErrorEnabled()) {
-                this.logger.error(message, e);
+            if (LOG.isErrorEnabled()) {
+                LOG.error(message, e);
             }
             throw new ProcessingException(message, e);
         }
@@ -608,8 +611,8 @@ public final class XIncludeTransformer e
      */
     @Override
     public void setDocumentLocator(final Locator locator) {
-        if (this.logger.isDebugEnabled()) {
-            this.logger.debug("setDocumentLocator called "
+        if (LOG.isDebugEnabled()) {
+            LOG.debug("setDocumentLocator called "
                     + locator.getSystemId());
         }
 

Modified: cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/XMLGenerator.java
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/XMLGenerator.java?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/XMLGenerator.java (original)
+++ cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/XMLGenerator.java Tue Aug  9 13:56:40 2011
@@ -43,8 +43,8 @@ import org.apache.cocoon.sax.AbstractSAX
 import org.apache.cocoon.sax.util.XMLUtils;
 import org.apache.cocoon.xml.dom.DOMStreamer;
 import org.apache.cocoon.xml.sax.SAXBuffer;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 import org.w3c.dom.Node;
 import org.xml.sax.SAXException;
 
@@ -55,7 +55,11 @@ import org.xml.sax.SAXException;
 public class XMLGenerator extends AbstractSAXGenerator
         implements CachingPipelineComponent {
 
-    private final static Log LOG = LogFactory.getLog(XMLGenerator.class);
+    /**
+     * Logger.
+     */
+    private static final Logger LOG =
+            LoggerFactory.getLogger(XMLGenerator.class);
 
     private transient Starter generator;
 

Modified: cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/XSLTTransformer.java
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/XSLTTransformer.java?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/XSLTTransformer.java (original)
+++ cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/component/XSLTTransformer.java Tue Aug  9 13:56:40 2011
@@ -41,8 +41,8 @@ import org.apache.cocoon.sax.SAXConsumer
 import org.apache.cocoon.sax.util.InMemoryLRUResourceCache;
 import org.apache.cocoon.sax.util.SAXConsumerAdapter;
 import org.apache.cocoon.sax.util.ValidityValue;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 public class XSLTTransformer extends AbstractSAXTransformer {
 
@@ -67,7 +67,8 @@ public class XSLTTransformer extends Abs
     /**
      * This class log.
      */
-    private final Log LOG = LogFactory.getLog(XSLTTransformer.class);
+    private static final Logger LOG =
+            LoggerFactory.getLogger(XSLTTransformer.class);
 
     /**
      * The XSLT parameters reference.
@@ -271,7 +272,7 @@ public class XSLTTransformer extends Abs
         result.setLexicalHandler(consumer);
         transformerHandler.setResult(result);
 
-        TraxErrorListener traxErrorListener = new TraxErrorListener(this.LOG,
+        TraxErrorListener traxErrorListener = new TraxErrorListener(LOG,
                 this.source.toExternalForm());
         transformerHandler.getTransformer().setErrorListener(traxErrorListener);
 

Modified: cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/xpointer/XPointer.java
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/xpointer/XPointer.java?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/xpointer/XPointer.java (original)
+++ cocoon/cocoon3/trunk/cocoon-sax/src/main/java/org/apache/cocoon/sax/xpointer/XPointer.java Tue Aug  9 13:56:40 2011
@@ -20,7 +20,7 @@ import java.io.IOException;
 import java.util.ArrayList;
 import java.util.List;
 
-import org.apache.commons.logging.Log;
+import org.slf4j.Logger;
 import org.xml.sax.Attributes;
 import org.xml.sax.ContentHandler;
 import org.xml.sax.Locator;
@@ -33,9 +33,9 @@ public final class XPointer implements C
 
     private final List<PointerPart> pointerParts = new ArrayList<PointerPart>();
 
-    private Log log;
+    private Logger log;
 
-    public void setLog(Log log) {
+    public void setLog(Logger log) {
         this.log = log;
     }
 

Modified: cocoon/cocoon3/trunk/cocoon-sax/src/test/java/org/apache/cocoon/sax/component/LinkRewriterTransformerTest.java
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-sax/src/test/java/org/apache/cocoon/sax/component/LinkRewriterTransformerTest.java?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-sax/src/test/java/org/apache/cocoon/sax/component/LinkRewriterTransformerTest.java (original)
+++ cocoon/cocoon3/trunk/cocoon-sax/src/test/java/org/apache/cocoon/sax/component/LinkRewriterTransformerTest.java Tue Aug  9 13:56:40 2011
@@ -32,18 +32,18 @@ import javax.xml.parsers.SAXParserFactor
 import org.apache.cocoon.pipeline.NonCachingPipeline;
 import org.apache.cocoon.pipeline.Pipeline;
 import org.apache.cocoon.sax.SAXPipelineComponent;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
 import org.custommonkey.xmlunit.Diff;
 import org.custommonkey.xmlunit.XMLUnit;
 import org.junit.BeforeClass;
 import org.junit.Test;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 public final class LinkRewriterTransformerTest {
 
-    private static final Log LOG = LogFactory.getLog(
-            LinkRewriterTransformerTest.class);
-
+    private static final Logger LOG =
+            LoggerFactory.getLogger(LinkRewriterTransformerTest.class);
+    
     @BeforeClass
     public static void setUp() {
         XMLUnit.setIgnoreWhitespace(true);

Modified: cocoon/cocoon3/trunk/cocoon-servlet/pom.xml
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-servlet/pom.xml?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-servlet/pom.xml (original)
+++ cocoon/cocoon3/trunk/cocoon-servlet/pom.xml Tue Aug  9 13:56:40 2011
@@ -20,82 +20,105 @@
 <!-- $Id$ -->
 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
 
-  <modelVersion>4.0.0</modelVersion>
-  <packaging>jar</packaging>
+    <modelVersion>4.0.0</modelVersion>
+    <packaging>jar</packaging>
 
-  <parent>
-    <groupId>org.apache.cocoon.parent</groupId>
-    <artifactId>cocoon-parent</artifactId>
-    <version>3.0.0-beta-1-SNAPSHOT</version>
-    <relativePath>../parent/pom.xml</relativePath>
-  </parent>
+    <parent>
+        <groupId>org.apache.cocoon.parent</groupId>
+        <artifactId>cocoon-parent</artifactId>
+        <version>3.0.0-beta-1-SNAPSHOT</version>
+        <relativePath>../parent/pom.xml</relativePath>
+    </parent>
 
-  <groupId>org.apache.cocoon.servlet</groupId>
-  <artifactId>cocoon-servlet</artifactId>
-  <version>3.0.0-beta-1-SNAPSHOT</version>
+    <groupId>org.apache.cocoon.servlet</groupId>
+    <artifactId>cocoon-servlet</artifactId>
+    <version>3.0.0-beta-1-SNAPSHOT</version>
   
-  <name>Apache Cocoon 3: Servlet</name>
-  <description>Using Cocoon 3 within the Servlet Service framework.</description>
+    <name>Apache Cocoon 3: Servlet</name>
+    <description>Using Cocoon 3 within the Servlet Service framework.</description>
 
-  <dependencies>
-    <!-- Cocoon -->
-    <dependency>
-      <groupId>org.apache.cocoon.sitemap</groupId>
-      <artifactId>cocoon-sitemap</artifactId>
-    </dependency>
-    <dependency>
-      <groupId>org.apache.cocoon.controller</groupId>
-      <artifactId>cocoon-controller</artifactId>
-    </dependency>
-    <dependency>
-      <groupId>org.apache.cocoon.sax</groupId>
-      <artifactId>cocoon-sax</artifactId>
-    </dependency>
-
-    <!-- Cocoon subprojects -->
-    <dependency>
-      <groupId>org.apache.cocoon</groupId>
-      <artifactId>cocoon-servlet-service-impl</artifactId>
-    </dependency>
-    <dependency>
-      <groupId>org.apache.cocoon</groupId>
-      <artifactId>cocoon-spring-configurator</artifactId>
-    </dependency>
-    <dependency>
-      <groupId>org.apache.cocoon</groupId>
-      <artifactId>cocoon-jnet</artifactId>
-    </dependency>
-    <dependency>
-      <groupId>org.apache.cocoon</groupId>
-      <artifactId>cocoon-block-deployment</artifactId>
-    </dependency>
-
-    <!-- Spring AOP support -->
-    <dependency>
-      <groupId>org.springframework</groupId>
-      <artifactId>spring-aop</artifactId>
-    </dependency>
-    <dependency>
-      <groupId>org.aspectj</groupId>
-      <artifactId>aspectjrt</artifactId>
-    </dependency>
-    <dependency>
-      <groupId>org.aspectj</groupId>
-      <artifactId>aspectjweaver</artifactId>
-    </dependency>
-
-    <!-- Other libraries -->
-    <dependency>
-      <groupId>javax.servlet</groupId>
-      <artifactId>servlet-api</artifactId>
-      <scope>provided</scope>
-    </dependency>
-
-    <!--  Test dependencies -->
-    <dependency>
-      <groupId>junit</groupId>
-      <artifactId>junit</artifactId>
-      <scope>test</scope>
-    </dependency>
-  </dependencies>
+    <dependencies>
+        <!-- Cocoon -->
+        <dependency>
+            <groupId>org.apache.cocoon.sitemap</groupId>
+            <artifactId>cocoon-sitemap</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.cocoon.controller</groupId>
+            <artifactId>cocoon-controller</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.cocoon.sax</groupId>
+            <artifactId>cocoon-sax</artifactId>
+        </dependency>
+
+        <!-- Cocoon subprojects -->
+        <dependency>
+            <groupId>org.apache.cocoon</groupId>
+            <artifactId>cocoon-servlet-service-impl</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.cocoon</groupId>
+            <artifactId>cocoon-spring-configurator</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.cocoon</groupId>
+            <artifactId>cocoon-jnet</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.cocoon</groupId>
+            <artifactId>cocoon-block-deployment</artifactId>
+        </dependency>
+
+        <!-- Spring AOP support -->
+        <dependency>
+            <groupId>org.springframework</groupId>
+            <artifactId>spring-aop</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.aspectj</groupId>
+            <artifactId>aspectjrt</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.aspectj</groupId>
+            <artifactId>aspectjweaver</artifactId>
+        </dependency>
+
+        <!-- Other libraries -->
+        <dependency>
+            <groupId>javax.servlet</groupId>
+            <artifactId>servlet-api</artifactId>
+            <scope>provided</scope>
+        </dependency>
+
+        <!-- Logging -->
+        <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>slf4j-api</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>ch.qos.logback</groupId>
+            <artifactId>logback-core</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>ch.qos.logback</groupId>
+            <artifactId>logback-classic</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>commons-logging</groupId>
+            <artifactId>commons-logging</artifactId>
+            <scope>provided</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>jcl-over-slf4j</artifactId>
+        </dependency>
+
+        <!--  Test dependencies -->
+        <dependency>
+            <groupId>junit</groupId>
+            <artifactId>junit</artifactId>
+            <scope>test</scope>
+        </dependency>
+    </dependencies>
 </project>

Modified: cocoon/cocoon3/trunk/cocoon-servlet/src/main/java/org/apache/cocoon/servlet/DebugFilter.java
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-servlet/src/main/java/org/apache/cocoon/servlet/DebugFilter.java?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-servlet/src/main/java/org/apache/cocoon/servlet/DebugFilter.java (original)
+++ cocoon/cocoon3/trunk/cocoon-servlet/src/main/java/org/apache/cocoon/servlet/DebugFilter.java Tue Aug  9 13:56:40 2011
@@ -28,8 +28,8 @@ import javax.servlet.ServletResponse;
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpSession;
 
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 /**
  * Servlet filter for printing request debug information into log file.
@@ -38,7 +38,11 @@ import org.apache.commons.logging.LogFac
  */
 public class DebugFilter implements Filter {
 
-    private final Log logger = LogFactory.getLog(this.getClass());
+    /**
+     * Logger.
+     */
+    private static final Logger LOG =
+            LoggerFactory.getLogger(DebugFilter.class);
 
     final static protected String lineSeparator = "\n";
 
@@ -76,7 +80,7 @@ public class DebugFilter implements Filt
             ++this.activeRequestCount;
             final HttpServletRequest request = (HttpServletRequest) req;
 
-            if (this.logger.isDebugEnabled()) {
+            if (LOG.isDebugEnabled()) {
                 final StringBuffer msg = new StringBuffer();
 
                 msg.append("DEBUGGING INFORMATION:").append(lineSeparator);
@@ -160,7 +164,7 @@ public class DebugFilter implements Filt
                         }
                     }
                 }
-                this.logger.debug(msg.toString());
+                LOG.debug(msg.toString());
             }
 
             // Delegate

Modified: cocoon/cocoon3/trunk/cocoon-servlet/src/main/java/org/apache/cocoon/servlet/RequestProcessor.java
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-servlet/src/main/java/org/apache/cocoon/servlet/RequestProcessor.java?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-servlet/src/main/java/org/apache/cocoon/servlet/RequestProcessor.java (original)
+++ cocoon/cocoon3/trunk/cocoon-servlet/src/main/java/org/apache/cocoon/servlet/RequestProcessor.java Tue Aug  9 13:56:40 2011
@@ -47,16 +47,20 @@ import org.apache.cocoon.sitemap.Invocat
 import org.apache.cocoon.sitemap.SitemapBuilder;
 import org.apache.cocoon.sitemap.node.SitemapNode;
 import org.apache.cocoon.spring.configurator.ResourceUtils;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.BeanFactory;
 
 public class RequestProcessor {
-
+    /**
+     * Logger.
+     */
+    private static final Logger LOG =
+            LoggerFactory.getLogger(RequestProcessor.class);
+    
     private URL baseURL;
     private BeanFactory beanFactory;
     private boolean inServletServiceFramework;
-    private final Log logger = LogFactory.getLog(this.getClass());
     private ServletContext servletContext;
     private SitemapNode sitemapNode;
     private String sitemapPath;
@@ -100,8 +104,8 @@ public class RequestProcessor {
                 CallStackHelper.leaveServlet();
             }
         } finally {
-            if (this.logger.isInfoEnabled()) {
-                this.logger.info("Sitemap execution for " + request.getRequestURI() + " took "
+            if (LOG.isInfoEnabled()) {
+                LOG.info("Sitemap execution for " + request.getRequestURI() + " took "
                         + (System.nanoTime() - start) / 1000000f + " ms.");
             }
         }
@@ -157,8 +161,8 @@ public class RequestProcessor {
 
             this.baseURL = this.servletContext.getResource(baseURL);
 
-            if (this.logger.isDebugEnabled()) {
-                this.logger.debug("Setting the baseURL to " + this.baseURL);
+            if (LOG.isDebugEnabled()) {
+                LOG.debug("Setting the baseURL to " + this.baseURL);
             }
         } catch (MalformedURLException e) {
             throw new InvalidBaseUrlException("An exception occurred while retrieving the base "
@@ -215,8 +219,8 @@ public class RequestProcessor {
                     buildNumber = "/rev" + buildNumberAttr;
                 }
             } catch (IOException e) {
-                if (this.logger.isDebugEnabled()) {
-                    this.logger.debug("Error while reading an attribute from the manifest.", e);
+                if (LOG.isDebugEnabled()) {
+                    LOG.debug("Error while reading an attribute from the manifest.", e);
                 }
             }
             this.version += buildNumber;
@@ -236,12 +240,12 @@ public class RequestProcessor {
     }
 
     private void logRequest(HttpServletRequest request) {
-        if (this.logger.isInfoEnabled()) {
-            this.logger.info("Performing " + request.getMethod().toUpperCase() + " request at "
+        if (LOG.isInfoEnabled()) {
+            LOG.info("Performing " + request.getMethod().toUpperCase() + " request at "
                     + request.getRequestURI());
         }
-        if (this.logger.isDebugEnabled()) {
-            this.logger.debug("The base URL for this request is " + this.getBaseURL());
+        if (LOG.isDebugEnabled()) {
+            LOG.debug("The base URL for this request is " + this.getBaseURL());
         }
     }
 
@@ -331,8 +335,8 @@ public class RequestProcessor {
         // conditional request support (no need to send an unmodified response)
         // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
         if (!ResponseHeaderCollector.isModifiedResponse()) {
-            if (this.logger.isInfoEnabled()) {
-                this.logger.info("Going to send NOT MODIFIED response: statusCode="
+            if (LOG.isInfoEnabled()) {
+                LOG.info("Going to send NOT MODIFIED response: statusCode="
                         + HttpServletResponse.SC_NOT_MODIFIED + ", lastModified="
                         + lastModified);
             }
@@ -352,8 +356,8 @@ public class RequestProcessor {
         response.setStatus(statusCode);
 
         // logging
-        if (this.logger.isInfoEnabled()) {
-            this.logger.info("Going to send " + request.getMethod().toUpperCase() + " response: mimeType=" + mimeType
+        if (LOG.isInfoEnabled()) {
+            LOG.info("Going to send " + request.getMethod().toUpperCase() + " response: mimeType=" + mimeType
                     + ", contentLength=" + contentLengh + ", statusCode=" + statusCode + ", lastModified="
                     + lastModified);
         }

Modified: cocoon/cocoon3/trunk/cocoon-servlet/src/main/java/org/apache/cocoon/servlet/XMLSitemapServlet.java
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-servlet/src/main/java/org/apache/cocoon/servlet/XMLSitemapServlet.java?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-servlet/src/main/java/org/apache/cocoon/servlet/XMLSitemapServlet.java (original)
+++ cocoon/cocoon3/trunk/cocoon-servlet/src/main/java/org/apache/cocoon/servlet/XMLSitemapServlet.java Tue Aug  9 13:56:40 2011
@@ -25,10 +25,9 @@ import javax.servlet.http.HttpServlet;
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
 import org.apache.cocoon.configuration.Settings;
-
 import org.apache.cocoon.spring.configurator.WebAppContextUtils;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 /**
  * The Cocoon 3 servlet. It works with and without the Servlet-Service framework.
@@ -37,7 +36,11 @@ public class XMLSitemapServlet extends H
 
     private static final long serialVersionUID = 1L;
 
-    protected static final Log LOG = LogFactory.getLog(XMLSitemapServlet.class);
+    /**
+     * Logger.
+     */
+    protected static final Logger LOG =
+            LoggerFactory.getLogger(XMLSitemapServlet.class);
 
     protected transient RequestProcessor requestProcessor;
 
@@ -61,7 +64,7 @@ public class XMLSitemapServlet extends H
             final Settings settings = (Settings) WebAppContextUtils.
                     getCurrentWebApplicationContext().getBean(
                     Settings.class.getName());
-            
+
             if (!settings.isReloadingEnabled("sitemap")
                     && this.requestProcessor != null) {
                 return;

Modified: cocoon/cocoon3/trunk/cocoon-servlet/src/main/java/org/apache/cocoon/servlet/component/RedirectorComponent.java
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-servlet/src/main/java/org/apache/cocoon/servlet/component/RedirectorComponent.java?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-servlet/src/main/java/org/apache/cocoon/servlet/component/RedirectorComponent.java (original)
+++ cocoon/cocoon3/trunk/cocoon-servlet/src/main/java/org/apache/cocoon/servlet/component/RedirectorComponent.java Tue Aug  9 13:56:40 2011
@@ -32,12 +32,16 @@ import org.apache.cocoon.pipeline.compon
 import org.apache.cocoon.pipeline.component.Finisher;
 import org.apache.cocoon.pipeline.component.Starter;
 import org.apache.cocoon.servlet.util.HttpContextHelper;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 public class RedirectorComponent extends AbstractPipelineComponent implements Starter, Finisher {
 
-    private final Log logger = LogFactory.getLog(this.getClass());
+    /**
+     * Logger.
+     */
+    private static final Logger LOG =
+            LoggerFactory.getLogger(RedirectorComponent.class);
 
     private Map<String, Object> parameters;
     private String uri;
@@ -70,7 +74,7 @@ public class RedirectorComponent extends
                 response.sendRedirect(location);
             }
         } catch (IOException e) {
-            this.logger.error("Can't redirect to " + this.uri, e);
+            LOG.error("Can't redirect to " + this.uri, e);
             throw new ProcessingException(e);
         }
     }

Modified: cocoon/cocoon3/trunk/cocoon-servlet/src/main/java/org/apache/cocoon/servlet/controller/ControllerContextHelper.java
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-servlet/src/main/java/org/apache/cocoon/servlet/controller/ControllerContextHelper.java?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-servlet/src/main/java/org/apache/cocoon/servlet/controller/ControllerContextHelper.java (original)
+++ cocoon/cocoon3/trunk/cocoon-servlet/src/main/java/org/apache/cocoon/servlet/controller/ControllerContextHelper.java Tue Aug  9 13:56:40 2011
@@ -18,12 +18,10 @@ package org.apache.cocoon.servlet.contro
 
 import java.util.Collections;
 import java.util.Map;
-
 import javax.servlet.http.HttpServletRequest;
-
 import org.apache.cocoon.servlet.util.HttpContextHelper;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 /**
  * This class helps with storing and retrieving the controller context.
@@ -34,7 +32,11 @@ import org.apache.commons.logging.LogFac
  */
 public final class ControllerContextHelper {
 
-    private static final Log LOG = LogFactory.getLog(ControllerContextHelper.class);
+    /**
+     * Logger.
+     */
+    private static final Logger LOG =
+            LoggerFactory.getLogger(ControllerContextHelper.class);
 
     private static final String CONTEXT_OBJECT = ControllerContextHelper.class.getName();
 

Added: cocoon/cocoon3/trunk/cocoon-servlet/src/main/java/org/apache/cocoon/spring/configurator/logback/LogbackConfigurator.java
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-servlet/src/main/java/org/apache/cocoon/spring/configurator/logback/LogbackConfigurator.java?rev=1155368&view=auto
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-servlet/src/main/java/org/apache/cocoon/spring/configurator/logback/LogbackConfigurator.java (added)
+++ cocoon/cocoon3/trunk/cocoon-servlet/src/main/java/org/apache/cocoon/spring/configurator/logback/LogbackConfigurator.java Tue Aug  9 13:56:40 2011
@@ -0,0 +1,79 @@
+/*
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.cocoon.spring.configurator.logback;
+
+import ch.qos.logback.classic.LoggerContext;
+import ch.qos.logback.classic.joran.JoranConfigurator;
+import ch.qos.logback.core.util.StatusPrinter;
+import org.apache.cocoon.configuration.Settings;
+import org.slf4j.LoggerFactory;
+import org.springframework.beans.factory.InitializingBean;
+import org.springframework.core.io.Resource;
+
+public class LogbackConfigurator extends JoranConfigurator
+        implements InitializingBean {
+
+    /** The settings object that is used to substitute variable values. */
+    protected Settings settings;
+
+    /** The configuration resources. */
+    protected Resource resource;
+
+    /**
+     * Inject the settings object.
+     * @param settings The settings bean.
+     */
+    public void setSettings(final Settings settings) {
+        this.settings = settings;
+    }
+
+    /**
+     * Set the configuration resource.
+     * @param resource The resource.
+     */
+    public void setResource(final Resource resource) {
+        this.resource = resource;
+    }
+
+    /**
+     * This method is called after the instance is setup and before it is used.
+     * @throws Exception If anything during configuration goes wrong an exception
+     * is thrown.
+     * @see org.springframework.beans.factory.InitializingBean#afterPropertiesSet()
+     */
+    public void afterPropertiesSet()
+            throws Exception {
+
+        final LoggerContext loggerCtx =
+                (LoggerContext) LoggerFactory.getILoggerFactory();
+        setContext(loggerCtx);
+        loggerCtx.reset();
+
+        getContext().putProperty(Settings.KEY_CACHE_DIRECTORY,
+                this.settings.getCacheDirectory());
+        getContext().putProperty(Settings.KEY_CONTAINER_ENCODING,
+                this.settings.getContainerEncoding());
+        getContext().putProperty(Settings.KEY_FORM_ENCODING,
+                this.settings.getFormEncoding());
+        getContext().putProperty(Settings.KEY_WORK_DIRECTORY,
+                this.settings.getWorkDirectory());
+        for (Object propName : this.settings.getPropertyNames()) {
+            getContext().putProperty((String) propName,
+                    this.settings.getProperty((String) propName));
+        }
+
+        doConfigure(resource.getURL());
+        StatusPrinter.print(loggerCtx);
+    }
+}

Modified: cocoon/cocoon3/trunk/cocoon-sitemap/pom.xml
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-sitemap/pom.xml?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-sitemap/pom.xml (original)
+++ cocoon/cocoon3/trunk/cocoon-sitemap/pom.xml Tue Aug  9 13:56:40 2011
@@ -20,60 +20,83 @@
 <!-- $Id$ -->
 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
 
-  <modelVersion>4.0.0</modelVersion>
-  <packaging>jar</packaging>
+    <modelVersion>4.0.0</modelVersion>
+    <packaging>jar</packaging>
 
-  <parent>
-    <groupId>org.apache.cocoon.parent</groupId>
-    <artifactId>cocoon-parent</artifactId>
+    <parent>
+        <groupId>org.apache.cocoon.parent</groupId>
+        <artifactId>cocoon-parent</artifactId>
+        <version>3.0.0-beta-1-SNAPSHOT</version>
+        <relativePath>../parent</relativePath>
+    </parent>
+
+    <groupId>org.apache.cocoon.sitemap</groupId>
+    <artifactId>cocoon-sitemap</artifactId>
     <version>3.0.0-beta-1-SNAPSHOT</version>
-    <relativePath>../parent</relativePath>
-  </parent>
 
-  <groupId>org.apache.cocoon.sitemap</groupId>
-  <artifactId>cocoon-sitemap</artifactId>
-  <version>3.0.0-beta-1-SNAPSHOT</version>
-
-  <name>Apache Cocoon 3: Sitemap</name>
-  <description>A sitemap language interpreter.</description>
-
-  <dependencies>
-    <dependency>
-      <groupId>org.apache.cocoon.pipeline</groupId>
-      <artifactId>cocoon-pipeline</artifactId>
-    </dependency>
-    <dependency>
-      <groupId>org.apache.cocoon.sax</groupId>
-      <artifactId>cocoon-sax</artifactId>
-    </dependency>
-
-    <dependency>
-      <groupId>org.springframework</groupId>
-      <artifactId>spring-context</artifactId>
-    </dependency>
-    <dependency>
-      <groupId>org.springframework</groupId>
-      <artifactId>spring-aop</artifactId>
-    </dependency>
-    <dependency>
-      <groupId>commons-jexl</groupId>
-      <artifactId>commons-jexl</artifactId>
-    </dependency>
-    <dependency>
-      <groupId>org.apache.cocoon</groupId>
-      <artifactId>cocoon-spring-configurator</artifactId>
-    </dependency>
-
-    <!-- Test dependencies -->
-    <dependency>
-      <groupId>junit</groupId>
-      <artifactId>junit</artifactId>
-      <scope>test</scope>
-    </dependency>
-    <dependency>
-      <groupId>junit-addons</groupId>
-      <artifactId>junit-addons</artifactId>
-      <scope>test</scope>
-    </dependency>
-  </dependencies>
+    <name>Apache Cocoon 3: Sitemap</name>
+    <description>A sitemap language interpreter.</description>
+
+    <dependencies>
+        <dependency>
+            <groupId>org.apache.cocoon.pipeline</groupId>
+            <artifactId>cocoon-pipeline</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.cocoon.sax</groupId>
+            <artifactId>cocoon-sax</artifactId>
+        </dependency>
+
+        <dependency>
+            <groupId>org.springframework</groupId>
+            <artifactId>spring-context</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.springframework</groupId>
+            <artifactId>spring-aop</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.commons</groupId>
+            <artifactId>commons-jexl</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.cocoon</groupId>
+            <artifactId>cocoon-spring-configurator</artifactId>
+        </dependency>
+        
+        <!-- Logging -->
+        <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>slf4j-api</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>ch.qos.logback</groupId>
+            <artifactId>logback-core</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>ch.qos.logback</groupId>
+            <artifactId>logback-classic</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>commons-logging</groupId>
+            <artifactId>commons-logging</artifactId>
+            <scope>provided</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>jcl-over-slf4j</artifactId>
+        </dependency>
+
+        <!-- Test dependencies -->
+        <dependency>
+            <groupId>junit</groupId>
+            <artifactId>junit</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>junit-addons</groupId>
+            <artifactId>junit-addons</artifactId>
+            <scope>test</scope>
+        </dependency>
+    </dependencies>
 </project>

Modified: cocoon/cocoon3/trunk/cocoon-sitemap/src/main/java/org/apache/cocoon/sitemap/InvocationImpl.java
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-sitemap/src/main/java/org/apache/cocoon/sitemap/InvocationImpl.java?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-sitemap/src/main/java/org/apache/cocoon/sitemap/InvocationImpl.java (original)
+++ cocoon/cocoon3/trunk/cocoon-sitemap/src/main/java/org/apache/cocoon/sitemap/InvocationImpl.java Tue Aug  9 13:56:40 2011
@@ -37,13 +37,18 @@ import org.apache.cocoon.sitemap.express
 import org.apache.cocoon.sitemap.objectmodel.ObjectModel;
 import org.apache.cocoon.sitemap.util.ExceptionHandler;
 import org.apache.cocoon.sitemap.util.ParameterHelper;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
 
 public class InvocationImpl implements Invocation {
 
-    private final Log errorLogger = LogFactory.getLog(this.getClass().getName() + "/handle-errors");
+    /**
+     * Logger.
+     */
+    private static final Logger ERROR_LOG =
+            LoggerFactory.getLogger(InvocationImpl.class.getName() 
+            + "/handle-errors");
 
     private static final Pattern PARAMETER_PATTERN = Pattern.compile("\\{([a-zA-Z\\-]+):([^\\{]*)\\}");
 
@@ -340,7 +345,7 @@ public class InvocationImpl implements I
         ParameterHelper.setThrowable(this.parameters, cause);
 
         String message = "Error while executing the sitemap. [request-uri=" + this.getRequestURI() + "]";
-        this.errorLogger.error(message, throwable);
+        ERROR_LOG.error(message, throwable);
     }
 
     private LanguageInterpreter getLanguageInterpreter(final String language) {

Modified: cocoon/cocoon3/trunk/cocoon-sitemap/src/main/java/org/apache/cocoon/sitemap/component/FileReaderComponent.java
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-sitemap/src/main/java/org/apache/cocoon/sitemap/component/FileReaderComponent.java?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-sitemap/src/main/java/org/apache/cocoon/sitemap/component/FileReaderComponent.java (original)
+++ cocoon/cocoon3/trunk/cocoon-sitemap/src/main/java/org/apache/cocoon/sitemap/component/FileReaderComponent.java Tue Aug  9 13:56:40 2011
@@ -28,13 +28,17 @@ import org.apache.cocoon.pipeline.cachin
 import org.apache.cocoon.pipeline.caching.TimestampCacheKey;
 import org.apache.cocoon.pipeline.component.CachingPipelineComponent;
 import org.apache.cocoon.pipeline.util.URLConnectionUtils;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 public class FileReaderComponent extends AbstractReader implements CachingPipelineComponent {
 
-    private final Log logger = LogFactory.getLog(this.getClass());
-
+    /**
+     * Logger.
+     */
+    private static final Logger LOG =
+            LoggerFactory.getLogger(FileReaderComponent.class);
+    
     public FileReaderComponent() {
         super();
     }
@@ -55,7 +59,7 @@ public class FileReaderComponent extends
             URLConnectionUtils.closeQuietly(connection);
             return timestampCacheKey;
         } catch (IOException e) {
-            this.logger.error("Can't construct cache key. Error while connecting to " + this.source, e);
+            LOG.error("Can't construct cache key. Error while connecting to " + this.source, e);
         }
 
         return null;
@@ -89,7 +93,7 @@ public class FileReaderComponent extends
 
         } catch (IOException e) {
             String message = "FileReader cannot read from '" + this.source + "'";
-            this.logger.error(message, e);
+            LOG.error(message, e);
             throw new ProcessingException(message, e);
         } finally {
             URLConnectionUtils.closeQuietly(connection);

Modified: cocoon/cocoon3/trunk/cocoon-sitemap/src/main/java/org/apache/cocoon/sitemap/expression/JexlLanguageInterpreter.java
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-sitemap/src/main/java/org/apache/cocoon/sitemap/expression/JexlLanguageInterpreter.java?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-sitemap/src/main/java/org/apache/cocoon/sitemap/expression/JexlLanguageInterpreter.java (original)
+++ cocoon/cocoon3/trunk/cocoon-sitemap/src/main/java/org/apache/cocoon/sitemap/expression/JexlLanguageInterpreter.java Tue Aug  9 13:56:40 2011
@@ -18,30 +18,39 @@
  */
 package org.apache.cocoon.sitemap.expression;
 
-import java.util.Map;
-
 import org.apache.cocoon.sitemap.objectmodel.ObjectModel;
-import org.apache.commons.jexl.Expression;
-import org.apache.commons.jexl.ExpressionFactory;
-import org.apache.commons.jexl.JexlContext;
-import org.apache.commons.jexl.JexlHelper;
+import org.apache.commons.jexl2.Expression;
+import org.apache.commons.jexl2.JexlContext;
+import org.apache.commons.jexl2.JexlEngine;
+import org.apache.commons.jexl2.MapContext;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 public class JexlLanguageInterpreter implements LanguageInterpreter {
 
-    public String resolve(String expression, ObjectModel objectModel) {
+    /**
+     * Logger.
+     */
+    private static final Logger LOG =
+            LoggerFactory.getLogger(JexlLanguageInterpreter.class);
+
+    @Override
+    public String resolve(final String expression,
+            final ObjectModel objectModel) {
+
+        final JexlEngine jexlEngine = new JexlEngine();
+        jexlEngine.setLenient(false);
+
         Object result = null;
         try {
-            Expression e = ExpressionFactory.createExpression(expression);
-            JexlContext jc = JexlHelper.createContext();
-            @SuppressWarnings("unchecked")
-            Map<String, Object> vars = jc.getVars();
-            vars.putAll(objectModel.getParameters());
-
-            result = e.evaluate(jc);
-        } catch (Exception e1) {
-            e1.printStackTrace();
+            final Expression expr = jexlEngine.createExpression(expression);
+            final JexlContext jexlContext =
+                    new MapContext(objectModel.getParameters());
+            result = expr.evaluate(jexlContext);
+        } catch (Exception e) {
+            LOG.error("While evaluating '" + expression + "'", e);
         }
 
-        return result != null ? result.toString() : "";
+        return result == null ? "" : result.toString();
     }
 }

Modified: cocoon/cocoon3/trunk/cocoon-sitemap/src/main/java/org/apache/cocoon/sitemap/node/AbstractSitemapNode.java
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-sitemap/src/main/java/org/apache/cocoon/sitemap/node/AbstractSitemapNode.java?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-sitemap/src/main/java/org/apache/cocoon/sitemap/node/AbstractSitemapNode.java (original)
+++ cocoon/cocoon3/trunk/cocoon-sitemap/src/main/java/org/apache/cocoon/sitemap/node/AbstractSitemapNode.java Tue Aug  9 13:56:40 2011
@@ -31,13 +31,17 @@ import org.apache.cocoon.sitemap.Invocat
 import org.apache.cocoon.sitemap.node.annotations.NodeChild;
 import org.apache.cocoon.sitemap.node.annotations.Parameter;
 import org.apache.cocoon.sitemap.util.SpringProxyHelper;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 public abstract class AbstractSitemapNode implements SitemapNode {
 
-    private final Log logger = LogFactory.getLog(this.getClass());
-
+    /**
+     * Logger.
+     */
+    private static final Logger LOG =
+            LoggerFactory.getLogger(AbstractSitemapNode.class);
+    
     private final List<SitemapNode> children = new LinkedList<SitemapNode>();
 
     private final Map<String, String> parameters = new HashMap<String, String>();
@@ -61,9 +65,9 @@ public abstract class AbstractSitemapNod
                 try {
                     childField.set(this, SpringProxyHelper.unpackProxy(child));
                 } catch (IllegalArgumentException e) {
-                    this.logger.error("Failed to set child field for child class '" + child.getClass().getName(), e);
+                    LOG.error("Failed to set child field for child class '" + child.getClass().getName(), e);
                 } catch (IllegalAccessException e) {
-                    this.logger.error("Failed to set child field for child class '" + child.getClass().getName(), e);
+                    LOG.error("Failed to set child field for child class '" + child.getClass().getName(), e);
                 }
             } else {
                 this.children.add(child);
@@ -85,8 +89,8 @@ public abstract class AbstractSitemapNod
         InvocationResult result = InvocationResult.NONE;
 
         for (SitemapNode child : this.children) {
-            if (this.logger.isDebugEnabled()) {
-                this.logger.debug(child + ".invoke(" + invocation.getRequestURI() + ")");
+            if (LOG.isDebugEnabled()) {
+                LOG.debug(child + ".invoke(" + invocation.getRequestURI() + ")");
             }
 
             // aggregate the results of child invocations, the overall result is
@@ -125,11 +129,11 @@ public abstract class AbstractSitemapNod
                     parameterField.set(this, value);
                 } catch (IllegalArgumentException e) {
                     String message = "Failed to set parameter field " + key;
-                    this.logger.error(message, e);
+                    LOG.error(message, e);
                     throw new RuntimeException(message, e);
                 } catch (IllegalAccessException e) {
                     String message = "Failed to set parameter field " + key;
-                    this.logger.error(message, e);
+                    LOG.error(message, e);
                     throw new RuntimeException(message, e);
                 }
                 continue;

Modified: cocoon/cocoon3/trunk/cocoon-sitemap/src/main/java/org/apache/cocoon/sitemap/node/MatchNode.java
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-sitemap/src/main/java/org/apache/cocoon/sitemap/node/MatchNode.java?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-sitemap/src/main/java/org/apache/cocoon/sitemap/node/MatchNode.java (original)
+++ cocoon/cocoon3/trunk/cocoon-sitemap/src/main/java/org/apache/cocoon/sitemap/node/MatchNode.java Tue Aug  9 13:56:40 2011
@@ -20,7 +20,6 @@ package org.apache.cocoon.sitemap.node;
 
 import java.util.LinkedList;
 import java.util.Map;
-
 import org.apache.cocoon.sitemap.Invocation;
 import org.apache.cocoon.sitemap.matcher.ContainsMatcher;
 import org.apache.cocoon.sitemap.matcher.EndsWithMatcher;
@@ -30,14 +29,18 @@ import org.apache.cocoon.sitemap.matcher
 import org.apache.cocoon.sitemap.matcher.StartsWithMatcher;
 import org.apache.cocoon.sitemap.matcher.WildcardMatcher;
 import org.apache.cocoon.sitemap.node.annotations.Parameter;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 @Node(name = "match")
 public class MatchNode extends AbstractSitemapNode {
 
-    private final Log logger = LogFactory.getLog(this.getClass());
-
+    /**
+     * Logger.
+     */
+    private static final Logger LOG =
+            LoggerFactory.getLogger(MatchNode.class);
+    
     @Parameter
     private String name;
 
@@ -153,7 +156,7 @@ public class MatchNode extends AbstractS
         if (matcherContextList.size() > 1) {
             String message = "Only one matching attribute (regexp, equals, contains, wildcard, pattern) can be set: "
                     + matcherContextList;
-            this.logger.error(message);
+            LOG.error(message);
             throw new MatchingAttributeException(message);
         }
         return matcherContextList.isEmpty() ? null : matcherContextList.getFirst();
@@ -179,7 +182,11 @@ public class MatchNode extends AbstractS
 
     protected static class MatcherContext {
 
-        private static final Log LOG = LogFactory.getLog(MatcherContext.class);
+        /**
+         * Logger.
+         */
+        private static final Logger LOG =
+                LoggerFactory.getLogger(MatcherContext.class);
 
         private Matcher matcher;
         private String expression;

Modified: cocoon/cocoon3/trunk/cocoon-stax/pom.xml
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-stax/pom.xml?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-stax/pom.xml (original)
+++ cocoon/cocoon3/trunk/cocoon-stax/pom.xml Tue Aug  9 13:56:40 2011
@@ -16,125 +16,134 @@
 -->
 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
 
-  <modelVersion>4.0.0</modelVersion>
-  <packaging>jar</packaging>
+    <modelVersion>4.0.0</modelVersion>
+    <packaging>jar</packaging>
 
-  <parent>
-    <groupId>org.apache.cocoon.parent</groupId>
-    <artifactId>cocoon-parent</artifactId>
-    <version>3.0.0-beta-1-SNAPSHOT</version>
-    <relativePath>../parent</relativePath>
-  </parent>
+    <parent>
+        <groupId>org.apache.cocoon.parent</groupId>
+        <artifactId>cocoon-parent</artifactId>
+        <version>3.0.0-beta-1-SNAPSHOT</version>
+        <relativePath>../parent</relativePath>
+    </parent>
 
-  <groupId>org.apache.cocoon.stax</groupId>
-  <artifactId>cocoon-stax</artifactId>
-  <version>3.0.0-beta-1-SNAPSHOT</version>
+    <groupId>org.apache.cocoon.stax</groupId>
+    <artifactId>cocoon-stax</artifactId>
+    <version>3.0.0-beta-1-SNAPSHOT</version>
   
-  <name>Apache Cocoon 3: StAX</name>
-  <description>Cocoon 3 components required for building StAX pipelines and components.</description>
+    <name>Apache Cocoon 3: StAX</name>
+    <description>Cocoon 3 components required for building StAX pipelines and components.</description>
+
+    <dependencies>
+        <dependency>
+            <groupId>org.apache.cocoon.pipeline</groupId>
+            <artifactId>cocoon-pipeline</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.codehaus.woodstox</groupId>
+            <artifactId>wstx-asl</artifactId>
+            <optional>true</optional>
+        </dependency>   
+        <dependency>
+            <groupId>org.apache.cocoon.sax</groupId>
+            <artifactId>cocoon-sax</artifactId>
+            <optional>true</optional>
+        </dependency>
+
+        <!-- Logging -->
+        <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>slf4j-api</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>ch.qos.logback</groupId>
+            <artifactId>logback-core</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>ch.qos.logback</groupId>
+            <artifactId>logback-classic</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>commons-logging</groupId>
+            <artifactId>commons-logging</artifactId>
+            <scope>provided</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>jcl-over-slf4j</artifactId>
+        </dependency>
+        
+        <!-- test dependencies -->
+        <dependency>
+            <groupId>commons-io</groupId>
+            <artifactId>commons-io</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>junit</groupId>
+            <artifactId>junit</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>xmlunit</groupId>
+            <artifactId>xmlunit</artifactId>
+            <scope>test</scope>
+        </dependency>
+    </dependencies>
 
-  <dependencies>
-    <dependency>
-      <groupId>org.apache.cocoon.pipeline</groupId>
-      <artifactId>cocoon-pipeline</artifactId>
-    </dependency>
-    <dependency>
-      <groupId>commons-logging</groupId>
-      <artifactId>commons-logging</artifactId>
-      <exclusions>
-        <exclusion>
-          <artifactId>logkit</artifactId>
-          <groupId>logkit</groupId>
-        </exclusion>
-        <exclusion>
-          <artifactId>avalon-framework</artifactId>
-          <groupId>avalon-framework</groupId>
-        </exclusion>
-      </exclusions>
-    </dependency>
-    <dependency>
-      <groupId>org.codehaus.woodstox</groupId>
-      <artifactId>wstx-asl</artifactId>
-      <optional>true</optional>
-    </dependency>   
-    <dependency>
-      <groupId>org.apache.cocoon.sax</groupId>
-      <artifactId>cocoon-sax</artifactId>
-      <optional>true</optional>
-    </dependency>
-
-    <!-- test dependencies -->
-    <dependency>
-      <groupId>commons-io</groupId>
-      <artifactId>commons-io</artifactId>
-      <scope>test</scope>
-    </dependency>
-    <dependency>
-      <groupId>junit</groupId>
-      <artifactId>junit</artifactId>
-      <scope>test</scope>
-    </dependency>
-    <dependency>
-      <groupId>xmlunit</groupId>
-      <artifactId>xmlunit</artifactId>
-      <scope>test</scope>
-    </dependency>
-  </dependencies>
-
-  <build>
-    <plugins>
-      <plugin>
-        <artifactId>maven-surefire-plugin</artifactId>
-        <configuration>
-          <excludes>
-            <exclude>**/cocoon/stax/stress/**</exclude>
-          </excludes>
-        </configuration>
-      </plugin>
-      <plugin>
-        <groupId>org.codehaus.mojo</groupId>
-        <artifactId>rat-maven-plugin</artifactId>
-        <configuration>
-          <excludes>
-            <exclude>src/main/java/org/apache/cocoon/stax/converter/util/*.java</exclude>
-          </excludes>
-        </configuration>
-      </plugin>      
-    </plugins>
-  </build>
-
-  <profiles>
-    <profile>
-      <id>stress</id>
-      <build>
+    <build>
         <plugins>
-          <plugin>
-            <artifactId>maven-surefire-plugin</artifactId>
-            <configuration>
-              <excludes>
-                <exclude>**/cocoon/**</exclude>
-              </excludes>
-            </configuration>
-            <executions>
-              <execution>
-                <id>integration-test</id>
-                <goals>
-                  <goal>test</goal>
-                </goals>
-                <phase>test</phase>
+            <plugin>
+                <artifactId>maven-surefire-plugin</artifactId>
                 <configuration>
-                  <excludes>
-                    <exclude>none</exclude>
-                  </excludes>
-                  <includes>
-                    <include>**/cocoon/stax/stress/test/*Test.*</include>
-                  </includes>
+                    <excludes>
+                        <exclude>**/cocoon/stax/stress/**</exclude>
+                    </excludes>
                 </configuration>
-              </execution>
-            </executions>            
-          </plugin>
+            </plugin>
+            <plugin>
+                <groupId>org.codehaus.mojo</groupId>
+                <artifactId>rat-maven-plugin</artifactId>
+                <configuration>
+                    <excludes>
+                        <exclude>src/main/java/org/apache/cocoon/stax/converter/util/*.java</exclude>
+                    </excludes>
+                </configuration>
+            </plugin>      
         </plugins>
-      </build>
-    </profile>
-  </profiles>
+    </build>
+
+    <profiles>
+        <profile>
+            <id>stress</id>
+            <build>
+                <plugins>
+                    <plugin>
+                        <artifactId>maven-surefire-plugin</artifactId>
+                        <configuration>
+                            <excludes>
+                                <exclude>**/cocoon/**</exclude>
+                            </excludes>
+                        </configuration>
+                        <executions>
+                            <execution>
+                                <id>integration-test</id>
+                                <goals>
+                                    <goal>test</goal>
+                                </goals>
+                                <phase>test</phase>
+                                <configuration>
+                                    <excludes>
+                                        <exclude>none</exclude>
+                                    </excludes>
+                                    <includes>
+                                        <include>**/cocoon/stax/stress/test/*Test.*</include>
+                                    </includes>
+                                </configuration>
+                            </execution>
+                        </executions>            
+                    </plugin>
+                </plugins>
+            </build>
+        </profile>
+    </profiles>
 </project>

Modified: cocoon/cocoon3/trunk/cocoon-stax/src/main/java/org/apache/cocoon/stax/component/IncludeTransformer.java
URL: http://svn.apache.org/viewvc/cocoon/cocoon3/trunk/cocoon-stax/src/main/java/org/apache/cocoon/stax/component/IncludeTransformer.java?rev=1155368&r1=1155367&r2=1155368&view=diff
==============================================================================
--- cocoon/cocoon3/trunk/cocoon-stax/src/main/java/org/apache/cocoon/stax/component/IncludeTransformer.java (original)
+++ cocoon/cocoon3/trunk/cocoon-stax/src/main/java/org/apache/cocoon/stax/component/IncludeTransformer.java Tue Aug  9 13:56:40 2011
@@ -25,15 +25,14 @@ import javax.xml.namespace.QName;
 import javax.xml.stream.XMLStreamException;
 import javax.xml.stream.events.Attribute;
 import javax.xml.stream.events.XMLEvent;
-
 import org.apache.cocoon.pipeline.ProcessingException;
 import org.apache.cocoon.pipeline.component.AbstractPipelineComponent;
 import org.apache.cocoon.pipeline.util.StringRepresentation;
 import org.apache.cocoon.stax.AbstractStAXTransformer;
 import org.apache.cocoon.stax.StAXProducer;
 import org.apache.cocoon.stax.navigation.Navigator;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 /**
  * A transformer that includes a xml document into another at the place where a include tag is found
@@ -41,8 +40,12 @@ import org.apache.commons.logging.LogFac
  */
 public class IncludeTransformer extends AbstractStAXTransformer {
 
-    private final Log logger = LogFactory.getLog(this.getClass());
-
+    /**
+     * Logger.
+     */
+    private static final Logger LOG =
+            LoggerFactory.getLogger(IncludeTransformer.class);
+    
     private static final String INCLUDE_NS = "http://apache.org/cocoon/3.0/include";
 
     private static final String INCLUDE_EL = "include";
@@ -118,7 +121,7 @@ public class IncludeTransformer extends 
                         this.includeDelegate = new XMLGenerator(source.openConnection().getInputStream());
                     } catch (IOException e) {
                         String message = "Can't read from URL " + sourceAttribute.getValue();
-                        this.logger.error(message, e);
+                        LOG.error(message, e);
                         throw new ProcessingException(message, e);
                     }
                 } else if (!this.isIncludeEnd.fulfillsCriteria(event)) {
@@ -154,14 +157,14 @@ public class IncludeTransformer extends 
             } else {
                 source = new URL(this.baseUrl, sourceAtt);
             }
-            if (this.logger.isDebugEnabled()) {
-                this.logger.debug("Including source: " + source);
+            if (LOG.isDebugEnabled()) {
+                LOG.debug("Including source: " + source);
             }
 
             return source;
         } catch (MalformedURLException e) {
             String message = "Can't parse URL " + sourceAtt;
-            this.logger.error(message, e);
+            LOG.error(message, e);
             throw new ProcessingException(message, e);
         }
     }



Mime
View raw message