brenuart wrote:
vleugels wrote:
Why: we're currently developing a master data editor for a billing application. The editor works on a staging application (mimicking the production deployment). If the changes work in the staging environment, we want to replicate the changes to the production environment (using the recorded SQL). The database schema ist identical of course.
Is this possible? Or a good idea at all?
Why not using two session factories (one per database) and JTA for disttributed transaction. Your changes will committed only if both databases accept them...
We dont need (nor want) one 2PC transaction context. Changes to the first dataset are tested (could take some time), and after succesfull testing the change would be replicated to production.
What we need is the change-set (in SQL or Object-Form). The most elegant solution (well, for me) would be to store the changed objects from the staging run, and later apply them to the production environment. SQL would be even simpler (just pipe the diff to sqlplus later on).
We need incremental changes, avoiding the replacement of the whole production data set.
Cheers,
Dirk