pyegeria 5.2.1.1__py3-none-any.whl → 5.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.
- commands/cat/.DS_Store +0 -0
- commands/cat/Dr-Egeria_md-orig.py +166 -0
- commands/cat/__init__.py +23 -0
- commands/cat/dr_egeria_jupyter.py +122 -0
- commands/cat/dr_egeria_md.py +247 -0
- {pyegeria/commands → commands}/cat/exp_list_glossaries.py +3 -4
- {pyegeria/commands → commands}/cat/get_asset_graph.py +4 -4
- {pyegeria/commands → commands}/cat/get_collection.py +8 -9
- {pyegeria/commands → commands}/cat/get_project_dependencies.py +6 -8
- {pyegeria/commands → commands}/cat/get_project_structure.py +6 -8
- {pyegeria/commands → commands}/cat/get_tech_type_elements.py +13 -15
- {pyegeria/commands → commands}/cat/glossary_actions.py +184 -34
- {pyegeria/commands → commands}/cat/list_assets.py +9 -6
- commands/cat/list_categories.py +192 -0
- {pyegeria/commands → commands}/cat/list_cert_types.py +6 -6
- {pyegeria/commands → commands}/cat/list_collections.py +62 -19
- commands/cat/list_data_structures.py +223 -0
- {pyegeria/commands → commands}/cat/list_deployed_catalogs.py +9 -8
- {pyegeria/commands → commands}/cat/list_deployed_database_schemas.py +10 -9
- {pyegeria/commands → commands}/cat/list_deployed_databases.py +9 -8
- pyegeria/commands/cat/list_servers_deployed_imp.py → commands/cat/list_deployed_servers.py +3 -3
- {pyegeria/commands → commands}/cat/list_glossaries.py +57 -15
- {pyegeria/commands → commands}/cat/list_projects.py +5 -5
- {pyegeria/commands → commands}/cat/list_tech_type_elements.py +3 -3
- {pyegeria/commands → commands}/cat/list_tech_types.py +4 -4
- {pyegeria/commands → commands}/cat/list_terms.py +93 -45
- {pyegeria/commands → commands}/cat/list_todos.py +3 -3
- {pyegeria/commands → commands}/cat/list_user_ids.py +9 -8
- {pyegeria/commands → commands}/cli/__init__.py +1 -1
- {pyegeria/commands → commands}/cli/egeria.py +506 -250
- {pyegeria/commands → commands}/cli/egeria_cat.py +127 -50
- {pyegeria/commands → commands}/cli/egeria_login_tui.py +15 -17
- {pyegeria/commands → commands}/cli/egeria_my.py +22 -15
- {pyegeria/commands → commands}/cli/egeria_ops.py +54 -55
- {pyegeria/commands → commands}/cli/egeria_tech.py +364 -152
- {pyegeria/commands → commands}/cli/ops_config.py +11 -4
- commands/cli/txt_custom_v2.tcss +19 -0
- commands/my/__init__.py +22 -0
- {pyegeria/commands → commands}/my/list_my_profile.py +6 -8
- {pyegeria/commands → commands}/my/list_my_roles.py +4 -4
- {pyegeria/commands → commands}/my/monitor_my_todos.py +7 -7
- {pyegeria/commands → commands}/my/monitor_open_todos.py +7 -7
- {pyegeria/commands → commands}/my/todo_actions.py +3 -2
- commands/ops/__init__.py +23 -0
- {pyegeria/commands → commands}/ops/gov_server_actions.py +5 -4
- {pyegeria/commands → commands}/ops/list_archives.py +7 -6
- {pyegeria/commands → commands}/ops/list_catalog_targets.py +4 -4
- {pyegeria/commands → commands}/ops/load_archive.py +4 -2
- {pyegeria/commands → commands}/ops/monitor_asset_events.py +8 -7
- {pyegeria/commands → commands}/ops/monitor_engine_activity.py +5 -5
- {pyegeria/commands → commands}/ops/monitor_engine_activity_c.py +3 -3
- {pyegeria/commands → commands}/ops/monitor_gov_eng_status.py +3 -2
- {pyegeria/commands → commands}/ops/monitor_integ_daemon_status.py +23 -15
- {pyegeria/commands → commands}/ops/monitor_platform_status.py +5 -4
- {pyegeria/commands → commands}/ops/monitor_server_startup.py +7 -7
- {pyegeria/commands → commands}/ops/monitor_server_status.py +16 -11
- {pyegeria/commands → commands}/ops/orig_monitor_server_list.py +2 -2
- {pyegeria/commands → commands}/ops/orig_monitor_server_status.py +3 -3
- {pyegeria/commands → commands}/ops/refresh_integration_daemon.py +4 -4
- {pyegeria/commands → commands}/ops/restart_integration_daemon.py +3 -3
- {pyegeria/commands → commands}/ops/table_integ_daemon_status.py +3 -3
- commands/tech/__init__.py +22 -0
- commands/tech/generic_actions.py +74 -0
- {pyegeria/commands → commands}/tech/get_element_info.py +5 -7
- {pyegeria/commands → commands}/tech/get_guid_info.py +4 -5
- {pyegeria/commands → commands}/tech/get_tech_details.py +8 -9
- {pyegeria/commands → commands}/tech/get_tech_type_template.py +4 -4
- pyegeria/commands/tech/list_elements.py → commands/tech/list_all_om_type_elements.py +11 -10
- pyegeria/commands/tech/list_elements_x.py → commands/tech/list_all_om_type_elements_x.py +11 -12
- pyegeria/commands/tech/list_related_elements.py → commands/tech/list_all_related_elements.py +11 -9
- {pyegeria/commands → commands}/tech/list_anchored_elements.py +16 -16
- {pyegeria/commands → commands}/tech/list_asset_types.py +4 -4
- commands/tech/list_elements_by_classification_by_property_value.py +200 -0
- commands/tech/list_elements_by_property_value.py +180 -0
- commands/tech/list_elements_by_property_value_x.py +201 -0
- {pyegeria/commands → commands}/tech/list_elements_for_classification.py +11 -9
- {pyegeria/commands → commands}/tech/list_gov_action_processes.py +5 -6
- commands/tech/list_information_supply_chains.py +167 -0
- {pyegeria/commands → commands}/tech/list_registered_services.py +3 -3
- commands/tech/list_related_elements_with_prop_value.py +221 -0
- {pyegeria/commands → commands}/tech/list_related_specification.py +3 -3
- {pyegeria/commands → commands}/tech/list_relationship_types.py +4 -5
- {pyegeria/commands → commands}/tech/list_relationships.py +3 -3
- commands/tech/list_solution_blueprints.py +181 -0
- commands/tech/list_solution_components.py +185 -0
- commands/tech/list_solution_roles.py +184 -0
- {pyegeria/commands → commands}/tech/list_tech_templates.py +3 -3
- {pyegeria/commands → commands}/tech/list_valid_metadata_values.py +5 -6
- {pyegeria/commands → commands}/tech/table_tech_templates.py +16 -13
- {pyegeria/commands → commands}/tech/x_list_related_elements.py +6 -4
- md_processing/__init__.py +49 -0
- md_processing/data/commands.json +3252 -0
- md_processing/dr_egeria_inbox/archive/dr_egeria_intro.md +254 -0
- md_processing/dr_egeria_inbox/archive/dr_egeria_intro_more_terms.md +696 -0
- md_processing/dr_egeria_inbox/archive/dr_egeria_intro_part1.md +254 -0
- md_processing/dr_egeria_inbox/archive/dr_egeria_intro_part2.md +298 -0
- md_processing/dr_egeria_inbox/archive/dr_egeria_intro_part3.md +608 -0
- md_processing/dr_egeria_inbox/archive/dr_egeria_intro_part4.md +94 -0
- md_processing/dr_egeria_inbox/archive/freddie_intro.md +284 -0
- md_processing/dr_egeria_inbox/archive/freddie_intro_orig.md +275 -0
- md_processing/dr_egeria_inbox/archive/test-term.md +110 -0
- md_processing/dr_egeria_inbox/cat_test.md +100 -0
- md_processing/dr_egeria_inbox/data_field.md +54 -0
- md_processing/dr_egeria_inbox/data_spec.md +77 -0
- md_processing/dr_egeria_inbox/data_spec_test.md +2406 -0
- md_processing/dr_egeria_inbox/data_test.md +86 -0
- md_processing/dr_egeria_inbox/dr_egeria_intro_categories.md +168 -0
- md_processing/dr_egeria_inbox/dr_egeria_intro_part1.md +280 -0
- md_processing/dr_egeria_inbox/dr_egeria_intro_part2.md +313 -0
- md_processing/dr_egeria_inbox/dr_egeria_intro_part3.md +1073 -0
- md_processing/dr_egeria_inbox/dr_egeria_isc1.md +44 -0
- md_processing/dr_egeria_inbox/glossary_creation_experiment.ipynb +341 -0
- md_processing/dr_egeria_inbox/glossary_test1.md +324 -0
- md_processing/dr_egeria_inbox/rel.md +8 -0
- md_processing/dr_egeria_inbox/sb.md +119 -0
- md_processing/dr_egeria_inbox/search_test.md +39 -0
- md_processing/dr_egeria_inbox/solution-components.md +154 -0
- md_processing/dr_egeria_inbox/solution_blueprints.md +118 -0
- md_processing/dr_egeria_inbox/synonym_test.md +42 -0
- md_processing/dr_egeria_inbox/t2.md +268 -0
- md_processing/dr_egeria_outbox/processed-2025-05-15 19:52-data_test.md +94 -0
- md_processing/dr_egeria_outbox/processed-2025-05-16 07:39-data_test.md +88 -0
- md_processing/dr_egeria_outbox/processed-2025-05-17 16:01-data_field.md +56 -0
- md_processing/dr_egeria_outbox/processed-2025-05-18 15:51-data_test.md +103 -0
- md_processing/dr_egeria_outbox/processed-2025-05-18 16:47-data_test.md +94 -0
- md_processing/dr_egeria_outbox/processed-2025-05-19 07:14-data_test.md +96 -0
- md_processing/dr_egeria_outbox/processed-2025-05-19 07:20-data_test.md +100 -0
- md_processing/dr_egeria_outbox/processed-2025-05-19 07:22-data_test.md +88 -0
- md_processing/dr_egeria_outbox/processed-2025-05-19 09:26-data_test.md +91 -0
- md_processing/dr_egeria_outbox/processed-2025-05-19 10:27-data_test.md +91 -0
- md_processing/dr_egeria_outbox/processed-2025-05-19 14:04-data_test.md +91 -0
- md_processing/md_commands/__init__.py +3 -0
- md_processing/md_commands/blueprint_commands.py +303 -0
- md_processing/md_commands/data_designer_commands.py +1182 -0
- md_processing/md_commands/glossary_commands.py +1144 -0
- md_processing/md_commands/project_commands.py +163 -0
- md_processing/md_processing_utils/__init__.py +4 -0
- md_processing/md_processing_utils/common_md_proc_utils.py +724 -0
- md_processing/md_processing_utils/common_md_utils.py +172 -0
- md_processing/md_processing_utils/extraction_utils.py +486 -0
- md_processing/md_processing_utils/md_processing_constants.py +128 -0
- md_processing/md_processing_utils/message_constants.py +19 -0
- pyegeria/.DS_Store +0 -0
- pyegeria/__init__.py +231 -146
- pyegeria/_client.py +36 -13
- pyegeria/_exceptions.py +55 -46
- pyegeria/_globals.py +11 -1
- pyegeria/_validators.py +5 -5
- pyegeria/asset_catalog_omvs.py +78 -21
- pyegeria/automated_curation_omvs.py +11 -6
- pyegeria/classification_manager_omvs.py +41 -37
- pyegeria/collection_manager_omvs.py +722 -705
- pyegeria/core_omag_server_config.py +1 -1
- pyegeria/create_tech_guid_lists.py +13 -13
- pyegeria/data_designer_omvs.py +5104 -0
- pyegeria/dr.egeria spec.md +9 -0
- pyegeria/egeria_cat_client.py +5 -8
- pyegeria/egeria_client.py +39 -24
- pyegeria/egeria_config_client.py +2 -1
- pyegeria/egeria_my_client.py +4 -4
- pyegeria/egeria_tech_client.py +40 -18
- pyegeria/feedback_manager_omvs.py +1 -1
- pyegeria/full_omag_server_config.py +5 -3
- pyegeria/glossary_browser_omvs.py +1915 -694
- pyegeria/glossary_manager_omvs.py +685 -1842
- pyegeria/m_test.py +118 -0
- pyegeria/md_processing_helpers.py +58 -0
- pyegeria/md_processing_utils.py +2147 -0
- pyegeria/md_processing_utils_orig.py +1103 -0
- pyegeria/mermaid_utilities.py +1194 -14
- pyegeria/metadata_explorer_omvs.py +5 -50
- pyegeria/my_profile_omvs.py +3 -2
- pyegeria/output_formatter.py +389 -0
- pyegeria/platform_services.py +5 -5
- pyegeria/project_manager_omvs.py +97 -18
- pyegeria/runtime_manager_omvs.py +8 -10
- pyegeria/server_operations.py +2 -2
- pyegeria/solution_architect_omvs.py +2156 -0
- pyegeria/template_manager_omvs.py +13 -13
- pyegeria/utils.py +3 -1
- pyegeria/valid_metadata_omvs.py +5 -4
- pyegeria/x_action_author_omvs.py +3 -6
- {pyegeria-5.2.1.1.dist-info → pyegeria-5.3.dist-info}/METADATA +9 -8
- pyegeria-5.3.dist-info/RECORD +196 -0
- {pyegeria-5.2.1.1.dist-info → pyegeria-5.3.dist-info}/WHEEL +1 -1
- pyegeria-5.3.dist-info/entry_points.txt +99 -0
- pyegeria/commands/README.md +0 -47
- pyegeria/commands/__init__.py +0 -22
- pyegeria/commands/cat/__init__.py +0 -1
- pyegeria/commands/doc/README.md +0 -145
- pyegeria/commands/doc/Visual Command Reference/README.md +0 -511
- pyegeria/commands/doc/Visual Command Reference/cat/show/assets/asset-graph 2024-11-20 at 15.56.42.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/cat/show/assets/assets-in-domain 2024-11-20 at 15.49.55@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/cat/show/assets/elements-of-type 2024-11-20 at 16.01.35.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/cat/show/assets/tech-type-elements 2024-11-20 at 16.05.05.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/cat/show/deployed-data/deployed-data-catalogs 2024-12-17 at 15.43.27@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/cat/show/deployed-data/deployed-data-catalogs-2024-11-20 at 16.17.43@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/cat/show/deployed-data/deployed-schemas 2024-11-25 at 20.14.50@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/cat/show/deployed-data/deployed-schemas 2024-12-17 at 15.48.38@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/cat/show/deployed-data/deployed-servers 2024-11-25 at 20.21.25@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/cat/show/deployed-data/deployed-servers 2024-12-17 at 15.52.16@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/cat/show/deployed-data/deployed_databases 2024-12-16 at 16.40.31@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/cat/show/glossary/list-glossaries 2024-11-25 at 20.30.02.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/cat/show/glossary/list-terms 2024-11-25 at 20.32.11.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/cat/show/info/asset-types 2024-11-25 at 20.34.19@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/cat/show/info/certification-types 2024-11-25 at 20.37.07.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/cat/show/info/collection-graph 2024-12-12 at 11.33.18@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/cat/show/info/list-collections 2024-12-10 at 14.25.51@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/cat/show/info/list-todos 2024-12-12 at 11.46.30@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/cat/show/info/list-user-ids 2024-12-12 at 11.51.09@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/cat/show/info/tech-types 2024-12-12 at 11.37.20@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/cat/show/projects/project_dependencies 2024-12-14 at 16.24.39@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/cat/show/projects/project_structure 2024-12-14 at 16.21.35@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/cat/show/projects/projects 2024-12-14 at 16.18.10@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/hey_egeria tui 2024-12-16 at 16.58.22@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/my/show/my_profile 2024-12-14 at 16.29.27@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/my/show/my_roles 2024-12-14 at 16.32.10@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/my/show/my_todos 2024-12-15 at 16.24.13@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/my/show/open_todos 2024-12-14 at 16.36.12@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/ops/show/engines/list_engine_activity compressed 2024-12-15 at 16.48.48@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/ops/show/engines/monitor_engine_activity 2024-12-15 at 16.32.55@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/ops/show/engines/monitor_engine_activity compressed 2024-12-15 at 16.38.29@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/ops/show/engines/monitor_engine_status 2024-12-15 at 16.51.26.jpeg +0 -0
- pyegeria/commands/doc/Visual Command Reference/ops/show/integrations/monitor_integration_daemon_status 2024-12-15 at 16.57.12@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/ops/show/integrations/monitor_integration_targets 2024-12-15 at 17.02.19@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/ops/show/platforms/monitor_platform_status 2024-12-15 at 19.53.18@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/ops/show/servers/monitor_server_status 2024-12-15 at 19.59.39@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/ops/show/servers/monitor_server_status full 2024-12-15 at 20.01.57@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/ops/show/servers/monitor_startup_servers 2024-12-15 at 19.56.07@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/tech/show/elements/get_anchored_elements 2024-12-15 at 21.25.41@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/tech/show/elements/get_elements_of_om_type 2024-12-16 at 14.39.59@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/tech/show/elements/info_for_guid 2024-12-16 at 11.35.29@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/tech/show/elements/list_elements_by_om-type 2024-12-16 at 14.24.18@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/tech/show/elements/list_elements_by_om-type extended 2024-12-16 at 14.28.46@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/tech/show/elements/list_elements_of_om_type_by_classification 2024-12-16 at 14.35.26@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/tech/show/elements/related_elements 2024-12-16 at 14.55.01@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/tech/show/elements/show_related_specifications 2024-12-16 at 15.04.55@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/tech/show/tech-info/asset_types 2024-12-16 at 15.10.16@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/tech/show/tech-info/detailed_governance_action_processes 2024-12-16 at 15.16.26@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/tech/show/tech-info/governance_action_processes 2024-12-16 at 15.13.01@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/tech/show/tech-info/registered_services 2024-12-16 at 16.44.54@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/tech/show/tech-info/relationship_types 2024-12-16 at 16.20.34@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/tech/show/tech-info/relationship_types 2024-12-19 at 10.51.54@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/tech/show/tech-info/valid_metadata_values 2024-12-16 at 15.31.56@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/tech/show/tech-types/list_tech_type_template_specs 2024-12-16 at 16.03.22@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/tech/show/tech-types/list_technology_types 2024-12-16 at 15.39.20@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/tech/show/tech-types/tech_type_details 2024-12-16 at 15.37.21@2x.png +0 -0
- pyegeria/commands/doc/Visual Command Reference/tech/show/tech-types/tech_type_templates 2024-12-16 at 16.11.48@2x.png +0 -0
- pyegeria/commands/doc/glossary/basic-glossary-tui.md +0 -109
- pyegeria/commands/doc/glossary/images/delete-glossary-step1 2024-11-06 at 15.47.23@2x.png +0 -0
- pyegeria/commands/doc/glossary/images/delete-glossary-step2 2024-11-06 at 15.51.29@2x.png +0 -0
- pyegeria/commands/doc/glossary/images/delete-glossary-step3 2024-11-06 at 15.53.19@2x.png +0 -0
- pyegeria/commands/doc/glossary/images/delete-glossary-step4 2024-11-06 at 15.55.11@2x.png +0 -0
- pyegeria/commands/doc/glossary/images/out-create-glossary example 2024-11-05 at 20.38.04@2x.png +0 -0
- pyegeria/commands/doc/glossary/images/out-create-term 2024-11-06 at 20.48.29.png +0 -0
- pyegeria/commands/doc/glossary/images/out-delete-term 2024-11-07 at 03.57.25.png +0 -0
- pyegeria/commands/doc/glossary/images/out-display-terms-for-glossary-test 2024-11-06 at 20.51.28.png +0 -0
- pyegeria/commands/doc/glossary/images/out-export-example 2024-11-07 at 09.54.57.png +0 -0
- pyegeria/commands/doc/glossary/images/out-exported-terms 2024-11-06 at 21.06.32.png +0 -0
- pyegeria/commands/doc/glossary/images/out-glossary-list example 2024-11-05 at 20.41.02@2x.png +0 -0
- pyegeria/commands/doc/glossary/images/out-import-terms 2024-11-07 at 08.15.18.png +0 -0
- pyegeria/commands/doc/glossary/images/out-list-all-terms 2024-11-06 at 16.22.20@2x.png +0 -0
- pyegeria/commands/doc/glossary/images/out-list-terms-for-example 2024-11-06 at 16.40.12.png +0 -0
- pyegeria/commands/doc/glossary/images/out-list-terms-second 2024-11-06 at 16.45.13.png +0 -0
- pyegeria/commands/doc/glossary/images/out-pipx install pyegeria 2024-11-10 at 18.12.21.png +0 -0
- pyegeria/commands/doc/glossary/images/out-server-status-full 2024-11-10 at 18.25.14.png +0 -0
- pyegeria/commands/doc/glossary/images/out-servers-status 2024-11-10 at 18.15.42.png +0 -0
- pyegeria/commands/doc/glossary/images/out-upsert-import 2024-11-07 at 19.37.00.png +0 -0
- pyegeria/commands/doc/glossary/images/tui-2024-11-10 at 18.26.29.png +0 -0
- pyegeria/commands/doc/glossary/images/tui-create-glossary example 2024-11-05 at 20.34.24@2x.png +0 -0
- pyegeria/commands/doc/glossary/images/tui-create-term 2024-11-06 at 20.46.35.png +0 -0
- pyegeria/commands/doc/glossary/images/tui-delete-term 2024-11-07 at 03.51.57.png +0 -0
- pyegeria/commands/doc/glossary/images/tui-display-terms-for-example 2024-11-06 at 20.56.49.png +0 -0
- pyegeria/commands/doc/glossary/images/tui-export-example 2024-11-07 at 09.52.59.png +0 -0
- pyegeria/commands/doc/glossary/images/tui-hey-egeria 2024-11-10 at 18.31.01.png +0 -0
- pyegeria/commands/doc/glossary/images/tui-import-upsert-example 2024-11-07 at 10.08.37.png +0 -0
- pyegeria/commands/doc/glossary/images/tui-list-terms-second 2024-11-06 at 16.46.34.png +0 -0
- pyegeria/commands/doc/glossary/images/tui-load-archive.png +0 -0
- pyegeria/commands/doc/glossary/images/tui-server-status-full 2024-11-10 at 19.14.36.png +0 -0
- pyegeria/commands/doc/glossary/images/tui-show-glossaries 2024-11-07 at 20.00.05.png +0 -0
- pyegeria/commands/doc/glossary/images/tui-show-glossary-terms 2024-11-05 at 19.37.53@2x.png +0 -0
- pyegeria/commands/doc/glossary/images/tui-upsert 2024-11-07 at 11.49.04.png +0 -0
- pyegeria/commands/doc/glossary/images/upsert-example.om-terms 2024-11-07 at 11.44.05.png +0 -0
- pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/README.md +0 -346
- pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/images/CleanShot 2024-11-18 at 21.32.03@2x.png +0 -0
- pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/images/Xmind 1731421782704.png +0 -0
- pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/images/Xmind 1731422134920.png +0 -0
- pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/images/hey_egeria 2024-11-12 at 20.38.43.png +0 -0
- pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/images/hey_egeria cat 2024-11-12 at 21.41.43.png +0 -0
- pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/images/out-integ-status-list 2024-11-12 at 16.45.26.png +0 -0
- pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/images/out-integ-status-live 2024-11-12 at 16.44.12@2x.png +0 -0
- pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/images/out-server-status 2024-11-10 at 18.15.42@2x.png +0 -0
- pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/images/out-server-status-full 2024-11-10 at 18.25.14@2x.png +0 -0
- pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/images/short-cut commands 2024-11-12 at 22.22.13.png +0 -0
- pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/images/tui-hey-egeria.png +0 -0
- pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/images/tui-integration-status-paging.png +0 -0
- pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/images/tui-load-archive 2024-11-10 at 19.19.09@2x.png +0 -0
- pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/images/tui-show-server-status 2024-11-10 at 18.52.01@2x.png +0 -0
- pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/images/tui-show-server-status-full 2024-11-10.png +0 -0
- pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/images/tui-status-paging 2024-11-12 at 16.26.14@2x.png +0 -0
- pyegeria/commands/ops/__init__.py +0 -22
- pyegeria/commands/tech/__init__.py +0 -0
- pyegeria-5.2.1.1.dist-info/RECORD +0 -231
- pyegeria-5.2.1.1.dist-info/entry_points.txt +0 -81
- {pyegeria/commands → commands}/cat/README.md +0 -0
- {pyegeria/commands → commands}/my/README.md +0 -0
- {pyegeria/commands → commands}/ops/README.md +0 -0
- {pyegeria/commands → commands}/ops/x_engine_actions.py +0 -0
- {pyegeria/commands → commands}/tech/README.md +0 -0
- /pyegeria/commands/my/__init__.py → /md_processing/dr_egeria_inbox/t1.md +0 -0
- {pyegeria-5.2.1.1.dist-info → pyegeria-5.3.dist-info}/LICENSE +0 -0
@@ -0,0 +1,221 @@
|
|
1
|
+
"""This finds all elements related to the specified element by the specified relationship type,
|
2
|
+
that match the property value for the properties specified"""
|
3
|
+
|
4
|
+
import argparse
|
5
|
+
import os
|
6
|
+
import sys
|
7
|
+
import time
|
8
|
+
|
9
|
+
from jedi import Project
|
10
|
+
from rich import box
|
11
|
+
from rich.console import Console
|
12
|
+
from rich.markdown import Markdown
|
13
|
+
from rich.prompt import Prompt
|
14
|
+
from rich.table import Table
|
15
|
+
|
16
|
+
from pyegeria import (
|
17
|
+
EgeriaTech,
|
18
|
+
InvalidParameterException,
|
19
|
+
PropertyServerException,
|
20
|
+
UserNotAuthorizedException,
|
21
|
+
print_exception_response,
|
22
|
+
)
|
23
|
+
|
24
|
+
console = Console()
|
25
|
+
EGERIA_METADATA_STORE = os.environ.get("EGERIA_METADATA_STORE", "active-metadata-store")
|
26
|
+
EGERIA_KAFKA_ENDPOINT = os.environ.get("KAFKA_ENDPOINT", "localhost:9092")
|
27
|
+
EGERIA_PLATFORM_URL = os.environ.get("EGERIA_PLATFORM_URL", "https://localhost:9443")
|
28
|
+
EGERIA_VIEW_SERVER = os.environ.get("EGERIA_VIEW_SERVER", "view-server")
|
29
|
+
EGERIA_VIEW_SERVER_URL = os.environ.get(
|
30
|
+
"EGERIA_VIEW_SERVER_URL", "https://localhost:9443"
|
31
|
+
)
|
32
|
+
EGERIA_INTEGRATION_DAEMON = os.environ.get("EGERIA_INTEGRATION_DAEMON", "integration-daemon")
|
33
|
+
EGERIA_ADMIN_USER = os.environ.get("ADMIN_USER", "garygeeke")
|
34
|
+
EGERIA_ADMIN_PASSWORD = os.environ.get("ADMIN_PASSWORD", "secret")
|
35
|
+
EGERIA_USER = os.environ.get("EGERIA_USER", "erinoverview")
|
36
|
+
EGERIA_USER_PASSWORD = os.environ.get("EGERIA_USER_PASSWORD", "secret")
|
37
|
+
EGERIA_JUPYTER = bool(os.environ.get("EGERIA_JUPYTER", "False"))
|
38
|
+
EGERIA_WIDTH = int(os.environ.get("EGERIA_WIDTH", "220"))
|
39
|
+
|
40
|
+
|
41
|
+
def list_related_elements_with_prop_value(
|
42
|
+
element_guid: str,
|
43
|
+
relationship_type: str,
|
44
|
+
property_value: str,
|
45
|
+
property_names: [str],
|
46
|
+
om_type: str,
|
47
|
+
server: str,
|
48
|
+
url: str,
|
49
|
+
username: str,
|
50
|
+
password: str,
|
51
|
+
jupyter: bool = EGERIA_JUPYTER,
|
52
|
+
width: int = EGERIA_WIDTH,
|
53
|
+
):
|
54
|
+
c_client = EgeriaTech(server, url, user_id=username, user_pwd=password)
|
55
|
+
token = c_client.create_egeria_bearer_token()
|
56
|
+
|
57
|
+
if om_type is not None:
|
58
|
+
om_typedef = c_client.get_typedef_by_name(om_type)
|
59
|
+
if type(om_typedef) is str:
|
60
|
+
print(
|
61
|
+
f"The type name '{om_type}' is not known to the Egeria platform at {url} - {server}"
|
62
|
+
)
|
63
|
+
sys.exit(1)
|
64
|
+
|
65
|
+
def generate_table() -> Table:
|
66
|
+
"""Make a new table."""
|
67
|
+
table = Table(
|
68
|
+
caption=f"Metadata Elements for: {url} - {server} @ {time.asctime()}",
|
69
|
+
style="bold bright_white on black",
|
70
|
+
row_styles=["bold bright_white on black"],
|
71
|
+
header_style="white on dark_blue",
|
72
|
+
title_style="bold bright_white on black",
|
73
|
+
caption_style="white on black",
|
74
|
+
show_lines=True,
|
75
|
+
box=box.ROUNDED,
|
76
|
+
title=f"Elements related to: '{element_guid}' ",
|
77
|
+
expand=True,
|
78
|
+
# width=500
|
79
|
+
)
|
80
|
+
table.add_column("Relationship GUID", width=38, no_wrap=True)
|
81
|
+
table.add_column("Rel Header", width=38, no_wrap=True)
|
82
|
+
table.add_column("Relationship Props")
|
83
|
+
table.add_column("Related GUID", width=38, no_wrap=True)
|
84
|
+
table.add_column("Properties")
|
85
|
+
table.add_column("Element Header")
|
86
|
+
|
87
|
+
elements = c_client.get_related_elements(
|
88
|
+
element_guid, relationship_type, om_type
|
89
|
+
)
|
90
|
+
|
91
|
+
if type(elements) is list:
|
92
|
+
for element in elements:
|
93
|
+
header = element["relationshipHeader"]
|
94
|
+
el_type = header["type"]["typeName"]
|
95
|
+
el_home = header["origin"]["homeMetadataCollectionName"]
|
96
|
+
el_create_time = header["versions"]["createTime"][:-10]
|
97
|
+
el_guid = header["guid"]
|
98
|
+
el_class = header.get("classifications", "---")
|
99
|
+
rel_header_md = (
|
100
|
+
f"* Type: {el_type}\n"
|
101
|
+
f"* Home: {el_home}\n"
|
102
|
+
f"* Created: {el_create_time}\n"
|
103
|
+
)
|
104
|
+
rel_header_out = Markdown(rel_header_md)
|
105
|
+
rel_props = element.get("relationshipProperties", "---")
|
106
|
+
|
107
|
+
rel_props_md = ""
|
108
|
+
if type(rel_props) is list:
|
109
|
+
for prop in rel_props.keys():
|
110
|
+
rel_props_md += (
|
111
|
+
f"* **{prop}**: {element['relationshipProperties'][prop]}\n"
|
112
|
+
)
|
113
|
+
rel_props_out = Markdown(rel_props_md)
|
114
|
+
|
115
|
+
c_md = ""
|
116
|
+
if type(el_class) is list:
|
117
|
+
for classification in el_class:
|
118
|
+
classification_name = classification.get(
|
119
|
+
"classificationName", "---"
|
120
|
+
)
|
121
|
+
c_md = f"* **{classification_name}**\n"
|
122
|
+
class_props = classification.get(
|
123
|
+
"classificationProperties", "---"
|
124
|
+
)
|
125
|
+
if type(class_props) is dict:
|
126
|
+
for prop in class_props.keys():
|
127
|
+
c_md += f" * **{prop}**: {class_props[prop]}\n"
|
128
|
+
c_md_out = Markdown(c_md)
|
129
|
+
|
130
|
+
rel_element = element["relatedElement"]
|
131
|
+
rel_el_header = rel_element["elementHeader"]
|
132
|
+
rel_type = rel_el_header["type"]["typeName"]
|
133
|
+
rel_home = rel_el_header["origin"]["homeMetadataCollectionName"]
|
134
|
+
rel_guid = rel_el_header["guid"]
|
135
|
+
|
136
|
+
rel_el_header_md = f"* Type: {rel_type}\n" f"* Home: {rel_home}\n"
|
137
|
+
rel_el_header_out = Markdown(rel_el_header_md)
|
138
|
+
|
139
|
+
rel_el_props_md = ""
|
140
|
+
for prop in rel_element["properties"].keys():
|
141
|
+
rel_el_props_md += (
|
142
|
+
f"* **{prop}**: {rel_element['properties'][prop]}\n"
|
143
|
+
)
|
144
|
+
rel_el_props_out = Markdown(rel_el_props_md)
|
145
|
+
|
146
|
+
table.add_row(
|
147
|
+
el_guid,
|
148
|
+
rel_header_out,
|
149
|
+
rel_props_out,
|
150
|
+
# el_q_name,
|
151
|
+
rel_guid,
|
152
|
+
rel_el_props_out,
|
153
|
+
rel_el_header_out,
|
154
|
+
)
|
155
|
+
|
156
|
+
return table
|
157
|
+
else:
|
158
|
+
print("No instances found")
|
159
|
+
sys.exit(1)
|
160
|
+
|
161
|
+
try:
|
162
|
+
console = Console(width=width, force_terminal=not jupyter)
|
163
|
+
|
164
|
+
with console.pager(styles=True):
|
165
|
+
console.print(generate_table())
|
166
|
+
|
167
|
+
except (
|
168
|
+
InvalidParameterException,
|
169
|
+
PropertyServerException,
|
170
|
+
UserNotAuthorizedException,
|
171
|
+
) as e:
|
172
|
+
print_exception_response(e)
|
173
|
+
print("\n\nPerhaps the type name isn't known")
|
174
|
+
finally:
|
175
|
+
c_client.close_session()
|
176
|
+
|
177
|
+
|
178
|
+
def main():
|
179
|
+
parser = argparse.ArgumentParser()
|
180
|
+
parser.add_argument("--server", help="Name of the server to display status for")
|
181
|
+
parser.add_argument("--url", help="URL Platform to connect to")
|
182
|
+
parser.add_argument("--userid", help="User Id")
|
183
|
+
parser.add_argument("--password", help="Password")
|
184
|
+
|
185
|
+
args = parser.parse_args()
|
186
|
+
|
187
|
+
server = args.server.strip() if args.server is not None else EGERIA_VIEW_SERVER
|
188
|
+
url = args.url.strip if args.url is not None else EGERIA_PLATFORM_URL
|
189
|
+
userid = args.userid.strip() if args.userid is not None else EGERIA_USER
|
190
|
+
password = (
|
191
|
+
args.password.strip() if args.password is not None else EGERIA_USER_PASSWORD
|
192
|
+
)
|
193
|
+
|
194
|
+
try:
|
195
|
+
element_guid = Prompt.ask("Guid of base element").strip()
|
196
|
+
relationship_type = Prompt.ask("Enter the relationship type to follow").strip()
|
197
|
+
property_value = Prompt.ask("Enter the property value to search for").strip()
|
198
|
+
property_names = Prompt.ask(
|
199
|
+
"Enter a comma seperated list of properties to search"
|
200
|
+
).strip()
|
201
|
+
om_type = Prompt.ask(
|
202
|
+
"Enter the Open Metadata Type to find elements of", default="Referenceable"
|
203
|
+
)
|
204
|
+
om_type = om_type.strip() if type(om_type) is str else None
|
205
|
+
list_related_elements_with_prop_value(
|
206
|
+
element_guid,
|
207
|
+
relationship_type,
|
208
|
+
property_value,
|
209
|
+
[property_names],
|
210
|
+
om_type,
|
211
|
+
server,
|
212
|
+
url,
|
213
|
+
userid,
|
214
|
+
password,
|
215
|
+
)
|
216
|
+
except KeyboardInterrupt:
|
217
|
+
pass
|
218
|
+
|
219
|
+
|
220
|
+
if __name__ == "__main__":
|
221
|
+
main()
|
@@ -19,22 +19,22 @@ from rich.prompt import Prompt
|
|
19
19
|
from rich.table import Table
|
20
20
|
|
21
21
|
from pyegeria import (
|
22
|
+
ClassificationManager,
|
22
23
|
InvalidParameterException,
|
23
24
|
PropertyServerException,
|
24
25
|
UserNotAuthorizedException,
|
25
26
|
print_exception_response,
|
26
|
-
ClassificationManager,
|
27
27
|
)
|
28
28
|
|
29
29
|
console = Console()
|
30
30
|
EGERIA_METADATA_STORE = os.environ.get("EGERIA_METADATA_STORE", "active-metadata-store")
|
31
31
|
EGERIA_KAFKA_ENDPOINT = os.environ.get("KAFKA_ENDPOINT", "localhost:9092")
|
32
32
|
EGERIA_PLATFORM_URL = os.environ.get("EGERIA_PLATFORM_URL", "https://localhost:9443")
|
33
|
-
EGERIA_VIEW_SERVER = os.environ.get("
|
33
|
+
EGERIA_VIEW_SERVER = os.environ.get("EGERIA_VIEW_SERVER", "view-server")
|
34
34
|
EGERIA_VIEW_SERVER_URL = os.environ.get(
|
35
35
|
"EGERIA_VIEW_SERVER_URL", "https://localhost:9443"
|
36
36
|
)
|
37
|
-
EGERIA_INTEGRATION_DAEMON = os.environ.get("
|
37
|
+
EGERIA_INTEGRATION_DAEMON = os.environ.get("EGERIA_INTEGRATION_DAEMON", "integration-daemon")
|
38
38
|
EGERIA_ADMIN_USER = os.environ.get("ADMIN_USER", "garygeeke")
|
39
39
|
EGERIA_ADMIN_PASSWORD = os.environ.get("ADMIN_PASSWORD", "secret")
|
40
40
|
EGERIA_USER = os.environ.get("EGERIA_USER", "erinoverview")
|
@@ -11,8 +11,7 @@ import argparse
|
|
11
11
|
import os
|
12
12
|
import time
|
13
13
|
|
14
|
-
from rich import box
|
15
|
-
from rich import print
|
14
|
+
from rich import box, print
|
16
15
|
from rich.console import Console
|
17
16
|
from rich.markdown import Markdown
|
18
17
|
from rich.prompt import Prompt
|
@@ -22,18 +21,18 @@ from pyegeria import (
|
|
22
21
|
InvalidParameterException,
|
23
22
|
PropertyServerException,
|
24
23
|
UserNotAuthorizedException,
|
24
|
+
ValidMetadataManager,
|
25
25
|
print_exception_response,
|
26
26
|
)
|
27
|
-
from pyegeria import ValidMetadataManager
|
28
27
|
|
29
28
|
EGERIA_METADATA_STORE = os.environ.get("EGERIA_METADATA_STORE", "active-metadata-store")
|
30
29
|
EGERIA_KAFKA_ENDPOINT = os.environ.get("KAFKA_ENDPOINT", "localhost:9092")
|
31
30
|
EGERIA_PLATFORM_URL = os.environ.get("EGERIA_PLATFORM_URL", "https://localhost:9443")
|
32
|
-
EGERIA_VIEW_SERVER = os.environ.get("
|
31
|
+
EGERIA_VIEW_SERVER = os.environ.get("EGERIA_VIEW_SERVER", "view-server")
|
33
32
|
EGERIA_VIEW_SERVER_URL = os.environ.get(
|
34
33
|
"EGERIA_VIEW_SERVER_URL", "https://localhost:9443"
|
35
34
|
)
|
36
|
-
EGERIA_INTEGRATION_DAEMON = os.environ.get("
|
35
|
+
EGERIA_INTEGRATION_DAEMON = os.environ.get("EGERIA_INTEGRATION_DAEMON", "integration-daemon")
|
37
36
|
EGERIA_ADMIN_USER = os.environ.get("ADMIN_USER", "garygeeke")
|
38
37
|
EGERIA_ADMIN_PASSWORD = os.environ.get("ADMIN_PASSWORD", "secret")
|
39
38
|
EGERIA_USER = os.environ.get("EGERIA_USER", "erinoverview")
|
@@ -20,21 +20,21 @@ from rich.prompt import Prompt
|
|
20
20
|
from rich.table import Table
|
21
21
|
|
22
22
|
from pyegeria import (
|
23
|
+
ClassificationManager,
|
23
24
|
InvalidParameterException,
|
24
25
|
PropertyServerException,
|
25
26
|
UserNotAuthorizedException,
|
26
|
-
ClassificationManager,
|
27
27
|
max_paging_size,
|
28
28
|
)
|
29
29
|
|
30
30
|
EGERIA_METADATA_STORE = os.environ.get("EGERIA_METADATA_STORE", "active-metadata-store")
|
31
31
|
EGERIA_KAFKA_ENDPOINT = os.environ.get("KAFKA_ENDPOINT", "localhost:9092")
|
32
32
|
EGERIA_PLATFORM_URL = os.environ.get("EGERIA_PLATFORM_URL", "https://localhost:9443")
|
33
|
-
EGERIA_VIEW_SERVER = os.environ.get("
|
33
|
+
EGERIA_VIEW_SERVER = os.environ.get("EGERIA_VIEW_SERVER", "view-server")
|
34
34
|
EGERIA_VIEW_SERVER_URL = os.environ.get(
|
35
35
|
"EGERIA_VIEW_SERVER_URL", "https://localhost:9443"
|
36
36
|
)
|
37
|
-
EGERIA_INTEGRATION_DAEMON = os.environ.get("
|
37
|
+
EGERIA_INTEGRATION_DAEMON = os.environ.get("EGERIA_INTEGRATION_DAEMON", "integration-daemon")
|
38
38
|
EGERIA_ADMIN_USER = os.environ.get("ADMIN_USER", "garygeeke")
|
39
39
|
EGERIA_ADMIN_PASSWORD = os.environ.get("ADMIN_PASSWORD", "secret")
|
40
40
|
EGERIA_USER = os.environ.get("EGERIA_USER", "erinoverview")
|
@@ -0,0 +1,181 @@
|
|
1
|
+
#!/usr/bin/env python3
|
2
|
+
"""
|
3
|
+
SPDX-License-Identifier: Apache-2.0
|
4
|
+
Copyright Contributors to the ODPi Egeria project.
|
5
|
+
|
6
|
+
A simple viewer for Information Solution Blueprints
|
7
|
+
|
8
|
+
"""
|
9
|
+
|
10
|
+
import argparse
|
11
|
+
import os
|
12
|
+
import time
|
13
|
+
|
14
|
+
from rich import box, print
|
15
|
+
from rich.console import Console
|
16
|
+
from rich.markdown import Markdown
|
17
|
+
from rich.panel import Panel
|
18
|
+
from rich.prompt import Prompt
|
19
|
+
from rich.table import Table
|
20
|
+
from rich.text import Text
|
21
|
+
from rich.tree import Tree
|
22
|
+
|
23
|
+
from pyegeria import (
|
24
|
+
InvalidParameterException,
|
25
|
+
ProjectManager,
|
26
|
+
PropertyServerException,
|
27
|
+
UserNotAuthorizedException,
|
28
|
+
save_mermaid_html,
|
29
|
+
)
|
30
|
+
from pyegeria._exceptions import print_exception_response
|
31
|
+
from pyegeria.mermaid_utilities import EGERIA_MERMAID_FOLDER
|
32
|
+
from pyegeria.solution_architect_omvs import SolutionArchitect
|
33
|
+
|
34
|
+
disable_ssl_warnings = True
|
35
|
+
EGERIA_METADATA_STORE = os.environ.get("EGERIA_METADATA_STORE", "active-metadata-store")
|
36
|
+
EGERIA_KAFKA_ENDPOINT = os.environ.get("KAFKA_ENDPOINT", "localhost:9092")
|
37
|
+
EGERIA_PLATFORM_URL = os.environ.get("EGERIA_PLATFORM_URL", "https://localhost:9443")
|
38
|
+
EGERIA_VIEW_SERVER = os.environ.get("EGERIA_VIEW_SERVER", "qs-view-server")
|
39
|
+
EGERIA_VIEW_SERVER_URL = os.environ.get(
|
40
|
+
"EGERIA_VIEW_SERVER_URL", "https://localhost:9443"
|
41
|
+
)
|
42
|
+
EGERIA_INTEGRATION_DAEMON = os.environ.get("EGERIA_INTEGRATION_DAEMON", "integration-daemon")
|
43
|
+
EGERIA_ADMIN_USER = os.environ.get("ADMIN_USER", "garygeeke")
|
44
|
+
EGERIA_ADMIN_PASSWORD = os.environ.get("ADMIN_PASSWORD", "secret")
|
45
|
+
EGERIA_USER = os.environ.get("EGERIA_USER", "erinoverview")
|
46
|
+
EGERIA_USER_PASSWORD = os.environ.get("EGERIA_USER_PASSWORD", "secret")
|
47
|
+
EGERIA_JUPYTER = bool(os.environ.get("EGERIA_JUPYTER", "False"))
|
48
|
+
EGERIA_WIDTH = int(os.environ.get("EGERIA_WIDTH", "150"))
|
49
|
+
EGERIA_MERMAID_FOLDER = os.environ.get("EGERIA_MERMAID_FOLDER", "work/mermaid_graphs")
|
50
|
+
|
51
|
+
|
52
|
+
def blueprint_list(
|
53
|
+
search_string: str,
|
54
|
+
server_name: str,
|
55
|
+
platform_url: str,
|
56
|
+
user: str,
|
57
|
+
user_password: str,
|
58
|
+
jupyter: bool = EGERIA_JUPYTER,
|
59
|
+
width: int = EGERIA_WIDTH,
|
60
|
+
timeout: int = 30,
|
61
|
+
):
|
62
|
+
"""A Supply Chain viewer"""
|
63
|
+
client = SolutionArchitect(server_name, platform_url, user, user_password)
|
64
|
+
token = client.create_egeria_bearer_token()
|
65
|
+
|
66
|
+
def generate_table() -> Table | str:
|
67
|
+
table = Table(
|
68
|
+
title=f"Blueprints matching {search_string} @ {time.asctime()}",
|
69
|
+
style="bright_white on black",
|
70
|
+
header_style="bright_white on dark_blue",
|
71
|
+
title_style="bold white on black",
|
72
|
+
caption_style="white on black",
|
73
|
+
show_lines=True,
|
74
|
+
box=box.ROUNDED,
|
75
|
+
caption=f"View Server '{server_name}' @ Platform - {platform_url}",
|
76
|
+
expand=True,
|
77
|
+
)
|
78
|
+
table.add_column("Blueprint Name / Diagram Link", justify="center")
|
79
|
+
table.add_column(
|
80
|
+
"Qualified Name / GUID / Version",
|
81
|
+
justify="center",
|
82
|
+
width=38,
|
83
|
+
no_wrap=False,
|
84
|
+
)
|
85
|
+
table.add_column("Description", justify="center")
|
86
|
+
table.add_column("Solution Components", justify="center")
|
87
|
+
|
88
|
+
blueprints = client.find_solution_blueprints(search_string)
|
89
|
+
if isinstance(blueprints, list) is False:
|
90
|
+
return "No Blueprints found"
|
91
|
+
|
92
|
+
for bp in blueprints:
|
93
|
+
bp_name = bp["properties"].get("displayName", "---")
|
94
|
+
bp_qname = bp["properties"].get("qualifiedName", "---")
|
95
|
+
bp_guid = bp["elementHeader"]["guid"]
|
96
|
+
bp_desc = bp["properties"].get("description", "---")
|
97
|
+
bp_unique_name = f"{bp_qname}\n\n--\n\n{bp_guid}"
|
98
|
+
bp_mermaid = bp.get("mermaidGraph", "---")
|
99
|
+
if bp_mermaid != "---":
|
100
|
+
link = save_mermaid_html(
|
101
|
+
bp_name, bp_mermaid, f"{EGERIA_MERMAID_FOLDER}/blueprints"
|
102
|
+
)
|
103
|
+
link = f"file://:{link}"
|
104
|
+
bp_mermaid = Text(link, style="blue link " + link)
|
105
|
+
|
106
|
+
bp_mermaid_label = Text(f"{bp_name}\n\n--\n\n{bp_mermaid}")
|
107
|
+
|
108
|
+
bp_components = bp.get("solutionComponents", [])
|
109
|
+
comp_md = ""
|
110
|
+
first_comp = True
|
111
|
+
for component in bp_components:
|
112
|
+
comp = component.get("solutionComponent", "")
|
113
|
+
if isinstance(comp, dict) is False:
|
114
|
+
continue
|
115
|
+
comp_props = comp.get("properties", {})
|
116
|
+
comp_name = comp_props.get("displayName", "---")
|
117
|
+
comp_description = comp_props.get("description", "---")
|
118
|
+
comp_planned = comp_props["extendedProperties"].get(
|
119
|
+
"plannedDeployedImplementationType", "---"
|
120
|
+
)
|
121
|
+
comp_type = comp_props.get("solutionComponentType", "---")
|
122
|
+
|
123
|
+
comp_actors = comp.get("actors", [])
|
124
|
+
comp_actors_list = f"{len(comp_actors)}\n"
|
125
|
+
for actor in comp_actors:
|
126
|
+
comp_actor_role = actor["relationshipProperties"].get("role", "---")
|
127
|
+
comp_actor_props = actor["relatedElement"].get("properties", {})
|
128
|
+
comp_actor_props_md = f"\n\t* Role: {comp_actor_role}\n"
|
129
|
+
for prop in comp_actor_props.keys():
|
130
|
+
comp_actor_props_md += f"\n\t\t* {prop}: {comp_actor_props[prop]}"
|
131
|
+
comp_actors_list += comp_actor_props_md
|
132
|
+
if first_comp:
|
133
|
+
first_comp = False
|
134
|
+
else:
|
135
|
+
comp_md += "\n\n---\n\n"
|
136
|
+
comp_md += f"Solution Component {comp_name}\n\n"
|
137
|
+
comp_md += f"* Type: {comp_type}\n"
|
138
|
+
comp_md += f"* Description: {comp_description}\n"
|
139
|
+
comp_md += f"* Planned Deployment: {comp_planned}\n"
|
140
|
+
comp_md += f"* Actors: {comp_actors_list}\n"
|
141
|
+
comp_out = Markdown(comp_md)
|
142
|
+
table.add_row(bp_mermaid_label, bp_unique_name, bp_desc, comp_out)
|
143
|
+
|
144
|
+
return table
|
145
|
+
|
146
|
+
try:
|
147
|
+
console = Console(width=width, force_terminal=not jupyter)
|
148
|
+
with console.pager():
|
149
|
+
console.print(generate_table())
|
150
|
+
|
151
|
+
except (
|
152
|
+
InvalidParameterException,
|
153
|
+
PropertyServerException,
|
154
|
+
UserNotAuthorizedException,
|
155
|
+
) as e:
|
156
|
+
print_exception_response(e)
|
157
|
+
|
158
|
+
|
159
|
+
def main():
|
160
|
+
parser = argparse.ArgumentParser()
|
161
|
+
|
162
|
+
parser.add_argument("--server", help="Name of the server to display status for")
|
163
|
+
parser.add_argument("--url", help="URL Platform to connect to")
|
164
|
+
parser.add_argument("--userid", help="User Id")
|
165
|
+
parser.add_argument("--password", help="User Password")
|
166
|
+
args = parser.parse_args()
|
167
|
+
|
168
|
+
server = args.server if args.server is not None else EGERIA_VIEW_SERVER
|
169
|
+
url = args.url if args.url is not None else EGERIA_PLATFORM_URL
|
170
|
+
userid = args.userid if args.userid is not None else EGERIA_USER
|
171
|
+
user_pass = args.password if args.password is not None else EGERIA_USER_PASSWORD
|
172
|
+
|
173
|
+
try:
|
174
|
+
search_string = Prompt.ask("Enter a search string:", default="*")
|
175
|
+
blueprint_list(search_string, server, url, userid, user_pass)
|
176
|
+
except KeyboardInterrupt:
|
177
|
+
pass
|
178
|
+
|
179
|
+
|
180
|
+
if __name__ == "__main__":
|
181
|
+
main()
|
@@ -0,0 +1,185 @@
|
|
1
|
+
#!/usr/bin/env python3
|
2
|
+
"""
|
3
|
+
SPDX-License-Identifier: Apache-2.0
|
4
|
+
Copyright Contributors to the ODPi Egeria project.
|
5
|
+
|
6
|
+
A simple viewer for Information Solution Components
|
7
|
+
|
8
|
+
"""
|
9
|
+
|
10
|
+
import argparse
|
11
|
+
import os
|
12
|
+
import time
|
13
|
+
|
14
|
+
from rich import box, print
|
15
|
+
from rich.console import Console
|
16
|
+
from rich.markdown import Markdown
|
17
|
+
from rich.panel import Panel
|
18
|
+
from rich.prompt import Prompt
|
19
|
+
from rich.table import Table
|
20
|
+
from rich.text import Text
|
21
|
+
from rich.tree import Tree
|
22
|
+
|
23
|
+
from pyegeria import (
|
24
|
+
InvalidParameterException,
|
25
|
+
ProjectManager,
|
26
|
+
PropertyServerException,
|
27
|
+
UserNotAuthorizedException,
|
28
|
+
save_mermaid_html,
|
29
|
+
)
|
30
|
+
from pyegeria._exceptions import print_exception_response
|
31
|
+
from pyegeria.mermaid_utilities import EGERIA_MERMAID_FOLDER
|
32
|
+
from pyegeria.solution_architect_omvs import SolutionArchitect
|
33
|
+
|
34
|
+
disable_ssl_warnings = True
|
35
|
+
EGERIA_METADATA_STORE = os.environ.get("EGERIA_METADATA_STORE", "active-metadata-store")
|
36
|
+
EGERIA_KAFKA_ENDPOINT = os.environ.get("KAFKA_ENDPOINT", "localhost:9092")
|
37
|
+
EGERIA_PLATFORM_URL = os.environ.get("EGERIA_PLATFORM_URL", "https://localhost:9443")
|
38
|
+
EGERIA_VIEW_SERVER = os.environ.get("EGERIA_VIEW_SERVER", "qs-view-server")
|
39
|
+
EGERIA_VIEW_SERVER_URL = os.environ.get(
|
40
|
+
"EGERIA_VIEW_SERVER_URL", "https://localhost:9443"
|
41
|
+
)
|
42
|
+
EGERIA_INTEGRATION_DAEMON = os.environ.get("EGERIA_INTEGRATION_DAEMON", "integration-daemon")
|
43
|
+
EGERIA_ADMIN_USER = os.environ.get("ADMIN_USER", "garygeeke")
|
44
|
+
EGERIA_ADMIN_PASSWORD = os.environ.get("ADMIN_PASSWORD", "secret")
|
45
|
+
EGERIA_USER = os.environ.get("EGERIA_USER", "erinoverview")
|
46
|
+
EGERIA_USER_PASSWORD = os.environ.get("EGERIA_USER_PASSWORD", "secret")
|
47
|
+
EGERIA_JUPYTER = bool(os.environ.get("EGERIA_JUPYTER", "False"))
|
48
|
+
EGERIA_WIDTH = int(os.environ.get("EGERIA_WIDTH", "150"))
|
49
|
+
EGERIA_MERMAID_FOLDER = os.environ.get("EGERIA_MERMAID_FOLDER", "work/mermaid_graphs")
|
50
|
+
|
51
|
+
|
52
|
+
def solution_component_list(
|
53
|
+
search_string: str,
|
54
|
+
server_name: str,
|
55
|
+
platform_url: str,
|
56
|
+
user: str,
|
57
|
+
user_password: str,
|
58
|
+
jupyter: bool = EGERIA_JUPYTER,
|
59
|
+
width: int = EGERIA_WIDTH,
|
60
|
+
timeout: int = 30,
|
61
|
+
):
|
62
|
+
"""A Solution Component viewer"""
|
63
|
+
client = SolutionArchitect(server_name, platform_url, user, user_password)
|
64
|
+
token = client.create_egeria_bearer_token()
|
65
|
+
|
66
|
+
def generate_table() -> Table | str:
|
67
|
+
table = Table(
|
68
|
+
title=f"Solution Components matching {search_string} @ {time.asctime()}",
|
69
|
+
style="bright_white on black",
|
70
|
+
header_style="bright_white on dark_blue",
|
71
|
+
title_style="bold white on black",
|
72
|
+
caption_style="white on black",
|
73
|
+
show_lines=True,
|
74
|
+
box=box.ROUNDED,
|
75
|
+
caption=f"View Server '{server_name}' @ Platform - {platform_url}",
|
76
|
+
expand=True,
|
77
|
+
)
|
78
|
+
table.add_column(
|
79
|
+
"Component Name / Diagram Link", justify="center", no_wrap=False
|
80
|
+
)
|
81
|
+
table.add_column("Component Type / Planned Deployment Type", justify="center")
|
82
|
+
table.add_column(
|
83
|
+
"Qualified Name / GUID", justify="center", width=38, no_wrap=False
|
84
|
+
)
|
85
|
+
table.add_column("Description / HeadCount", justify="center")
|
86
|
+
table.add_column("Sub-Components", justify="center")
|
87
|
+
|
88
|
+
components = client.find_solution_components(search_string)
|
89
|
+
if isinstance(components, list) is False:
|
90
|
+
return "No components found"
|
91
|
+
|
92
|
+
for component in components:
|
93
|
+
component_name = component["properties"].get("displayName", "---")
|
94
|
+
component_type = component["properties"].get("solutionComponentType", "---")
|
95
|
+
planned_deployment_type = (
|
96
|
+
component["properties"]
|
97
|
+
.get("extendedProperties", {})
|
98
|
+
.get("plannedDeployedImplementationType", "---")
|
99
|
+
)
|
100
|
+
component_info = f"Type: {component_type}\n\n--\n\nPlanned Deployment Type: \n{planned_deployment_type}"
|
101
|
+
|
102
|
+
component_qname = component["properties"].get("qualifiedName", "---")
|
103
|
+
component_guid = component["elementHeader"]["guid"]
|
104
|
+
component_unique_name = f"{component_qname}\n\n--\n\n{component_guid}"
|
105
|
+
|
106
|
+
component_desc = component["properties"].get("description", "---")
|
107
|
+
|
108
|
+
component_mermaid = component.get("mermaidGraph", "---")
|
109
|
+
if component_mermaid != "---":
|
110
|
+
link = save_mermaid_html(
|
111
|
+
component_name,
|
112
|
+
component_mermaid,
|
113
|
+
f"{EGERIA_MERMAID_FOLDER}/components",
|
114
|
+
)
|
115
|
+
link = f"file://:{link}"
|
116
|
+
component_mermaid = Text(link, style="blue link " + link)
|
117
|
+
|
118
|
+
component_mermaid_label = Text(
|
119
|
+
f"{component_name}\n\n--\n\n{component_mermaid}"
|
120
|
+
)
|
121
|
+
|
122
|
+
component_components = component.get("solutionComponents", [])
|
123
|
+
comp_props_md = ""
|
124
|
+
first_comp = True
|
125
|
+
for component in component_components:
|
126
|
+
comp = component.get("relatedElement", "")
|
127
|
+
if isinstance(comp, dict) is False:
|
128
|
+
continue
|
129
|
+
comp_props = comp.get("properties", {})
|
130
|
+
comp_props_md = ""
|
131
|
+
for prop in comp_props.keys():
|
132
|
+
comp_props_md += f"* **{prop}**: {comp_props[prop]}\n"
|
133
|
+
|
134
|
+
if first_comp:
|
135
|
+
first_comp = False
|
136
|
+
else:
|
137
|
+
comp_props_md += "\n\n---\n\n"
|
138
|
+
|
139
|
+
comp_props_out = Markdown(comp_props_md)
|
140
|
+
table.add_row(
|
141
|
+
component_mermaid_label,
|
142
|
+
component_info,
|
143
|
+
component_unique_name,
|
144
|
+
component_desc,
|
145
|
+
comp_props_out,
|
146
|
+
)
|
147
|
+
|
148
|
+
return table
|
149
|
+
|
150
|
+
try:
|
151
|
+
console = Console(width=width, force_terminal=not jupyter)
|
152
|
+
with console.pager():
|
153
|
+
console.print(generate_table())
|
154
|
+
|
155
|
+
except (
|
156
|
+
InvalidParameterException,
|
157
|
+
PropertyServerException,
|
158
|
+
UserNotAuthorizedException,
|
159
|
+
) as e:
|
160
|
+
print_exception_response(e)
|
161
|
+
|
162
|
+
|
163
|
+
def main():
|
164
|
+
parser = argparse.ArgumentParser()
|
165
|
+
|
166
|
+
parser.add_argument("--server", help="Name of the server to display status for")
|
167
|
+
parser.add_argument("--url", help="URL Platform to connect to")
|
168
|
+
parser.add_argument("--userid", help="User Id")
|
169
|
+
parser.add_argument("--password", help="User Password")
|
170
|
+
args = parser.parse_args()
|
171
|
+
|
172
|
+
server = args.server if args.server is not None else EGERIA_VIEW_SERVER
|
173
|
+
url = args.url if args.url is not None else EGERIA_PLATFORM_URL
|
174
|
+
userid = args.userid if args.userid is not None else EGERIA_USER
|
175
|
+
user_pass = args.password if args.password is not None else EGERIA_USER_PASSWORD
|
176
|
+
|
177
|
+
try:
|
178
|
+
search_string = Prompt.ask("Enter a search string:", default="*")
|
179
|
+
solution_component_list(search_string, server, url, userid, user_pass)
|
180
|
+
except KeyboardInterrupt:
|
181
|
+
pass
|
182
|
+
|
183
|
+
|
184
|
+
if __name__ == "__main__":
|
185
|
+
main()
|