portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rwat...@apache.org
Subject cvs commit: jakarta-jetspeed-2/layout-portlets/src/java/org/apache/jetspeed/portlets/layout MultiColumnPortlet.java
Date Tue, 25 Jan 2005 00:53:36 GMT
rwatler     2005/01/24 16:53:36

  Modified:    layout-portlets/src/java/org/apache/jetspeed/portlets/layout
                        MultiColumnPortlet.java
  Log:
  cleanup PageManager update SecurityException handling and logging
  
  Revision  Changes    Path
  1.8       +18 -4     jakarta-jetspeed-2/layout-portlets/src/java/org/apache/jetspeed/portlets/layout/MultiColumnPortlet.java
  
  Index: MultiColumnPortlet.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed-2/layout-portlets/src/java/org/apache/jetspeed/portlets/layout/MultiColumnPortlet.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- MultiColumnPortlet.java	4 Jan 2005 16:01:58 -0000	1.7
  +++ MultiColumnPortlet.java	25 Jan 2005 00:53:36 -0000	1.8
  @@ -83,11 +83,17 @@
               {
                   pm.updatePage(page);
               }
  +            catch (SecurityException se)
  +            {
  +                // ignore page security constraint violations, only
  +                // permitted users can edit managed pages; page
  +                // update will remain transient
  +                log.info("Unable to update page " + page.getId() + " layout due to security
permission/constraint.", se);
  +            }
               catch (Exception e)
               {
  -                throw new PortletException(e.toString(), e);
  +                log.error("Unable to update page " + page.getId() + " layout: "+e.toString(),
e);
               }
  -
           }
   
           // if (targetState != null && targetState.isMaximized())
  @@ -210,13 +216,21 @@
   
           if (unconstrainedFound)
           {
  +            Page page = getRequestContext(request).getPage();
               try
               {
  -                pm.updatePage(getRequestContext(request).getPage());
  +                pm.updatePage(page);
  +            }
  +            catch (SecurityException se)
  +            {
  +                // ignore page security constraint violations, only
  +                // permitted users can edit managed pages; page
  +                // update will remain transient
  +                log.info("Unable to update page " + page.getId() + " layout due to security
permission/constraint.");
               }
               catch (Exception e)
               {
  -                log.warn("Unable to update Page information: "+e.toString(), e);
  +                log.error("Unable to update page " + page.getId() + " layout: "+e.toString(),
e);
               }           
           }
   
  
  
  

---------------------------------------------------------------------
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