Class SystemOptionManager

java.lang.Object
org.apache.drill.exec.server.options.BaseOptionManager
org.apache.drill.exec.server.options.SystemOptionManager
All Implemented Interfaces:
AutoCloseable, Iterable<OptionValue>, OptionManager, OptionSet

public class SystemOptionManager extends BaseOptionManager implements AutoCloseable

OptionManager that holds options within DrillbitContext. Only one instance of this class exists per drillbit. Options set at the system level affect the entire system and persist between restarts.

All the system options are externalized into conf file. While adding a new system option a validator should be added and the default value for the option should be set in the conf files(example : drill-module.conf) under the namespace drill.exec.options.

The SystemOptionManager loads all the validators and the default values for the options are fetched from the config. The validators are populated with the default values fetched from the config. If the option is not set in the conf files config option is missing exception will be thrown.

If the option is set using ALTER, the value that is set will be returned. Else the default value that is loaded into validator from the config will be returned.