portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tay...@apache.org
Subject svn commit: r673860 - in /portals/jetspeed-2/portal/trunk: ./ applications/jetspeed/src/main/webapp/WEB-INF/ components/jetspeed-db-tools/src/main/java/org/apache/jetspeed/tools/db/serializer/ components/jetspeed-page-manager/src/main/java/org/apache/j...
Date Thu, 03 Jul 2008 23:01:22 GMT
Author: taylor
Date: Thu Jul  3 16:01:21 2008
New Revision: 673860

URL: http://svn.apache.org/viewvc?rev=673860&view=rev
Log:
https://issues.apache.org/jira/browse/JS2-818
This feature is written and tested. However I could not get it to run in the jetspeed-deploy:deploy goal because of an assumption I made in mistake
The serializer writes its pages out to the target/ directory during the build. The jetspeed-deploy plugin does not look there for pages, but instead looks in a resource in the repo
In order for this feature to work, it would need to repackage the page files first. It would be better if pages are moved out of the WEB-INF/pages directory, and instead put in another
directory on the file system. See: https://issues.apache.org/jira/browse/JS2-891

Added:
    portals/jetspeed-2/portal/trunk/applications/jetspeed/src/main/webapp/WEB-INF/web-2.4.xml
    portals/jetspeed-2/portal/trunk/components/jetspeed-page-manager/src/main/java/org/apache/jetspeed/serializer/
    portals/jetspeed-2/portal/trunk/components/jetspeed-page-manager/src/main/java/org/apache/jetspeed/serializer/JetspeedUserTemplateSerializer.java
    portals/jetspeed-2/portal/trunk/quickStart.sh   (with props)
Modified:
    portals/jetspeed-2/portal/trunk/components/jetspeed-db-tools/src/main/java/org/apache/jetspeed/tools/db/serializer/JetspeedSerializerApplicationImpl.java
    portals/jetspeed-2/portal/trunk/components/jetspeed-page-manager/src/main/java/org/apache/jetspeed/page/AbstractPageManager.java
    portals/jetspeed-2/portal/trunk/components/jetspeed-page-manager/src/main/java/org/apache/jetspeed/page/PageManagerUtils.java
    portals/jetspeed-2/portal/trunk/components/jetspeed-page-manager/src/main/java/org/apache/jetspeed/page/impl/DatabasePageManager.java
    portals/jetspeed-2/portal/trunk/components/jetspeed-serializer/src/main/java/org/apache/jetspeed/serializer/objects/JSUser.java
    portals/jetspeed-2/portal/trunk/components/jetspeed-serializer/src/main/java/org/apache/jetspeed/serializer/objects/JSUsers.java
    portals/jetspeed-2/portal/trunk/etc/xsd/j2-seed.xsd
    portals/jetspeed-2/portal/trunk/jetspeed-api/src/main/java/org/apache/jetspeed/om/folder/Folder.java
    portals/jetspeed-2/portal/trunk/jetspeed-api/src/main/java/org/apache/jetspeed/page/PageManager.java
    portals/jetspeed-2/portal/trunk/jetspeed-api/src/main/java/org/apache/jetspeed/serializer/JetspeedSerializer.java
    portals/jetspeed-2/portal/trunk/jetspeed-portal-resources/src/main/resources/assembly/jetspeed-properties.xml
    portals/jetspeed-2/portal/trunk/jetspeed-portal-resources/src/main/resources/assembly/serializer.xml
    portals/jetspeed-2/portal/trunk/jetspeed-portal-resources/src/main/resources/conf/jetspeed/jetspeed.properties
    portals/jetspeed-2/portal/trunk/jetspeed-portal-resources/src/main/resources/seed/j2-seed.xml

Added: portals/jetspeed-2/portal/trunk/applications/jetspeed/src/main/webapp/WEB-INF/web-2.4.xml
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/applications/jetspeed/src/main/webapp/WEB-INF/web-2.4.xml?rev=673860&view=auto
==============================================================================
--- portals/jetspeed-2/portal/trunk/applications/jetspeed/src/main/webapp/WEB-INF/web-2.4.xml (added)
+++ portals/jetspeed-2/portal/trunk/applications/jetspeed/src/main/webapp/WEB-INF/web-2.4.xml Thu Jul  3 16:01:21 2008
@@ -0,0 +1,323 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<!--
+Licensed to the Apache Software Foundation (ASF) under one or more
+contributor license agreements.  See the NOTICE file distributed with
+this work for additional information regarding copyright ownership.
+The ASF licenses this file to You 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.
+-->
+<web-app xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="2.4"
+	xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee   http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
+  <display-name>Jetspeed-2 Enterprise Portal</display-name>	
+  
+  <!-- Log4JConfigurator context-listener parameters -->    
+  <context-param>
+    <param-name>log4j.config.file</param-name>
+    <param-value>/WEB-INF/conf/Log4j.properties</param-value>
+  </context-param>
+  <context-param>
+    <param-name>log4j.config.webApplicationRoot.key</param-name>
+    <param-value>applicationRoot</param-value>
+  </context-param>
+      
+  <filter>
+    <filter-name>XXSUrlAttackFilter</filter-name>
+    <filter-class>org.apache.jetspeed.engine.servlet.XXSUrlAttackFilter</filter-class>
+  </filter>
+  
+  <filter>
+      <filter-name>staticResourceCachingFilter</filter-name>
+      <filter-class>org.apache.jetspeed.engine.servlet.StaticResourceCachingFilter</filter-class>
+      <init-param>
+          <param-name>ExpireHours</param-name>
+          <param-value>48</param-value>
+      </init-param>
+  </filter>
+  
+  <!--
+  <filter>
+    <filter-name>PortalFilter</filter-name>
+    <filter-class>org.apache.jetspeed.login.filter.PortalFilter</filter-class>   
+  </filter>
+  -->
+
+  <filter-mapping>
+    <filter-name>XXSUrlAttackFilter</filter-name>
+    <url-pattern>/*</url-pattern>
+  </filter-mapping>    
+  
+  <filter-mapping>
+      <filter-name>staticResourceCachingFilter</filter-name>
+      <servlet-name>default</servlet-name>
+  </filter-mapping>
+  
+<!--      
+  <filter-mapping>
+    <filter-name>PortalFilter</filter-name>
+    <url-pattern>/*</url-pattern>    
+  </filter-mapping>  
+-->    
+  
+  <listener>
+    <listener-class>org.apache.jetspeed.webapp.logging.Log4JConfigurator</listener-class>
+  </listener>
+  
+  <listener>
+    <listener-class>org.apache.jetspeed.engine.JetspeedServlet</listener-class>
+  </listener>
+
+  <servlet>
+    <servlet-name>jetspeed</servlet-name>
+    <servlet-class>org.apache.jetspeed.engine.JetspeedServlet</servlet-class>
+    <init-param>
+      <param-name>properties</param-name>
+      <param-value>/WEB-INF/conf/jetspeed.properties</param-value>
+    </init-param>
+    <init-param>
+      <param-name>applicationRoot</param-name>
+      <param-value>webContext</param-value>
+    </init-param>
+    <load-on-startup>1</load-on-startup>
+  </servlet>
+
+  	<!-- Define Velocity template compiler -->
+	<servlet>
+		<servlet-name>velocity</servlet-name>
+		<servlet-class>org.apache.jetspeed.velocity.JetspeedVelocityViewServlet</servlet-class>
+		<init-param>
+			<param-name>org.apache.velocity.toolbox</param-name>
+			<param-value>/WEB-INF/toolbox.xml</param-value>
+		</init-param>
+		<init-param>
+			<param-name>org.apache.velocity.properties</param-name>
+			<param-value>/WEB-INF/velocity.properties</param-value>
+		</init-param>
+		<init-param>
+			<param-name>org.apache.jetspeed.cache.size</param-name>
+			<param-value>50</param-value>
+		</init-param>
+		<init-param>
+			<param-name>org.apache.jetspeed.cache.validation.interval</param-name>
+			<param-value>-1</param-value>
+		</init-param>
+		<load-on-startup>10</load-on-startup>
+	</servlet>
+    
+  <servlet>
+    <servlet-name>LoginProxyServlet</servlet-name>
+    <servlet-class>org.apache.jetspeed.login.LoginProxyServlet</servlet-class>
+	<init-param>
+		<param-name>credentialsFromRequest</param-name>
+		<param-value>true</param-value>
+	</init-param>        
+  </servlet>
+
+  <servlet>
+    <servlet-name>LoginServlet</servlet-name>
+    <servlet-class>org.apache.jetspeed.login.LoginServlet</servlet-class>
+  </servlet>
+    
+  <servlet>
+    <servlet-name>LoginErrorServlet</servlet-name>
+    <servlet-class>org.apache.jetspeed.login.LoginErrorServlet</servlet-class>
+  </servlet>
+
+  <servlet>
+    <servlet-name>LoginRedirectorServlet</servlet-name>
+    <servlet-class>org.apache.jetspeed.login.LoginRedirectorServlet</servlet-class>
+  </servlet>
+
+  <servlet>
+    <servlet-name>LogoutServlet</servlet-name>
+    <servlet-class>org.apache.jetspeed.login.LogoutServlet</servlet-class>
+  </servlet>
+
+  <servlet>
+    <servlet-name>ManagerServlet</servlet-name>
+    <servlet-class>org.apache.jetspeed.manager.ManagerServlet</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+       <servlet-name>
+          jetspeed
+       </servlet-name>
+       <url-pattern>/portal/*</url-pattern>
+    </servlet-mapping>
+    <servlet-mapping>
+       <servlet-name>
+          jetspeed
+       </servlet-name>
+       <url-pattern>/portlet/*</url-pattern>
+    </servlet-mapping>            
+    <servlet-mapping>
+       <servlet-name>
+          jetspeed
+       </servlet-name>
+       <url-pattern>/jetspeed/*</url-pattern>
+    </servlet-mapping>
+    <servlet-mapping>
+       <servlet-name>
+          jetspeed
+       </servlet-name>
+       <url-pattern>/fileserver/*</url-pattern>
+    </servlet-mapping>            
+    <servlet-mapping>
+       <servlet-name>
+          jetspeed
+       </servlet-name>
+       <url-pattern>/ajaxapi/*</url-pattern>
+    </servlet-mapping>            
+    <servlet-mapping>
+       <servlet-name>
+          jetspeed
+       </servlet-name>
+       <url-pattern>/ajax/*</url-pattern>
+    </servlet-mapping>            
+    <servlet-mapping>
+       <servlet-name>
+          jetspeed
+       </servlet-name>
+       <url-pattern>/desktop/*</url-pattern>
+    </servlet-mapping>            
+    <servlet-mapping>
+       <servlet-name>
+          jetspeed
+       </servlet-name>
+       <url-pattern>/action/*</url-pattern>
+    </servlet-mapping>            
+    <servlet-mapping>
+       <servlet-name>
+          jetspeed
+       </servlet-name>
+       <url-pattern>/render/*</url-pattern>
+    </servlet-mapping>
+    <servlet-mapping>
+       <servlet-name>
+          jetspeed
+       </servlet-name>
+       <url-pattern>/configure/*</url-pattern>
+    </servlet-mapping>
+    <servlet-mapping>
+       <servlet-name>
+          jetspeed
+       </servlet-name>
+       <url-pattern>/dtconfigure/*</url-pattern>
+    </servlet-mapping>
+    
+    <!-- Map *.vm files to Velocity  -->
+	<servlet-mapping>
+		<servlet-name>velocity</servlet-name>
+		<url-pattern>*.vm</url-pattern>
+	</servlet-mapping>	
+    
+    <servlet-mapping>
+        <servlet-name>LoginProxyServlet</servlet-name>
+        <url-pattern>/login/proxy</url-pattern>
+    </servlet-mapping>
+
+    <servlet-mapping>
+        <servlet-name>LoginServlet</servlet-name>
+        <url-pattern>/login/login</url-pattern>
+    </servlet-mapping>
+    
+    <servlet-mapping>
+        <servlet-name>LoginErrorServlet</servlet-name>
+        <url-pattern>/login/error</url-pattern>
+    </servlet-mapping>
+    
+    <servlet-mapping>
+        <servlet-name>LoginRedirectorServlet</servlet-name>
+        <url-pattern>/login/redirector</url-pattern>
+    </servlet-mapping>
+
+    <servlet-mapping>
+        <servlet-name>LogoutServlet</servlet-name>
+        <url-pattern>/login/logout</url-pattern>
+    </servlet-mapping>
+
+    <servlet-mapping>
+        <servlet-name>ManagerServlet</servlet-name>
+        <url-pattern>/manager/*</url-pattern>
+    </servlet-mapping>
+
+  <!-- The Usual Welcome File List -->
+  <welcome-file-list>
+    <welcome-file>index.jsp</welcome-file>
+  </welcome-file-list>
+  
+  <!-- JNDI Db resource -->
+   <resource-ref>
+      <description>DB Connection</description>
+      <res-ref-name>jdbc/jetspeed</res-ref-name>
+      <res-type>javax.sql.DataSource</res-type>
+      <res-auth>Container</res-auth>
+  </resource-ref>
+  
+  <!-- JNDI CommonJ WorkManager resource -->
+  <!--
+  If you want to use Commonj Work Manager provided by the container in parallel rendering, uncomment the following.
+  -->
+  <!--
+  <resource-ref>
+    <description>WorkManager</description>
+    <res-ref-name>wm/jetspeed</res-ref-name>
+    <res-type>commonj.work.WorkManager</res-type>
+    <res-auth>Container</res-auth>
+    <res-sharing-scope>Shareable</res-sharing-scope>
+  </resource-ref>
+  -->
+
+  <!-- Protect LogInRedirectory.jsp.  This will require a login when called -->
+  <security-constraint>
+    <web-resource-collection>
+      <web-resource-name>Login</web-resource-name>
+      <url-pattern>/login/redirector</url-pattern>
+    </web-resource-collection>
+    <auth-constraint>
+      <!-- the required portal user role name defined in: -->
+      <!-- /WEB-INF/assembly/security-atn.xml             -->
+      <role-name>portal-user</role-name>
+    </auth-constraint>
+  </security-constraint>
+
+  <!--  securing the ManagerServlet -->
+  <security-constraint>
+    <web-resource-collection>
+      <web-resource-name>Manager</web-resource-name>
+      <url-pattern>/manager/*</url-pattern>
+    </web-resource-collection>
+    <auth-constraint>
+      <role-name>admin</role-name>
+    </auth-constraint>
+  </security-constraint>
+
+  <!-- Login configuration uses form-based authentication -->
+  <login-config>
+    <auth-method>FORM</auth-method>
+    <realm-name>Jetspeed</realm-name>
+    <form-login-config>
+      <form-login-page>/login/login</form-login-page>
+      <form-error-page>/login/error</form-error-page>
+    </form-login-config>
+  </login-config>
+
+  <security-role>
+    <description>Portal Administrator</description>
+    <role-name>admin</role-name>
+  </security-role>
+
+  <security-role>
+    <description>Portal User</description>
+    <role-name>portal-user</role-name>
+  </security-role>
+
+</web-app>

Modified: portals/jetspeed-2/portal/trunk/components/jetspeed-db-tools/src/main/java/org/apache/jetspeed/tools/db/serializer/JetspeedSerializerApplicationImpl.java
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/components/jetspeed-db-tools/src/main/java/org/apache/jetspeed/tools/db/serializer/JetspeedSerializerApplicationImpl.java?rev=673860&r1=673859&r2=673860&view=diff
==============================================================================
--- portals/jetspeed-2/portal/trunk/components/jetspeed-db-tools/src/main/java/org/apache/jetspeed/tools/db/serializer/JetspeedSerializerApplicationImpl.java (original)
+++ portals/jetspeed-2/portal/trunk/components/jetspeed-db-tools/src/main/java/org/apache/jetspeed/tools/db/serializer/JetspeedSerializerApplicationImpl.java Thu Jul  3 16:01:21 2008
@@ -191,6 +191,7 @@
         }
         catch (Exception e)
         {
+            e.printStackTrace();
             logger.error(e);
             if (e instanceof SerializerException)
             {

Modified: portals/jetspeed-2/portal/trunk/components/jetspeed-page-manager/src/main/java/org/apache/jetspeed/page/AbstractPageManager.java
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/components/jetspeed-page-manager/src/main/java/org/apache/jetspeed/page/AbstractPageManager.java?rev=673860&r1=673859&r2=673860&view=diff
==============================================================================
--- portals/jetspeed-2/portal/trunk/components/jetspeed-page-manager/src/main/java/org/apache/jetspeed/page/AbstractPageManager.java (original)
+++ portals/jetspeed-2/portal/trunk/components/jetspeed-page-manager/src/main/java/org/apache/jetspeed/page/AbstractPageManager.java Thu Jul  3 16:01:21 2008
@@ -1208,7 +1208,19 @@
     {
         PageManagerUtils.deepCopyFolder(this, srcFolder, destinationPath, owner);
     }
-            
+
+    /**
+     * Deep merge a folder
+     *  
+     * @param source source folder
+     * @param dest destination folder
+     */
+    public void deepMergeFolder(Folder srcFolder, String destinationPath, String owner)
+    throws NodeException
+    {
+        PageManagerUtils.deepMergeFolder(this, srcFolder, destinationPath, owner);
+    }
+    
     public Page getUserPage(String userName, String pageName)
     throws PageNotFoundException, NodeException
     {

Modified: portals/jetspeed-2/portal/trunk/components/jetspeed-page-manager/src/main/java/org/apache/jetspeed/page/PageManagerUtils.java
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/components/jetspeed-page-manager/src/main/java/org/apache/jetspeed/page/PageManagerUtils.java?rev=673860&r1=673859&r2=673860&view=diff
==============================================================================
--- portals/jetspeed-2/portal/trunk/components/jetspeed-page-manager/src/main/java/org/apache/jetspeed/page/PageManagerUtils.java (original)
+++ portals/jetspeed-2/portal/trunk/components/jetspeed-page-manager/src/main/java/org/apache/jetspeed/page/PageManagerUtils.java Thu Jul  3 16:01:21 2008
@@ -272,5 +272,72 @@
             deepCopyFolder(pageManager, folder, newPath, null);
         }        
     }
+
+    /**
+     * Deep merge a folder
+     *  
+     * @param source source folder
+     * @param dest destination folder
+     */
+    public static void deepMergeFolder(PageManager pageManager, Folder srcFolder, String destinationPath, String owner)
+    throws NodeException
+    {
+        boolean found = true;
+        Folder dstFolder = null;
+        try
+        {
+            dstFolder = pageManager.getFolder(destinationPath);
+        }
+        catch (FolderNotFoundException e)
+        {
+            found = false;
+        }
+        if (!found)
+        {
+            dstFolder = pageManager.copyFolder(srcFolder, destinationPath);
+            if (owner != null)
+            {
+                SecurityConstraints constraints = dstFolder.getSecurityConstraints();
+                if (constraints == null)
+                {
+                    constraints = pageManager.newSecurityConstraints();
+                    dstFolder.setSecurityConstraints(constraints);
+                }
+                dstFolder.getSecurityConstraints().setOwner(owner);
+            }
+            pageManager.updateFolder(dstFolder);
+        }
+        Iterator pages = srcFolder.getPages().iterator();
+        while (pages.hasNext())
+        {
+            Page srcPage = (Page)pages.next();
+            String path = PageManagerUtils.concatenatePaths(destinationPath, srcPage.getName());
+            if (!pageManager.pageExists(path))
+            {
+                Page dstPage = pageManager.copyPage(srcPage, path);
+                pageManager.updatePage(dstPage);
+            }
+        }
+     
+        Iterator links = srcFolder.getLinks().iterator();
+        while (links.hasNext())
+        {
+            Link srcLink = (Link)links.next();
+            String path = PageManagerUtils.concatenatePaths(destinationPath, srcLink.getName());
+            if (!pageManager.linkExists(path))
+            {            
+                Link dstLink = pageManager.copyLink(srcLink, path);
+                pageManager.updateLink(dstLink);
+            }
+        }
+     
+        Iterator folders = srcFolder.getFolders().iterator();
+        while (folders.hasNext())
+        {
+            Folder folder = (Folder)folders.next();
+            String newPath = concatenatePaths(destinationPath, folder.getName()); 
+            deepMergeFolder(pageManager, folder, newPath, null);
+        }        
+    }
     
 }

Modified: portals/jetspeed-2/portal/trunk/components/jetspeed-page-manager/src/main/java/org/apache/jetspeed/page/impl/DatabasePageManager.java
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/components/jetspeed-page-manager/src/main/java/org/apache/jetspeed/page/impl/DatabasePageManager.java?rev=673860&r1=673859&r2=673860&view=diff
==============================================================================
--- portals/jetspeed-2/portal/trunk/components/jetspeed-page-manager/src/main/java/org/apache/jetspeed/page/impl/DatabasePageManager.java (original)
+++ portals/jetspeed-2/portal/trunk/components/jetspeed-page-manager/src/main/java/org/apache/jetspeed/page/impl/DatabasePageManager.java Thu Jul  3 16:01:21 2008
@@ -1844,6 +1844,12 @@
     {
         PageManagerUtils.deepCopyFolder(this, srcFolder, destinationPath, owner);
     }
+
+    public void deepMergeFolder(Folder srcFolder, String destinationPath, String owner)
+    throws NodeException, PageNotUpdatedException
+    {
+        PageManagerUtils.deepMergeFolder(this, srcFolder, destinationPath, owner);
+    }
     
     /* (non-Javadoc)
      * @see org.apache.jetspeed.page.PageManager#addPages(org.apache.jetspeed.om.page.Page[])

Added: portals/jetspeed-2/portal/trunk/components/jetspeed-page-manager/src/main/java/org/apache/jetspeed/serializer/JetspeedUserTemplateSerializer.java
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/components/jetspeed-page-manager/src/main/java/org/apache/jetspeed/serializer/JetspeedUserTemplateSerializer.java?rev=673860&view=auto
==============================================================================
--- portals/jetspeed-2/portal/trunk/components/jetspeed-page-manager/src/main/java/org/apache/jetspeed/serializer/JetspeedUserTemplateSerializer.java (added)
+++ portals/jetspeed-2/portal/trunk/components/jetspeed-page-manager/src/main/java/org/apache/jetspeed/serializer/JetspeedUserTemplateSerializer.java Thu Jul  3 16:01:21 2008
@@ -0,0 +1,188 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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.jetspeed.serializer;
+
+import java.security.PrivilegedAction;
+import java.util.Map;
+import java.util.prefs.Preferences;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.apache.jetspeed.administration.PortalConfigurationConstants;
+import org.apache.jetspeed.components.util.ConfigurationProperties;
+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.folder.InvalidFolderException;
+import org.apache.jetspeed.page.PageManager;
+import org.apache.jetspeed.page.PageManagerUtils;
+import org.apache.jetspeed.page.document.NodeException;
+import org.apache.jetspeed.security.JSSubject;
+import org.apache.jetspeed.security.SecurityException;
+import org.apache.jetspeed.security.User;
+import org.apache.jetspeed.security.UserManager;
+import org.apache.jetspeed.serializer.objects.JSSnapshot;
+import org.apache.jetspeed.serializer.objects.JSUser;
+
+/**
+ * JetspeedSecuritySerializer - Security component serializer
+ * 
+ * @author <a href="mailto:taylor@apache.org">David Sean Taylor</a>
+ * @version $Id: $
+ */
+public class JetspeedUserTemplateSerializer extends AbstractJetspeedComponentSerializer
+{
+    private final static Log log = LogFactory.getLog(JetspeedUserTemplateSerializer.class);
+    private PageManager pageManager;
+    private UserManager userManager;
+    private String adminUserName = null;
+    
+    public JetspeedUserTemplateSerializer(PageManager pageManager, UserManager userManager, ConfigurationProperties config)
+    {
+        this.pageManager = pageManager;
+        this.userManager = userManager;
+        this.adminUserName = config.getString(PortalConfigurationConstants.USERS_DEFAULT_ADMIN);
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see org.apache.jetspeed.serializer.JetspeedComponentSerializer#processExport(org.apache.jetspeed.serializer.objects.JSSnapshot,
+     *      java.util.Map, org.apache.commons.logging.Log)
+     */
+    protected void processExport(JSSnapshot snapshot, Map settings, Log log) throws SerializerException
+    {
+        if (isSettingSet(settings, JetspeedSerializer.KEY_PROCESS_USER_TEMPLATES))
+        {
+            log.info("collecting user template info");
+        }
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see org.apache.jetspeed.serializer.JetspeedComponentSerializer#processImport(org.apache.jetspeed.serializer.objects.JSSnapshot,
+     *      java.util.Map, org.apache.commons.logging.Log)
+     */
+    protected void processImport(JSSnapshot snapshot, Map settings, Log log) throws SerializerException
+    {
+        if (isSettingSet(settings, JetspeedSerializer.KEY_PROCESS_USER_TEMPLATES))
+        {
+            log.info("creating user templates");
+            User adminUser = null;
+            try
+            {
+                adminUser = userManager.getUser(this.adminUserName);
+            }
+            catch (Exception e)
+            {
+                System.out.println("admin user failed to retrieve " + adminUserName);
+                e.printStackTrace();
+                adminUser = null;
+            }            
+            if (adminUser == null)
+                throw new SerializerException(SecurityException.USER_DOES_NOT_EXIST.create("admin"));
+            for (JSUser user : snapshot.getUsers())
+            {
+                String folderTemplate = user.getUserTemplate();
+                String ssubsite = user.getSubsite();
+                if (folderTemplate != null)
+                {
+                    String userTemplate = null;
+                    String subsite = null;
+                    if (user.getSubsite() != null)
+                    {
+                        subsite = user.getSubsite();
+                        String path = PageManagerUtils.concatenatePaths(Folder.SUBSITE_ROOT_FOLDER, subsite);
+                        userTemplate = PageManagerUtils.concatenatePaths(path, Folder.USER_FOLDER + user.getName());
+                        //userTemplate = Folder.SUBSITE_ROOT_FOLDER + subsite + Folder.USER_FOLDER + user.getName();
+                    } 
+                    else
+                    {
+                        userTemplate = Folder.USER_FOLDER + user.getName();
+                    }
+                    this.createUserTemplate(folderTemplate, userTemplate, subsite, this.pageManager, user.getName(), adminUser);
+                }
+
+            }
+        }
+    }
+
+    protected void deleteData(Map settings, Log log) throws SerializerException
+    {
+        if (isSettingSet(settings, JetspeedSerializer.KEY_PROCESS_USER_TEMPLATES))
+        {
+            log.info("deleting user templates");
+        }
+    }
+
+    // creating userhome pages from usertemplates
+    private void createUserTemplate(String folderTemplate, String userTemplate, String subsite, final PageManager pageManager, String userName, User adminUser)
+    {
+        final String innerFolderTemplate = folderTemplate;
+        final String templateFolder = userTemplate;
+        final String innerSubsite = subsite;
+        final PageManager innerPageManager = pageManager;
+        final String innerUserName = userName;
+
+        JetspeedException pe = (JetspeedException) JSSubject.doAsPrivileged(adminUser.getSubject(), new PrivilegedAction()
+        {
+
+            public Object run()
+            {
+                try
+                {
+                    if (innerSubsite != null)
+                    {
+                        User innerUser = userManager.getUser(innerUserName);                   
+                        Preferences attributes = innerUser.getUserAttributes();
+                        attributes.put(User.USER_INFO_SUBSITE, innerSubsite);
+                    }
+                    Folder source = innerPageManager.getFolder(innerFolderTemplate);
+                    innerPageManager.deepMergeFolder(source, templateFolder, innerUserName);
+                    Folder newFolder = pageManager.getFolder(templateFolder);
+                    newFolder.setTitle("Home Folder");
+                    newFolder.setShortTitle("Home");
+                    return null;
+                } 
+                catch (FolderNotFoundException e1)
+                {
+                    return e1;
+                } 
+                catch (InvalidFolderException e1)
+                {
+                    return e1;
+                } 
+                catch (NodeException e1)
+                {
+                    e1.printStackTrace();
+                    return e1;
+                }
+                catch (SecurityException se)
+                {
+                    se.printStackTrace();
+                    return se;                    
+                }
+            }
+        }, null);
+
+        if (pe != null)
+        {
+        }
+    }
+
+}

Modified: portals/jetspeed-2/portal/trunk/components/jetspeed-serializer/src/main/java/org/apache/jetspeed/serializer/objects/JSUser.java
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/components/jetspeed-serializer/src/main/java/org/apache/jetspeed/serializer/objects/JSUser.java?rev=673860&r1=673859&r2=673860&view=diff
==============================================================================
--- portals/jetspeed-2/portal/trunk/components/jetspeed-serializer/src/main/java/org/apache/jetspeed/serializer/objects/JSUser.java (original)
+++ portals/jetspeed-2/portal/trunk/components/jetspeed-serializer/src/main/java/org/apache/jetspeed/serializer/objects/JSUser.java Thu Jul  3 16:01:21 2008
@@ -35,7 +35,6 @@
  */
 public class JSUser
 {
-
     private String name;
 
     private char[] password;
@@ -60,6 +59,9 @@
 
     private JSPrincipalRules rules = new JSPrincipalRules();
 
+    private String userTemplate;
+    private String subsite;
+    
     private transient Principal principal;
 
     public JSUser()
@@ -301,18 +303,29 @@
      */
     private static final XMLFormat XML = new XMLFormat(JSUser.class)
     {
-
         public void write(Object o, OutputElement xml)
-                throws XMLStreamException
+        throws XMLStreamException
         {
             try
             {
                 JSUser g = (JSUser) o;
                 String s = g.getName();
-                if ((s == null) || (s.length() == 0)) s = "guest";
+                if ((s == null) || (s.length() == 0))
+                {
+                    s = "guest";
+                }
                 xml.setAttribute("name", s);
-
-                
+                s = g.getUserTemplate();
+                if ((s != null) && (s.length() > 0))
+                {
+                    xml.setAttribute("userTemplate", s);
+                }
+                s = g.getSubsite();
+                if ((s != null) && (s.length() > 0))
+                {
+                    xml.setAttribute("subsite", s);
+                }
+                                
                 xml.add(g.getPwData());
 
                 /** named fields HERE */
@@ -339,11 +352,14 @@
             {
                 JSUser g = (JSUser) o;
                 g.name = StringEscapeUtils.unescapeHtml(xml.getAttribute("name", "unknown"));
-                
+                g.userTemplate = StringEscapeUtils.unescapeHtml(xml.getAttribute("userTemplate", ""));
+                if (g.userTemplate.equals(""))
+                    g.userTemplate = null;
+                g.subsite = StringEscapeUtils.unescapeHtml(xml.getAttribute("subsite", ""));
+                if (g.subsite.equals(""))
+                    g.subsite = null;
                 
                 Object o1 = null;
- 
-
 				while (xml.hasNext())
 				{
 					o1 = xml.getNext(); // mime
@@ -354,25 +370,19 @@
 						g.pwData = (JSPWAttributes) o1;
 						g.resetPassword();
 					}
-					else
-					if (o1 instanceof JSUserGroups)
+					else if (o1 instanceof JSUserGroups)
 						g.groupString = (JSUserGroups) o1;
-					else
-	                    if (o1 instanceof JSUserRoles)
-	                        g.roleString = (JSUserRoles) o1;
-	                    else
-                            if (o1 instanceof JSUserAttributes)
-	                            g.userInfo  = (JSUserAttributes) o1;
-	                            else
-		                        if (o1 instanceof JSNVPElements)
-		                        	g.preferences  = (JSNVPElements) o1;
-		                        else
-	                                if (o1 instanceof JSPrincipalRules)
-	                                g.rules  = (JSPrincipalRules) o1;
+					else if (o1 instanceof JSUserRoles)
+	                    g.roleString = (JSUserRoles) o1;
+	                else if (o1 instanceof JSUserAttributes)
+	                    g.userInfo  = (JSUserAttributes) o1;
+	                else if (o1 instanceof JSNVPElements)
+		                g.preferences  = (JSNVPElements) o1;
+                    else if (o1 instanceof JSPrincipalRules)
+	                    g.rules  = (JSPrincipalRules) o1;
                 }
-                
- 
-            } catch (Exception e)
+            } 
+            catch (Exception e)
             {
                 e.printStackTrace();
             }
@@ -479,4 +489,28 @@
 		this.pwData = pwData;
 	}
 
+    
+    public String getSubsite()
+    {
+        return subsite;
+    }
+
+    
+    public void setSubsite(String subsite)
+    {
+        this.subsite = subsite;
+    }
+
+    
+    public String getUserTemplate()
+    {
+        return userTemplate;
+    }
+
+    
+    public void setUserTemplate(String userTemplate)
+    {
+        this.userTemplate = userTemplate;
+    }
+
 }
\ No newline at end of file

Modified: portals/jetspeed-2/portal/trunk/components/jetspeed-serializer/src/main/java/org/apache/jetspeed/serializer/objects/JSUsers.java
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/components/jetspeed-serializer/src/main/java/org/apache/jetspeed/serializer/objects/JSUsers.java?rev=673860&r1=673859&r2=673860&view=diff
==============================================================================
--- portals/jetspeed-2/portal/trunk/components/jetspeed-serializer/src/main/java/org/apache/jetspeed/serializer/objects/JSUsers.java (original)
+++ portals/jetspeed-2/portal/trunk/components/jetspeed-serializer/src/main/java/org/apache/jetspeed/serializer/objects/JSUsers.java Thu Jul  3 16:01:21 2008
@@ -24,6 +24,6 @@
  * @author hajo
  *
  */
-public class JSUsers extends ArrayList
+public class JSUsers extends ArrayList<JSUser>
 {
 }

Modified: portals/jetspeed-2/portal/trunk/etc/xsd/j2-seed.xsd
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/etc/xsd/j2-seed.xsd?rev=673860&r1=673859&r2=673860&view=diff
==============================================================================
--- portals/jetspeed-2/portal/trunk/etc/xsd/j2-seed.xsd (original)
+++ portals/jetspeed-2/portal/trunk/etc/xsd/j2-seed.xsd Thu Jul  3 16:01:21 2008
@@ -21,19 +21,58 @@
   <xs:element name="Snapshot">
     <xs:complexType>
       <xs:sequence>
-        <xs:element ref="tns:softwareVersion"/>
-        <xs:element ref="tns:softwareSubVersion"/>
-        <xs:element ref="tns:default_rule"/>
-        <xs:element ref="tns:encryption"/>
-        <xs:element ref="tns:MimeTypes"/>
-        <xs:element ref="tns:MediaTypes"/>
-        <xs:element ref="tns:Capabilities"/>
-        <xs:element ref="tns:Clients"/>
-        <xs:element ref="tns:Roles"/>
-        <xs:element ref="tns:Groups"/>
-        <xs:element ref="tns:Users"/>
-        <xs:element ref="tns:Permissions"/>
-        <xs:element ref="tns:ProfilingRules"/>
+        <xs:choice>
+	        <xs:element ref="tns:Null"/>
+            <xs:element ref="tns:softwareVersion"/>
+        </xs:choice>
+        <xs:choice>
+            <xs:element ref="tns:Null"/>        
+	        <xs:element  ref="tns:softwareSubVersion"/>
+		</xs:choice>
+        <xs:choice>
+            <xs:element ref="tns:Null"/>			        
+	        <xs:element  ref="tns:default_rule"/>
+	    </xs:choice>
+        <xs:choice>
+            <xs:element ref="tns:Null"/>			        	    
+	        <xs:element  ref="tns:encryption"/>
+	    </xs:choice>
+        <xs:choice>
+            <xs:element ref="tns:Null"/>			        	    
+	        <xs:element  ref="tns:MimeTypes"/>
+	    </xs:choice>
+        <xs:choice>
+            <xs:element ref="tns:Null"/>			        	    
+	        <xs:element  ref="tns:MediaTypes"/>
+	    </xs:choice>
+        <xs:choice>
+            <xs:element ref="tns:Null"/>			        	    
+	        <xs:element  ref="tns:Capabilities"/>
+	    </xs:choice>
+        <xs:choice>
+            <xs:element ref="tns:Null"/>			        	    
+	        <xs:element  ref="tns:Clients"/>
+	    </xs:choice>
+        <xs:choice>
+            <xs:element ref="tns:Null"/>			        	    
+	        <xs:element  ref="tns:Roles"/>
+	    </xs:choice>
+        <xs:choice>
+            <xs:element ref="tns:Null"/>			        	    
+	        <xs:element  ref="tns:Groups"/>
+	    </xs:choice>
+        <xs:choice>
+            <xs:element ref="tns:Null"/>			        	    
+	        <xs:element  ref="tns:Users"/>
+	    </xs:choice>
+        <xs:choice>
+            <xs:element ref="tns:Null"/>			        	    
+	        <xs:element  ref="tns:Permissions"/>
+	    </xs:choice>
+        <xs:choice>
+            <xs:element ref="tns:Null"/>			        	    
+	        <xs:element  ref="tns:ProfilingRules"/>
+	    </xs:choice>
       </xs:sequence>
       <xs:attribute name="name" use="required" type="xs:string"/>
     </xs:complexType>
@@ -155,12 +194,12 @@
   <xs:element name="Role" type="xs:string"/>
   <xs:element name="Groups">
     <xs:complexType>
-      <xs:sequence>
-        <xs:element maxOccurs="unbounded" ref="tns:Group"/>
+      <xs:sequence minOccurs='0'>
+        <xs:element minOccurs='0' maxOccurs="unbounded" ref="tns:Group"/>
       </xs:sequence>
     </xs:complexType>
   </xs:element>
-  <xs:element name="Group" type="xs:string"/>
+  <xs:element name="Group" type="xs:string" />
   <xs:element name="Users">
     <xs:complexType>
       <xs:sequence>
@@ -177,11 +216,22 @@
         </xs:choice>
         <xs:element ref="tns:roles"/>
         <xs:element ref="tns:groups"/>
-        <xs:element ref="tns:preferences"/>
-        <xs:element ref="tns:userinfo"/>
-        <xs:element ref="tns:Rules"/>
+        <xs:choice>
+          <xs:element ref="tns:Null"/>        
+	      <xs:element ref="tns:preferences"/>
+	    </xs:choice>
+	    <xs:choice>
+          <xs:element ref="tns:Null"/>	    
+          <xs:element ref="tns:userinfo"/>
+        </xs:choice>
+        <xs:choice>
+           <xs:element ref="tns:Null"/>        
+           <xs:element ref="tns:Rules"/>
+        </xs:choice>
       </xs:sequence>
       <xs:attribute name="name" use="required" type="xs:string"/>
+      <xs:attribute name="userTemplate" type="xs:string"/>
+      <xs:attribute name="subsite"  type="xs:string"/>
     </xs:complexType>
   </xs:element>
   <xs:element name="Null">
@@ -198,7 +248,7 @@
         </xs:simpleType>
       </xs:attribute>
       <xs:attribute name="password" use="required" type="xs:string"/>
-      <xs:attribute name="requiresUpdate" use="required">
+      <xs:attribute name="requiresUpdate">
         <xs:simpleType>
           <xs:restriction base="xs:string">
             <xs:enumeration value="TRUE" />

Modified: portals/jetspeed-2/portal/trunk/jetspeed-api/src/main/java/org/apache/jetspeed/om/folder/Folder.java
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/jetspeed-api/src/main/java/org/apache/jetspeed/om/folder/Folder.java?rev=673860&r1=673859&r2=673860&view=diff
==============================================================================
--- portals/jetspeed-2/portal/trunk/jetspeed-api/src/main/java/org/apache/jetspeed/om/folder/Folder.java (original)
+++ portals/jetspeed-2/portal/trunk/jetspeed-api/src/main/java/org/apache/jetspeed/om/folder/Folder.java Thu Jul  3 16:01:21 2008
@@ -57,6 +57,7 @@
     String MEDIATYPE_FOLDER = PATH_SEPARATOR + RESERVED_MEDIATYPE_FOLDER_NAME + PATH_SEPARATOR;
     String LANGUAGE_FOLDER = PATH_SEPARATOR + RESERVED_LANGUAGE_FOLDER_NAME + PATH_SEPARATOR;
     String COUNTRY_FOLDER = PATH_SEPARATOR + RESERVED_COUNTRY_FOLDER_NAME + PATH_SEPARATOR;
+    String SUBSITE_ROOT_FOLDER = RESERVED_SUBSITE_FOLDER_PREFIX + "subsite-root" + PATH_SEPARATOR;
 
     int RESERVED_FOLDER_NONE = 0;    
     int RESERVED_FOLDER_SUBSITES = 1;

Modified: portals/jetspeed-2/portal/trunk/jetspeed-api/src/main/java/org/apache/jetspeed/page/PageManager.java
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/jetspeed-api/src/main/java/org/apache/jetspeed/page/PageManager.java?rev=673860&r1=673859&r2=673860&view=diff
==============================================================================
--- portals/jetspeed-2/portal/trunk/jetspeed-api/src/main/java/org/apache/jetspeed/page/PageManager.java (original)
+++ portals/jetspeed-2/portal/trunk/jetspeed-api/src/main/java/org/apache/jetspeed/page/PageManager.java Thu Jul  3 16:01:21 2008
@@ -597,11 +597,24 @@
      * @param source source folder
      * @param dest destination folder
      * @param owner set owner of the new folder(s), or null for no owner
+     * @throws NodeException if the root folder already exists
      */
     public void deepCopyFolder(Folder srcFolder, String destinationPath, String owner)
         throws NodeException;
 
     /**
+     * Deep merges a source folder into a destination folder. Copies a folder and all subcontents including
+     * other folders, subpages, links, menus, security, fragments. If a destination resource already exists,
+     * it is skipped over without error.
+     *  
+     * @param source source folder
+     * @param dest destination folder
+     * @param owner set owner of the new folder(s), or null for no owner
+     */
+    public void deepMergeFolder(Folder srcFolder, String destinationPath, String owner)
+        throws NodeException;
+    
+    /**
      * Retrieve a page for the given user name and page name
      * 
      * @param userName

Modified: portals/jetspeed-2/portal/trunk/jetspeed-api/src/main/java/org/apache/jetspeed/serializer/JetspeedSerializer.java
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/jetspeed-api/src/main/java/org/apache/jetspeed/serializer/JetspeedSerializer.java?rev=673860&r1=673859&r2=673860&view=diff
==============================================================================
--- portals/jetspeed-2/portal/trunk/jetspeed-api/src/main/java/org/apache/jetspeed/serializer/JetspeedSerializer.java (original)
+++ portals/jetspeed-2/portal/trunk/jetspeed-api/src/main/java/org/apache/jetspeed/serializer/JetspeedSerializer.java Thu Jul  3 16:01:21 2008
@@ -71,6 +71,7 @@
     String KEY_PROCESS_USER_PREFERENCES = "process_user_preferences";
     String KEY_PROCESS_PORTAL_PREFERENCES = "process_portal_preferences";
     String KEY_PROCESS_ENTITIES = "process_entities";
+    String KEY_PROCESS_USER_TEMPLATES = "process_user_templates";
     String KEY_LOGGER = "logger";
     String KEY_OVERWRITE_EXISTING = "overwrite_existing";
     String KEY_BACKUP_BEFORE_PROCESS = "backup_before_process";

Modified: portals/jetspeed-2/portal/trunk/jetspeed-portal-resources/src/main/resources/assembly/jetspeed-properties.xml
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/jetspeed-portal-resources/src/main/resources/assembly/jetspeed-properties.xml?rev=673860&r1=673859&r2=673860&view=diff
==============================================================================
--- portals/jetspeed-2/portal/trunk/jetspeed-portal-resources/src/main/resources/assembly/jetspeed-properties.xml (original)
+++ portals/jetspeed-2/portal/trunk/jetspeed-portal-resources/src/main/resources/assembly/jetspeed-properties.xml Thu Jul  3 16:01:21 2008
@@ -20,7 +20,7 @@
 
   <!-- Commons configuration object generated from jetspeed.properties + override.properties -->
   <bean id="portal_configuration" class="org.apache.jetspeed.components.util.ConfigurationProperties">
-    <meta key="j2:cat" value="default" />
+    <meta key="j2:cat" value="default,springProperties" />
     <property name="locations">
       <list>
         <value>file:///${jetspeedPropertiesPath}/jetspeed.properties</value>

Modified: portals/jetspeed-2/portal/trunk/jetspeed-portal-resources/src/main/resources/assembly/serializer.xml
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/jetspeed-portal-resources/src/main/resources/assembly/serializer.xml?rev=673860&r1=673859&r2=673860&view=diff
==============================================================================
--- portals/jetspeed-2/portal/trunk/jetspeed-portal-resources/src/main/resources/assembly/serializer.xml (original)
+++ portals/jetspeed-2/portal/trunk/jetspeed-portal-resources/src/main/resources/assembly/serializer.xml Thu Jul  3 16:01:21 2008
@@ -26,6 +26,13 @@
           <constructor-arg index="1" ref="org.apache.jetspeed.components.portletentity.PortletEntityAccessComponent" />
           <constructor-arg index="2" ref="org.apache.jetspeed.search.SearchEngine" />
         </bean>
+<!-- 
+        <bean class="org.apache.jetspeed.serializer.JetspeedUserTemplateSerializer">
+          <constructor-arg index="0" ref="org.apache.jetspeed.page.PageManager" />
+          <constructor-arg index="1" ref="org.apache.jetspeed.security.UserManager" />
+		  <constructor-arg index="2" ref="portal_configuration" />          
+        </bean>
+ -->        
       </list>
     </constructor-arg>
     <constructor-arg index="1">
@@ -52,6 +59,9 @@
         <entry key="process_user_preferences">
           <value type="java.lang.Boolean">true</value>
         </entry>
+        <entry key="process_user_templates">
+          <value type="java.lang.Boolean">true</value>
+        </entry>        
         <!--  following serializers are not yet implemented/available -->
         <entry key="process_portal_preferences">
           <value type="java.lang.Boolean">false</value>

Modified: portals/jetspeed-2/portal/trunk/jetspeed-portal-resources/src/main/resources/conf/jetspeed/jetspeed.properties
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/jetspeed-portal-resources/src/main/resources/conf/jetspeed/jetspeed.properties?rev=673860&r1=673859&r2=673860&view=diff
==============================================================================
--- portals/jetspeed-2/portal/trunk/jetspeed-portal-resources/src/main/resources/conf/jetspeed/jetspeed.properties (original)
+++ portals/jetspeed-2/portal/trunk/jetspeed-portal-resources/src/main/resources/conf/jetspeed/jetspeed.properties Thu Jul  3 16:01:21 2008
@@ -75,7 +75,7 @@
 supported.portletmode = secure  # currently only used for testing purposes
 # auto-switching
 # switch config mode to built-in custom config mode portlet
-supported.portletmode.autoswitch.config=false
+supported.portletmode.autoswitch.config=true
 # switch edit_defaults mode to edit mode automatically for portlets not supporting edit_defaults mode
 supported.portletmode.autoswitch.edit_defaults=false
 # auto-switching surrogate portlet for config mode

Modified: portals/jetspeed-2/portal/trunk/jetspeed-portal-resources/src/main/resources/seed/j2-seed.xml
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/jetspeed-portal-resources/src/main/resources/seed/j2-seed.xml?rev=673860&r1=673859&r2=673860&view=diff
==============================================================================
--- portals/jetspeed-2/portal/trunk/jetspeed-portal-resources/src/main/resources/seed/j2-seed.xml (original)
+++ portals/jetspeed-2/portal/trunk/jetspeed-portal-resources/src/main/resources/seed/j2-seed.xml Thu Jul  3 16:01:21 2008
@@ -349,7 +349,7 @@
 				<Rule locator="page" rule="subsite-by-hostname"/>
 			</Rules>
 		</User>
-		<User name="tomcat">
+	<User name="tomcat" userTemplate='/_user/template/' subsite='_hostname/localhost'>
 			<credentials password="tomcat" enabled="TRUE" requiresUpdate="FALSE"/>
 			<roles></roles>
 			<groups></groups>

Added: portals/jetspeed-2/portal/trunk/quickStart.sh
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/quickStart.sh?rev=673860&view=auto
==============================================================================
--- portals/jetspeed-2/portal/trunk/quickStart.sh (added)
+++ portals/jetspeed-2/portal/trunk/quickStart.sh Thu Jul  3 16:01:21 2008
@@ -0,0 +1,4 @@
+cd applications/jetspeed-demo
+mvn -o jetspeed-db:init -P demo 
+mvn -o jetspeed-deploy:deploy -P demo
+cd ../..

Propchange: portals/jetspeed-2/portal/trunk/quickStart.sh
------------------------------------------------------------------------------
    svn:executable = *



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