portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rwat...@apache.org
Subject svn commit: r786253 - /portals/jetspeed-2/portal/branches/JETSPEED-2.1.3-POSTRELEASE/components/page-manager/src/java/org/apache/jetspeed/page/PageImporter.java
Date Thu, 18 Jun 2009 20:38:12 GMT
Author: rwatler
Date: Thu Jun 18 20:38:12 2009
New Revision: 786253

URL: http://svn.apache.org/viewvc?rev=786253&view=rev
Log:
JS2-1034: suppress page exporter errors w/o DBPSML data

Modified:
    portals/jetspeed-2/portal/branches/JETSPEED-2.1.3-POSTRELEASE/components/page-manager/src/java/org/apache/jetspeed/page/PageImporter.java

Modified: portals/jetspeed-2/portal/branches/JETSPEED-2.1.3-POSTRELEASE/components/page-manager/src/java/org/apache/jetspeed/page/PageImporter.java
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/branches/JETSPEED-2.1.3-POSTRELEASE/components/page-manager/src/java/org/apache/jetspeed/page/PageImporter.java?rev=786253&r1=786252&r2=786253&view=diff
==============================================================================
--- portals/jetspeed-2/portal/branches/JETSPEED-2.1.3-POSTRELEASE/components/page-manager/src/java/org/apache/jetspeed/page/PageImporter.java
(original)
+++ portals/jetspeed-2/portal/branches/JETSPEED-2.1.3-POSTRELEASE/components/page-manager/src/java/org/apache/jetspeed/page/PageImporter.java
Thu Jun 18 20:38:12 2009
@@ -21,6 +21,7 @@
 import org.apache.commons.configuration.PropertiesConfiguration;
 import org.apache.jetspeed.exception.JetspeedException;
 import org.apache.jetspeed.om.folder.Folder;
+import org.apache.jetspeed.om.folder.FolderNotFoundException;
 import org.apache.jetspeed.om.page.Link;
 import org.apache.jetspeed.om.page.Page;
 import org.apache.jetspeed.om.page.PageSecurity;
@@ -118,26 +119,37 @@
     public void fullImport()
     throws JetspeedException
     {
-        Folder fsRoot = sourceManager.getFolder(rootFolder);                
-        importFolder(fsRoot);
-        
-        
-        // create the root page security
-        PageSecurity sourcePageSecurity = null;
-        try
-        {
-            sourcePageSecurity = sourceManager.getPageSecurity();
-        }
-        catch (DocumentNotFoundException e)
-        {
-            // skip over it, not found
-        }
-        
-        if (sourcePageSecurity != null)
-        {
-            PageSecurity rootSecurity = destManager.copyPageSecurity(sourcePageSecurity);
       
-            destManager.updatePageSecurity(rootSecurity);
-        }
+        // get root folder
+        Folder fsRoot = null;
+        try
+        {
+            fsRoot = sourceManager.getFolder(rootFolder);
+        }
+        catch (FolderNotFoundException fnfe)
+        {
+        }
+        if (fsRoot != null)
+        {
+            // import root folder
+            importFolder(fsRoot);
+
+            // create the root page security
+            PageSecurity sourcePageSecurity = null;
+            try
+            {
+                sourcePageSecurity = sourceManager.getPageSecurity();
+            }
+            catch (DocumentNotFoundException e)
+            {
+                // skip over it, not found
+            }
+
+            if (sourcePageSecurity != null)
+            {
+                PageSecurity rootSecurity = destManager.copyPageSecurity(sourcePageSecurity);
+                destManager.updatePageSecurity(rootSecurity);
+            }
+        }
     }
 
     public void folderTreeImport()



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


Mime
View raw message