]> git.aero2k.de Git - tmp/jakarta-migration.git/commitdiff
CSPACE-4526: Adding more support for PostgreSQL to be the default DB. These changes...
authorRichard Millet <richard.millet@berkeley.edu>
Mon, 21 Nov 2011 19:15:53 +0000 (19:15 +0000)
committerRichard Millet <richard.millet@berkeley.edu>
Mon, 21 Nov 2011 19:15:53 +0000 (19:15 +0000)
services/JaxRsServiceProvider/src/main/resources/META-INF/persistence.xml
services/authorization/service/src/main/resources/applicationContext-authorization.xml

index 96e4234dea4e56ed4dc0c0056fb1b7d940ff0e25..d454ed04b970fbf99a101b63044e0dda9a0f6db0 100644 (file)
         <class>org.collectionspace.services.authorization.PermissionRoleRel</class>\r
         <class>org.collectionspace.services.authorization.Role</class>\r
         <class>org.collectionspace.services.authorization.AccountRoleRel</class>\r
+        \r
+        <!-- \r
         <properties>\r
                        <property name="hibernate.dialect" value="org.hibernate.dialect.PostgreSQLDialect"/>\r
             <property name="hibernate.max_fetch_depth" value="3"/>\r
+        --> \r
                        <!-- Until our JNDI issue with Nuxeo is resolved, we have to use these JDBC properties rather than a datasource -->\r
+               <!--    \r
                        <property name="hibernate.connection.driver_class" value="org.postgresql.Driver"/>\r
                        <property name="hibernate.connection.username" value="postgres"/>\r
                        <property name="hibernate.connection.password" value="pgSEE^quell"/>\r
                        <property name="hibernate.connection.url" value="jdbc:postgresql://localhost:5432/cspace"/>\r
-                       \r
+               -->\r
+            <!--property name="hibernate.hbm2ddl.auto" value="create-drop"/-->\r
+        <!--\r
+        </properties>\r
+         -->\r
+\r
+        <properties>\r
+                       <property name="hibernate.dialect" value="${db.dialect}"/>\r
+            <property name="hibernate.max_fetch_depth" value="3"/>\r
+                       <!-- Until our JNDI issue with Nuxeo is resolved, we have to use these JDBC properties rather than a datasource -->\r
+                       <property name="hibernate.connection.driver_class" value="${db.jdbc.driver.class}"/>\r
+                       <property name="hibernate.connection.username" value="${db.user}"/>\r
+                       <property name="hibernate.connection.password" value="${db.user.password}"/>\r
+                       <property name="hibernate.connection.url" value="jdbc:${db}://localhost:${db.port}/cspace"/>\r
             <!--property name="hibernate.hbm2ddl.auto" value="create-drop"/-->\r
         </properties>\r
 \r
index 5f8d801d259e0dd1778f7b82a0864812101a0583..dac9c386e70729aa583790d115a8513bed768065 100644 (file)
     </bean>
      -->
     
+    <!-- 
        <bean id="dataSource" class="org.apache.commons.dbcp.BasicDataSource" destroy-method="close">
         <property name="driverClassName" value="org.postgresql.Driver"/>
         <property name="url" value="jdbc:postgresql://localhost:5432/cspace"/>
         <property name="username" value="postgres"/>
         <property name="password" value="pgSEE^quell"/>
+    </bean>
+     -->
+
+       <bean id="dataSource" class="org.apache.commons.dbcp.BasicDataSource" destroy-method="close">
+        <property name="driverClassName" value="${db.jdbc.driver.class}"/>
+        <property name="url" value="jdbc:${db}://localhost:${db.port}/cspace"/>
+        <property name="username" value="${db.user}"/>
+        <property name="password" value="${db.user.password}"/>
     </bean>    
 
     <bean id="lookupStrategy" class="org.springframework.security.acls.jdbc.BasicLookupStrategy">