Skip to main content

No project description provided

Project description

GoodData Pipelines

A high level library for automating the lifecycle of GoodData Cloud (GDC).

You can use the package to manage following resoursec in GDC:

  1. Provisioning (create, update, delete)
    • User profiles
    • User Groups
    • User/Group permissions
    • User Data Filters
    • Child workspaces (incl. Workspace Data Filter settings)
  2. [PLANNED]: Backup and restore of workspaces
  3. [PLANNED]: Custom fields management
    • extend the Logical Data Model of a child workspace

In case you are not interested in incorporating a library in your own program, but would like to use a ready-made script, consider having a look at GoodData Productivity Tools.

Provisioning

The entities can be managed either in full load or incremental way.

Full load means that the input data should represent the full and complete desired state of GDC after the script has finished. For example, you would include specification of all child workspaces you want to exist in GDC in the input data for workspace provisioning. Any workspaces present in GDC and not defined in the source data (i.e., your input) will be deleted.

On the other hand, the incremental load treats the source data as instructions for a specific change, e.g., a creation or a deletion of a specific workspace. You can specify which workspaces you would want to delete or create, while the rest of the workspaces already present in GDC will remain as they are, ignored by the provisioning script.

The provisioning module exposes Provisioner classes reflecting the different entities. The typical usage would involve importing the Provisioner class and the data input data model for the class and planned provisioning method:

import os
from csv import DictReader
from pathlib import Path

# Import the Entity Provisioner class and corresponing model from gooddata_pipelines library
from gooddata_pipelines import UserFullLoad, UserProvisioner

# Optional: you can set up logging and subscribe it to the Provisioner
from utils.logger import setup_logging

setup_logging()
logger = logging.getLogger(__name__)

# Create the Provisioner instance - you can also create the instance from a GDC yaml profile
provisioner = UserProvisioner(
    host=os.environ["GDC_HOSTNAME"], token=os.environ["GDC_AUTH_TOKEN"]
)

# Optional: subscribe to logs
provisioner.logger.subscribe(logger)

# Load your data from your data source
source_data_path: Path = Path("path/to/some.csv")
source_data_reader = DictReader(source_data_path.read_text().splitlines())
source_data = [row for row in source_data_reader]

# Validate your input data with
full_load_data: list[UserFullLoad] = UserFullLoad.from_list_of_dicts(
    source_data
)
provisioner.full_load(full_load_data)

Ready made scripts covering the basic use cases can be found here in the GoodData Productivity Tools repository

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

gooddata_pipelines-1.47.1.dev4.tar.gz (167.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

gooddata_pipelines-1.47.1.dev4-py3-none-any.whl (129.4 kB view details)

Uploaded Python 3

File details

Details for the file gooddata_pipelines-1.47.1.dev4.tar.gz.

File metadata

  • Download URL: gooddata_pipelines-1.47.1.dev4.tar.gz
  • Upload date:
  • Size: 167.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for gooddata_pipelines-1.47.1.dev4.tar.gz
Algorithm Hash digest
SHA256 45b1c17ce38f94f7917899b72c418720457008cfc2f8f18fed178fa8391d2521
MD5 69720c96c5ac9e7462996ecbe77b8605
BLAKE2b-256 2e8de6452d1bdb966b4d8aaf4e306c23e6853e53b5793b99e868538e0f587307

See more details on using hashes here.

File details

Details for the file gooddata_pipelines-1.47.1.dev4-py3-none-any.whl.

File metadata

File hashes

Hashes for gooddata_pipelines-1.47.1.dev4-py3-none-any.whl
Algorithm Hash digest
SHA256 6d0d2ec9f484019f44eaeda9f097caf2ec94e6a94ad560335df3eebc2ba74510
MD5 ce1644f9f845579ac5986e16370efea2
BLAKE2b-256 64f9dd81e22ec8c46e4bffed56ed9dd5db00304303a9771bea44d4176b4fd852

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page