- Transfer data between different data structures.
- Contextualize data.
- Set up the required resources for an application, such as InField.
- Load static demo data.
Directory structure and naming standards
Establishing a directory structure and naming standard for modules and configuration files is vital to successfully deploying and administering CDF projects with the Cognite Toolkit.Module directory structure
Each module is implemented as a directory in the file system. The directory’s name describes the content or the purpose of the module. Use lowercase for the name and underscores to separate words. For example, a module that sets up the required resources to transfer asset data from a source system called “Scada” in the “Springfield” location could be named springfield_scada_asset_data_pipeline. To add more information, create a README.md file in the module directory. Modules contain YAML configuration files that describe the resources needed to solve the task, including access groups. The Cognite Toolkit requires that the YAML files are stored in subdirectories according to the resource type they describe. For an overview of the default resource hierarchy, see the reference section. Example module structure for a data pipeline:Resource configuration files (YAML)
To establish logical coherence across modules in Cognite Data Fusion, we highly recommend using the external IDs and following the naming conventions in your configuration files. The Cognite Toolkit accepts configurations that don’t follow these recommendations but will display warnings. The structure of the YAML resource configuration files matches the Cognite Data Fusion API specification. The required formats are described in the YAML configuration reference article. With a few exceptions, you can describe all resources as a list or a single instance in a YAML file: Option 1:Security
Access control should be self-contained within each module. You need to configure which roles (groups) each module requires and which resources the groups can access. Follow the principle of least privilege and allow each module to access only the information and resources necessary for its purpose. A module can have multiple groups, but those groups should not have access to resources defined outside of the module. Example:idscopes uses the external ID, while the API uses the internal ID. The Cognite Toolkit resolves the external ID to the internal ID before sending the request to the Cognite API to make the configuration transferrable between environments.