utils.rc.dtos.project_run
Module Contents
Classes
Attributes
- utils.rc.dtos.project_run.logger
- class utils.rc.dtos.project_run.ProjectRun(data={})
- __set_data(data={})
- static create_project_run(project_id: str, name: str, schedule: str, scenario_id: str = None, timeout_in_hours: int = None) ProjectRun
Creates the project run. Project run is like a cron job where you can run any scenario at a certain frequency
- Parameters:
project_id (str) – id of the project
name (str) – name of the project
schedule (str) – schedule at which it needs to run. its format is cron style. eg. 5 * * * * to run every hour at 5th minute
scenario_id (str, optional) – if of the scenario, if not provided, default scenario is taken. Defaults to None.
timeout_in_hours (int, optional) – timeout of the cronjob. Defaults to None.
- Returns:
project run object
- Return type:
- update_project_run(schedule: str, timeout_in_hours: int = None)
Updates the schedule of the project run
- Parameters:
schedule (str) – new schedule at which it should run
timeout_in_hours (int, optional) – timeout of the cronjob. Defaults to None.
- enable_project_run()
Enables the project run
- disable_project_run()
Enables the project run
- delete_project_run()
Deletes the project run
- publish_project_run()
Publish the project run metadata
- run_manually(variables: dict = None, job_run_id: str = None, delete_old_run_id: bool = False, run_async_mode: bool = True)
Manually run a project with the provided variables and job run ID. This method delegates the task to ProjectRunWrapper.run_manually. :param variables: A dictionary of variables to use during the project execution (default is None). :type variables: dict, optional :param These variables can be accessed within the project to customize its behavior.: :param job_run_id: The ID of the job run. If not provided (None), a new ID will be generated. :type job_run_id: str, optional :param delete_old_run_id: If True, the previous job run data associated with the provided job run ID will be deleted (default is False). :type delete_old_run_id: bool, optional :param Use with caution: :param as this will remove any historical data related to the specified job run ID.:
- Returns:
None
- static find_all_project_runs(project_id: str) List[ProjectRun]
Retrieves all the project runs associated with the project
- Parameters:
project_id (str) – id of the project
- Returns:
list of all project runs
- Return type:
List[ProjectRun]
- static find_project_run_by_name(project_id: str, name: str) ProjectRun
Finds project run by name
- Parameters:
project_id (str) – id of the project
name (str) – name of the project run
- Returns:
project run object, none if project run not found
- Return type:
- add_project_run_sync(entity_id: str, data_source_id: str, data_source_options: dict)
- find_all_project_run_entries()
Fetches all project run entries of the project run
- Returns:
all the project run entries
- Return type:
dict
- get_project_run_entry_details(entry_id)
- static get_recipe_run_logs(project_run_entry_id, transform_id)