The process of synchronizing data between different instances of DBMS can be done in several ways, but usually through a process known as replication.
There are several products that provide a solid platform for replication, some free, some paid. The most important thing is to understand the motivator of this need, and then understand which architecture would meet your need.
Generally speaking, writing a Java program to replicate data between servers should be the solution chosen only if no available alternative solves your problem.
mirroring refers to exporting the local database to a server?
– João Reis
For example, in my local bank I have 30 new records. At one point I want to mirror these new records to my external bank.
– Rafael
The best method of data synchronization depends greatly on the expected result, the type of system and data, and the infrastructure available on both sides. I suggest explaining the purpose of this process. For example, if you are backing up there are certain alternatives (]see my answer here](http://answall.com/a/36716/227)); if it is to send certain registered records it would be possible to queue the items and send them asynchronously using any technology you want; and so on.
– utluiz