Loading TOC...

tieredstorage.partitionTransfer

tieredstorage.partitionTransfer(
   $partition-db-id as (Number|String),
   $partition-name as String,
   $dst-db-id as (Number|String),
   [$options as String[]]
) as null

Summary

This function detaches forests in a partition from one database and attaches them to another. For details, see Transferring Partitions between Databases in the Administrator's Guide.

Parameters
$partition-db-id ID of the database from which the partition will be moved.
$partition-name Name of the partition.
$dst-db-id ID of the database to which the partition will be moved.
$options Whether or not data will be deleted. Valid option value:
timeout=N
Specifies the number of seconds to wait for a forest to re-open after a configuration is made during the transfer operation.

Example

const ts = require('/MarkLogic/tieredstorage');

ts.partitionTransfer(xdmp.database('srcDB'), '2017-October', xdmp.database('dstDB'));
   

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