pyegeria 5.4.0.28__py3-none-any.whl → 5.5.3.3__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of pyegeria might be problematic. Click here for more details.
- commands/__init__.py +24 -0
- commands/cat/Dr-Egeria_md-orig.py +2 -2
- commands/cat/collection_actions.py +197 -0
- commands/cat/dr_egeria_command_help.py +137 -38
- commands/cat/dr_egeria_jupyter.py +7 -7
- commands/cat/dr_egeria_md.py +10 -267
- commands/cat/exp_list_glossaries.py +11 -14
- commands/cat/get_asset_graph.py +37 -267
- commands/cat/{get_collection.py → get_collection_tree.py} +10 -18
- commands/cat/get_project_dependencies.py +14 -14
- commands/cat/get_project_structure.py +15 -14
- commands/cat/get_tech_type_elements.py +16 -116
- commands/cat/glossary_actions.py +145 -298
- commands/cat/list_assets.py +3 -11
- commands/cat/list_cert_types.py +17 -63
- commands/cat/list_collections.py +17 -139
- commands/cat/list_deployed_catalogs.py +15 -27
- commands/cat/list_deployed_database_schemas.py +27 -43
- commands/cat/list_deployed_databases.py +16 -31
- commands/cat/list_deployed_servers.py +35 -54
- commands/cat/list_glossaries.py +18 -17
- commands/cat/list_projects.py +10 -12
- commands/cat/list_tech_type_elements.py +21 -37
- commands/cat/list_tech_types.py +13 -25
- commands/cat/list_terms.py +38 -79
- commands/cat/list_todos.py +4 -11
- commands/cat/list_user_ids.py +3 -10
- commands/cat/my_reports.py +559 -0
- commands/cat/run_report.py +394 -0
- commands/cat/{list_format_set.py → run_report_orig.py} +136 -44
- commands/cli/egeria.py +182 -219
- commands/cli/egeria_cat.py +32 -59
- commands/cli/egeria_my.py +13 -0
- commands/cli/egeria_ops.py +69 -74
- commands/cli/egeria_tech.py +17 -93
- commands/{cat → deprecated}/list_data_designer.py +2 -4
- commands/{cat → deprecated}/list_data_structures_full.py +3 -6
- commands/deprecated/old_get_asset_graph.py +315 -0
- commands/my/__init__.py +0 -2
- commands/my/list_my_profile.py +27 -34
- commands/my/list_my_roles.py +1 -7
- commands/my/monitor_my_todos.py +1 -7
- commands/my/monitor_open_todos.py +6 -7
- commands/my/todo_actions.py +4 -5
- commands/ops/__init__.py +0 -2
- commands/ops/gov_server_actions.py +17 -21
- commands/ops/list_archives.py +17 -38
- commands/ops/list_catalog_targets.py +33 -40
- commands/ops/load_archive.py +14 -11
- commands/ops/{monitor_engine_activity_c.py → monitor_active_engine_activity.py} +51 -82
- commands/ops/{monitor_integ_daemon_status.py → monitor_daemon_status.py} +35 -55
- commands/ops/monitor_engine_activity.py +79 -77
- commands/ops/{monitor_gov_eng_status.py → monitor_engine_status.py} +10 -7
- commands/ops/monitor_platform_status.py +38 -50
- commands/ops/monitor_server_startup.py +6 -11
- commands/ops/monitor_server_status.py +7 -11
- commands/ops/orig_monitor_server_list.py +8 -8
- commands/ops/orig_monitor_server_status.py +1 -5
- commands/ops/refresh_integration_daemon.py +5 -5
- commands/ops/restart_integration_daemon.py +5 -5
- commands/ops/table_integ_daemon_status.py +6 -6
- commands/ops/x_engine_actions.py +7 -7
- commands/tech/__init__.py +0 -2
- commands/tech/{generic_actions.py → element_actions.py} +6 -11
- commands/tech/get_element_info.py +20 -29
- commands/tech/get_guid_info.py +23 -42
- commands/tech/get_tech_details.py +20 -35
- commands/tech/get_tech_type_template.py +28 -39
- commands/tech/list_all_om_type_elements.py +24 -30
- commands/tech/list_all_om_type_elements_x.py +22 -28
- commands/tech/list_all_related_elements.py +19 -28
- commands/tech/list_anchored_elements.py +22 -30
- commands/tech/list_asset_types.py +19 -24
- commands/tech/list_elements_by_classification_by_property_value.py +26 -32
- commands/tech/list_elements_by_property_value.py +19 -25
- commands/tech/list_elements_by_property_value_x.py +20 -28
- commands/tech/list_elements_for_classification.py +28 -41
- commands/tech/list_gov_action_processes.py +16 -27
- commands/tech/list_information_supply_chains.py +22 -30
- commands/tech/list_registered_services.py +14 -26
- commands/tech/list_related_elements_with_prop_value.py +15 -25
- commands/tech/list_related_specification.py +1 -4
- commands/tech/list_relationship_types.py +15 -25
- commands/tech/list_relationships.py +20 -36
- commands/tech/list_solution_blueprints.py +28 -33
- commands/tech/list_solution_components.py +23 -29
- commands/tech/list_solution_roles.py +21 -32
- commands/tech/list_tech_templates.py +51 -54
- commands/tech/list_valid_metadata_values.py +5 -9
- commands/tech/table_tech_templates.py +2 -6
- commands/tech/x_list_related_elements.py +1 -4
- examples/GeoSpatial Products Example.py +524 -0
- examples/Jupyter Notebooks/P-egeria-server-config.ipynb +2137 -0
- examples/Jupyter Notebooks/README.md +2 -0
- examples/Jupyter Notebooks/common/P-environment-check.ipynb +115 -0
- examples/Jupyter Notebooks/common/__init__.py +14 -0
- examples/Jupyter Notebooks/common/common-functions.ipynb +4694 -0
- examples/Jupyter Notebooks/common/environment-check.ipynb +52 -0
- examples/Jupyter Notebooks/common/globals.ipynb +184 -0
- examples/Jupyter Notebooks/common/globals.py +154 -0
- examples/Jupyter Notebooks/common/orig_globals.py +152 -0
- examples/format_sets/all_format_sets.json +910 -0
- examples/format_sets/custom_format_sets.json +268 -0
- examples/format_sets/subset_format_sets.json +187 -0
- examples/format_sets_save_load_example.py +291 -0
- examples/jacquard_data_sets.py +129 -0
- examples/output_formats_example.py +193 -0
- examples/test_jacquard_data_sets.py +54 -0
- examples/test_jacquard_data_sets_scenarios.py +94 -0
- md_processing/__init__.py +33 -24
- md_processing/command_dispatcher.py +33 -0
- md_processing/command_mapping.py +221 -0
- md_processing/data/commands/commands_data_designer.json +537 -0
- md_processing/data/commands/commands_external_reference.json +733 -0
- md_processing/data/commands/commands_feedback.json +155 -0
- md_processing/data/commands/commands_general.json +204 -0
- md_processing/data/commands/commands_glossary.json +218 -0
- md_processing/data/commands/commands_governance.json +3678 -0
- md_processing/data/commands/commands_product_manager.json +865 -0
- md_processing/data/commands/commands_project.json +642 -0
- md_processing/data/commands/commands_solution_architect.json +366 -0
- md_processing/data/commands.json +6489 -30060
- md_processing/data/{commands-working.json → commands_working.json} +9304 -13513
- md_processing/data/gened_report_specs.py +6584 -0
- md_processing/data/generated_format_sets.json +6533 -0
- md_processing/data/generated_format_sets_old.json +4137 -0
- md_processing/data/generated_format_sets_old.py +45 -0
- md_processing/dr_egeria.py +182 -0
- md_processing/md_commands/data_designer_commands.py +195 -583
- md_processing/md_commands/ext_ref_commands.py +530 -0
- md_processing/md_commands/feedback_commands.py +726 -0
- md_processing/md_commands/glossary_commands.py +106 -490
- md_processing/md_commands/governance_officer_commands.py +129 -18
- md_processing/md_commands/product_manager_commands.py +362 -115
- md_processing/md_commands/project_commands.py +351 -134
- md_processing/md_commands/solution_architect_commands.py +276 -232
- md_processing/md_commands/view_commands.py +295 -0
- md_processing/md_processing_utils/common_md_proc_utils.py +258 -166
- md_processing/md_processing_utils/common_md_utils.py +138 -43
- md_processing/md_processing_utils/determine_width.py +103 -0
- md_processing/md_processing_utils/extraction_utils.py +100 -39
- md_processing/md_processing_utils/gen_report_specs.py +643 -0
- md_processing/md_processing_utils/generate_dr_help.py +61 -33
- md_processing/md_processing_utils/generate_md_cmd_templates.py +20 -19
- md_processing/md_processing_utils/generate_md_templates.py +3 -12
- md_processing/md_processing_utils/md_processing_constants.py +1053 -72
- pyegeria/__init__.py +203 -158
- pyegeria/core/__init__.py +40 -0
- pyegeria/core/_base_platform_client.py +574 -0
- pyegeria/core/_base_server_client.py +573 -0
- pyegeria/{_exceptions_new.py → core/_exceptions.py} +62 -30
- pyegeria/{_globals.py → core/_globals.py} +14 -3
- pyegeria/core/_server_client.py +6073 -0
- pyegeria/{_validators.py → core/_validators.py} +7 -8
- pyegeria/core/config.py +654 -0
- pyegeria/{create_tech_guid_lists.py → core/create_tech_guid_lists.py} +0 -1
- pyegeria/core/load_config.py +37 -0
- pyegeria/{logging_configuration.py → core/logging_configuration.py} +1 -1
- pyegeria/core/mcp_adapter.py +144 -0
- pyegeria/core/mcp_server.py +212 -0
- pyegeria/core/utils.py +405 -0
- pyegeria/{_client.py → deprecated/_client.py} +24 -25
- pyegeria/{_deprecated_gov_engine.py → deprecated/_deprecated_gov_engine.py} +16 -16
- pyegeria/{classification_manager_omvs.py → deprecated/classification_manager_omvs.py} +1987 -1877
- pyegeria/{output_formatter.py → deprecated/output_formatter_with_machine_keys.py} +298 -45
- pyegeria/{runtime_manager_omvs.py → deprecated/runtime_manager_omvs.py} +155 -171
- pyegeria/{valid_metadata_omvs.py → deprecated/valid_metadata_omvs.py} +93 -93
- pyegeria/{x_action_author_omvs.py → deprecated/x_action_author_omvs.py} +2 -3
- pyegeria/egeria_cat_client.py +26 -70
- pyegeria/egeria_client.py +130 -93
- pyegeria/egeria_config_client.py +40 -46
- pyegeria/egeria_tech_client.py +141 -54
- pyegeria/models/__init__.py +150 -0
- pyegeria/{models.py → models/models.py} +156 -20
- pyegeria/omvs/__init__.py +84 -0
- pyegeria/omvs/action_author.py +342 -0
- pyegeria/omvs/actor_manager.py +5980 -0
- pyegeria/omvs/asset_catalog.py +842 -0
- pyegeria/omvs/asset_maker.py +2736 -0
- pyegeria/omvs/automated_curation.py +4403 -0
- pyegeria/omvs/classification_manager.py +11213 -0
- pyegeria/{collection_manager.py → omvs/collection_manager.py} +1334 -1160
- pyegeria/omvs/community_matters_omvs.py +468 -0
- pyegeria/{core_omag_server_config.py → omvs/core_omag_server_config.py} +157 -157
- pyegeria/{data_designer.py → omvs/data_designer.py} +1115 -660
- pyegeria/omvs/data_discovery.py +869 -0
- pyegeria/omvs/data_engineer.py +372 -0
- pyegeria/omvs/digital_business.py +1133 -0
- pyegeria/omvs/external_links.py +1752 -0
- pyegeria/omvs/feedback_manager.py +834 -0
- pyegeria/{full_omag_server_config.py → omvs/full_omag_server_config.py} +73 -69
- pyegeria/{glossary_manager.py → omvs/glossary_manager.py} +857 -519
- pyegeria/{governance_officer.py → omvs/governance_officer.py} +964 -468
- pyegeria/omvs/lineage_linker.py +314 -0
- pyegeria/omvs/location_arena.py +1525 -0
- pyegeria/omvs/metadata_expert.py +668 -0
- pyegeria/omvs/metadata_explorer_omvs.py +2943 -0
- pyegeria/omvs/my_profile.py +1042 -0
- pyegeria/omvs/notification_manager.py +358 -0
- pyegeria/omvs/people_organizer.py +394 -0
- pyegeria/{platform_services.py → omvs/platform_services.py} +113 -193
- pyegeria/omvs/product_manager.py +1825 -0
- pyegeria/omvs/project_manager.py +1907 -0
- pyegeria/omvs/reference_data.py +1140 -0
- pyegeria/omvs/registered_info.py +334 -0
- pyegeria/omvs/runtime_manager.py +2817 -0
- pyegeria/omvs/schema_maker.py +446 -0
- pyegeria/{server_operations.py → omvs/server_operations.py} +27 -26
- pyegeria/{solution_architect_omvs.py → omvs/solution_architect.py} +1886 -1505
- pyegeria/omvs/specification_properties.py +37 -0
- pyegeria/omvs/subject_area.py +1042 -0
- pyegeria/omvs/template_manager_omvs.py +236 -0
- pyegeria/omvs/time_keeper.py +1761 -0
- pyegeria/omvs/valid_metadata.py +3221 -0
- pyegeria/omvs/valid_metadata_lists.py +37 -0
- pyegeria/omvs/valid_type_lists.py +37 -0
- pyegeria/view/__init__.py +28 -0
- pyegeria/{_output_format_models.py → view/_output_format_models.py} +160 -24
- pyegeria/view/_output_formats.py +14 -0
- pyegeria/view/base_report_formats.py +2719 -0
- pyegeria/view/dr_egeria_reports.py +56 -0
- pyegeria/view/format_set_executor.py +397 -0
- pyegeria/{md_processing_utils.py → view/md_processing_utils.py} +5 -5
- pyegeria/{mermaid_utilities.py → view/mermaid_utilities.py} +2 -154
- pyegeria/view/output_formatter.py +1297 -0
- pyegeria-5.5.3.3.dist-info/METADATA +218 -0
- pyegeria-5.5.3.3.dist-info/RECORD +241 -0
- {pyegeria-5.4.0.28.dist-info → pyegeria-5.5.3.3.dist-info}/WHEEL +2 -1
- pyegeria-5.5.3.3.dist-info/entry_points.txt +103 -0
- pyegeria-5.5.3.3.dist-info/top_level.txt +4 -0
- commands/cat/.DS_Store +0 -0
- commands/cat/.env +0 -8
- commands/cat/README.md +0 -16
- commands/cat/debug_log +0 -1126
- commands/cat/debug_log.2025-08-18_11-34-38_088636.zip +0 -0
- commands/cat/list_categories.py +0 -192
- commands/cat/logs/pyegeria.log +0 -4
- commands/cli/debug_log +0 -0
- commands/cli/debug_log.log +0 -0
- commands/cli/txt_custom_v2.tcss +0 -19
- commands/my/README.md +0 -17
- commands/ops/README.md +0 -24
- commands/ops/logs/pyegeria.log +0 -0
- commands/ops/monitor_asset_events.py +0 -108
- commands/tech/README.md +0 -24
- md_processing/.DS_Store +0 -0
- md_processing/dr-egeria-outbox/Collections-2025-08-12-13-30-37.md +0 -163
- md_processing/dr-egeria-outbox/Collections-2025-08-12-13-35-58.md +0 -474
- md_processing/dr_egeria_inbox/Derive-Dr-Gov-Defs.md +0 -8
- md_processing/dr_egeria_inbox/Dr.Egeria Templates.md +0 -873
- md_processing/dr_egeria_inbox/arch_test.md +0 -57
- md_processing/dr_egeria_inbox/archive/dr_egeria_intro.md +0 -254
- md_processing/dr_egeria_inbox/archive/dr_egeria_intro_more_terms.md +0 -696
- md_processing/dr_egeria_inbox/archive/dr_egeria_intro_part1.md +0 -254
- md_processing/dr_egeria_inbox/archive/dr_egeria_intro_part2.md +0 -298
- md_processing/dr_egeria_inbox/archive/dr_egeria_intro_part3.md +0 -608
- md_processing/dr_egeria_inbox/archive/dr_egeria_intro_part4.md +0 -94
- md_processing/dr_egeria_inbox/archive/freddie_intro.md +0 -284
- md_processing/dr_egeria_inbox/archive/freddie_intro_orig.md +0 -275
- md_processing/dr_egeria_inbox/archive/test-term.md +0 -110
- md_processing/dr_egeria_inbox/cat_test.md +0 -100
- md_processing/dr_egeria_inbox/collections.md +0 -39
- md_processing/dr_egeria_inbox/data_designer_debug.log +0 -6
- md_processing/dr_egeria_inbox/data_designer_out.md +0 -60
- md_processing/dr_egeria_inbox/data_designer_search_test.md +0 -11
- md_processing/dr_egeria_inbox/data_field.md +0 -54
- md_processing/dr_egeria_inbox/data_spec.md +0 -77
- md_processing/dr_egeria_inbox/data_spec_test.md +0 -2406
- md_processing/dr_egeria_inbox/data_test.md +0 -179
- md_processing/dr_egeria_inbox/data_test2.md +0 -429
- md_processing/dr_egeria_inbox/data_test3.md +0 -462
- md_processing/dr_egeria_inbox/dr_egeria_data_designer_1.md +0 -124
- md_processing/dr_egeria_inbox/dr_egeria_intro_categories.md +0 -168
- md_processing/dr_egeria_inbox/dr_egeria_intro_part1.md +0 -280
- md_processing/dr_egeria_inbox/dr_egeria_intro_part2.md +0 -318
- md_processing/dr_egeria_inbox/dr_egeria_intro_part3.md +0 -1073
- md_processing/dr_egeria_inbox/dr_egeria_isc1.md +0 -44
- md_processing/dr_egeria_inbox/generated_help_report.md +0 -9
- md_processing/dr_egeria_inbox/glossary_creation_experiment.ipynb +0 -341
- md_processing/dr_egeria_inbox/glossary_list.md +0 -5
- md_processing/dr_egeria_inbox/glossary_search_test.md +0 -40
- md_processing/dr_egeria_inbox/glossary_test1.md +0 -324
- md_processing/dr_egeria_inbox/gov_def.md +0 -482
- md_processing/dr_egeria_inbox/gov_def2.md +0 -447
- md_processing/dr_egeria_inbox/img.png +0 -0
- md_processing/dr_egeria_inbox/product.md +0 -211
- md_processing/dr_egeria_inbox/rel.md +0 -8
- md_processing/dr_egeria_inbox/sb.md +0 -119
- md_processing/dr_egeria_inbox/solution-components.md +0 -136
- md_processing/dr_egeria_inbox/solution_blueprints.md +0 -118
- md_processing/dr_egeria_inbox/synonym_test.md +0 -42
- md_processing/dr_egeria_inbox/t2.md +0 -268
- md_processing/dr_egeria_outbox/.obsidian/app.json +0 -1
- md_processing/dr_egeria_outbox/.obsidian/appearance.json +0 -1
- md_processing/dr_egeria_outbox/.obsidian/community-plugins.json +0 -6
- md_processing/dr_egeria_outbox/.obsidian/core-plugins.json +0 -31
- md_processing/dr_egeria_outbox/.obsidian/plugins/calendar/data.json +0 -10
- md_processing/dr_egeria_outbox/.obsidian/plugins/calendar/main.js +0 -4459
- md_processing/dr_egeria_outbox/.obsidian/plugins/calendar/manifest.json +0 -10
- md_processing/dr_egeria_outbox/.obsidian/plugins/obsidian-kanban/data.json +0 -3
- md_processing/dr_egeria_outbox/.obsidian/plugins/obsidian-kanban/main.js +0 -153
- md_processing/dr_egeria_outbox/.obsidian/plugins/obsidian-kanban/manifest.json +0 -11
- md_processing/dr_egeria_outbox/.obsidian/plugins/obsidian-kanban/styles.css +0 -1
- md_processing/dr_egeria_outbox/.obsidian/plugins/obsidian-tasks-plugin/main.js +0 -500
- md_processing/dr_egeria_outbox/.obsidian/plugins/obsidian-tasks-plugin/manifest.json +0 -12
- md_processing/dr_egeria_outbox/.obsidian/plugins/obsidian-tasks-plugin/styles.css +0 -1
- md_processing/dr_egeria_outbox/.obsidian/plugins/templater-obsidian/main.js +0 -37
- md_processing/dr_egeria_outbox/.obsidian/plugins/templater-obsidian/manifest.json +0 -11
- md_processing/dr_egeria_outbox/.obsidian/plugins/templater-obsidian/styles.css +0 -220
- md_processing/dr_egeria_outbox/.obsidian/types.json +0 -28
- md_processing/dr_egeria_outbox/.obsidian/workspace.json +0 -220
- md_processing/dr_egeria_outbox/Untitled.canvas +0 -1
- md_processing/dr_egeria_outbox/friday/processed-2025-08-22 21:22-dr_egeria_intro_part1.md +0 -312
- md_processing/dr_egeria_outbox/friday/processed-2025-08-22 21:23-dr_egeria_intro_part1.md +0 -265
- md_processing/dr_egeria_outbox/friday/processed-2025-08-23 15:06-dr_egeria_intro_part1.md +0 -230
- md_processing/dr_egeria_outbox/friday/processed-2025-08-23 15:30-dr_egeria_intro_part1.md +0 -296
- md_processing/dr_egeria_outbox/friday/processed-2025-08-23 15:31-dr_egeria_intro_part1.md +0 -253
- md_processing/dr_egeria_outbox/friday/processed-2025-08-23 16:08-dr_egeria_intro_part2.md +0 -343
- md_processing/dr_egeria_outbox/friday/processed-2025-08-23 16:12-dr_egeria_intro_part2.md +0 -343
- md_processing/dr_egeria_outbox/monday/processed-2025-08-19 07:05-product.md +0 -426
- md_processing/dr_egeria_outbox/monday/processed-2025-08-19 07:56-product.md +0 -212
- md_processing/dr_egeria_outbox/monday/processed-2025-08-19 09:43-product.md +0 -201
- md_processing/dr_egeria_outbox/sunday/processed-2025-07-20 14:55-product.md +0 -77
- md_processing/dr_egeria_outbox/sunday/processed-2025-07-20 15:05-product.md +0 -75
- md_processing/dr_egeria_outbox/sunday/processed-2025-07-20 15:11-product.md +0 -74
- md_processing/dr_egeria_outbox/sunday/processed-2025-07-20 20:40-collections.md +0 -49
- md_processing/dr_egeria_outbox/thursday/processed-2025-07-17 15:00-Derive-Dr-Gov-Defs.md +0 -719
- md_processing/dr_egeria_outbox/thursday/processed-2025-07-17 20:13-Derive-Dr-Gov-Defs.md +0 -41
- md_processing/dr_egeria_outbox/thursday/processed-2025-07-17 20:14-Derive-Dr-Gov-Defs.md +0 -33
- md_processing/dr_egeria_outbox/thursday/processed-2025-07-17 20:50-Derive-Dr-Gov-Defs.md +0 -192
- md_processing/dr_egeria_outbox/thursday/processed-2025-07-17 22:08-gov_def2.md +0 -486
- md_processing/dr_egeria_outbox/thursday/processed-2025-07-17 22:10-gov_def2.md +0 -486
- md_processing/dr_egeria_outbox/thursday/processed-2025-07-18 08:53-gov_def2.md +0 -486
- md_processing/dr_egeria_outbox/thursday/processed-2025-07-18 08:54-gov_def2.md +0 -486
- md_processing/dr_egeria_outbox/thursday/processed-2025-07-18 09:03-gov_def2.md +0 -486
- md_processing/dr_egeria_outbox/thursday/processed-2025-07-18 09:06-gov_def2.md +0 -486
- md_processing/dr_egeria_outbox/thursday/processed-2025-07-18 09:10-gov_def2.md +0 -486
- md_processing/dr_egeria_outbox/tuesday/processed-2025-07-16 19:15-gov_def2.md +0 -527
- md_processing/dr_egeria_outbox/tuesday/processed-2025-07-17 12:08-gov_def2.md +0 -527
- md_processing/dr_egeria_outbox/tuesday/processed-2025-07-17 14:27-gov_def2.md +0 -485
- md_processing/dr_egeria_outbox/tuesday/processed-2025-08-19 10:55-product.md +0 -209
- md_processing/family_docs/Data Designer/Create_Data_Class.md +0 -164
- md_processing/family_docs/Data Designer/Create_Data_Dictionary.md +0 -30
- md_processing/family_docs/Data Designer/Create_Data_Field.md +0 -162
- md_processing/family_docs/Data Designer/Create_Data_Specification.md +0 -36
- md_processing/family_docs/Data Designer/Create_Data_Structure.md +0 -38
- md_processing/family_docs/Data Designer/View_Data_Classes.md +0 -78
- md_processing/family_docs/Data Designer/View_Data_Dictionaries.md +0 -78
- md_processing/family_docs/Data Designer/View_Data_Fields.md +0 -78
- md_processing/family_docs/Data Designer/View_Data_Specifications.md +0 -78
- md_processing/family_docs/Data Designer/View_Data_Structures.md +0 -78
- md_processing/family_docs/Data Designer.md +0 -842
- md_processing/family_docs/Digital Product Manager/Add_Member->Collection.md +0 -42
- md_processing/family_docs/Digital Product Manager/Attach_Collection->Resource.md +0 -36
- md_processing/family_docs/Digital Product Manager/Create_Agreement.md +0 -96
- md_processing/family_docs/Digital Product Manager/Create_Data_Sharing_Agreement.md +0 -72
- md_processing/family_docs/Digital Product Manager/Create_DigitalSubscription.md +0 -102
- md_processing/family_docs/Digital Product Manager/Create_Digital_Product.md +0 -134
- md_processing/family_docs/Digital Product Manager/Link_Agreement_Items.md +0 -60
- md_processing/family_docs/Digital Product Manager/Link_Contracts.md +0 -26
- md_processing/family_docs/Digital Product Manager/Link_Digital_Product_-_Digital_Product.md +0 -30
- md_processing/family_docs/Digital Product Manager/Link_Subscribers.md +0 -48
- md_processing/family_docs/Digital Product Manager.md +0 -668
- md_processing/family_docs/Glossary/Attach_Category_Parent.md +0 -18
- md_processing/family_docs/Glossary/Attach_Term-Term_Relationship.md +0 -26
- md_processing/family_docs/Glossary/Create_Category.md +0 -38
- md_processing/family_docs/Glossary/Create_Glossary.md +0 -42
- md_processing/family_docs/Glossary/Create_Term.md +0 -70
- md_processing/family_docs/Glossary.md +0 -206
- md_processing/family_docs/Governance Officer/Create_Business_Imperative.md +0 -106
- md_processing/family_docs/Governance Officer/Create_Certification_Type.md +0 -112
- md_processing/family_docs/Governance Officer/Create_Governance_Approach.md +0 -114
- md_processing/family_docs/Governance Officer/Create_Governance_Obligation.md +0 -114
- md_processing/family_docs/Governance Officer/Create_Governance_Principle.md +0 -114
- md_processing/family_docs/Governance Officer/Create_Governance_Procedure.md +0 -128
- md_processing/family_docs/Governance Officer/Create_Governance_Process.md +0 -122
- md_processing/family_docs/Governance Officer/Create_Governance_Processing_Purpose.md +0 -106
- md_processing/family_docs/Governance Officer/Create_Governance_Responsibility.md +0 -122
- md_processing/family_docs/Governance Officer/Create_Governance_Rule.md +0 -122
- md_processing/family_docs/Governance Officer/Create_Governance_Strategy.md +0 -106
- md_processing/family_docs/Governance Officer/Create_License_Type.md +0 -112
- md_processing/family_docs/Governance Officer/Create_Naming_Standard_Rule.md +0 -122
- md_processing/family_docs/Governance Officer/Create_Regulation_Article.md +0 -106
- md_processing/family_docs/Governance Officer/Create_Regulation_Definition.md +0 -118
- md_processing/family_docs/Governance Officer/Create_Security_Access_Control.md +0 -114
- md_processing/family_docs/Governance Officer/Create_Security_Group.md +0 -120
- md_processing/family_docs/Governance Officer/Create_Service_Level_Objectives.md +0 -122
- md_processing/family_docs/Governance Officer/Create_Threat_Definition.md +0 -106
- md_processing/family_docs/Governance Officer/Link_Governance_Controls.md +0 -32
- md_processing/family_docs/Governance Officer/Link_Governance_Drivers.md +0 -32
- md_processing/family_docs/Governance Officer/Link_Governance_Policies.md +0 -32
- md_processing/family_docs/Governance Officer/View_Governance_Definitions.md +0 -82
- md_processing/family_docs/Governance Officer.md +0 -2412
- md_processing/family_docs/Solution Architect/Create_Information_Supply_Chain.md +0 -70
- md_processing/family_docs/Solution Architect/Create_Solution_Blueprint.md +0 -44
- md_processing/family_docs/Solution Architect/Create_Solution_Component.md +0 -96
- md_processing/family_docs/Solution Architect/Create_Solution_Role.md +0 -66
- md_processing/family_docs/Solution Architect/Link_Information_Supply_Chain_Peers.md +0 -32
- md_processing/family_docs/Solution Architect/Link_Solution_Component_Peers.md +0 -32
- md_processing/family_docs/Solution Architect/View_Information_Supply_Chains.md +0 -32
- md_processing/family_docs/Solution Architect/View_Solution_Blueprints.md +0 -32
- md_processing/family_docs/Solution Architect/View_Solution_Components.md +0 -32
- md_processing/family_docs/Solution Architect/View_Solution_Roles.md +0 -32
- md_processing/family_docs/Solution Architect.md +0 -490
- md_processing/md_processing_utils/debug_log +0 -574
- md_processing/md_processing_utils/debug_log.log +0 -0
- md_processing/md_processing_utils/dr-egeria-help-2025-07-17T17:22:09.md +0 -2065
- md_processing/md_processing_utils/generated_help_terms.md +0 -842
- pyegeria/.DS_Store +0 -0
- pyegeria/README.md +0 -35
- pyegeria/_client_new.py +0 -1102
- pyegeria/_output_formats.py +0 -730
- pyegeria/asset_catalog_omvs.py +0 -864
- pyegeria/automated_curation_omvs.py +0 -3765
- pyegeria/config.py +0 -523
- pyegeria/egeria_my_client.py +0 -91
- pyegeria/feedback_manager_omvs.py +0 -4573
- pyegeria/load_config_orig.py +0 -218
- pyegeria/md_processing_helpers.py +0 -58
- pyegeria/md_processing_utils_orig.py +0 -1103
- pyegeria/metadata_explorer_omvs.py +0 -2326
- pyegeria/my_profile_omvs.py +0 -1022
- pyegeria/project_manager.py +0 -1591
- pyegeria/registered_info.py +0 -167
- pyegeria/template_manager_omvs.py +0 -1414
- pyegeria/utils.py +0 -256
- pyegeria-5.4.0.28.dist-info/METADATA +0 -77
- pyegeria-5.4.0.28.dist-info/RECORD +0 -343
- pyegeria-5.4.0.28.dist-info/entry_points.txt +0 -105
- /commands/cat/debug_log.log → /pyegeria/deprecated/__init__.py +0 -0
- /pyegeria/{_exceptions.py → deprecated/_exceptions.py} +0 -0
- /pyegeria/{collection_models.py → models/collection_models.py} +0 -0
- {pyegeria-5.4.0.28.dist-info → pyegeria-5.5.3.3.dist-info/licenses}/LICENSE +0 -0
pyegeria/project_manager.py
DELETED
|
@@ -1,1591 +0,0 @@
|
|
|
1
|
-
"""
|
|
2
|
-
PDX-License-Identifier: Apache-2.0
|
|
3
|
-
Copyright Contributors to the ODPi Egeria project.
|
|
4
|
-
|
|
5
|
-
Create, maintain and explore projects.
|
|
6
|
-
https://egeria-project.org/concepts/project
|
|
7
|
-
|
|
8
|
-
"""
|
|
9
|
-
|
|
10
|
-
import asyncio
|
|
11
|
-
|
|
12
|
-
from pyegeria._client_new import Client2
|
|
13
|
-
from pyegeria.config import settings as app_settings
|
|
14
|
-
from pyegeria.models import (SearchStringRequestBody, FilterRequestBody, GetRequestBody, NewElementRequestBody,
|
|
15
|
-
TemplateRequestBody)
|
|
16
|
-
from pyegeria.utils import body_slimmer, dynamic_catch
|
|
17
|
-
|
|
18
|
-
EGERIA_LOCAL_QUALIFIER = app_settings.User_Profile.egeria_local_qualifier
|
|
19
|
-
from pyegeria._globals import NO_ELEMENTS_FOUND, NO_PROJECTS_FOUND
|
|
20
|
-
|
|
21
|
-
PROJECT_TYPES = ["Project", "Campaign", "StudyProject", "Task", "PersonalProject"]
|
|
22
|
-
|
|
23
|
-
class ProjectManager(Client2):
|
|
24
|
-
"""
|
|
25
|
-
Create and manage projects. Projects may be organized in a hierarchy.
|
|
26
|
-
See https://egeria-project.org/types/1/0130-Projects
|
|
27
|
-
|
|
28
|
-
Attributes:
|
|
29
|
-
|
|
30
|
-
server_name: str
|
|
31
|
-
The name of the View Server to connect to.
|
|
32
|
-
platform_url : str
|
|
33
|
-
URL of the server platform to connect to
|
|
34
|
-
user_id : str
|
|
35
|
-
The identity of the user calling the method - this sets a default optionally used by the methods
|
|
36
|
-
when the user doesn't pass the user_id on a method call.
|
|
37
|
-
user_pwd: str
|
|
38
|
-
The password associated with the user_id. Defaults to None
|
|
39
|
-
"""
|
|
40
|
-
|
|
41
|
-
def __init__(
|
|
42
|
-
self,
|
|
43
|
-
view_server: str,
|
|
44
|
-
platform_url: str,
|
|
45
|
-
user_id: str,
|
|
46
|
-
user_pwd: str = None,
|
|
47
|
-
token: str = None,
|
|
48
|
-
):
|
|
49
|
-
self.view_server = view_server
|
|
50
|
-
self.platform_url = platform_url
|
|
51
|
-
self.user_id = user_id
|
|
52
|
-
self.user_pwd = user_pwd
|
|
53
|
-
self.project_command_base: str = (
|
|
54
|
-
f"/api/open-metadata/project-manager/projects"
|
|
55
|
-
)
|
|
56
|
-
Client2.__init__(self, view_server, platform_url, user_id, user_pwd, token)
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
def _generate_project_output(self):
|
|
60
|
-
pass
|
|
61
|
-
#
|
|
62
|
-
# Retrieving Projects= Information - https://egeria-project.org/concepts/project
|
|
63
|
-
#
|
|
64
|
-
async def _async_get_linked_projects(
|
|
65
|
-
self,
|
|
66
|
-
parent_guid: str,
|
|
67
|
-
project_status: str = None,
|
|
68
|
-
effective_time: str = None,
|
|
69
|
-
start_from: int = 0,
|
|
70
|
-
page_size: int = None,
|
|
71
|
-
) -> list | str:
|
|
72
|
-
"""Returns the list of projects that are linked off of the supplied element. Any relationship will do.
|
|
73
|
-
The request body is optional, but if supplied acts as a filter on project status. Async version.
|
|
74
|
-
|
|
75
|
-
Parameters
|
|
76
|
-
----------
|
|
77
|
-
parent_guid: str
|
|
78
|
-
The identity of the parent to find linked projects from.
|
|
79
|
-
project_status: str, optional
|
|
80
|
-
Optionally, filter results by project status.
|
|
81
|
-
effective_time: str, optional
|
|
82
|
-
Time at which to query for projects. Time format is "YYYY-MM-DDTHH:MM:SS" (ISO 8601).
|
|
83
|
-
|
|
84
|
-
start_from: int, [default=0], optional
|
|
85
|
-
When multiple pages of results are available, the page number to start from.
|
|
86
|
-
page_size: int, [default=None]
|
|
87
|
-
The number of items to return in a single page. If not specified, the default will be taken from
|
|
88
|
-
the class instance.
|
|
89
|
-
Returns
|
|
90
|
-
-------
|
|
91
|
-
List | str
|
|
92
|
-
|
|
93
|
-
A list of projects linked off of the supplied element filtered by project status and effective time.
|
|
94
|
-
|
|
95
|
-
Raises
|
|
96
|
-
------
|
|
97
|
-
|
|
98
|
-
InvalidParameterException
|
|
99
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
|
100
|
-
PropertyServerException
|
|
101
|
-
Raised by the server when an issue arises in processing a valid request
|
|
102
|
-
NotAuthorizedException
|
|
103
|
-
The principle specified by the user_id does not have authorization for the requested action
|
|
104
|
-
|
|
105
|
-
"""
|
|
106
|
-
|
|
107
|
-
if page_size is None:
|
|
108
|
-
page_size = self.page_size
|
|
109
|
-
|
|
110
|
-
body = {
|
|
111
|
-
"filter": project_status,
|
|
112
|
-
"effectiveTime": effective_time,
|
|
113
|
-
}
|
|
114
|
-
body_s = body_slimmer(body)
|
|
115
|
-
url = (
|
|
116
|
-
f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/project-manager/"
|
|
117
|
-
f"metadata-elements/{parent_guid}/projects?startFrom={start_from}&pageSize={page_size}"
|
|
118
|
-
)
|
|
119
|
-
|
|
120
|
-
resp = await self._async_make_request("POST", url, body_s)
|
|
121
|
-
return resp.json().get("elements", "No linked projects found")
|
|
122
|
-
|
|
123
|
-
def get_linked_projects(
|
|
124
|
-
self,
|
|
125
|
-
parent_guid: str,
|
|
126
|
-
project_status: str = None,
|
|
127
|
-
effective_time: str = None,
|
|
128
|
-
start_from: int = 0,
|
|
129
|
-
page_size: int = None,
|
|
130
|
-
) -> list | str:
|
|
131
|
-
"""Returns the list of projects that are linked off of the supplied element. Any relationship will do.
|
|
132
|
-
The request body is optional, but if supplied acts as a filter on project status.
|
|
133
|
-
|
|
134
|
-
Parameters
|
|
135
|
-
----------
|
|
136
|
-
parent_guid: str
|
|
137
|
-
The identity of the parent to find linked projects from
|
|
138
|
-
project_status: str, optional
|
|
139
|
-
Optionally, filter results by project status.
|
|
140
|
-
effective_time: str, optional
|
|
141
|
-
Time at which to query for projects. Time format is "YYYY-MM-DDTHH:MM:SS" (ISO 8601).
|
|
142
|
-
|
|
143
|
-
start_from: int, [default=0], optional
|
|
144
|
-
When multiple pages of results are available, the page number to start from.
|
|
145
|
-
page_size: int, [default=None]
|
|
146
|
-
The number of items to return in a single page. If not specified, the default will be taken from
|
|
147
|
-
the class instance.
|
|
148
|
-
Returns
|
|
149
|
-
-------
|
|
150
|
-
List | str
|
|
151
|
-
|
|
152
|
-
A list of projects linked off of the supplied element filtered by project status and effective time.
|
|
153
|
-
|
|
154
|
-
Raises
|
|
155
|
-
------
|
|
156
|
-
|
|
157
|
-
InvalidParameterException
|
|
158
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
|
159
|
-
PropertyServerException
|
|
160
|
-
Raised by the server when an issue arises in processing a valid request
|
|
161
|
-
NotAuthorizedException
|
|
162
|
-
The principle specified by the user_id does not have authorization for the requested action
|
|
163
|
-
|
|
164
|
-
"""
|
|
165
|
-
loop = asyncio.get_event_loop()
|
|
166
|
-
resp = loop.run_until_complete(
|
|
167
|
-
self._async_get_linked_projects(
|
|
168
|
-
parent_guid,
|
|
169
|
-
project_status,
|
|
170
|
-
effective_time,
|
|
171
|
-
start_from,
|
|
172
|
-
page_size,
|
|
173
|
-
)
|
|
174
|
-
)
|
|
175
|
-
return resp
|
|
176
|
-
|
|
177
|
-
async def _async_get_classified_projects(
|
|
178
|
-
self,
|
|
179
|
-
project_classification: str,
|
|
180
|
-
effective_time: str = None,
|
|
181
|
-
start_from: int = 0,
|
|
182
|
-
page_size: int = None,
|
|
183
|
-
) -> list | str:
|
|
184
|
-
"""Returns the list of projects with a particular classification. The name of the classification is
|
|
185
|
-
supplied in the request body. Examples of these classifications include StudyProject, PersonalProject,
|
|
186
|
-
Campaign or Task. There is also GlossaryProject and GovernanceProject. Async version.
|
|
187
|
-
|
|
188
|
-
Parameters
|
|
189
|
-
----------
|
|
190
|
-
project_classification: str
|
|
191
|
-
The project classification to search for.
|
|
192
|
-
effective_time: str, optional
|
|
193
|
-
Time at which to query for projects. Time format is "YYYY-MM-DDTHH:MM:SS" (ISO 8601).
|
|
194
|
-
|
|
195
|
-
start_from: int, [default=0], optional
|
|
196
|
-
When multiple pages of results are available, the page number to start from.
|
|
197
|
-
page_size: int, [default=None]
|
|
198
|
-
The number of items to return in a single page. If not specified, the default will be taken from
|
|
199
|
-
the class instance.
|
|
200
|
-
Returns
|
|
201
|
-
-------
|
|
202
|
-
List | str
|
|
203
|
-
|
|
204
|
-
A list of projects filtered by project classification, and effective time.
|
|
205
|
-
|
|
206
|
-
Raises
|
|
207
|
-
------
|
|
208
|
-
|
|
209
|
-
InvalidParameterException
|
|
210
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
|
211
|
-
PropertyServerException
|
|
212
|
-
Raised by the server when an issue arises in processing a valid request
|
|
213
|
-
NotAuthorizedException
|
|
214
|
-
The principle specified by the user_id does not have authorization for the requested action
|
|
215
|
-
|
|
216
|
-
"""
|
|
217
|
-
|
|
218
|
-
if page_size is None:
|
|
219
|
-
page_size = self.page_size
|
|
220
|
-
|
|
221
|
-
body = {
|
|
222
|
-
"filter": project_classification,
|
|
223
|
-
"effectiveTime": effective_time,
|
|
224
|
-
}
|
|
225
|
-
body_s = body_slimmer(body)
|
|
226
|
-
url = (
|
|
227
|
-
f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/project-manager/"
|
|
228
|
-
f"projects/by-classifications?startFrom={start_from}&pageSize={page_size}"
|
|
229
|
-
)
|
|
230
|
-
|
|
231
|
-
resp = await self._async_make_request("POST", url, body_s)
|
|
232
|
-
return resp.json()
|
|
233
|
-
|
|
234
|
-
def get_classified_projects(
|
|
235
|
-
self,
|
|
236
|
-
project_classification: str,
|
|
237
|
-
effective_time: str = None,
|
|
238
|
-
start_from: int = 0,
|
|
239
|
-
page_size: int = None,
|
|
240
|
-
) -> list | str:
|
|
241
|
-
"""Returns the list of projects with a particular classification. The name of the classification is
|
|
242
|
-
supplied in the request body. Examples of these classifications include StudyProject, PersonalProject,
|
|
243
|
-
Campaign or Task. There is also GlossaryProject and GovernanceProject.
|
|
244
|
-
|
|
245
|
-
Parameters
|
|
246
|
-
----------
|
|
247
|
-
project_classification: str
|
|
248
|
-
The project classification to search for.
|
|
249
|
-
effective_time: str, optional
|
|
250
|
-
Time at which to query for projects. Time format is "YYYY-MM-DDTHH:MM:SS" (ISO 8601).
|
|
251
|
-
|
|
252
|
-
start_from: int, [default=0], optional
|
|
253
|
-
When multiple pages of results are available, the page number to start from.
|
|
254
|
-
page_size: int, [default=None]
|
|
255
|
-
The number of items to return in a single page. If not specified, the default will be taken from
|
|
256
|
-
the class instance.
|
|
257
|
-
Returns
|
|
258
|
-
-------
|
|
259
|
-
List | str
|
|
260
|
-
|
|
261
|
-
A list of projects filtered by project classification, and effective time.
|
|
262
|
-
|
|
263
|
-
Raises
|
|
264
|
-
------
|
|
265
|
-
|
|
266
|
-
InvalidParameterException
|
|
267
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
|
268
|
-
PropertyServerException
|
|
269
|
-
Raised by the server when an issue arises in processing a valid request
|
|
270
|
-
NotAuthorizedException
|
|
271
|
-
The principle specified by the user_id does not have authorization for the requested action
|
|
272
|
-
|
|
273
|
-
"""
|
|
274
|
-
loop = asyncio.get_event_loop()
|
|
275
|
-
resp = loop.run_until_complete(
|
|
276
|
-
self._async_get_classified_projects(
|
|
277
|
-
project_classification,
|
|
278
|
-
effective_time,
|
|
279
|
-
start_from,
|
|
280
|
-
page_size,
|
|
281
|
-
)
|
|
282
|
-
)
|
|
283
|
-
return resp
|
|
284
|
-
|
|
285
|
-
async def _async_get_project_team(
|
|
286
|
-
self,
|
|
287
|
-
project_guid: str,
|
|
288
|
-
team_role: str = None,
|
|
289
|
-
effective_time: str = None,
|
|
290
|
-
start_from: int = 0,
|
|
291
|
-
page_size: int = None,
|
|
292
|
-
) -> list | str:
|
|
293
|
-
"""Returns the list of actors that are linked off of the project. This includes the project managers.
|
|
294
|
-
The optional request body allows a teamRole to be specified as a filter. To filter out the project managers,
|
|
295
|
-
specify ProjectManagement as the team role. See https://egeria-project.org/concepts/project for details.
|
|
296
|
-
Async version.
|
|
297
|
-
|
|
298
|
-
Parameters
|
|
299
|
-
----------
|
|
300
|
-
project_guid: str
|
|
301
|
-
The identity of the project to return team information about.
|
|
302
|
-
team_role: str, optional
|
|
303
|
-
team role to filter on. Project managers would be "ProjectManagement".
|
|
304
|
-
effective_time: str, optional
|
|
305
|
-
Time at which to query the team role. Time format is "YYYY-MM-DDTHH:MM:SS" (ISO 8601).
|
|
306
|
-
|
|
307
|
-
start_from: int, [default=0], optional
|
|
308
|
-
When multiple pages of results are available, the page number to start from.
|
|
309
|
-
page_size: int, [default=None]
|
|
310
|
-
The number of items to return in a single page. If not specified, the default will be taken from
|
|
311
|
-
the class instance.
|
|
312
|
-
|
|
313
|
-
Returns
|
|
314
|
-
-------
|
|
315
|
-
list | str
|
|
316
|
-
The list of actors linked off the project, including project managers Returns a string if none found.
|
|
317
|
-
|
|
318
|
-
Raises
|
|
319
|
-
------
|
|
320
|
-
InvalidParameterException
|
|
321
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values.
|
|
322
|
-
PropertyServerException
|
|
323
|
-
Raised by the server when an issue arises in processing a valid request.
|
|
324
|
-
NotAuthorizedException
|
|
325
|
-
The principle specified by the user_id does not have authorization for the requested action.
|
|
326
|
-
Notes
|
|
327
|
-
-----
|
|
328
|
-
"""
|
|
329
|
-
|
|
330
|
-
if page_size is None:
|
|
331
|
-
page_size = self.page_size
|
|
332
|
-
|
|
333
|
-
body = {effective_time: effective_time, "filter": team_role}
|
|
334
|
-
body_s = body_slimmer(body)
|
|
335
|
-
url = (
|
|
336
|
-
f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/project-manager/projects/"
|
|
337
|
-
f"{project_guid}/team?startFrom={start_from}&pageSize={page_size}"
|
|
338
|
-
)
|
|
339
|
-
|
|
340
|
-
resp = await self._async_make_request("POST", url, body_s)
|
|
341
|
-
|
|
342
|
-
result = resp.json().get("elements", NO_ELEMENTS_FOUND)
|
|
343
|
-
return result
|
|
344
|
-
|
|
345
|
-
def get_project_team(
|
|
346
|
-
self,
|
|
347
|
-
project_guid: str,
|
|
348
|
-
team_role: str = None,
|
|
349
|
-
effective_time: str = None,
|
|
350
|
-
start_from: int = 0,
|
|
351
|
-
page_size: int = None,
|
|
352
|
-
) -> list | str:
|
|
353
|
-
"""Returns the list of actors that are linked off of the project. This includes the project managers.
|
|
354
|
-
The optional request body allows a teamRole to be specified as a filter. To filter out the project managers,
|
|
355
|
-
specify ProjectManagement as the team role. See https://egeria-project.org/concepts/project for details.
|
|
356
|
-
Async version.
|
|
357
|
-
|
|
358
|
-
Parameters
|
|
359
|
-
----------
|
|
360
|
-
project_guid: str
|
|
361
|
-
The identity of the project to return team information about.
|
|
362
|
-
team_role: str, optional
|
|
363
|
-
team role to filter on. Project managers would be "ProjectManagement".
|
|
364
|
-
effective_time: str, optional
|
|
365
|
-
Time at which to query the team role. Time format is "YYYY-MM-DDTHH:MM:SS" (ISO 8601).
|
|
366
|
-
|
|
367
|
-
start_from: int, [default=0], optional
|
|
368
|
-
When multiple pages of results are available, the page number to start from.
|
|
369
|
-
page_size: int, [default=None]
|
|
370
|
-
The number of items to return in a single page. If not specified, the default will be taken from
|
|
371
|
-
the class instance.
|
|
372
|
-
|
|
373
|
-
Returns
|
|
374
|
-
-------
|
|
375
|
-
list | str
|
|
376
|
-
The list of actors linked off the project, including project managers Returns a string if none found.
|
|
377
|
-
|
|
378
|
-
Raises
|
|
379
|
-
------
|
|
380
|
-
InvalidParameterException
|
|
381
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values.
|
|
382
|
-
PropertyServerException
|
|
383
|
-
Raised by the server when an issue arises in processing a valid request.
|
|
384
|
-
NotAuthorizedException
|
|
385
|
-
The principle specified by the user_id does not have authorization for the requested action.
|
|
386
|
-
Notes
|
|
387
|
-
-----
|
|
388
|
-
"""
|
|
389
|
-
loop = asyncio.get_event_loop()
|
|
390
|
-
resp = loop.run_until_complete(
|
|
391
|
-
self._async_get_project_team(
|
|
392
|
-
project_guid,
|
|
393
|
-
team_role,
|
|
394
|
-
effective_time,
|
|
395
|
-
start_from,
|
|
396
|
-
page_size,
|
|
397
|
-
)
|
|
398
|
-
)
|
|
399
|
-
return resp
|
|
400
|
-
|
|
401
|
-
@dynamic_catch
|
|
402
|
-
async def _async_find_projects(
|
|
403
|
-
self,
|
|
404
|
-
search_string: str, classification_names: list[str] = None, metadata_element_types: list[str] = None,
|
|
405
|
-
starts_with: bool = False,
|
|
406
|
-
ends_with: bool = False,
|
|
407
|
-
ignore_case: bool = False,
|
|
408
|
-
start_from: int = 0,
|
|
409
|
-
page_size: int = 0,
|
|
410
|
-
output_format: str = "json", output_format_set: str | dict = None,
|
|
411
|
-
body: dict | SearchStringRequestBody = None
|
|
412
|
-
) -> list | str:
|
|
413
|
-
"""Returns the list of projects matching the search string.
|
|
414
|
-
The search string is located in the request body and is interpreted as a plain string.
|
|
415
|
-
The request parameters, startsWith, endsWith and ignoreCase can be used to allow a fuzzy search.
|
|
416
|
-
Async version.
|
|
417
|
-
|
|
418
|
-
Parameters
|
|
419
|
-
----------
|
|
420
|
-
search_string: str,
|
|
421
|
-
Search string to use to find matching projects. If the search string is '*' then all projects returned.
|
|
422
|
-
effective_time: str, [default=None], optional
|
|
423
|
-
Effective time of the query. If not specified will default to any time.
|
|
424
|
-
|
|
425
|
-
starts_with : bool, [default=False], optional
|
|
426
|
-
Starts with the supplied string.
|
|
427
|
-
ends_with : bool, [default=False], optional
|
|
428
|
-
Ends with the supplied string
|
|
429
|
-
ignore_case : bool, [default=False], optional
|
|
430
|
-
Ignore case when searching
|
|
431
|
-
start_from: int, [default=0], optional
|
|
432
|
-
When multiple pages of results are available, the page number to start from.
|
|
433
|
-
page_size: int, [default=None]
|
|
434
|
-
The number of items to return in a single page. If not specified, the default will be taken from
|
|
435
|
-
the class instance.
|
|
436
|
-
Returns
|
|
437
|
-
-------
|
|
438
|
-
List | str
|
|
439
|
-
|
|
440
|
-
A list of projects matching the search string. Returns a string if none found.
|
|
441
|
-
|
|
442
|
-
Raises
|
|
443
|
-
------
|
|
444
|
-
|
|
445
|
-
InvalidParameterException
|
|
446
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
|
447
|
-
PropertyServerException
|
|
448
|
-
Raised by the server when an issue arises in processing a valid request
|
|
449
|
-
NotAuthorizedException
|
|
450
|
-
The principle specified by the user_id does not have authorization for the requested action
|
|
451
|
-
|
|
452
|
-
"""
|
|
453
|
-
|
|
454
|
-
url = (
|
|
455
|
-
f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/project-manager/projects/"
|
|
456
|
-
f"by-search-string"
|
|
457
|
-
)
|
|
458
|
-
|
|
459
|
-
response = await self._async_find_request(url, _type="Project",
|
|
460
|
-
_gen_output=self._generate_project_output,
|
|
461
|
-
search_string=search_string,
|
|
462
|
-
classification_names=classification_names,
|
|
463
|
-
metadata_element_types=metadata_element_types,
|
|
464
|
-
starts_with=starts_with, ends_with=ends_with, ignore_case=ignore_case,
|
|
465
|
-
start_from=start_from, page_size=page_size,
|
|
466
|
-
output_format=output_format, output_format_set=output_format_set,
|
|
467
|
-
body=body)
|
|
468
|
-
|
|
469
|
-
return response
|
|
470
|
-
|
|
471
|
-
@dynamic_catch
|
|
472
|
-
def find_projects(
|
|
473
|
-
self,
|
|
474
|
-
search_string: str, classification_names: list[str] = None, metadata_element_types: list[str] = None,
|
|
475
|
-
starts_with: bool = False,
|
|
476
|
-
ends_with: bool = False,
|
|
477
|
-
ignore_case: bool = False,
|
|
478
|
-
start_from: int = 0,
|
|
479
|
-
page_size: int = 0,
|
|
480
|
-
output_format: str = "json", output_format_set: str | dict = None,
|
|
481
|
-
body: dict | SearchStringRequestBody = None
|
|
482
|
-
) -> list | str:
|
|
483
|
-
|
|
484
|
-
"""Returns the list of projects matching the search string.
|
|
485
|
-
The search string is located in the request body and is interpreted as a plain string.
|
|
486
|
-
The request parameters, startsWith, endsWith and ignoreCase can be used to allow a fuzzy search.
|
|
487
|
-
|
|
488
|
-
Parameters
|
|
489
|
-
----------
|
|
490
|
-
search_string: str,
|
|
491
|
-
Search string to use to find matching projects. If the search string is '*' then all projects returned.
|
|
492
|
-
effective_time: str, [default=None], optional
|
|
493
|
-
Effective time of the query. If not specified will default to any time.
|
|
494
|
-
|
|
495
|
-
starts_with : bool, [default=False], optional
|
|
496
|
-
Starts with the supplied string.
|
|
497
|
-
ends_with : bool, [default=False], optional
|
|
498
|
-
Ends with the supplied string
|
|
499
|
-
ignore_case : bool, [default=False], optional
|
|
500
|
-
Ignore case when searching
|
|
501
|
-
start_from: int, [default=0], optional
|
|
502
|
-
When multiple pages of results are available, the page number to start from.
|
|
503
|
-
page_size: int, [default=None]
|
|
504
|
-
The number of items to return in a single page. If not specified, the default will be taken from
|
|
505
|
-
the class instance.
|
|
506
|
-
Returns
|
|
507
|
-
-------
|
|
508
|
-
List | str
|
|
509
|
-
|
|
510
|
-
A list of projects matching the search string. Returns a string if none found.
|
|
511
|
-
|
|
512
|
-
Raises
|
|
513
|
-
------
|
|
514
|
-
|
|
515
|
-
InvalidParameterException
|
|
516
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
|
517
|
-
PropertyServerException
|
|
518
|
-
Raised by the server when an issue arises in processing a valid request
|
|
519
|
-
NotAuthorizedException
|
|
520
|
-
The principle specified by the user_id does not have authorization for the requested action
|
|
521
|
-
|
|
522
|
-
"""
|
|
523
|
-
loop = asyncio.get_event_loop()
|
|
524
|
-
resp = loop.run_until_complete(
|
|
525
|
-
self._async_find_projects(
|
|
526
|
-
search_string,
|
|
527
|
-
classification_names,
|
|
528
|
-
metadata_element_types,
|
|
529
|
-
starts_with,
|
|
530
|
-
ends_with,
|
|
531
|
-
ignore_case,
|
|
532
|
-
start_from,
|
|
533
|
-
page_size,
|
|
534
|
-
output_format,
|
|
535
|
-
output_format_set,
|
|
536
|
-
body,
|
|
537
|
-
)
|
|
538
|
-
)
|
|
539
|
-
|
|
540
|
-
return resp
|
|
541
|
-
|
|
542
|
-
@dynamic_catch
|
|
543
|
-
async def _async_get_projects_by_name(
|
|
544
|
-
self, filter_string: str = None, classification_names: list[str] = None,
|
|
545
|
-
body: dict | FilterRequestBody = None,
|
|
546
|
-
start_from: int = 0, page_size: int = 0,
|
|
547
|
-
output_format: str = 'JSON',
|
|
548
|
-
output_format_set: str | dict = None) -> list | str:
|
|
549
|
-
url = f"{self.project_command_base}/by-name"
|
|
550
|
-
|
|
551
|
-
response = await self._async_get_name_request(url, _type="Projects",
|
|
552
|
-
_gen_output=self._generate_projects_output,
|
|
553
|
-
filter_string=filter_string,
|
|
554
|
-
classification_names=classification_names,
|
|
555
|
-
start_from=start_from, page_size=page_size,
|
|
556
|
-
output_format=output_format, output_format_set=output_format_set,
|
|
557
|
-
body=body)
|
|
558
|
-
|
|
559
|
-
return response
|
|
560
|
-
|
|
561
|
-
@dynamic_catch
|
|
562
|
-
def get_projects_by_name(
|
|
563
|
-
self, filter_string: str = None, classification_names: list[str] = None,
|
|
564
|
-
body: dict | FilterRequestBody = None,
|
|
565
|
-
start_from: int = 0, page_size: int = 0,
|
|
566
|
-
output_format: str = 'JSON',
|
|
567
|
-
output_format_set: str | dict = None) -> list | str:
|
|
568
|
-
|
|
569
|
-
loop = asyncio.get_event_loop()
|
|
570
|
-
resp = loop.run_until_complete(
|
|
571
|
-
self._async_get_projects_by_name(
|
|
572
|
-
filter_string,
|
|
573
|
-
classification_names,
|
|
574
|
-
body,
|
|
575
|
-
start_from,
|
|
576
|
-
page_size,
|
|
577
|
-
output_format,
|
|
578
|
-
output_format_set,
|
|
579
|
-
)
|
|
580
|
-
)
|
|
581
|
-
return resp
|
|
582
|
-
|
|
583
|
-
@dynamic_catch
|
|
584
|
-
async def _async_get_project_by_guid(self, project_guid: str, element_type: str = None,
|
|
585
|
-
body: dict | GetRequestBody = None,
|
|
586
|
-
output_format: str = 'JSON',
|
|
587
|
-
output_format_set: str | dict = None) -> dict | str:
|
|
588
|
-
"""Return the properties of a specific project. Async version.
|
|
589
|
-
|
|
590
|
-
Parameters
|
|
591
|
-
----------
|
|
592
|
-
project_guid: str,
|
|
593
|
-
unique identifier of the collection.
|
|
594
|
-
element_type: str, default = None, optional
|
|
595
|
-
type of collection - Collection, DataSpec, Agreement, etc.
|
|
596
|
-
body: dict | GetRequestBody, optional, default = None
|
|
597
|
-
full request body.
|
|
598
|
-
output_format: str, default = "JSON"
|
|
599
|
-
- one of "DICT", "MERMAID" or "JSON"
|
|
600
|
-
output_format_set: str | dict, optional, default = None
|
|
601
|
-
The desired output columns/fields to include.
|
|
602
|
-
|
|
603
|
-
Returns
|
|
604
|
-
-------
|
|
605
|
-
dict | str
|
|
606
|
-
|
|
607
|
-
A JSON dict representing the specified collection. Returns a string if none found.
|
|
608
|
-
|
|
609
|
-
Raises
|
|
610
|
-
------
|
|
611
|
-
|
|
612
|
-
InvalidParameterException
|
|
613
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
|
614
|
-
PropertyServerException
|
|
615
|
-
Raised by the server when an issue arises in processing a valid request
|
|
616
|
-
NotAuthorizedException
|
|
617
|
-
The principle specified by the user_id does not have authorization for the requested action
|
|
618
|
-
|
|
619
|
-
Notes
|
|
620
|
-
----
|
|
621
|
-
Body sample:
|
|
622
|
-
{
|
|
623
|
-
"class": "GetRequestBody",
|
|
624
|
-
"asOfTime": "{{$isoTimestamp}}",
|
|
625
|
-
"effectiveTime": "{{$isoTimestamp}}",
|
|
626
|
-
"forLineage": false,
|
|
627
|
-
"forDuplicateProcessing": false
|
|
628
|
-
}
|
|
629
|
-
"""
|
|
630
|
-
|
|
631
|
-
url = (f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/project-manager/projects/"
|
|
632
|
-
f"{project_guid}")
|
|
633
|
-
type = element_type if element_type else "Collection"
|
|
634
|
-
|
|
635
|
-
response = await self._async_get_guid_request(url, _type=type,
|
|
636
|
-
_gen_output=self._generate_collection_output,
|
|
637
|
-
output_format=output_format, output_format_set=output_format_set,
|
|
638
|
-
body=body)
|
|
639
|
-
|
|
640
|
-
return response
|
|
641
|
-
|
|
642
|
-
@dynamic_catch
|
|
643
|
-
def get_project_by_guid(self, project_guid: str, element_type: str = None,
|
|
644
|
-
body: dict | GetRequestBody = None,
|
|
645
|
-
output_format: str = 'JSON',
|
|
646
|
-
output_format_set: str | dict = None) -> dict | str:
|
|
647
|
-
"""Return the properties of a specific project.
|
|
648
|
-
|
|
649
|
-
Parameters
|
|
650
|
-
----------
|
|
651
|
-
project_guid: str,
|
|
652
|
-
unique identifier of the collection.
|
|
653
|
-
element_type: str, default = None, optional
|
|
654
|
-
type of collection - Collection, DataSpec, Agreement, etc.
|
|
655
|
-
body: dict | GetRequestBody, optional, default = None
|
|
656
|
-
full request body.
|
|
657
|
-
output_format: str, default = "JSON"
|
|
658
|
-
- one of "DICT", "MERMAID" or "JSON"
|
|
659
|
-
output_format_set: str | dict, optional, default = None
|
|
660
|
-
The desired output columns/fields to include.
|
|
661
|
-
|
|
662
|
-
Returns
|
|
663
|
-
-------
|
|
664
|
-
dict | str
|
|
665
|
-
|
|
666
|
-
A JSON dict representing the specified collection. Returns a string if none found.
|
|
667
|
-
|
|
668
|
-
Raises
|
|
669
|
-
------
|
|
670
|
-
|
|
671
|
-
InvalidParameterException
|
|
672
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
|
673
|
-
PropertyServerException
|
|
674
|
-
Raised by the server when an issue arises in processing a valid request
|
|
675
|
-
NotAuthorizedException
|
|
676
|
-
The principle specified by the user_id does not have authorization for the requested action
|
|
677
|
-
|
|
678
|
-
Notes
|
|
679
|
-
----
|
|
680
|
-
Body sample:
|
|
681
|
-
{
|
|
682
|
-
"class": "GetRequestBody",
|
|
683
|
-
"asOfTime": "{{$isoTimestamp}}",
|
|
684
|
-
"effectiveTime": "{{$isoTimestamp}}",
|
|
685
|
-
"forLineage": false,
|
|
686
|
-
"forDuplicateProcessing": false
|
|
687
|
-
}
|
|
688
|
-
"""
|
|
689
|
-
loop = asyncio.get_event_loop()
|
|
690
|
-
resp = loop.run_until_complete(
|
|
691
|
-
self._async_get_project_by_guid(project_guid, element_type, body, output_format, output_format_set )
|
|
692
|
-
)
|
|
693
|
-
|
|
694
|
-
return resp
|
|
695
|
-
|
|
696
|
-
@dynamic_catch
|
|
697
|
-
async def _async_get_project_graph(
|
|
698
|
-
self,
|
|
699
|
-
project_guid: str,
|
|
700
|
-
element_type: str = None,
|
|
701
|
-
body: dict | GetRequestBody = None,
|
|
702
|
-
output_format: str = 'JSON',
|
|
703
|
-
output_format_set: str | dict = None,
|
|
704
|
-
) -> dict | str:
|
|
705
|
-
"""Return the mermaid graph of a specific project. Async version.
|
|
706
|
-
|
|
707
|
-
Parameters
|
|
708
|
-
----------
|
|
709
|
-
project_guid: str,
|
|
710
|
-
unique identifier of the project.
|
|
711
|
-
body: dict | GetRequestBody, optional, default = None
|
|
712
|
-
full request body.
|
|
713
|
-
|
|
714
|
-
Returns
|
|
715
|
-
-------
|
|
716
|
-
str
|
|
717
|
-
|
|
718
|
-
A mermaid markdown string representing the graph of the project.
|
|
719
|
-
Raises
|
|
720
|
-
------
|
|
721
|
-
|
|
722
|
-
InvalidParameterException
|
|
723
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
|
724
|
-
PropertyServerException
|
|
725
|
-
Raised by the server when an issue arises in processing a valid request
|
|
726
|
-
NotAuthorizedException
|
|
727
|
-
The principle specified by the user_id does not have authorization for the requested action
|
|
728
|
-
|
|
729
|
-
"""
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
url = (f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/project-manager/pr"
|
|
733
|
-
f"ojects/{project_guid}/graph")
|
|
734
|
-
|
|
735
|
-
response = await self._async_get_guid_request(url, _type=element_type,
|
|
736
|
-
_gen_output=self._generate_project_output,
|
|
737
|
-
output_format=output_format, output_format_set=output_format_set,
|
|
738
|
-
body=body)
|
|
739
|
-
|
|
740
|
-
return response
|
|
741
|
-
|
|
742
|
-
@dynamic_catch
|
|
743
|
-
def get_project_graph(
|
|
744
|
-
self,
|
|
745
|
-
project_guid: str,
|
|
746
|
-
element_type: str = None,
|
|
747
|
-
body: dict | GetRequestBody = None,
|
|
748
|
-
output_format: str = 'JSON',
|
|
749
|
-
output_format_set: str | dict = None,
|
|
750
|
-
) -> dict | str:
|
|
751
|
-
"""Return the mermaid graph of a specific project. Async version.
|
|
752
|
-
|
|
753
|
-
Parameters
|
|
754
|
-
----------
|
|
755
|
-
project_guid: str,
|
|
756
|
-
unique identifier of the project.
|
|
757
|
-
body: dict | GetRequestBody, optional, default = None
|
|
758
|
-
full request body.
|
|
759
|
-
|
|
760
|
-
Returns
|
|
761
|
-
-------
|
|
762
|
-
str
|
|
763
|
-
|
|
764
|
-
A mermaid markdown string representing the graph of the project.
|
|
765
|
-
Raises
|
|
766
|
-
------
|
|
767
|
-
|
|
768
|
-
InvalidParameterException
|
|
769
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
|
770
|
-
PropertyServerException
|
|
771
|
-
Raised by the server when an issue arises in processing a valid request
|
|
772
|
-
NotAuthorizedException
|
|
773
|
-
The principle specified by the user_id does not have authorization for the requested action
|
|
774
|
-
|
|
775
|
-
"""
|
|
776
|
-
loop = asyncio.get_event_loop()
|
|
777
|
-
resp = loop.run_until_complete(
|
|
778
|
-
self._async_get_project_graph(project_guid, element_type, body, output_format, output_format_set)
|
|
779
|
-
)
|
|
780
|
-
|
|
781
|
-
return resp
|
|
782
|
-
|
|
783
|
-
#
|
|
784
|
-
# Create project methods
|
|
785
|
-
#
|
|
786
|
-
@dynamic_catch
|
|
787
|
-
async def _async_create_project(
|
|
788
|
-
self,
|
|
789
|
-
body: dict | NewElementRequestBody,
|
|
790
|
-
) -> str:
|
|
791
|
-
"""Create project: https://egeria-project.org/concepts/project Async version.
|
|
792
|
-
|
|
793
|
-
Parameters
|
|
794
|
-
----------.
|
|
795
|
-
body: dict
|
|
796
|
-
A dict representing the details of the project to create. To create different kinds of projects,
|
|
797
|
-
set the initial_classifications in the body to be, for instance, "PersonalProject" or "Campaign".
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
Returns
|
|
801
|
-
-------
|
|
802
|
-
str - the guid of the created project
|
|
803
|
-
|
|
804
|
-
Raises
|
|
805
|
-
------
|
|
806
|
-
InvalidParameterException
|
|
807
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
|
808
|
-
PropertyServerException
|
|
809
|
-
Raised by the server when an issue arises in processing a valid request
|
|
810
|
-
NotAuthorizedException
|
|
811
|
-
The principle specified by the user_id does not have authorization for the requested action
|
|
812
|
-
Notes
|
|
813
|
-
-----
|
|
814
|
-
|
|
815
|
-
Body structure like:
|
|
816
|
-
{
|
|
817
|
-
"class": "NewElementRequestBody",
|
|
818
|
-
"anchorGUID" : "anchor GUID, if set then isOwnAnchor=false",
|
|
819
|
-
"isOwnAnchor" : False,
|
|
820
|
-
"parentGUID" : "parent GUID, if set, set all parameters beginning 'parent'",
|
|
821
|
-
"parentRelationshipTypeName" : "open metadata type name",
|
|
822
|
-
"parentAtEnd1": True,
|
|
823
|
-
"initialClassifications" : {
|
|
824
|
-
"Folder" : {
|
|
825
|
-
"class": "FolderProperties"
|
|
826
|
-
}
|
|
827
|
-
},
|
|
828
|
-
"projectProperties": {
|
|
829
|
-
"class" : "ProjectProperties",
|
|
830
|
-
"qualifiedName": "Must provide a unique name here",
|
|
831
|
-
"identifier" : "Add business identifier",
|
|
832
|
-
"name" : "Add display name here",
|
|
833
|
-
"description" : "Add description of the project here",
|
|
834
|
-
"projectStatus": "Add appropriate valid value for type",
|
|
835
|
-
"projectPhase" : "Add appropriate valid value for phase",
|
|
836
|
-
"projectHealth" : "Add appropriate valid value for health",
|
|
837
|
-
"startDate" : "date/time",
|
|
838
|
-
"plannedEndDate" : "date/time"
|
|
839
|
-
}
|
|
840
|
-
}
|
|
841
|
-
|
|
842
|
-
"""
|
|
843
|
-
|
|
844
|
-
|
|
845
|
-
url = f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/project-manager/projects"
|
|
846
|
-
|
|
847
|
-
return await self._async_create_element_body_request(body, ["ProjectProperties"], body)
|
|
848
|
-
|
|
849
|
-
@dynamic_catch
|
|
850
|
-
def create_project(
|
|
851
|
-
self,
|
|
852
|
-
body: dict | NewElementRequestBody,
|
|
853
|
-
) -> str:
|
|
854
|
-
"""Create project: https://egeria-project.org/concepts/project
|
|
855
|
-
|
|
856
|
-
Parameters
|
|
857
|
-
----------.
|
|
858
|
-
body: dict
|
|
859
|
-
A dict representing the details of the project to create.
|
|
860
|
-
|
|
861
|
-
Returns
|
|
862
|
-
-------
|
|
863
|
-
str - the guid of the created collection
|
|
864
|
-
|
|
865
|
-
Raises
|
|
866
|
-
------
|
|
867
|
-
InvalidParameterException
|
|
868
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
|
869
|
-
PropertyServerException
|
|
870
|
-
Raised by the server when an issue arises in processing a valid request
|
|
871
|
-
NotAuthorizedException
|
|
872
|
-
The principle specified by the user_id does not have authorization for the requested action
|
|
873
|
-
|
|
874
|
-
Notes
|
|
875
|
-
-----
|
|
876
|
-
Body structure like:
|
|
877
|
-
{
|
|
878
|
-
"anchorGUID" : "anchor GUID, if set then isOwnAnchor=false",
|
|
879
|
-
"isOwnAnchor" : False,
|
|
880
|
-
"parentGUID" : "parent GUID, if set, set all parameters beginning 'parent'",
|
|
881
|
-
"parentRelationshipTypeName" : "open metadata type name",
|
|
882
|
-
"parentAtEnd1": True,
|
|
883
|
-
"projectProperties": {
|
|
884
|
-
"class" : "ProjectProperties",
|
|
885
|
-
"qualifiedName": "Must provide a unique name here",
|
|
886
|
-
"identifier" : "Add business identifier",
|
|
887
|
-
"name" : "Add display name here",
|
|
888
|
-
"description" : "Add description of the project here",
|
|
889
|
-
"projectStatus": "Add appropriate valid value for type",
|
|
890
|
-
"projectPhase" : "Add appropriate valid value for phase",
|
|
891
|
-
"projectHealth" : "Add appropriate valid value for health",
|
|
892
|
-
"startDate" : "date/time",
|
|
893
|
-
"plannedEndDate" : "date/time"
|
|
894
|
-
}
|
|
895
|
-
}
|
|
896
|
-
|
|
897
|
-
"""
|
|
898
|
-
loop = asyncio.get_event_loop()
|
|
899
|
-
resp = loop.run_until_complete(
|
|
900
|
-
self._async_create_project(body)
|
|
901
|
-
)
|
|
902
|
-
return resp
|
|
903
|
-
|
|
904
|
-
@dynamic_catch
|
|
905
|
-
async def _async_create_project_from_template(
|
|
906
|
-
self,
|
|
907
|
-
body: dict | TemplateRequestBody,
|
|
908
|
-
) -> str:
|
|
909
|
-
"""Create a new metadata element to represent a project using an existing metadata element as a template.
|
|
910
|
-
The template defines additional classifications and relationships that should be added to the new project.
|
|
911
|
-
Async version.
|
|
912
|
-
|
|
913
|
-
Parameters
|
|
914
|
-
----------
|
|
915
|
-
|
|
916
|
-
body: dict
|
|
917
|
-
A dict representing the details of the collection to create.
|
|
918
|
-
|
|
919
|
-
|
|
920
|
-
Returns
|
|
921
|
-
-------
|
|
922
|
-
str - the guid of the created project.
|
|
923
|
-
|
|
924
|
-
Raises
|
|
925
|
-
------
|
|
926
|
-
InvalidParameterException
|
|
927
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
|
928
|
-
PropertyServerException
|
|
929
|
-
Raised by the server when an issue arises in processing a valid request
|
|
930
|
-
NotAuthorizedException
|
|
931
|
-
The principle specified by the user_id does not have authorization for the requested action
|
|
932
|
-
|
|
933
|
-
Notes
|
|
934
|
-
-----
|
|
935
|
-
JSON Structure looks like:
|
|
936
|
-
{
|
|
937
|
-
"class": "TemplateRequestBody",
|
|
938
|
-
"anchorGUID": "anchor GUID, if set then isOwnAnchor=false",
|
|
939
|
-
"isOwnAnchor": false,
|
|
940
|
-
"parentGUID": "parent GUID, if set, set all parameters beginning 'parent'",
|
|
941
|
-
"parentRelationshipTypeName": "open metadata type name",
|
|
942
|
-
"parentAtEnd1": true,
|
|
943
|
-
"templateGUID": "template GUID",
|
|
944
|
-
"replacementProperties": {
|
|
945
|
-
"class": "ElementProperties",
|
|
946
|
-
"propertyValueMap" : {
|
|
947
|
-
"propertyName" : {
|
|
948
|
-
"class": "PrimitiveTypePropertyValue",
|
|
949
|
-
"typeName": "string",
|
|
950
|
-
"primitiveTypeCategory" : "OM_PRIMITIVE_TYPE_STRING",
|
|
951
|
-
"primitiveValue" : "value of property"
|
|
952
|
-
}
|
|
953
|
-
}
|
|
954
|
-
},
|
|
955
|
-
"placeholderPropertyValues" : {
|
|
956
|
-
"placeholderProperty1Name" : "property1Value",
|
|
957
|
-
"placeholderProperty2Name" : "property2Value"
|
|
958
|
-
}
|
|
959
|
-
}
|
|
960
|
-
|
|
961
|
-
|
|
962
|
-
"""
|
|
963
|
-
|
|
964
|
-
url = f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/project-manager/projects/from-template"
|
|
965
|
-
return await self._async_create_element_from_template(url, body)
|
|
966
|
-
|
|
967
|
-
@dynamic_catch
|
|
968
|
-
def create_project_from_template(
|
|
969
|
-
self,
|
|
970
|
-
body: dict,
|
|
971
|
-
) -> str:
|
|
972
|
-
"""Create a new metadata element to represent a project using an existing metadata element as a template.
|
|
973
|
-
The template defines additional classifications and relationships that should be added to the new project.
|
|
974
|
-
|
|
975
|
-
Parameters
|
|
976
|
-
----------
|
|
977
|
-
|
|
978
|
-
body: dict
|
|
979
|
-
A dict representing the details of the collection to create.
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
Returns
|
|
983
|
-
-------
|
|
984
|
-
str - the guid of the created project.
|
|
985
|
-
|
|
986
|
-
Raises
|
|
987
|
-
------
|
|
988
|
-
InvalidParameterException
|
|
989
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
|
990
|
-
PropertyServerException
|
|
991
|
-
Raised by the server when an issue arises in processing a valid request
|
|
992
|
-
NotAuthorizedException
|
|
993
|
-
The principle specified by the user_id does not have authorization for the requested action
|
|
994
|
-
|
|
995
|
-
Notes
|
|
996
|
-
-----
|
|
997
|
-
JSON Structure looks like:
|
|
998
|
-
{
|
|
999
|
-
"class": "TemplateRequestBody",
|
|
1000
|
-
"anchorGUID": "anchor GUID, if set then isOwnAnchor=false",
|
|
1001
|
-
"isOwnAnchor": false,
|
|
1002
|
-
"parentGUID": "parent GUID, if set, set all parameters beginning 'parent'",
|
|
1003
|
-
"parentRelationshipTypeName": "open metadata type name",
|
|
1004
|
-
"parentAtEnd1": true,
|
|
1005
|
-
"templateGUID": "template GUID",
|
|
1006
|
-
"replacementProperties": {
|
|
1007
|
-
"class": "ElementProperties",
|
|
1008
|
-
"propertyValueMap" : {
|
|
1009
|
-
"propertyName" : {
|
|
1010
|
-
"class": "PrimitiveTypePropertyValue",
|
|
1011
|
-
"typeName": "string",
|
|
1012
|
-
"primitiveTypeCategory" : "OM_PRIMITIVE_TYPE_STRING",
|
|
1013
|
-
"primitiveValue" : "value of property"
|
|
1014
|
-
}
|
|
1015
|
-
}
|
|
1016
|
-
},
|
|
1017
|
-
"placeholderPropertyValues" : {
|
|
1018
|
-
"placeholderProperty1Name" : "property1Value",
|
|
1019
|
-
"placeholderProperty2Name" : "property2Value"
|
|
1020
|
-
}
|
|
1021
|
-
}
|
|
1022
|
-
"""
|
|
1023
|
-
loop = asyncio.get_event_loop()
|
|
1024
|
-
resp = loop.run_until_complete(self._async_create_project_from_template(body))
|
|
1025
|
-
return resp
|
|
1026
|
-
|
|
1027
|
-
#
|
|
1028
|
-
#
|
|
1029
|
-
#
|
|
1030
|
-
|
|
1031
|
-
async def _async_update_project(
|
|
1032
|
-
self,
|
|
1033
|
-
project_guid: str,
|
|
1034
|
-
qualified_name: str = None,
|
|
1035
|
-
identifier: str = None,
|
|
1036
|
-
display_name: str = None,
|
|
1037
|
-
description: str = None,
|
|
1038
|
-
project_status: str = None,
|
|
1039
|
-
project_phase: str = None,
|
|
1040
|
-
project_health: str = None,
|
|
1041
|
-
start_date: str = None,
|
|
1042
|
-
planned_end_date: str = None,
|
|
1043
|
-
replace_all_props: bool = False,
|
|
1044
|
-
) -> None:
|
|
1045
|
-
"""Update the properties of a project. Async Version.
|
|
1046
|
-
|
|
1047
|
-
Parameters
|
|
1048
|
-
----------
|
|
1049
|
-
project_guid: str
|
|
1050
|
-
Unique identifier for the project.
|
|
1051
|
-
qualified_name: str, optional, defaults to None
|
|
1052
|
-
The unique identifier of the project.
|
|
1053
|
-
identifier: str
|
|
1054
|
-
A project identifier.
|
|
1055
|
-
display_name: str
|
|
1056
|
-
The display name of the element. Will also be used as the basis of the qualified_name.
|
|
1057
|
-
description: str
|
|
1058
|
-
A description of the collection.
|
|
1059
|
-
project_status: str, optional
|
|
1060
|
-
The project status
|
|
1061
|
-
project_phase: str, optional
|
|
1062
|
-
Project phase as defined in valid values
|
|
1063
|
-
project_health: str, optional
|
|
1064
|
-
Project health as defined in valid values
|
|
1065
|
-
start_date: str, optional, defaults to None
|
|
1066
|
-
Start date of the project in ISO 8601 string format.
|
|
1067
|
-
planned_end_date: str, optional, defaults to None
|
|
1068
|
-
Planned completion date in ISO 8601 string format.
|
|
1069
|
-
replace_all_props: bool, optional, defaults to False
|
|
1070
|
-
If True, then all the properties of the project will be replaced with the specified properties.
|
|
1071
|
-
|
|
1072
|
-
Returns
|
|
1073
|
-
-------
|
|
1074
|
-
str - the guid of the created project task
|
|
1075
|
-
|
|
1076
|
-
Raises
|
|
1077
|
-
------
|
|
1078
|
-
InvalidParameterException
|
|
1079
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
|
1080
|
-
PropertyServerException
|
|
1081
|
-
Raised by the server when an issue arises in processing a valid request
|
|
1082
|
-
NotAuthorizedException
|
|
1083
|
-
The principle specified by the user_id does not have authorization for the requested action
|
|
1084
|
-
"""
|
|
1085
|
-
|
|
1086
|
-
replace_all_props_s = str(replace_all_props).lower()
|
|
1087
|
-
url = (
|
|
1088
|
-
f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/project-manager/projects/{project_guid}/"
|
|
1089
|
-
f"update?replaceAllProperties={replace_all_props_s}"
|
|
1090
|
-
)
|
|
1091
|
-
|
|
1092
|
-
body = {
|
|
1093
|
-
"class": "ProjectProperties",
|
|
1094
|
-
"qualifiedName": qualified_name,
|
|
1095
|
-
"identifier": identifier,
|
|
1096
|
-
"name": display_name,
|
|
1097
|
-
"description": description,
|
|
1098
|
-
"projectStatus": project_status,
|
|
1099
|
-
"projectPhase": project_phase,
|
|
1100
|
-
"projectHealth": project_health,
|
|
1101
|
-
"startDate": start_date,
|
|
1102
|
-
"plannedEndDate": planned_end_date,
|
|
1103
|
-
}
|
|
1104
|
-
body_s = body_slimmer(body)
|
|
1105
|
-
await self._async_make_request("POST", url, body_s)
|
|
1106
|
-
return
|
|
1107
|
-
|
|
1108
|
-
def update_project(
|
|
1109
|
-
self,
|
|
1110
|
-
project_guid: str,
|
|
1111
|
-
qualified_name: str = None,
|
|
1112
|
-
identifier: str = None,
|
|
1113
|
-
display_name: str = None,
|
|
1114
|
-
description: str = None,
|
|
1115
|
-
project_status: str = None,
|
|
1116
|
-
project_phase: str = None,
|
|
1117
|
-
project_health: str = None,
|
|
1118
|
-
start_date: str = None,
|
|
1119
|
-
planned_end_date: str = None,
|
|
1120
|
-
replace_all_props: bool = False,
|
|
1121
|
-
) -> None:
|
|
1122
|
-
"""Update the properties of a project.
|
|
1123
|
-
|
|
1124
|
-
Parameters
|
|
1125
|
-
----------
|
|
1126
|
-
project_guid: str
|
|
1127
|
-
Unique identifier for the project.
|
|
1128
|
-
qualified_name: str, optional, defaults to None
|
|
1129
|
-
The unique identifier of the project.
|
|
1130
|
-
identifier: str
|
|
1131
|
-
A project identifier.
|
|
1132
|
-
display_name: str
|
|
1133
|
-
The display name of the element. Will also be used as the basis of the qualified_name.
|
|
1134
|
-
description: str
|
|
1135
|
-
A description of the collection.
|
|
1136
|
-
project_status: str, optional
|
|
1137
|
-
The project status
|
|
1138
|
-
project_phase: str, optional
|
|
1139
|
-
Project phase as defined in valid values
|
|
1140
|
-
project_health: str, optional
|
|
1141
|
-
Project health as defined in valid values
|
|
1142
|
-
start_date: str, optional, defaults to None
|
|
1143
|
-
Start date of the project in ISO 8601 string format.
|
|
1144
|
-
planned_end_date: str, optional, defaults to None
|
|
1145
|
-
Planned completion date in ISO 8601 string format.
|
|
1146
|
-
replace_all_props: bool, optional, defaults to False
|
|
1147
|
-
If True, then all the properties of the project will be replaced with the specified properties.
|
|
1148
|
-
|
|
1149
|
-
Returns
|
|
1150
|
-
-------
|
|
1151
|
-
str - the guid of the created project task
|
|
1152
|
-
|
|
1153
|
-
Raises
|
|
1154
|
-
------
|
|
1155
|
-
InvalidParameterException
|
|
1156
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
|
1157
|
-
PropertyServerException
|
|
1158
|
-
Raised by the server when an issue arises in processing a valid request
|
|
1159
|
-
NotAuthorizedException
|
|
1160
|
-
The principle specified by the user_id does not have authorization for the requested action
|
|
1161
|
-
"""
|
|
1162
|
-
loop = asyncio.get_event_loop()
|
|
1163
|
-
loop.run_until_complete(
|
|
1164
|
-
self._async_update_project(
|
|
1165
|
-
project_guid,
|
|
1166
|
-
qualified_name,
|
|
1167
|
-
identifier,
|
|
1168
|
-
display_name,
|
|
1169
|
-
description,
|
|
1170
|
-
project_status,
|
|
1171
|
-
project_phase,
|
|
1172
|
-
project_health,
|
|
1173
|
-
start_date,
|
|
1174
|
-
planned_end_date,
|
|
1175
|
-
replace_all_props,
|
|
1176
|
-
)
|
|
1177
|
-
)
|
|
1178
|
-
return
|
|
1179
|
-
|
|
1180
|
-
async def _async_delete_project(
|
|
1181
|
-
self,
|
|
1182
|
-
project_guid: str, cascade: bool = False
|
|
1183
|
-
) -> None:
|
|
1184
|
-
"""Delete a project. It is detected from all parent elements. Async version
|
|
1185
|
-
|
|
1186
|
-
Parameters
|
|
1187
|
-
----------
|
|
1188
|
-
project_guid: str
|
|
1189
|
-
The guid of the project to update.
|
|
1190
|
-
cascade: bool, optional, defaults to False
|
|
1191
|
-
If true, then all anchored elements will be deleted.
|
|
1192
|
-
|
|
1193
|
-
Returns
|
|
1194
|
-
-------
|
|
1195
|
-
Nothing
|
|
1196
|
-
|
|
1197
|
-
Raises
|
|
1198
|
-
------
|
|
1199
|
-
InvalidParameterException
|
|
1200
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
|
1201
|
-
PropertyServerException
|
|
1202
|
-
Raised by the server when an issue arises in processing a valid request
|
|
1203
|
-
NotAuthorizedException
|
|
1204
|
-
The principle specified by the user_id does not have authorization for the requested action
|
|
1205
|
-
|
|
1206
|
-
"""
|
|
1207
|
-
cascade_s = str(cascade).lower()
|
|
1208
|
-
url = (
|
|
1209
|
-
f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/project-manager/projects/"
|
|
1210
|
-
f"{project_guid}/delete?cascadedDelete={cascade_s}"
|
|
1211
|
-
)
|
|
1212
|
-
|
|
1213
|
-
body = {"class": "NullRequestBody"}
|
|
1214
|
-
|
|
1215
|
-
await self._async_make_request("POST", url, body)
|
|
1216
|
-
return
|
|
1217
|
-
|
|
1218
|
-
def delete_project(
|
|
1219
|
-
self,
|
|
1220
|
-
project_guid: str, cascade: bool = False
|
|
1221
|
-
) -> None:
|
|
1222
|
-
"""Delete a project. It is detected from all parent elements.
|
|
1223
|
-
|
|
1224
|
-
Parameters
|
|
1225
|
-
----------
|
|
1226
|
-
project_guid: str
|
|
1227
|
-
The guid of the collection to update.
|
|
1228
|
-
cascade: bool, optional, defaults to False
|
|
1229
|
-
If true, then all anchored elements will be deleted.
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
cascade: bool, optional, defaults to False
|
|
1233
|
-
If true, then all anchored elements will be deleted.
|
|
1234
|
-
Returns
|
|
1235
|
-
-------
|
|
1236
|
-
Nothing
|
|
1237
|
-
|
|
1238
|
-
Raises
|
|
1239
|
-
------
|
|
1240
|
-
|
|
1241
|
-
InvalidParameterException
|
|
1242
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
|
1243
|
-
PropertyServerException
|
|
1244
|
-
Raised by the server when an issue arises in processing a valid request
|
|
1245
|
-
NotAuthorizedException
|
|
1246
|
-
The principle specified by the user_id does not have authorization for the requested action
|
|
1247
|
-
|
|
1248
|
-
"""
|
|
1249
|
-
loop = asyncio.get_event_loop()
|
|
1250
|
-
loop.run_until_complete(self._async_delete_project(project_guid, cascade))
|
|
1251
|
-
return
|
|
1252
|
-
|
|
1253
|
-
async def _async_add_to_project_team(
|
|
1254
|
-
self,
|
|
1255
|
-
project_guid: str,
|
|
1256
|
-
actor_guid: str,
|
|
1257
|
-
team_role: str = None,
|
|
1258
|
-
effective_from: str = None,
|
|
1259
|
-
effective_to: str = None,
|
|
1260
|
-
) -> None:
|
|
1261
|
-
"""Add an actor to a project. The request body is optional. If supplied, it contains the name of the role that
|
|
1262
|
-
the actor plays in the project. Async version.
|
|
1263
|
-
|
|
1264
|
-
Parameters
|
|
1265
|
-
----------
|
|
1266
|
-
project_guid: str
|
|
1267
|
-
identity of the project to update.
|
|
1268
|
-
actor_guid: str
|
|
1269
|
-
identity of the actor to add.
|
|
1270
|
-
team_role: str, optional, defaults to None
|
|
1271
|
-
Name of the role the actor plays in the project.
|
|
1272
|
-
effective_from: str, optional, defaults to None
|
|
1273
|
-
Date at which the actor becomes active in the project. Date format is ISO 8601 string format.
|
|
1274
|
-
effective_to: str, optional, defaults to None
|
|
1275
|
-
Date at which the actor is no longer active in the project. Date format is ISO 8601 string format.
|
|
1276
|
-
|
|
1277
|
-
Returns
|
|
1278
|
-
-------
|
|
1279
|
-
None
|
|
1280
|
-
|
|
1281
|
-
Raises
|
|
1282
|
-
------
|
|
1283
|
-
|
|
1284
|
-
InvalidParameterException
|
|
1285
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
|
1286
|
-
PropertyServerException
|
|
1287
|
-
Raised by the server when an issue arises in processing a valid request
|
|
1288
|
-
NotAuthorizedException
|
|
1289
|
-
The principle specified by the user_id does not have authorization for the requested action
|
|
1290
|
-
|
|
1291
|
-
"""
|
|
1292
|
-
|
|
1293
|
-
url = (
|
|
1294
|
-
f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/project-manager/projects/{project_guid}/"
|
|
1295
|
-
f"members/{actor_guid}/attach"
|
|
1296
|
-
)
|
|
1297
|
-
body = {
|
|
1298
|
-
"class": "ProjectTeamProperties",
|
|
1299
|
-
"teamRole": team_role,
|
|
1300
|
-
"effectiveFrom": effective_from,
|
|
1301
|
-
"effectiveTo": effective_to,
|
|
1302
|
-
}
|
|
1303
|
-
body_s = body_slimmer(body)
|
|
1304
|
-
if body_s is None:
|
|
1305
|
-
await self._async_make_request("POST", url)
|
|
1306
|
-
else:
|
|
1307
|
-
await self._async_make_request("POST", url, body_s)
|
|
1308
|
-
return
|
|
1309
|
-
|
|
1310
|
-
def add_to_project_team(
|
|
1311
|
-
self,
|
|
1312
|
-
project_guid: str,
|
|
1313
|
-
actor_guid: str,
|
|
1314
|
-
team_role: str = None,
|
|
1315
|
-
effective_from: str = None,
|
|
1316
|
-
effective_to: str = None,
|
|
1317
|
-
) -> None:
|
|
1318
|
-
"""Add an actor to a project. The request body is optional. If supplied, it contains the name of the role that
|
|
1319
|
-
the actor plays in the project.
|
|
1320
|
-
|
|
1321
|
-
Parameters
|
|
1322
|
-
----------
|
|
1323
|
-
project_guid: str
|
|
1324
|
-
identity of the project to update.
|
|
1325
|
-
actor_guid: str
|
|
1326
|
-
identity of the actor to add.
|
|
1327
|
-
team_role: str, optional, defaults to None
|
|
1328
|
-
Name of the role the actor plays in the project.
|
|
1329
|
-
effective_from: str, optional, defaults to None
|
|
1330
|
-
Date at which the actor becomes active in the project. Date format is ISO 8601 string format.
|
|
1331
|
-
effective_to: str, optional, defaults to None
|
|
1332
|
-
Date at which the actor is no longer active in the project. Date format is ISO 8601 string format.
|
|
1333
|
-
|
|
1334
|
-
Returns
|
|
1335
|
-
-------
|
|
1336
|
-
None
|
|
1337
|
-
|
|
1338
|
-
Raises
|
|
1339
|
-
------
|
|
1340
|
-
|
|
1341
|
-
InvalidParameterException
|
|
1342
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
|
1343
|
-
PropertyServerException
|
|
1344
|
-
Raised by the server when an issue arises in processing a valid request
|
|
1345
|
-
NotAuthorizedException
|
|
1346
|
-
The principle specified by the user_id does not have authorization for the requested action
|
|
1347
|
-
|
|
1348
|
-
"""
|
|
1349
|
-
loop = asyncio.get_event_loop()
|
|
1350
|
-
loop.run_until_complete(
|
|
1351
|
-
self._async_add_to_project_team(
|
|
1352
|
-
project_guid,
|
|
1353
|
-
actor_guid,
|
|
1354
|
-
team_role,
|
|
1355
|
-
effective_from,
|
|
1356
|
-
effective_to,
|
|
1357
|
-
)
|
|
1358
|
-
)
|
|
1359
|
-
return
|
|
1360
|
-
|
|
1361
|
-
async def _async_remove_from_project_team(
|
|
1362
|
-
self,
|
|
1363
|
-
project_guid: str,
|
|
1364
|
-
actor_guid: str,
|
|
1365
|
-
) -> None:
|
|
1366
|
-
"""Remove an actor from a project. Async version.
|
|
1367
|
-
|
|
1368
|
-
Parameters
|
|
1369
|
-
----------
|
|
1370
|
-
project_guid: str
|
|
1371
|
-
identity of the project to remove members from.
|
|
1372
|
-
actor_guid: str
|
|
1373
|
-
identity of the actor to remove.
|
|
1374
|
-
|
|
1375
|
-
Returns
|
|
1376
|
-
-------
|
|
1377
|
-
None
|
|
1378
|
-
|
|
1379
|
-
Raises
|
|
1380
|
-
------
|
|
1381
|
-
|
|
1382
|
-
InvalidParameterException
|
|
1383
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
|
1384
|
-
PropertyServerException
|
|
1385
|
-
Raised by the server when an issue arises in processing a valid request
|
|
1386
|
-
NotAuthorizedException
|
|
1387
|
-
The principle specified by the user_id does not have authorization for the requested action
|
|
1388
|
-
|
|
1389
|
-
"""
|
|
1390
|
-
|
|
1391
|
-
url = (
|
|
1392
|
-
f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/project-manager/projects/{project_guid}/"
|
|
1393
|
-
f"members/{actor_guid}/detach"
|
|
1394
|
-
)
|
|
1395
|
-
|
|
1396
|
-
body = {"class": "NullRequestBody"}
|
|
1397
|
-
await self._async_make_request("POST", url, body)
|
|
1398
|
-
return
|
|
1399
|
-
|
|
1400
|
-
def remove_from_project_team(
|
|
1401
|
-
self,
|
|
1402
|
-
project_guid: str,
|
|
1403
|
-
actor_guid: str,
|
|
1404
|
-
) -> None:
|
|
1405
|
-
"""Remove an actor from a project.
|
|
1406
|
-
|
|
1407
|
-
Parameters
|
|
1408
|
-
----------
|
|
1409
|
-
project_guid: str
|
|
1410
|
-
identity of the project.
|
|
1411
|
-
actor_guid: str
|
|
1412
|
-
identity of the actor to remove.
|
|
1413
|
-
|
|
1414
|
-
Returns
|
|
1415
|
-
-------
|
|
1416
|
-
None
|
|
1417
|
-
|
|
1418
|
-
Raises
|
|
1419
|
-
------
|
|
1420
|
-
|
|
1421
|
-
InvalidParameterException
|
|
1422
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
|
1423
|
-
PropertyServerException
|
|
1424
|
-
Raised by the server when an issue arises in processing a valid request
|
|
1425
|
-
NotAuthorizedException
|
|
1426
|
-
The principle specified by the user_id does not have authorization for the requested action
|
|
1427
|
-
|
|
1428
|
-
"""
|
|
1429
|
-
loop = asyncio.get_event_loop()
|
|
1430
|
-
loop.run_until_complete(
|
|
1431
|
-
self._async_remove_from_project_team(project_guid, actor_guid)
|
|
1432
|
-
)
|
|
1433
|
-
return
|
|
1434
|
-
|
|
1435
|
-
async def _async_setup_project_management_role(
|
|
1436
|
-
self,
|
|
1437
|
-
project_guid: str,
|
|
1438
|
-
project_role_guid: str,
|
|
1439
|
-
) -> None:
|
|
1440
|
-
"""Create a ProjectManagement relationship between a project and a person role to show that anyone appointed to
|
|
1441
|
-
the role is a member of the project. Async version.
|
|
1442
|
-
|
|
1443
|
-
Parameters
|
|
1444
|
-
----------
|
|
1445
|
-
project_guid: str
|
|
1446
|
-
identity of the project.
|
|
1447
|
-
project_role_guid: str
|
|
1448
|
-
guid of the role to assign to the project.
|
|
1449
|
-
|
|
1450
|
-
|
|
1451
|
-
Returns
|
|
1452
|
-
-------
|
|
1453
|
-
None
|
|
1454
|
-
|
|
1455
|
-
Raises
|
|
1456
|
-
------
|
|
1457
|
-
|
|
1458
|
-
InvalidParameterException
|
|
1459
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
|
1460
|
-
PropertyServerException
|
|
1461
|
-
Raised by the server when an issue arises in processing a valid request
|
|
1462
|
-
NotAuthorizedException
|
|
1463
|
-
The principle specified by the user_id does not have authorization for the requested action
|
|
1464
|
-
|
|
1465
|
-
"""
|
|
1466
|
-
|
|
1467
|
-
url = (
|
|
1468
|
-
f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/project-manager/projects/{project_guid}/"
|
|
1469
|
-
f"project-management-roles/{project_role_guid}/attach"
|
|
1470
|
-
)
|
|
1471
|
-
|
|
1472
|
-
body = {"class": "NullRequestBody"}
|
|
1473
|
-
await self._async_make_request("POST", url, body)
|
|
1474
|
-
return
|
|
1475
|
-
|
|
1476
|
-
def setup_project_management_role(
|
|
1477
|
-
self,
|
|
1478
|
-
project_guid: str,
|
|
1479
|
-
project_role_guid: str,
|
|
1480
|
-
) -> None:
|
|
1481
|
-
"""Create a ProjectManagement relationship between a project and a person role to show that anyone appointed to
|
|
1482
|
-
the role is a member of the project. Async version.
|
|
1483
|
-
|
|
1484
|
-
Parameters
|
|
1485
|
-
----------
|
|
1486
|
-
project_guid: str
|
|
1487
|
-
identity of the project.
|
|
1488
|
-
project_role_guid: str
|
|
1489
|
-
guid of the role to assign to the project.
|
|
1490
|
-
|
|
1491
|
-
|
|
1492
|
-
Returns
|
|
1493
|
-
-------
|
|
1494
|
-
None
|
|
1495
|
-
|
|
1496
|
-
Raises
|
|
1497
|
-
------
|
|
1498
|
-
|
|
1499
|
-
InvalidParameterException
|
|
1500
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
|
1501
|
-
PropertyServerException
|
|
1502
|
-
Raised by the server when an issue arises in processing a valid request
|
|
1503
|
-
NotAuthorizedException
|
|
1504
|
-
The principle specified by the user_id does not have authorization for the requested action
|
|
1505
|
-
|
|
1506
|
-
"""
|
|
1507
|
-
loop = asyncio.get_event_loop()
|
|
1508
|
-
loop.run_until_complete(
|
|
1509
|
-
self._async_setup_project_management_role(project_guid, project_role_guid)
|
|
1510
|
-
)
|
|
1511
|
-
return
|
|
1512
|
-
|
|
1513
|
-
async def _async_clear_project_management_role(
|
|
1514
|
-
self,
|
|
1515
|
-
project_guid: str,
|
|
1516
|
-
project_role_guid: str,
|
|
1517
|
-
) -> None:
|
|
1518
|
-
"""Remove a ProjectManagement relationship between a project and a person role. Async version.
|
|
1519
|
-
|
|
1520
|
-
Parameters
|
|
1521
|
-
----------
|
|
1522
|
-
project_guid: str
|
|
1523
|
-
identity of the project.
|
|
1524
|
-
project_role_guid: str
|
|
1525
|
-
guid of the role to assign to the project.
|
|
1526
|
-
|
|
1527
|
-
|
|
1528
|
-
Returns
|
|
1529
|
-
-------
|
|
1530
|
-
None
|
|
1531
|
-
|
|
1532
|
-
Raises
|
|
1533
|
-
------
|
|
1534
|
-
|
|
1535
|
-
InvalidParameterException
|
|
1536
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
|
1537
|
-
PropertyServerException
|
|
1538
|
-
Raised by the server when an issue arises in processing a valid request
|
|
1539
|
-
NotAuthorizedException
|
|
1540
|
-
The principle specified by the user_id does not have authorization for the requested action
|
|
1541
|
-
|
|
1542
|
-
"""
|
|
1543
|
-
|
|
1544
|
-
url = (
|
|
1545
|
-
f"{self.platform_url}/servers/{self.view_server}/api/open-metadata/project-manager/projects/{project_guid}/"
|
|
1546
|
-
f"project-management-roles/{project_role_guid}/detach"
|
|
1547
|
-
)
|
|
1548
|
-
|
|
1549
|
-
body = {"class": "NullRequestBody"}
|
|
1550
|
-
await self._async_make_request("POST", url, body)
|
|
1551
|
-
return
|
|
1552
|
-
|
|
1553
|
-
def clear_project_management_role(
|
|
1554
|
-
self,
|
|
1555
|
-
project_guid: str,
|
|
1556
|
-
project_role_guid: str,
|
|
1557
|
-
) -> None:
|
|
1558
|
-
"""Clear a ProjectManagement relationship between a project and a person role.
|
|
1559
|
-
|
|
1560
|
-
Parameters
|
|
1561
|
-
----------
|
|
1562
|
-
project_guid: str
|
|
1563
|
-
identity of the project.
|
|
1564
|
-
project_role_guid: str
|
|
1565
|
-
guid of the role to assign to the project.
|
|
1566
|
-
|
|
1567
|
-
|
|
1568
|
-
Returns
|
|
1569
|
-
-------
|
|
1570
|
-
None
|
|
1571
|
-
|
|
1572
|
-
Raises
|
|
1573
|
-
------
|
|
1574
|
-
|
|
1575
|
-
InvalidParameterException
|
|
1576
|
-
If the client passes incorrect parameters on the request - such as bad URLs or invalid values
|
|
1577
|
-
PropertyServerException
|
|
1578
|
-
Raised by the server when an issue arises in processing a valid request
|
|
1579
|
-
NotAuthorizedException
|
|
1580
|
-
The principle specified by the user_id does not have authorization for the requested action
|
|
1581
|
-
|
|
1582
|
-
"""
|
|
1583
|
-
loop = asyncio.get_event_loop()
|
|
1584
|
-
loop.run_until_complete(
|
|
1585
|
-
self._async_clear_project_management_role(project_guid, project_role_guid)
|
|
1586
|
-
)
|
|
1587
|
-
return
|
|
1588
|
-
|
|
1589
|
-
|
|
1590
|
-
if __name__ == "__main__":
|
|
1591
|
-
print("Main-Project Manager")
|