Loading TOC...


   $domain-id as xs:unsignedLong,
   $forest-id as xs:unsignedLong,
   $max-spawn as xs:unsignedLong
) as empty-sequence()


This function pushes pending replication updates (either retries or zero-day) for the specified forest on the current host. If any updates are found, a new task is spawned to call this function again. This continues until all pending replication updates have been processed.

domain-id The ID of the replicated domain.
forest-id The ID of the replicated forest.
max-spawn The limit to the number of doable spawns. If a task respawns itself too many times, a spawn will eventually fail with an exception.


  xquery version "1.0-ml"; 

  import module namespace flexrep = "http://marklogic.com/xdmp/flexible-replication" 
      at "/MarkLogic/flexrep.xqy";

  import module namespace admin = "http://marklogic.com/xdmp/admin" 
      at "/MarkLogic/admin.xqy";

  let $forest-id :=  
      admin:forest-get-id(admin:get-configuration(), "MasterForest")

      flexrep:push-local-forest(5864248273900832906, $forest-id)
  (: Pushes all pending replication updates from the "MasterForest" forest on the host. :)

Required Privileges


Stack Overflow iconStack Overflow: Get the most useful answers to questions from the MarkLogic community, or ask your own question.