databricks.labs.dqx.config_loader
RunConfigLoader Objects
class RunConfigLoader()
Class to handle loading of configuration from the installation.
load_config
def load_config(assume_user: bool = True,
product_name: str = "dqx") -> WorkspaceConfig
Load workspace configuration from the installation. The workspace config contains all run configs.
Arguments:
assume_user
- if True, assume user installationproduct_name
- name of the product
load_run_config
def load_run_config(run_config_name: str | None,
install_folder: str | None = None,
assume_user: bool = True,
product_name: str = "dqx") -> RunConfig
Load run configuration from the installation.
Arguments:
run_config_name
- Name of the run configuration to use.install_folder
- Custom workspace installation folder. Required if DQX is installed in a custom folder.assume_user
- Whether to assume a per-user installation when loading the run configuration (True as default, skipped if install_folder is provided).product_name
- Product/installation identifier used to resolve installation paths for config loading in install_folder is not provided ("dqx" as default).
get_installation
def get_installation(assume_user: bool,
product_name: str,
install_folder: str | None = None) -> Installation
Get the installation for the given product name.
Arguments:
assume_user
- if True, assume user installationproduct_name
- name of the productinstall_folder
- optional installation folder
get_custom_installation
@staticmethod
def get_custom_installation(ws: WorkspaceClient, product_name: str,
install_folder: str) -> Installation
Creates an Installation instance for a custom installation folder, similar to assume_user_home and assume_global. This ensures the custom folder is created in the workspace when the installation is accessed.
Arguments:
ws
- Databricks SDKWorkspaceClient
product_name
- The product nameinstall_folder
- The custom installation folder path
Returns:
An Installation instance for the custom folder