Loading TOC...


   config as element(configuration),
   foreign-cluster-id as (Number|String),
   database-ids as (Number|String)[]
) as Sequence


This function is executed on a replica cluster to return the replication configuration for the specified local database from the specified foreign master cluster.

config A configuration specification, typically as returned from one of the Admin module functions.
foreign-cluster-id The ID of the foreign master cluster.
database-ids The ID of the replica database on the local cluster.


  let admin = require("/MarkLogic/admin.xqy")
  let cfg = admin.getConfiguration()
  let dbid = admin.databaseGetId(cfg, "Documents")
  let cid = admin.clusterGetForeignClusterIds(cfg)
  admin.clusterGetForeignMasterDatabase(cfg, fn.head(cid), dbid)

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