Loading TOC...

MarkLogic 12 EA 1 Product Documentation
temporal:set-lsqt-automation

temporal:set-lsqt-automation(
   $temporal-collection as xs:string,
   $on as xs:boolean,
   [$period as xs:unsignedInt],
   [$lag as xs:unsignedInt]
) as empty-sequence()

Summary

This function sets whether Last Stable Query Time (LSQT) management is automatic. And, if enabled, how often LSQT is to be advanced.

For details on how to use LSQT, see Last Stable Query Time (LSQT) and Application-controlled System Time in the Temporal Developer's Guide

Parameters
temporal-collection The name of temporal collection
on Whether automation is turned on (true). The default is off (false).
period How often LSQT is advanced, in milliseconds.
lag How much LSQT is lagged behind the max system start time, in milliseconds.

Example


xquery version "1.0-ml";

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

temporal:set-lsqt-automation("temporalCollection",fn:true(),5000)
=>
(: Automtacially advance LSQT every 5000 ms :)

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