dims        01/07/12 05:24:06

  Modified:    src/org/apache/cocoon Tag: cocoon_20_branch Constants.java
               src/org/apache/cocoon/servlet Tag: cocoon_20_branch
                        CocoonServlet.java
               src/org/apache/cocoon/sitemap Tag: cocoon_20_branch
                        Manager.java
  Log:
  Print full path of the log file in the Sitemap Handler not found message.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.4.2.3   +2 -1      xml-cocoon2/src/org/apache/cocoon/Constants.java
  
  Index: Constants.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/org/apache/cocoon/Constants.java,v
  retrieving revision 1.4.2.2
  retrieving revision 1.4.2.3
  diff -u -r1.4.2.2 -r1.4.2.3
  --- Constants.java    2001/06/15 11:27:45     1.4.2.2
  +++ Constants.java    2001/07/12 12:23:40     1.4.2.3
  @@ -10,7 +10,7 @@
   
   /**
    * @author <a href="mailto:[EMAIL PROTECTED]";>Stefano Mazzocchi</a>
  - * @version CVS $Revision: 1.4.2.2 $ $Date: 2001/06/15 11:27:45 $
  + * @version CVS $Revision: 1.4.2.3 $ $Date: 2001/07/12 12:23:40 $
    */
   
   public interface Constants {
  @@ -70,4 +70,5 @@
       String CONTEXT_CLASSPATH       = "classpath";
       String CONTEXT_CONFIG_URL      = "config-url";
       String CONTEXT_LOG_DIR         = "log-directory";
  +    String CONTEXT_LOG_FILE        = "log-file";
   }
  
  
  
  No                   revision
  
  
  No                   revision
  
  
  1.13.2.3  +4 -1      xml-cocoon2/src/org/apache/cocoon/servlet/CocoonServlet.java
  
  Index: CocoonServlet.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/org/apache/cocoon/servlet/CocoonServlet.java,v
  retrieving revision 1.13.2.2
  retrieving revision 1.13.2.3
  diff -u -r1.13.2.2 -r1.13.2.3
  --- CocoonServlet.java        2001/06/14 11:13:06     1.13.2.2
  +++ CocoonServlet.java        2001/07/12 12:23:52     1.13.2.3
  @@ -58,7 +58,7 @@
    * @author <a href="mailto:[EMAIL PROTECTED]";>Stefano Mazzocchi</a>
    * @author <a href="mailto:[EMAIL PROTECTED]";>Nicola Ken Barozzi</a> Aisa
    * @author <a href="mailto:[EMAIL PROTECTED]";>Berin Loritsch</a>
  - * @version CVS $Revision: 1.13.2.2 $ $Date: 2001/06/14 11:13:06 $
  + * @version CVS $Revision: 1.13.2.3 $ $Date: 2001/07/12 12:23:52 $
    */
   
   public class CocoonServlet extends HttpServlet {
  @@ -312,6 +312,9 @@
               if (logName == null) {
                   logName = "cocoon.log";
               }
  +     
  +             this.appContext.put(Constants.CONTEXT_LOG_FILE, logName);
  +
               final String path = logDir + logName;
               final AvalonFormatter formatter = new AvalonFormatter();
               formatter.setFormat( "%7.7{priority} %5.5{time}   [%8.8{category}] " +
  
  
  
  No                   revision
  
  
  No                   revision
  
  
  1.2.2.8   +9 -2      xml-cocoon2/src/org/apache/cocoon/sitemap/Manager.java
  
  Index: Manager.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/org/apache/cocoon/sitemap/Manager.java,v
  retrieving revision 1.2.2.7
  retrieving revision 1.2.2.8
  diff -u -r1.2.2.7 -r1.2.2.8
  --- Manager.java      2001/07/06 14:01:59     1.2.2.7
  +++ Manager.java      2001/07/12 12:24:00     1.2.2.8
  @@ -8,6 +8,7 @@
   
   package org.apache.cocoon.sitemap;
   
  +import java.io.File;
   import java.util.HashMap;
   import java.util.Iterator;
   import org.apache.avalon.framework.component.Component;
  @@ -33,7 +34,7 @@
    * checking regeneration of the sub <code>Sitemap</code>
    *
    * @author <a href="mailto:[EMAIL PROTECTED]";>Giacomo Pati</a>
  - * @version CVS $Revision: 1.2.2.7 $ $Date: 2001/07/06 14:01:59 $
  + * @version CVS $Revision: 1.2.2.8 $ $Date: 2001/07/12 12:24:00 $
    */
   public class Manager extends AbstractLoggable implements Component, Configurable, 
Composable, Contextualizable, ThreadSafe {
       private Context context;
  @@ -49,6 +50,9 @@
   
       /** The sitemap role manager */
       private RoleManager sitemapRoles;
  +    
  +    /** The log file path */
  +    private String logFilePath;
   
       /**
        * Set the role manager
  @@ -69,6 +73,9 @@
        */
       public void contextualize(Context context) throws ContextException {
           this.context = context;
  +        String logDir = (String) 
context.get(org.apache.cocoon.Constants.CONTEXT_LOG_DIR);
  +        String logFile = (String) 
context.get(org.apache.cocoon.Constants.CONTEXT_LOG_FILE);
  +        logFilePath = logDir + logFile;
       }
   
       /** get a component manager
  @@ -175,7 +182,7 @@
               environment.changeContext(uri_prefix, source);
               if (!sitemapHandler.available()) {
                   throw new ProcessingException("The sitemap handler's sitemap is not 
available. " +
  -                    "Please check cocoon.log for the exact error.",
  +                    "Please check "+ logFilePath +" for the exact error.",
                       sitemapHandler.getException());
               }
       }
  
  
  

----------------------------------------------------------------------
In case of troubles, e-mail:     [EMAIL PROTECTED]
To unsubscribe, e-mail:          [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to