I am using ha-jdbc to replicate databases as part of a JBoss setup. I would
like to use a FullSynchronizationStrategy to sync up databases when one has
been away, but the full sync strategy sets auto-commit to true and we have
BLOBs in our datasource, which prevents the sync up (everything worked fine
without the BLOBs). Since I cannot find a way to make it not do that, I am
looking into writing a custom synchronization strategy. This seems fairly
easy, but where should I put it? Is there any way to extend from the
outside, or do I need to make a custom jar with my own synchronization
strategy inside? Also, is there a way to make FullSynchronizationStrategy
not use auto-commit for the data?
Kind regards,
Fredrik
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
The FullSynchronizationStrategy only uses auto-commit for foreign key
manipulation. The actual insert/remove statements are executed with autocommit
off.
Regarding creating a custom implementation, the class attribute of <sync>
element in the ha-jdbc config lets you specify a custom implementation class.</sync>
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi All,
I am using ha-jdbc to replicate databases as part of a JBoss setup. I would
like to use a FullSynchronizationStrategy to sync up databases when one has
been away, but the full sync strategy sets auto-commit to true and we have
BLOBs in our datasource, which prevents the sync up (everything worked fine
without the BLOBs). Since I cannot find a way to make it not do that, I am
looking into writing a custom synchronization strategy. This seems fairly
easy, but where should I put it? Is there any way to extend from the
outside, or do I need to make a custom jar with my own synchronization
strategy inside? Also, is there a way to make FullSynchronizationStrategy
not use auto-commit for the data?
Kind regards,
Fredrik
The FullSynchronizationStrategy only uses auto-commit for foreign key
manipulation. The actual insert/remove statements are executed with autocommit
off.
Regarding creating a custom implementation, the class attribute of <sync>
element in the ha-jdbc config lets you specify a custom implementation class.</sync>