Bug 778883 (SOA-1325)

Summary: Schema tool can't be used more than once while changing DB.
Product: [JBoss] JBoss Enterprise SOA Platform 4 Reporter: Pavel Macik <pmacik>
Component: ToolingAssignee: Julian Coleman <jcoleman>
Status: CLOSED NEXTRELEASE QA Contact:
Severity: high Docs Contact:
Priority: high    
Version: 4.2 CP03   
Target Milestone: ---   
Target Release: 4.2 CP04   
Hardware: Unspecified   
OS: Unspecified   
URL: http://jira.jboss.org/jira/browse/SOA-1325
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2009-06-12 09:18:03 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Pavel Macik 2009-05-21 13:54:18 UTC
Date of First Response: 2009-05-25 05:05:38
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): 

110,111c110,111
<                 <move file="@{file}" tofile="@{file}.orig"/>
<                 <move file="@{file}.orig" tofile="@{file}">
---
>                 <move file="@{file}" tofile="@{file}.rf-orig"/>
>                 <move file="@{file}.rf-orig" tofile="@{file}">
124,125c124,125
<                 <move file="@{file}" tofile="@{file}.orig"/>
<                 <move file="@{file}.orig" tofile="@{file}">
---
>                 <move file="@{file}" tofile="@{file}.rfex-orig"/>
>                 <move file="@{file}.rfex-orig" tofile="@{file}">

Comment 1 Pavel Macik 2009-05-21 13:55:04 UTC
Link: Added: This issue is related to SOA-1223


Comment 2 Julian Coleman 2009-05-25 09:05:38 UTC
Fixed with revision 3075 (4.2.0 branch) of:
  build-tools/resource/schema/eap/build.xml
  build-tools/resource/schema/esb/build.xml

Commit message:
  JIRA SOA-1325
  
  Use a different name for the reconfigure target temporary file (from pmacik).
  Work around ant's copy/move behaviour by checking for the existance of the
  db.properties file.


Comment 3 Dana Mison 2009-06-04 05:53:27 UTC
Release Note added:

The database schema tool can now be used more than once to change your database configuration.

Comment 4 Pavel Macik 2009-06-12 09:18:03 UTC
Verified in CR4