Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 11.0.1 (Français) » SQL Remote » SQL Remote Replication Design » SQL Remote replication design and set up


Understanding transaction log-based replication

SQL Remote replicates:

  • Committed changes   Changes that have been made to databases as recorded in their transaction log.

  • Changes that modify data that belong to publications   SQL Remote scans the transaction log for committed changes to rows that belong to publications, packages the SQL statements into messages, and sends them to the subscriber databases.

On the consolidated database, all committed transactions in the transaction log that belong to publications are sent periodically to the remote databases.

On the remote databases, all committed transactions in the transaction log that belong to publications are sent periodically to the consolidated database.

The SQL Remote publish and subscribe model. The remote and consolidated databases each subscribe to the other's publications.
The database server handles publications

The SQL Anywhere database server is the component that evaluates the publications and writes the information to the transaction log. The more publications you have, the more work the database server must do.

SQL Anywhere evaluates the subscription expression for each update made to a table that is part of a publication. It adds the value of the expression to the transaction log, both before and after the update. For a table that is part of more than one publication, the subscription expression is evaluated before and after the update for each publication.

The additional information in the transaction log can affect performance in the following cases:

  • Expensive expressions   When a subscription expression is expensive to evaluate, it can affect performance.

  • Many publications   When a table belongs to several publications, many expressions must be evaluated. In contrast, the number of subscriptions is irrelevant to the database server.

  • Many-valued expressions   Some expressions are many-valued, which can lead to additional information in the transaction log. This can affect on performance.

Subscriptions are handled by SQL Remote

SQL Remote is the component that carries out the replication of statements.

During the send phase, the SQL Remote Message Agent maps the current subscriptions to the publication information in the transaction log and generates the appropriate messages for each remote user. See The Message Agent (dbremote).

See also

Replicating INSERT and DELETE statements
Replicating UPDATE statements
Replicating procedures
Replicating triggers
Data definition statements
Data types