rave-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ja...@apache.org
Subject svn commit: r1170556 - /incubator/rave/site/trunk/content/rave/documentation/configure-database.mdtext
Date Wed, 14 Sep 2011 12:08:32 GMT
Author: jasha
Date: Wed Sep 14 12:08:32 2011
New Revision: 1170556

URL: http://svn.apache.org/viewvc?rev=1170556&view=rev
Log:
Simplify the documentation

Modified:
    incubator/rave/site/trunk/content/rave/documentation/configure-database.mdtext

Modified: incubator/rave/site/trunk/content/rave/documentation/configure-database.mdtext
URL: http://svn.apache.org/viewvc/incubator/rave/site/trunk/content/rave/documentation/configure-database.mdtext?rev=1170556&r1=1170555&r2=1170556&view=diff
==============================================================================
--- incubator/rave/site/trunk/content/rave/documentation/configure-database.mdtext (original)
+++ incubator/rave/site/trunk/content/rave/documentation/configure-database.mdtext Wed Sep
14 12:08:32 2011
@@ -16,20 +16,29 @@ Notice:    Licensed to the Apache Softwa
            specific language governing permissions and limitations
            under the License.
 
-## Default values
+## Default setup
 In the default setup Rave uses an in memory [H2 database][1].
 
+All schemas are generated using JPA annotations. The H2 database is populated with low level
SQL queries using the DataSourcePopulator which is configured as Spring bean. These queries
are not guaranteed to work for a different database.
+
 To access the tables for the portal, go to [http://localhost:11111][2]. 
 To access the tables for the OpenSocial container (Shindig), go to [http://localhost:22222][3].
Username is `sa`, password `local`.
 
 
+
 ## Setup a different database
-All schemas are generated using JPA annotations. In the default setup the H2 database is
populated with low level SQL queries using the DataSourcePopulator which is configured as
Spring bean. These queries are not guaranteed to work for a different database.
 
 First start with [extending Rave][4].
 
-## MySQL setup
-Make sure the mysql jdbc driver ends up in the classpath. Either add it to a common lib directory
of the application container or add this dependency to the pom of the several modules:
+Make sure the jdbc driver ends up in the classpath. Either add it to a common lib directory
of the application container or add its dependency to the pom of the several modules.
+
+Then customize the properties for the portal and Shindig to use the database of your choice.
+
+## Sample values 
+
+### MySQL
+
+#### JDBC driver
 
     <dependency>
         <groupId>mysql</groupId>
@@ -37,7 +46,8 @@ Make sure the mysql jdbc driver ends up 
         <version>5.1.15</version>
     </dependency>
 
-Customize the properties for the Rave portal:
+#### Properties
+Rave portal:
 
     portal.dataSource.url=jdbc:mysql://localhost:3306/rave-portal
     portal.dataSource.driver=com.mysql.jdbc.Driver
@@ -48,7 +58,7 @@ Customize the properties for the Rave po
     portal.jpaVendorAdapter.databasePlatform=org.apache.openjpa.jdbc.sql.MySQLDictionary
     portal.jpaVendorAdapter.database=MYSQL
 
-Customize the properties for Rave Shindig:
+Rave Shindig:
 
     rave-shindig.dataSource.url=jdbc:mysql://localhost:3306/rave-shindig
     rave-shindig.dataSource.driver=com.mysql.jdbc.Driver
@@ -59,10 +69,11 @@ Customize the properties for Rave Shindi
     rave-shindig.jpaVendorAdapter.databasePlatform=org.apache.openjpa.jdbc.sql.MySQLDictionary
     rave-shindig.jpaVendorAdapter.database=MYSQL
 
+#### Notes
 The DataSourcePopulator uses a single statement to execute all queries in the configured
SQL files. The MySQL JDBC driver does not allow this by default, unless you add `allowMultiple=true`
to the driver url.
 
-## PostgreSQL setup
-Make sure the PostgreSQL jdbc driver ends up in the classpath. Either add it to a common
lib directory of the application container or add this dependency to the pom of the several
modules:
+### PostgreSQL
+#### JDBC driver
 
     <dependency>
         <groupId>postgresql</groupId>
@@ -70,7 +81,8 @@ Make sure the PostgreSQL jdbc driver end
         <version>9.0-801.jdbc4</version>
     </dependency>
 
-Customize the properties for the Rave portal:
+#### Properties
+Rave portal:
 
     portal.dataSource.url=jdbc:postgresql://localhost:5432/rave-portal
     portal.dataSource.driver=org.postgresql.Driver
@@ -81,7 +93,7 @@ Customize the properties for the Rave po
     portal.jpaVendorAdapter.databasePlatform=org.apache.openjpa.jdbc.sql.PostgresDictionary
     portal.jpaVendorAdapter.database=POSTGRESQL
 
-Customize the properties for Rave Shindig:
+Rave Shindig:
 
     rave-shindig.dataSource.url=jdbc:postgresql://localhost:5432/rave-portal
     rave-shindig.dataSource.driver=org.postgresql.Driver
@@ -92,6 +104,7 @@ Customize the properties for Rave Shindi
     rave-shindig.jpaVendorAdapter.databasePlatform=org.apache.openjpa.jdbc.sql.PostgresDictionary
     rave-shindig.jpaVendorAdapter.database=POSTGRESQL
 
+#### Notes
 The syntax for setting variables in SQL queries in PostgreSQL is different from the syntax
in H2 databases. Therefore the default data cannot be loaded using the initial data.
 
   [1]: http://www.h2database.com/



Mime
View raw message