db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jørgen Løland (JIRA) <j...@apache.org>
Subject [jira] Commented: (DERBY-2872) Add Replication functionality to Derby
Date Fri, 06 Jul 2007 11:56:04 GMT

    [ https://issues.apache.org/jira/browse/DERBY-2872?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12510664
] 

Jørgen Løland commented on DERBY-2872:
--------------------------------------

I have had a good look at the code in the store layer now. The design sketches for this feature
are currently like this:

Master role:
-----------
When a Derby instance is told to be the master of a db 'repli_db', a replication service is
booted in the store layer. This service will set up a replication log buffer and network communication
with the slave. The db is then sent to the slave. From this point on, all log records that
are added to the log of 'repli_db' are also added to the replication log buffer. 

A replication log shipper (part of the replication service) will read log records from the
replication buffer and send these to the slave, e.g. at given time intervals. 

Slave role:
----------
As for the master role, a replication service will be booted in the store layer when a Derby
is told to be the slave of a db. The replication slave service will set up a network connection
with the master and receive a db backup. Recovery is started, and the slave will not leave
recovery until it is told to transform into a normal Derby. While in recovery mode, the slave
will redo all log records that are received from the master.


Comments on this preliminary design are very much welcome! 

> Add Replication functionality to Derby
> --------------------------------------
>
>                 Key: DERBY-2872
>                 URL: https://issues.apache.org/jira/browse/DERBY-2872
>             Project: Derby
>          Issue Type: New Feature
>          Components: Miscellaneous
>    Affects Versions: 10.4.0.0
>            Reporter: Jørgen Løland
>            Assignee: Jørgen Løland
>         Attachments: proof_of_concept_master.diff, proof_of_concept_master.stat, proof_of_concept_slave.diff,
proof_of_concept_slave.stat, replication_funcspec.html, replication_script.txt
>
>
> It would be nice to have replication functionality to Derby; many potential Derby users
seem to want this. The attached functional specification lists some initial thoughts for how
this feature may work.
> Dag Wanvik had a look at this functionality some months ago. He wrote a proof of concept
patch that enables replication by copying (using file system copy) and redoing the existing
Derby transaction log to the slave (unfortunately, I can not find the mail thread now).
> DERBY-2852 contains a patch that enables replication by sending dedicated logical log
records to the slave through a network connection and redoing these.
> Replication has been requested and discussed previously in multiple threads, including
these:
> http://mail-archives.apache.org/mod_mbox/db-derby-user/200504.mbox/%3c426E04C1.1070904@yahoo.de%3e
> http://www.nabble.com/Does-Derby-support-Transaction-Logging---t2626667.html

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message