Hide Forgot
Date of First Response: 2009-06-24 10:19:15 project_key: SOA If one use the schema tool for the first time, it works. When db is changed and the schema tool is used again, the schema tool is not aware of the db change it uses old one (db.properties file). The fix is below (on the /tools/schema/build.xml): @@ -2,6 +2,14 @@ <project name="SOA Database Configuration Script" default="execute" basedir="."> <property file="build.properties"/> + <macrodef name="restore"> + <attribute name="file"/> + <sequential> + <delete failonerror="false" file="@{file}"/> + <copy file="@{file}.orig" tofile="@{file}" overwrite="true"/> + </sequential> + </macrodef> + <target name="execute" depends="check.profile, ask.profile, exists.profile, check.clustered, check.backup, do.backup"> <input addproperty="source.dir" message="Please enter the database you wish to configure [db2, mssql, mysql, oracle9i, oracle10g, postgresql]:"/> @@ -129,14 +137,6 @@ </sequential> </macrodef> - <macrodef name="restore"> - <attribute name="file"/> - <sequential> - <delete failonerror="false" file="@{file}"/> - <copy file="@{file}.orig" tofile="@{file}" overwrite="true"/> - </sequential> - </macrodef> - <delete failonerror="false"> <fileset dir="${target.dir}/deploy"> <include name="hsqldb-ds.xml"/> @@ -370,6 +370,13 @@ <copy file="@{file}" tofile="@{file}.orig"/> </sequential> </macrodef> + + <if> + <available file="../console/management-esb/db.properties.orig"/> + <then> + <restore file="../console/management-esb/db.properties"/> + </then> + </if> <echo message="Backing up files ..."/> <backup file="${target.dir}/deploy/jbossesb.sar/esb.juddi.xml"/>
Link: Added: This issue related SOA-1325
Fixed with revision 3208 (4.3 branch) of: build-tools/resource/schema/tool/esb/build.xml Commit message: JIRA SOA-1223 Split the backup into two parts - one for the configuration directories and one for the common directories. Fixes a bug when the schema tool was used with different configurations and should also fix db.properties overwrite (SOA-1223). Tested by pmacik.
verified in CR2