Architecture overview
Last updated
Last updated
SnowDDL consists of the following components:
- pydantic model representing the desired state of an object in Snowflake account;
- collection of blueprints;
- used to parse YAML config files into blueprints, one parser class per object type;
- used to compare blueprints with existing metadata in Snowflake account and generate DDL commands to apply changes, one resolver class per object type;
- initialized with Snowflake connection and SnowDDL config, used to build, format and execute commands by resolvers.
These components are combined into "applications" with the following workflow:
Initialize an empty config.
Generate individual blueprints using parsers or custom Python code, add blueprints to config.
Validate config. If encountered any errors, display error messages and stop execution.
Open connection to Snowflake using .
Initialize engine using Snowflake connection and config.
Execute resolvers to generate DDL commands. Suggest or apply DDL commands, depending on settings.
Display statistics, close Snowflake connection and finish the application.
You may extend the default application to build even more sophisticated automation.
Default application used by is available on GitHub:
For example, is an extension of default application, which is available in .