Loading TOC...

MarkLogic 10 Product Documentation
admin:forest-set-fast-data-max-size

admin:forest-set-fast-data-max-size(
   $config as element(configuration),
   $forest-id as xs:unsignedLong,
   $value as xs:unsignedInt
) as element(configuration)

Summary

This function sets the allowable size (in megabytes) for data to be kept by a forest in its fast data directory, or 0 for no limit.

Parameters
config A configuration specification, typically as returned from one of the Admin module functions.
forest-id The ID of the forest. For example, xdmp:forest("myForest") specifies the ID for a forest named "myForest".
value The allowable size (in megabytes) of the data to be kept by the forest in its fast-data-directory, or 0 for no limit.

Usage Notes

The server limits the size allocated to a forest to a portion of its configured fast-data directory. This limit is normally automatically calculated from the size of the fast data directory and the number of forests using it. When this parameter is not zero, it overrides the calculated limit. Recommended values are in the range of 16384 to 32768.

Example


  xquery version "1.0-ml";

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

  let $config := admin:get-configuration()
  return
  admin:forest-set-fast-data-max-size($config,
      admin:forest-get-id($config, "Documents"),
      16384)

      => sets the fast-data-max-size of the forest named "Documents" to
      16384 megabytes (16 gigabytes). Use admin:save-configuration to
      save the changes to the configuration or pass the configuration to
      other Admin API functions to make other changes.
  

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