portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From morci...@apache.org
Subject cvs commit: jakarta-jetspeed/xdocs changes.xml
Date Thu, 13 Mar 2003 01:08:12 GMT
morciuch    2003/03/12 17:08:12

  Modified:    docs/site changes.html
               src/java/org/apache/jetspeed/portal/security/portlets
                        PortletWrapper.java
               src/java/org/apache/jetspeed/services PortletStats.java
               src/java/org/apache/jetspeed/services/portletstats
                        JetspeedPortletStatsService.java
                        PortletStatsService.java
               webapp/WEB-INF/conf JetspeedResources.properties
               xdocs    changes.xml
  Log:
  Added feature to log portlet load time in place of bytes sent in the portlet stats service
(see Bugzilla issue# 17632).
  
  This feature is disabled by default (see logLoadTime in jr.props)
  
  Revision  Changes    Path
  1.116     +212 -211  jakarta-jetspeed/docs/site/changes.html
  
  Index: changes.html
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/docs/site/changes.html,v
  retrieving revision 1.115
  retrieving revision 1.116
  diff -u -r1.115 -r1.116
  --- changes.html	8 Mar 2003 02:17:47 -0000	1.115
  +++ changes.html	13 Mar 2003 01:08:10 -0000	1.116
  @@ -1,129 +1,127 @@
  -<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
  -
  -<!-- Content Stylesheet for Site -->
  -
  -        
  -<!-- start the processing -->
  -    <!-- ====================================================================== -->
  -    <!-- GENERATED FILE, DO NOT EDIT, EDIT THE XML FILE IN xdocs INSTEAD! -->
  -    <!-- Main Page Section -->
  -    <!-- ====================================================================== -->
  -    <html>
  -        <head>
  -            <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"/>
  -
  -                        
  -           
  -                                    
  -                        
  -            <title>Jetspeed - Jetspeed Changes Log</title>
  -        </head>
  -
  -        <body bgcolor="#ffffff" text="#000000" link="#525D76">        
  -            <table border="0" width="100%" cellspacing="0">
  -                <!-- TOP IMAGE -->
  -                <tr>
  -                    <td align="left">
  -<a href="http://jakarta.apache.org"><img src="http://jakarta.apache.org/images/jakarta-logo.gif"
border="0"/></a>
  -</td>
  -<td align="right">
  -<a href="http://jakarta.apache.org/jetspeed/"><img src="./images/logo.gif" alt="Jetspeed"
border="0"/></a>
  -</td>
  -                </tr>
  -            </table>
  -            <table border="0" width="100%" cellspacing="4">
  -                <tr><td colspan="2">
  -                    <hr noshade="" size="1"/>
  -                </td></tr>
  -                
  -                <tr>
  -                    <!-- LEFT SIDE NAVIGATION -->
  -                    <td width="20%" valign="top" nowrap="true">
  -                                <p><strong>Essentials</strong></p>
  -        <ul>
  -                    <li>    <a href="./index.html">Overview</a>
  -</li>
  -                    <li>    <a href="./features.html">Features</a>
  -</li>
  -                    <li>    <a href="./license.html">License</a>
  -</li>
  -                    <li>    <a href="./install.html">Installation</a>
  -</li>
  -                    <li>    <a href="./faq.html">FAQ</a>
  -</li>
  -                    <li>    <a href="./usejetspeed.html">Sample Sites</a>
  -</li>
  -                    <li>    <a href="./resources.html">Resources</a>
  -</li>
  -                    <li>    <a href="./todo.html">Todo</a>
  -</li>
  -                    <li>    <a href="./changes.html">Changes</a>
  -</li>
  -                </ul>
  -            <p><strong>Download</strong></p>
  -        <ul>
  -                    <li>    <a href="http://jakarta.apache.org/site/binindex.html">Binaries</a>
  -</li>
  -                    <li>    <a href="http://jakarta.apache.org/site/sourceindex.html">Source
Code</a>
  -</li>
  -                    <li>    <a href="./supporting-projects.html">Supporting
Projects</a>
  -</li>
  -                </ul>
  -            <p><strong>Documentation</strong></p>
  -        <ul>
  -                    <li>    <a href="./config_guide.html">Configuration Guide</a>
  -</li>
  -                    <li>    <a href="http://jakarta.apache.org/jetspeed/api/index.html">Javadocs</a>
  -</li>
  -                    <li>    <a href="./application-development.html">Development</a>
  -</li>
  -                    <li>    <a href="http://www.bluesunrise.com/jetspeed-docs/JetspeedTutorial.htm">Jetspeed
Tutorial</a>
  -</li>
  -                    <li>    <a href="./catalog.html">Portlet Catalog</a>
  -</li>
  -                </ul>
  -            <p><strong>Components</strong></p>
  -        <ul>
  -                    <li>    <a href="./registry.html">Registry</a>
  -</li>
  -                    <li>    <a href="./security.html">Security</a>
  -</li>
  -                    <li>    <a href="./content-syndication.html">Syndication</a>
  -</li>
  -                    <li>    <a href="./wap.html">WAP</a>
  -</li>
  -                    <li>    <a href="./customizer.html">Customization</a>
  -</li>
  -                    <li>    <a href="./diskcache.html">Cache</a>
  -</li>
  -                    <li>    <a href="./psml.html">PSML</a>
  -</li>
  -                </ul>
  -            <p><strong>Get Involved</strong></p>
  -        <ul>
  -                    <li>    <a href="./contributors.html">Contributors</a>
  -</li>
  -                    <li>    <a href="http://jakarta.apache.org/site/cvsindex.html">CVS
Repository</a>
  -</li>
  -                    <li>    <a href="http://cvs.apache.org/viewcvs/jakarta-jetspeed/">View
CVS</a>
  -</li>
  -                    <li>    <a href="./branches.html">CVS Branches</a>
  -</li>
  -                    <li>    <a href="./code-standards.html">Coding Spec</a>
  -</li>
  -                    <li>    <a href="http://issues.apache.org/bugzilla/buglist.cgi?product=jetspeed">Bug
Database</a>
  -</li>
  -                </ul>
  -                        </td>
  -                    <td width="80%" align="left" valign="top">
  -                                                                    <table border="0"
cellspacing="0" cellpadding="2" width="100%">
  -      <tr><td bgcolor="#525D76">
  -        <font color="#ffffff" face="arial,helvetica,sanserif">
  -          <a name="Changes since version 1.4b3"><strong>Changes since version
1.4b3</strong></a>
  -        </font>
  -      </td></tr>
  -      <tr><td>
  -        <blockquote>
  +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
  +
  +<!-- Content Stylesheet for Site -->
  +
  +        
  +<!-- start the processing -->
  +    <!-- ====================================================================== -->
  +    <!-- Main Page Section -->
  +    <!-- ====================================================================== -->
  +    <html>
  +        <head>
  +            <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"/>
  +
  +                        
  +           
  +                                    
  +            <title>Jetspeed - Jetspeed Changes Log</title>
  +        </head>
  +
  +        <body bgcolor="#ffffff" text="#000000" link="#525D76">        
  +            <table border="0" width="100%" cellspacing="0">
  +                <!-- TOP IMAGE -->
  +                <tr>
  +                    <td align="left">
  +<a href="http://jakarta.apache.org"><img src="http://jakarta.apache.org/images/jakarta-logo.gif"
border="0"/></a>
  +</td>
  +<td align="right">
  +<a href="http://jakarta.apache.org/jetspeed/"><img src="./images/logo.gif" alt="Jetspeed"
border="0"/></a>
  +</td>
  +                </tr>
  +            </table>
  +            <table border="0" width="100%" cellspacing="4">
  +                <tr><td colspan="2">
  +                    <hr noshade="" size="1"/>
  +                </td></tr>
  +                
  +                <tr>
  +                    <!-- LEFT SIDE NAVIGATION -->
  +                    <td width="20%" valign="top" nowrap="true">
  +                                <p><strong>Essentials</strong></p>
  +        <ul>
  +                    <li>    <a href="./index.html">Overview</a>
  +</li>
  +                    <li>    <a href="./features.html">Features</a>
  +</li>
  +                    <li>    <a href="./license.html">License</a>
  +</li>
  +                    <li>    <a href="./install.html">Installation</a>
  +</li>
  +                    <li>    <a href="./faq.html">FAQ</a>
  +</li>
  +                    <li>    <a href="./usejetspeed.html">Sample Sites</a>
  +</li>
  +                    <li>    <a href="./resources.html">Resources</a>
  +</li>
  +                    <li>    <a href="./todo.html">Todo</a>
  +</li>
  +                    <li>    <a href="./changes.html">Changes</a>
  +</li>
  +                </ul>
  +            <p><strong>Download</strong></p>
  +        <ul>
  +                    <li>    <a href="http://jakarta.apache.org/site/binindex.html">Binaries</a>
  +</li>
  +                    <li>    <a href="http://jakarta.apache.org/site/sourceindex.html">Source
Code</a>
  +</li>
  +                    <li>    <a href="./supporting-projects.html">Supporting
Projects</a>
  +</li>
  +                </ul>
  +            <p><strong>Documentation</strong></p>
  +        <ul>
  +                    <li>    <a href="./config_guide.html">Configuration Guide</a>
  +</li>
  +                    <li>    <a href="http://jakarta.apache.org/jetspeed/api/index.html">Javadocs</a>
  +</li>
  +                    <li>    <a href="./application-development.html">Development</a>
  +</li>
  +                    <li>    <a href="http://www.bluesunrise.com/jetspeed-docs/JetspeedTutorial.htm">Jetspeed
Tutorial</a>
  +</li>
  +                    <li>    <a href="./catalog.html">Portlet Catalog</a>
  +</li>
  +                </ul>
  +            <p><strong>Components</strong></p>
  +        <ul>
  +                    <li>    <a href="./registry.html">Registry</a>
  +</li>
  +                    <li>    <a href="./security.html">Security</a>
  +</li>
  +                    <li>    <a href="./content-syndication.html">Syndication</a>
  +</li>
  +                    <li>    <a href="./wap.html">WAP</a>
  +</li>
  +                    <li>    <a href="./customizer.html">Customization</a>
  +</li>
  +                    <li>    <a href="./diskcache.html">Cache</a>
  +</li>
  +                    <li>    <a href="./psml.html">PSML</a>
  +</li>
  +                </ul>
  +            <p><strong>Get Involved</strong></p>
  +        <ul>
  +                    <li>    <a href="./contributors.html">Contributors</a>
  +</li>
  +                    <li>    <a href="http://jakarta.apache.org/site/cvsindex.html">CVS
Repository</a>
  +</li>
  +                    <li>    <a href="http://cvs.apache.org/viewcvs/jakarta-jetspeed/">View
CVS</a>
  +</li>
  +                    <li>    <a href="./branches.html">CVS Branches</a>
  +</li>
  +                    <li>    <a href="./code-standards.html">Coding Spec</a>
  +</li>
  +                    <li>    <a href="http://issues.apache.org/bugzilla/buglist.cgi?product=jetspeed">Bug
Database</a>
  +</li>
  +                </ul>
  +                        </td>
  +                    <td width="80%" align="left" valign="top">
  +                                                                    <table border="0"
cellspacing="0" cellpadding="2" width="100%">
  +      <tr><td bgcolor="#525D76">
  +        <font color="#ffffff" face="arial,helvetica,sanserif">
  +          <a name="Changes since version 1.4b3"><strong>Changes since version
1.4b3</strong></a>
  +        </font>
  +      </td></tr>
  +      <tr><td>
  +        <blockquote>
                                       <ul>
   <!--
   ***
  @@ -135,13 +133,16 @@
   </li>
   -->
   <li>
  +  Add -   Bug # 17632 - 2003/03/12 - Added new feature to log portlet load time, contributed
by Todd Kuebler (MO)
  +</li>
  +<li>
     Fixed - Bug # 17734 - 2003/03/07 - SecurityCacheImpl overwrites cached permissions (DST)
   </li>
   <li>
     Add -   Bug # 17289 - 2003/03/05 - Assigning new role will merge the role's psml (MO)
   </li>
   <li>
  -  Add -                 2003/03/04 - New Portlet Customizer with Add and Edit Portlet features
contributed by Jeremy Ford (DST)
  +  Add -   Bug # 11738 - 2003/03/04 - New Portlet Customizer with Add and Edit Portlet features
contributed by Jeremy Ford (DST)
   </li>
   <li>
     Add -                 2003/02/26 - ChangeLanguagePortlet, contributed by Dessė Massimiliano
(DST)
  @@ -249,20 +250,20 @@
   <li>
     Fixed - Bug # 15448 - 2002/12/17 - Fixed rotation logger settings  (MO)
   </li>
  -</ul>
  -                            </blockquote>
  -        </p>
  -      </td></tr>
  -      <tr><td><br/></td></tr>
  -    </table>
  -                                                <table border="0" cellspacing="0" cellpadding="2"
width="100%">
  -      <tr><td bgcolor="#525D76">
  -        <font color="#ffffff" face="arial,helvetica,sanserif">
  -          <a name="Changes since version 1.4b2"><strong>Changes since version
1.4b2</strong></a>
  -        </font>
  -      </td></tr>
  -      <tr><td>
  -        <blockquote>
  +</ul>
  +                            </blockquote>
  +        </p>
  +      </td></tr>
  +      <tr><td><br/></td></tr>
  +    </table>
  +                                                <table border="0" cellspacing="0" cellpadding="2"
width="100%">
  +      <tr><td bgcolor="#525D76">
  +        <font color="#ffffff" face="arial,helvetica,sanserif">
  +          <a name="Changes since version 1.4b2"><strong>Changes since version
1.4b2</strong></a>
  +        </font>
  +      </td></tr>
  +      <tr><td>
  +        <blockquote>
                                       <ul>
   <!--
   ***
  @@ -283,20 +284,20 @@
   <li>
     Fixed - 2002/12/11 - LDAP Properties were incorrect (DST)
   </li>
  -</ul>
  -                            </blockquote>
  -        </p>
  -      </td></tr>
  -      <tr><td><br/></td></tr>
  -    </table>
  -                                                <table border="0" cellspacing="0" cellpadding="2"
width="100%">
  -      <tr><td bgcolor="#525D76">
  -        <font color="#ffffff" face="arial,helvetica,sanserif">
  -          <a name="Changes since version 1.4b1"><strong>Changes since version
1.4b1</strong></a>
  -        </font>
  -      </td></tr>
  -      <tr><td>
  -        <blockquote>
  +</ul>
  +                            </blockquote>
  +        </p>
  +      </td></tr>
  +      <tr><td><br/></td></tr>
  +    </table>
  +                                                <table border="0" cellspacing="0" cellpadding="2"
width="100%">
  +      <tr><td bgcolor="#525D76">
  +        <font color="#ffffff" face="arial,helvetica,sanserif">
  +          <a name="Changes since version 1.4b1"><strong>Changes since version
1.4b1</strong></a>
  +        </font>
  +      </td></tr>
  +      <tr><td>
  +        <blockquote>
                                       <ul>
   <li>
     Add - 2002/12/09 - LDAP Security Service, Initial Implementation (Sami, Ender,David)
  @@ -524,20 +525,20 @@
   <li>
     Add - 2002/07/19 - Allow for portlets to be selection one or more times on Customizer
from Scott Weaver (DST)
   </li>
  -      </ul>
  -                            </blockquote>
  -        </p>
  -      </td></tr>
  -      <tr><td><br/></td></tr>
  -    </table>
  -                                                <table border="0" cellspacing="0" cellpadding="2"
width="100%">
  -      <tr><td bgcolor="#525D76">
  -        <font color="#ffffff" face="arial,helvetica,sanserif">
  -          <a name="Changes since version 1.3a2"><strong>Changes since version
1.3a2</strong></a>
  -        </font>
  -      </td></tr>
  -      <tr><td>
  -        <blockquote>
  +      </ul>
  +                            </blockquote>
  +        </p>
  +      </td></tr>
  +      <tr><td><br/></td></tr>
  +    </table>
  +                                                <table border="0" cellspacing="0" cellpadding="2"
width="100%">
  +      <tr><td bgcolor="#525D76">
  +        <font color="#ffffff" face="arial,helvetica,sanserif">
  +          <a name="Changes since version 1.3a2"><strong>Changes since version
1.3a2</strong></a>
  +        </font>
  +      </td></tr>
  +      <tr><td>
  +        <blockquote>
                                       <ul>
   <li>
     Add - Added Change Log (PS)
  @@ -799,45 +800,45 @@
   <li>
     Add - 2002/07/16 - Jetspeed 1.4b1 Release (DST)
   </li>
  -</ul>
  -                            </blockquote>
  -        </p>
  -      </td></tr>
  -      <tr><td><br/></td></tr>
  -    </table>
  -                                        </td>
  -                </tr>
  -
  -                <!-- FOOTER -->
  -                <tr><td colspan="2">
  -                    <hr noshade="" size="1"/>
  -                </td></tr>
  -                <tr><td colspan="2">
  -                    <div align="center"><font color="#525D76" size="-1"><em>
  -                    Copyright &#169; 1999-2002, Apache Software Foundation
  -                    </em></font></div>
  -                </td></tr>
  -            </table>
  -        </body>
  -    </html>
  -<!-- end the processing -->
  -
  -
  -
  -
  -
  -
  -
  -
  -
  -
  -
  -
  -
  -
  -
  -
  -
  -
  -
  -
  +</ul>
  +                            </blockquote>
  +        </p>
  +      </td></tr>
  +      <tr><td><br/></td></tr>
  +    </table>
  +                                        </td>
  +                </tr>
  +
  +                <!-- FOOTER -->
  +                <tr><td colspan="2">
  +                    <hr noshade="" size="1"/>
  +                </td></tr>
  +                <tr><td colspan="2">
  +                    <div align="center"><font color="#525D76" size="-1"><em>
  +                    Copyright &#169; 1999-2002, Apache Software Foundation
  +                    </em></font></div>
  +                </td></tr>
  +            </table>
  +        </body>
  +    </html>
  +<!-- end the processing -->
  +
  +
  +
  +
  +
  +
  +
  +
  +
  +
  +
  +
  +
  +
  +
  +
  +
  +
  +
  +
  
  
  
  1.20      +11 -4     jakarta-jetspeed/src/java/org/apache/jetspeed/portal/security/portlets/PortletWrapper.java
  
  Index: PortletWrapper.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/portal/security/portlets/PortletWrapper.java,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -r1.19 -r1.20
  --- PortletWrapper.java	21 Jan 2003 21:33:57 -0000	1.19
  +++ PortletWrapper.java	13 Mar 2003 01:08:11 -0000	1.20
  @@ -96,6 +96,7 @@
        */
       private Portlet wrappedPortlet = null;
       private PortalResource portalResource = null;
  +    private ConcreteElement content = null;
   
       public PortletWrapper(Portlet inner)
       {
  @@ -138,14 +139,20 @@
       */
       public ConcreteElement getContent(RunData rundata)
       {
  -
  + 
           if (checkPermission(rundata, JetspeedSecurity.PERMISSION_VIEW))
           {
               if (PortletStats.isEnabled())
               {
  -                PortletStats.logAccess(rundata, this, PortletStats.ACCESS_OK);
  +            	long start = System.currentTimeMillis();
  +            	content = wrappedPortlet.getContent(rundata);
  +            	long time = System.currentTimeMillis() - start; // time it took to get the
content for this portlet
  +                PortletStats.logAccess(rundata, this, PortletStats.ACCESS_OK, time);
  +            } else {
  +            	content = wrappedPortlet.getContent(rundata);
               }
  -            return wrappedPortlet.getContent(rundata);
  +            
  +            return content;
           }
           else 
           {
  
  
  
  1.3       +10 -3     jakarta-jetspeed/src/java/org/apache/jetspeed/services/PortletStats.java
  
  Index: PortletStats.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/services/PortletStats.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- PortletStats.java	3 Sep 2002 15:01:40 -0000	1.2
  +++ PortletStats.java	13 Mar 2003 01:08:11 -0000	1.3
  @@ -111,11 +111,18 @@
       }
   
       /**
  -     * @see org.apahce.jetspeed.services.portletstats.PortletStatsService#logAccess
  +     * @see org.apache.jetspeed.services.portletstats.PortletStatsService#logAccess
        */
       public static void logAccess(RunData data, Portlet portlet, String statusCode) 
       {
           getService().logAccess(data, portlet, statusCode);
       }
  -            
  +    
  +    /**
  +     * @see org.apache.jetspeed.services.portletstats.PortletStatsService#logAccess
  +     */
  +    public static void logAccess(RunData data, Portlet portlet, String statusCode, long
time) 
  +    {
  +        getService().logAccess(data, portlet, statusCode, time);
  +    }
   }
  
  
  
  1.2       +28 -9     jakarta-jetspeed/src/java/org/apache/jetspeed/services/portletstats/JetspeedPortletStatsService.java
  
  Index: JetspeedPortletStatsService.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/services/portletstats/JetspeedPortletStatsService.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- JetspeedPortletStatsService.java	27 Aug 2002 19:09:58 -0000	1.1
  +++ JetspeedPortletStatsService.java	13 Mar 2003 01:08:11 -0000	1.2
  @@ -87,7 +87,7 @@
    * <LI><B>%t</B> - time in common log time format</LI>
    * <LI><B>%r</B> - first line of request</LI>
    * <LI><B>%s</B> - status (either 200 or 401)</LI>
  - * <LI><B>%b</B> - bytes sent (always "-" for no bytes sent)</LI>
  + * <LI><B>%b</B> - bytes sent (always "-" for no bytes sent). Optionally,
portlet load time may be logged (see logLoadTime property)</LI>
    * </UL>
    * <P>
    * Here's an example log entry:
  @@ -97,8 +97,8 @@
    * TODO:
    * <UL>
    * <LI>Statistics cache (by portlet and by user)</LI>
  - * <LI>Portlet exclusion</LI> 
  - * <LI>Configurable format pattern</LI>  
  + * <LI>Portlet exclusion</LI>
  + * <LI>Configurable format pattern</LI>
    * </UL>
    * 
    * @author <a href="mailto:morciuch@apache.org">Mark Orciuch</a>
  @@ -126,7 +126,7 @@
        * <LI>portlet name</LI>
        * <LI>request protocol</LI>
        * <LI>status code</LI>
  -     * <LI>always "-"</LI>
  +     * <LI>always "-" unless logLoadTime is true</LI>
        * </OL>
        */
       private static final String defaultLogFormat = "{0} {1} {2} [{3}] \"{4} {5}/{6} {7}\"
{8} {9}";
  @@ -146,6 +146,9 @@
       /** Date formatter */
       private SimpleDateFormat formatter = null;
   
  +    /** Log portlet load time instead of bytes sent (which is always zero) */
  +    private boolean logLoadTime = false;
  +
       /**
        * This is the early initialization method called by the 
        * Turbine <code>Service</code> framework
  @@ -160,6 +163,7 @@
           this.enabled = serviceConf.getBoolean("enabled");
           this.dateFormat = serviceConf.getString("dateFormat", "dd/MM/yyyy:hh:mm:ss z");
           this.formatter = new SimpleDateFormat(this.dateFormat);
  +        this.logLoadTime = serviceConf.getBoolean("logLoadTime", false);
           
           setInit(true);
   
  @@ -187,8 +191,9 @@
       /**
        * @see org.apache.jetspeed.services.portletstats.PortletStatsService#logAccess
        */
  -    public void logAccess(RunData data, Portlet portlet, String statusCode)
  +    public void logAccess(RunData data, Portlet portlet, String statusCode, long time)
       {
  +        
           if (!this.isEnabled())
           {
               return;
  @@ -196,7 +201,7 @@
           
           try 
           {
  -            Log.info(loggerName, this.getLogMessage(data, portlet, statusCode));
  +            Log.info(loggerName, this.getLogMessage(data, portlet, statusCode, time));
           }
           catch (Exception e)
           {
  @@ -210,9 +215,11 @@
        * @param data
        * @param portlet
        * @param statusCode
  +     * @param time
        * @return Formatted message
  +     * @exception Exception
        */
  -    private String getLogMessage(RunData data, Portlet portlet, String statusCode) 
  +    private String getLogMessage(RunData data, Portlet portlet, String statusCode, long
time) 
       throws Exception
       {        
    
  @@ -227,12 +234,24 @@
               portlet.getName(),
               req.getProtocol(),
               statusCode,
  -            "-"
  +            this.logLoadTime == true ? String.valueOf(time) : "-"
           }; 
   
           return MessageFormat.format(defaultLogFormat, args).toString();
   
       }
   
  +    /**
  +     * Formats log message using default load time
  +     * 
  +     * @param data
  +     * @param portlet
  +     * @param statusCode
  +     */
  +    public void logAccess(RunData data, Portlet portlet, String statusCode) 
  +    {
  +        logAccess(data, portlet, statusCode, 0);
  +    }
  +    
   }
   
  
  
  
  1.2       +11 -2     jakarta-jetspeed/src/java/org/apache/jetspeed/services/portletstats/PortletStatsService.java
  
  Index: PortletStatsService.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/services/portletstats/PortletStatsService.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- PortletStatsService.java	27 Aug 2002 19:09:58 -0000	1.1
  +++ PortletStatsService.java	13 Mar 2003 01:08:11 -0000	1.2
  @@ -89,13 +89,22 @@
       public boolean setEnabled(boolean state);
   
       /**
  -     * Logs portlet access.
  +     * Logs portlet access using default load time.
        * 
        * @param data       Current request info object
        * @param portlet    Portlet being logged
        * @param statusCode HTTP status code. For now, either 200 (successfull) or 401 (unauthorized)
        */
       public void logAccess(RunData data, Portlet portlet, String statusCode);
  +
  +    /**
  +     * Logs portlet access.
  +     * 
  +     * @param data       Current request info object
  +     * @param portlet    Portlet being logged
  +     * @param statusCode HTTP status code. For now, either 200 (successfull) or 401 (unauthorized)
  +     */
  +    public void logAccess(RunData data, Portlet portlet, String statusCode, long time);
   
   }
   
  
  
  
  1.95      +4 -1      jakarta-jetspeed/webapp/WEB-INF/conf/JetspeedResources.properties
  
  Index: JetspeedResources.properties
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/webapp/WEB-INF/conf/JetspeedResources.properties,v
  retrieving revision 1.94
  retrieving revision 1.95
  diff -u -r1.94 -r1.95
  --- JetspeedResources.properties	19 Feb 2003 17:39:46 -0000	1.94
  +++ JetspeedResources.properties	13 Mar 2003 01:08:11 -0000	1.95
  @@ -478,6 +478,9 @@
   # Date format to use in the log entry
   services.PortletStats.dateFormat = dd/MMM/yyyy:hh:mm:ss z
   
  +# Log portlet load time in place of bytes sent
  +services.PortletStats.logLoadTime = false
  +
   ##########################################
   # Diskcache configuration                #
   ##########################################
  
  
  
  1.132     +5 -2      jakarta-jetspeed/xdocs/changes.xml
  
  Index: changes.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/xdocs/changes.xml,v
  retrieving revision 1.131
  retrieving revision 1.132
  diff -u -r1.131 -r1.132
  --- changes.xml	7 Mar 2003 16:09:55 -0000	1.131
  +++ changes.xml	13 Mar 2003 01:08:11 -0000	1.132
  @@ -23,13 +23,16 @@
   </li>
   -->
   <li>
  +  Add -   Bug # 17632 - 2003/03/12 - Added new feature to log portlet load time, contributed
by Todd Kuebler (MO)
  +</li>
  +<li>
     Fixed - Bug # 17734 - 2003/03/07 - SecurityCacheImpl overwrites cached permissions (DST)
   </li>
   <li>
     Add -   Bug # 17289 - 2003/03/05 - Assigning new role will merge the role's psml (MO)
   </li>
   <li>
  -  Add -                 2003/03/04 - New Portlet Customizer with Add and Edit Portlet features
contributed by Jeremy Ford (DST)
  +  Add -   Bug # 11738 - 2003/03/04 - New Portlet Customizer with Add and Edit Portlet features
contributed by Jeremy Ford (DST)
   </li>
   <li>
     Add -                 2003/02/26 - ChangeLanguagePortlet, contributed by Dessė Massimiliano
(DST)
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org


Mime
View raw message