montague.interfaces¶
-
interface
montague.interfaces.
IConfigLoader
[source]¶ A config loader for a given config format. You do not have to implement app_config/server_config/filter_config. They must still be present, but can simply return NotImplementedError. In that case, Montague will extract the config from the config().
-
logging_config
(name)¶ Provides a dict suitable for passing to logging.config.dictConfig. It’s possible a config loader may only support a single logging config, which would be available under DEFAULT.
-
filter_config
(name)¶ Return the config for the specified filter. If name is montague.structs.DEFAULT, use the default name for the config format (such as ‘main’).
-
server_config
(name)¶ Return the config for the specified server. If name is montague.structs.DEFAULT, use the default name for the config format (such as ‘main’).
-
app_config
(name)¶ Return the config for the specified app. If name is montague.structs.DEFAULT, use the default name for the config format (such as ‘main’).
-
path
¶ Location of config data. Usually will be a filesystem path, but may be a URL, redis connection string, etc.
-
config
()¶ Returns the entire config as a dict in Montague standard format. Montague standard format has the following keys (all optional): global, application, composite, filter, server. Other than global, these keys should then contain name, config value pairs. Use DEFAULT for the default app/filter/server.
-