Undelete and delete replication
When deleting something, a method will be called for an object
<?php
$article = new midgard_article(13);
$article->delete();
?>
This could - for the sake of undeleting deleted objects -
create a metadata parameter 'metadata.lastaction' =
'delete'.
Chain of actions
-
delete()- sets action to
delete
- sets action to
-
undelete()- sets action to
update
- sets action to
-
purge()- remove data, leave repligard data
- Repligard data is used only for replication, so load won't go up
At the moment replication is done based on cron. There is a tool that goes and checks all the data to see which tables have been changed and replicates based on that information.