Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Database synchronization

Recently my clients have asked me if they can use they’re application remotely, disconnected from the local network and the company server.

One solution is to place the database in the cloud, but a connection to the database, and the cloud and an internet connection must be always available. There not always the case.

So my question is - Is there any database sync system, or a synchronization library so that I can work disconnected with local database and when I connect synchronize the changes I have made and receive changes others have made?

Update:

The application is under Windows (7/xp) ( for now )

It's in Delphi 2007 win32

All client need to have Read/Write access

All Clients have internet connection, but not always ON

Security is not critical, but the Sync service should encrypt the communication

When in the presence of the companies network the system should sync and use the Server Database and not the local one.

like image 295
Jlouro Avatar asked May 27 '12 10:05

Jlouro


People also ask

What is data synchronization example?

Let's see a simple example of data synchronization: Suppose we have added a new popular ringtone to one of the servers of a mobile service provider, so here, data synchronization means that all the service provider servers get identical sets of ringtones.

What is database synchronization SQL Server?

SQL Data Sync is a service that allows synchronizing data across multiple Azure SQL databases and on-premises SQL Server databases.

What is Data Sync used for?

Simplify and automate data movement – DataSync makes it easier to move data over the network between storage systems and services. DataSync automates both the management of data-transfer processes and the infrastructure required for high performance and secure data transfer.


3 Answers

You have a host of issues with thinking about such a solution. First, there are lots of possible solutions, such as:

  • Using database replication within a database, to mimic every update (like a "hot" backup)
  • Building an application to copy the database periodically (every night)
  • Using a third-party tool (which is what you are asking, I think)

With replication services, the connection does not have to always be up. Changes to the database are logged when the connection is not available and then applied when they can be sent.

However, there are lots of other issues when you leave a corporate network. What about security of the data and access rights? Do you have other options, such as making it easier to access the database from within the network? Do the users need only read-access to the database or read-write access? Would both versions need to be accessed at the same time. Would there be updates to both at the same time?

You may have other options that are more secure than just moving a database to the cloud.

like image 184
Gordon Linoff Avatar answered Sep 29 '22 10:09

Gordon Linoff


I believe RemObjects DataAbstract allows offline mode and synchronization by using what they call Briefcases. All your other requirements (security, encrypted connections, etc.) are also covered.

This is not a drop-in replacement, thought, and may need extensive rewrite/refactoring of your application. There are lots of upsides, thought; business rules can/should be enforced on the server (real security), scriptable business rules, multiplatform architecture, etc.

like image 44
Leonardo Herrera Avatar answered Sep 29 '22 12:09

Leonardo Herrera


There are some products available in the Java world (SymmetricDS lgpl license) - apart from actually being a working system it is documents how it achieved synchronization. Connects to any db with jdbc support. . There is a pro version but the user guide (downloadable pdf) gives you the db schema plus rules on push pull syncing. Useful if you want to build your own.

Btw there is a data replication so tag that would help.

like image 30
DavidG Avatar answered Sep 29 '22 12:09

DavidG