portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tay...@apache.org
Subject svn commit: r345854 - in /portals/jetspeed-2/trunk/etc/sql/xml: ./ README.txt populate-db-default.xml
Date Mon, 21 Nov 2005 07:02:42 GMT
Author: taylor
Date: Sun Nov 20 23:02:40 2005
New Revision: 345854

URL: http://svn.apache.org/viewcvs?rev=345854&view=rev
Log:
The XML mockups included in this commit are a suggested alternate way to populate the default
database data.
I think we have two new choices here:

(a) DDL UTILS DML support (http://db.apache.org/ddlutils/) db population scripts (I can't
actually find DML support here!)
    
(b) XML Files imported directly using the Jetspeed API

Where as I really like DDL UTILS, and it has a quicker maintainance model, I find the ability
to have standard XML files 
for importing or persistence model easier to understand for end users.
Also, this will work nicely for importing the database at runtime during installs.

So this XML: 

    <roles>admin, guest, user</roles>

would map to:

	roleManager.addRole("admin");
	roleManager.addRole("guest");
	roleManager.addRole("user");
	
and so forth for new users, permissions, profiling rules, capabilities, etc:	
	
     <user name='joe' password='xxx' template='/_user/template/'>
       <roles>admin, user</roles>
       <groups>dev</groups>
       <user-info>
           <info>
               <name>user.first.name</name>
               <value>Joseph</value>
           </info>
           <info>
               <name>user.last.name</name>
               <value>Stalin</value>
           </info>
       </user-info>
       
       <preferences/>
       
       <folder-template>/_user/template/</folder-template>
       <profile-rules>
           <rule name='page'>userrolefallback</rule>
           <rule name='page'>userrolefallback</rule>
       </profile-rules>
    </user>

Added:
    portals/jetspeed-2/trunk/etc/sql/xml/
    portals/jetspeed-2/trunk/etc/sql/xml/README.txt
    portals/jetspeed-2/trunk/etc/sql/xml/populate-db-default.xml

Added: portals/jetspeed-2/trunk/etc/sql/xml/README.txt
URL: http://svn.apache.org/viewcvs/portals/jetspeed-2/trunk/etc/sql/xml/README.txt?rev=345854&view=auto
==============================================================================
--- portals/jetspeed-2/trunk/etc/sql/xml/README.txt (added)
+++ portals/jetspeed-2/trunk/etc/sql/xml/README.txt Sun Nov 20 23:02:40 2005
@@ -0,0 +1,46 @@
+The XML mockups included in this directly are a suggested alternate way to populate the default
database data.
+I think we have two choices here:
+
+(a) DDL UTILS DML support (http://db.apache.org/ddlutils/) db population scripts (I can't
actually find DML support here!)
+    
+(b) XML Files imported directly using the Jetspeed API
+
+Where as I really like DDL UTILS, and it has a quicker maintainance model, I find the ability
to have standard XML files 
+for importing or persistence model easier to understand for end users.
+Also, this will work nicely for importing the database at runtime during installs.
+
+So this XML: 
+
+    <roles>admin, guest, user</roles>
+
+would map to:
+
+	roleManager.addRole("admin");
+	roleManager.addRole("guest");
+	roleManager.addRole("user");
+	
+and so forth for new users, permissions, profiling rules, capabilities, etc:	
+	
+     <user name='joe' password='xxx' template='/_user/template/'>
+       <roles>admin, user</roles>
+       <groups>dev</groups>
+       <user-info>
+           <info>
+               <name>user.first.name</name>
+               <value>Joseph</value>
+           </info>
+           <info>
+               <name>user.last.name</name>
+               <value>Stalin</value>
+           </info>
+       </user-info>
+       
+       <preferences/>
+       
+       <folder-template>/_user/template/</folder-template>
+       <profile-rules>
+           <rule name='page'>userrolefallback</rule>
+           <rule name='page'>userrolefallback</rule>
+       </profile-rules>
+    </user>
+	
\ No newline at end of file

Added: portals/jetspeed-2/trunk/etc/sql/xml/populate-db-default.xml
URL: http://svn.apache.org/viewcvs/portals/jetspeed-2/trunk/etc/sql/xml/populate-db-default.xml?rev=345854&view=auto
==============================================================================
--- portals/jetspeed-2/trunk/etc/sql/xml/populate-db-default.xml (added)
+++ portals/jetspeed-2/trunk/etc/sql/xml/populate-db-default.xml Sun Nov 20 23:02:40 2005
@@ -0,0 +1,39 @@
+<jetspeed-seed-data>
+    <roles>admin, guest, user</roles>
+    <groups>dev, test</groups>
+    
+     <user name='joe' password='xxx' template='/_user/template/'>
+       <roles>admin, user</roles>
+       <groups>dev</groups>
+       <user-info>
+           <info>
+               <name>user.first.name</name>
+               <value>Joseph</value>
+           </info>
+           <info>
+               <name>user.last.name</name>
+               <value>Stalin</value>
+           </info>
+       </user-info>
+       
+       <preferences/>
+       
+       <folder-template>/_user/template/</folder-template>
+       <profile-rules>
+           <rule name='page'>userrolefallback</rule>
+           <rule name='page'>userrolefallback</rule>
+       </profile-rules>
+    </user>
+
+    <permission type='folder' resource='/' actions='view, edit'>
+        <roles>admin, user</roles>
+        <groups>dev</groups>
+        <users>joe</users>
+    </permission>
+
+    <profiling-rule name='j2' class='org.apache.jetspeed.profile.RuleImpl' description='whatever'>
+        <criterion order='0' type='user' name='user' value='*' fallback='continue' />
+        <criterion order='1' type='path.session' name='path' value='default-page.psml'
fallback='continue' />        
+    </profiling-rule>
+    
+</jetspeed-seed-data>



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