]> git.aero2k.de Git - tmp/jakarta-migration.git/commitdiff
CSPACE-5340: Removed all hard coded references to "localhost" from our setting and...
authorRichard Millet <remillet@berkeley.edu>
Fri, 29 Jun 2012 23:31:52 +0000 (16:31 -0700)
committerRichard Millet <remillet@berkeley.edu>
Fri, 29 Jun 2012 23:31:52 +0000 (16:31 -0700)
15 files changed:
3rdparty/nuxeo/build.xml
3rdparty/nuxeo/nuxeo-server/5.5/config/default-repo-config.xml
services/JaxRsServiceProvider/src/main/resources/META-INF/persistence.xml
services/JaxRsServiceProvider/src/main/webapp/META-INF/context.xml
services/account/client/src/test/resources/META-INF/persistence.xml
services/account/pstore/src/test/resources/META-INF/persistence.xml
services/authentication/client/src/test/resources/META-INF/persistence.xml
services/authentication/jaxb/src/test/resources/META-INF/persistence.xml
services/authentication/pstore/src/test/resources/META-INF/persistence.xml
services/authorization-mgt/import/src/main/resources/META-INF/persistence.xml
services/authorization-mgt/import/src/main/resources/log4j.properties
services/authorization/pstore/src/test/resources/META-INF/persistence.xml
services/authorization/service/src/main/resources/applicationContext-authorization.xml
services/common/src/main/java/org/collectionspace/services/common/storage/jpa/JpaStorageUtils.java
services/security/client/src/test/resources/META-INF/persistence.xml

index e29826f698d52b8d043793577637d183459750d0..3e5b9ac6fdbb9af54d3f867a2ca97c778b735961 100644 (file)
             <fileset dir="${basedir}/nuxeo-server/${nuxeo.release}/config"/>\r
             <filterset>\r
                 <filter token="DB" value="${db}" />\r
-                               <filter token="DB_URL" value="jdbc:${db}://localhost:${db.port}/nuxeo"/>\r
+                               <filter token="DB_URL" value="jdbc:${db}://${db.host}:${db.port}/nuxeo"/>\r
+               <filter token="DB_SERVER_HOSTNAME" value="${db.host}"/>\r
                                <filter token="XA_DATASOURCE" value="${db.xaDataSource}" />\r
                 <filter token="NUXEO_USER" value="${db.nuxeo.user}" />\r
                 <filter token="NUXEO_PW" value="${db.nuxeo.user.password}" />\r
index 82eaf4c3ccbf2b5cba21611f0df4d1663a1e7e15..2c1b6d4b4953b34fe2fde3dce2ff92e4c457fcfc 100644 (file)
@@ -10,6 +10,7 @@
                                <!-- The transactional datasource for Nuxeo -->
                                <xa-datasource>@XA_DATASOURCE@</xa-datasource>                          
                                <property name="URL">@DB_URL@</property>
+                               <property name="ServerName">@DB_SERVER_HOSTNAME@</property>                             
                                <property name="DatabaseName">nuxeo</property>
                                <property name="User">@NUXEO_USER@</property>
                                <property name="Password">@NUXEO_PW@</property>
index d454ed04b970fbf99a101b63044e0dda9a0f6db0..f536675702f63b3c7b55e7ffb9a977afcd88c03a 100644 (file)
         <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
-            <!--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
@@ -41,7 +24,7 @@
                        <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.connection.url" value="jdbc:${db}://${db.host}:${db.port}/cspace"/>\r
             <!--property name="hibernate.hbm2ddl.auto" value="create-drop"/-->\r
         </properties>\r
 \r
index 56226e29a331faee9148ae2ed2e53cfdf867ba50..de1031dcb69fe10f8f77a723a33cabafc1ba9e11 100644 (file)
@@ -75,7 +75,7 @@
            username="${db.user}"
            password="${db.user.password}"
            driverClassName="${db.jdbc.driver.class}"
-           url="jdbc:${db}://localhost:${db.port}/cspace"
+           url="jdbc:${db}://${db.host}:${db.port}/cspace"
            maxActive="8"
            maxIdle="4"/>
                
@@ -85,7 +85,7 @@
            username="${db.user}"
            password="${db.user.password}"
            driverClassName="${db.jdbc.driver.class}"
-           url="jdbc:${db}://localhost:${db.port}/nuxeo"
+           url="jdbc:${db}://${db.host}:${db.port}/nuxeo"
            maxActive="8"
            maxIdle="4"/>       
 
index 0b6711432e7dc4f87a131922b97949cc4348790a..8c4188508f142e6caccebedd4746322e9b9905cf 100644 (file)
@@ -16,7 +16,7 @@
             <property name="hibernate.connection.driver_class" value="com.mysql.jdbc.Driver"/>
             <property name="hibernate.connection.username" value="test"/>
             <property name="hibernate.connection.password" value="test"/>
-            <property name="hibernate.connection.url" value="jdbc:mysql://localhost:3306/cspace"/-->
+            <property name="hibernate.connection.url" value="jdbc:mysql://${db.host}:3306/cspace"/-->
         </properties>
     </persistence-unit>
 </persistence>
index f332caa05b9ce6ca656c51d91df255c2430954fa..f6e45ccfefbeb647b61fea135fa36bf17bd41ae2 100644 (file)
@@ -14,7 +14,7 @@
             <property name="hibernate.connection.driver_class" value="com.mysql.jdbc.Driver"/>
             <property name="hibernate.connection.username" value="test"/>
             <property name="hibernate.connection.password" value="test"/>
-            <property name="hibernate.connection.url" value="jdbc:mysql://localhost:3306/cspace"/-->
+            <property name="hibernate.connection.url" value="jdbc:mysql://${db.host}:3306/cspace"/-->
         </properties>
     </persistence-unit>
 </persistence>
index 97d00a01d1d66b7b62f51a9d49362760a5bd5346..61ab30d52c172e7c1c90a185ff9312e3d074b95d 100644 (file)
@@ -13,7 +13,7 @@ http://java.sun.com/xml/ns/persistence/orm http://java.sun.com/xml/ns/persistenc
             <property name="hibernate.connection.driver_class" value="com.mysql.jdbc.Driver"/>
             <property name="hibernate.connection.username" value="test"/>
             <property name="hibernate.connection.password" value="test"/>
-            <property name="hibernate.connection.url" value="jdbc:mysql://localhost:3306/cspace"/-->
+            <property name="hibernate.connection.url" value="jdbc:mysql://${db.host}:3306/cspace"/-->
         </properties>
     </persistence-unit>
 </persistence>
index c46723c6bf5dd03b2cc6e5b30005f9b80bbee6ee..a9564d02da408c4ae0a56b6ffbe7a3e4b0b867e0 100644 (file)
@@ -11,7 +11,7 @@ http://java.sun.com/xml/ns/persistence/orm http://java.sun.com/xml/ns/persistenc
             <property name="hibernate.connection.driver_class" value="com.mysql.jdbc.Driver"/>
             <property name="hibernate.connection.username" value="test"/>
             <property name="hibernate.connection.password" value="test"/>
-            <property name="hibernate.connection.url" value="jdbc:mysql://localhost:3306/cspace"/-->
+            <property name="hibernate.connection.url" value="jdbc:mysql://${db.host}:3306/cspace"/-->
         </properties>
     </persistence-unit>
 </persistence>
index 05b2b43dfc5e7a8923eac0d2f35707d2b91d6760..59673d1db1f8b75527796f5955451a3bb86d1e5d 100644 (file)
@@ -11,7 +11,7 @@ http://java.sun.com/xml/ns/persistence/orm http://java.sun.com/xml/ns/persistenc
             <property name="hibernate.connection.driver_class" value="com.mysql.jdbc.Driver"/>
             <property name="hibernate.connection.username" value="test"/>
             <property name="hibernate.connection.password" value="test"/>
-            <property name="hibernate.connection.url" value="jdbc:mysql://localhost:3306/cspace"/-->
+            <property name="hibernate.connection.url" value="jdbc:mysql://${db.host}:3306/cspace"/-->
         </properties>
     </persistence-unit>
 </persistence>
index 911f05335423c5b3ad609d5f4ea4ec185c36be7b..52fe747e8647b69fe4eafed0b4873db127cb1b4e 100644 (file)
@@ -15,7 +15,7 @@
             <property name="hibernate.connection.driver_class" value="com.mysql.jdbc.Driver"/>
             <property name="hibernate.connection.username" value="test"/>
             <property name="hibernate.connection.password" value="test"/>
-            <property name="hibernate.connection.url" value="jdbc:mysql://localhost:3306/cspace"/-->
+            <property name="hibernate.connection.url" value="jdbc:mysql://${db.host}:3306/cspace"/-->
         </properties>
     </persistence-unit>
 </persistence>
index 7eab9d9f159277f9d5746ba92a8f7faf6da865d3..b245250850b79708ee89cc34b42e397cae92f98d 100644 (file)
@@ -28,3 +28,4 @@ log4j.logger.org.hibernate.cfg=WARN
 log4j.logger.org.springframework=INFO\r
 log4j.logger.ch.elca.el4j.services.xmlmerge=INFO\r
 log4j.logger.com.sun.xml.bind.v2.runtime=DEBUG\r
+log4j.logger.javax.persistence.PersistenceException=TRACE\r
index ec517f79d8df503f83b239af54b011f326a93948..8fcff4b370005eafe8c2e86156ac4c061a2e6fd5 100644 (file)
@@ -15,7 +15,7 @@
             <property name="hibernate.connection.driver_class" value="com.mysql.jdbc.Driver"/>
             <property name="hibernate.connection.username" value="test"/>
             <property name="hibernate.connection.password" value="test"/>
-            <property name="hibernate.connection.url" value="jdbc:mysql://localhost:3306/cspace"/-->
+            <property name="hibernate.connection.url" value="jdbc:mysql://${db.host}:3306/cspace"/-->
         </properties>
     </persistence-unit>
 </persistence>
index dac9c386e70729aa583790d115a8513bed768065..816f5b6f7d085caa02ba1e9996babbc57a838275 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="url" value="jdbc:${db}://${db.host}:${db.port}/cspace"/>
         <property name="username" value="${db.user}"/>
         <property name="password" value="${db.user.password}"/>
     </bean>    
index 9013358da1eb044c89913bba97b766bf38a2533f..b15f910c76737c284782949c1ec298ee6a62ef00 100644 (file)
@@ -566,7 +566,7 @@ public class JpaStorageUtils {
        if (result == null && !persistenceUnit.equalsIgnoreCase(CS_AUTHZ_PERSISTENCE_UNIT)) try {
                result = Persistence.createEntityManagerFactory(CS_AUTHZ_PERSISTENCE_UNIT);
        } catch (javax.persistence.PersistenceException e) {
-               logger.warn("Could not find a persistence unit for: " + CS_AUTHZ_PERSISTENCE_UNIT);
+               logger.warn("Problem with the persistence unit for: " + CS_AUTHZ_PERSISTENCE_UNIT, e);
        }
 
         return result;
index 97d00a01d1d66b7b62f51a9d49362760a5bd5346..61ab30d52c172e7c1c90a185ff9312e3d074b95d 100644 (file)
@@ -13,7 +13,7 @@ http://java.sun.com/xml/ns/persistence/orm http://java.sun.com/xml/ns/persistenc
             <property name="hibernate.connection.driver_class" value="com.mysql.jdbc.Driver"/>
             <property name="hibernate.connection.username" value="test"/>
             <property name="hibernate.connection.password" value="test"/>
-            <property name="hibernate.connection.url" value="jdbc:mysql://localhost:3306/cspace"/-->
+            <property name="hibernate.connection.url" value="jdbc:mysql://${db.host}:3306/cspace"/-->
         </properties>
     </persistence-unit>
 </persistence>