catalog_workspace_content.
store_analytics_model_to_disk
store_analytics_model_to_disk(workspace_id: str, path: Path = Path.cwd())
Stores analytics model for a given workspace in directory hierarchy.This method does not tie the declarative analytics model to the workspace and organization, thus it is recommended for migration between workspaces. If you want to backup analytics model between workspaces or organizations, use store_analytics_model_to_disk.
The directory structure below shows the output for the path set to Path("analytics_model_location")
.
analytics_model_location
└── analytics_model
├── analytical_dashboards
│ └── analytical_dashboard.yaml
├── dashboard_plugins
│ └── dashboard_plugin.yaml
├── filter_contexts
│ └── filter_context.yaml
├── metrics
│ └── metric.yaml
└── visualization_objects
└── visualization_object.yaml
Parameters
name | type | description |
---|---|---|
workspace_id | str | Workspace identification string e.g. "demo" |
path | Optional[Path] | Path to the root of the layout directory. Defaults to Path.cwd(). |
Returns
None
Example
# Store the analytics model to disk
sdk.catalog_workspace_content.store_analytics_model_to_disk(
workspace_id="123",
path=Path.cwd()
)