pyegeria 0.2.4__py3-none-any.whl → 5.3.0.dev3__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.
Files changed (239) hide show
  1. pyegeria/README.md +35 -0
  2. pyegeria/__init__.py +345 -14
  3. pyegeria/_client.py +376 -126
  4. pyegeria/_deprecated_gov_engine.py +451 -0
  5. pyegeria/_exceptions.py +6 -6
  6. pyegeria/_globals.py +7 -1
  7. pyegeria/_validators.py +9 -6
  8. pyegeria/asset_catalog_omvs.py +807 -0
  9. pyegeria/automated_curation_omvs.py +3760 -0
  10. pyegeria/classification_manager_omvs.py +5238 -0
  11. pyegeria/collection_manager_omvs.py +2727 -0
  12. pyegeria/commands/README.md +47 -0
  13. pyegeria/commands/__init__.py +22 -0
  14. pyegeria/commands/cat/README.md +16 -0
  15. pyegeria/commands/cat/__init__.py +1 -0
  16. pyegeria/commands/cat/exp_list_glossaries.py +156 -0
  17. pyegeria/commands/cat/get_asset_graph.py +319 -0
  18. pyegeria/commands/cat/get_collection.py +148 -0
  19. pyegeria/commands/cat/get_project_dependencies.py +168 -0
  20. pyegeria/commands/cat/get_project_structure.py +168 -0
  21. pyegeria/commands/cat/get_tech_type_elements.py +174 -0
  22. pyegeria/commands/cat/glossary_actions.py +362 -0
  23. pyegeria/commands/cat/list_assets.py +176 -0
  24. pyegeria/commands/cat/list_cert_types.py +194 -0
  25. pyegeria/commands/cat/list_collections.py +162 -0
  26. pyegeria/commands/cat/list_deployed_catalogs.py +217 -0
  27. pyegeria/commands/cat/list_deployed_database_schemas.py +251 -0
  28. pyegeria/commands/cat/list_deployed_databases.py +202 -0
  29. pyegeria/commands/cat/list_glossaries.py +150 -0
  30. pyegeria/commands/cat/list_projects.py +221 -0
  31. pyegeria/commands/cat/list_servers_deployed_imp.py +158 -0
  32. pyegeria/commands/cat/list_tech_type_elements.py +190 -0
  33. pyegeria/commands/cat/list_tech_types.py +140 -0
  34. pyegeria/commands/cat/list_terms.py +242 -0
  35. pyegeria/commands/cat/list_todos.py +189 -0
  36. pyegeria/commands/cat/list_user_ids.py +145 -0
  37. pyegeria/commands/cli/__init__.py +13 -0
  38. pyegeria/commands/cli/egeria.py +1844 -0
  39. pyegeria/commands/cli/egeria_cat.py +638 -0
  40. pyegeria/commands/cli/egeria_login_tui.py +313 -0
  41. pyegeria/commands/cli/egeria_my.py +248 -0
  42. pyegeria/commands/cli/egeria_ops.py +502 -0
  43. pyegeria/commands/cli/egeria_tech.py +618 -0
  44. pyegeria/commands/cli/ops_config.py +45 -0
  45. pyegeria/commands/cli/txt_custom_v2.tcss +19 -0
  46. pyegeria/commands/doc/README.md +145 -0
  47. pyegeria/commands/doc/Visual Command Reference/README.md +511 -0
  48. pyegeria/commands/doc/Visual Command Reference/cat/show/assets/asset-graph 2024-11-20 at 15.56.42.png +0 -0
  49. pyegeria/commands/doc/Visual Command Reference/cat/show/assets/assets-in-domain 2024-11-20 at 15.49.55@2x.png +0 -0
  50. pyegeria/commands/doc/Visual Command Reference/cat/show/assets/elements-of-type 2024-11-20 at 16.01.35.png +0 -0
  51. pyegeria/commands/doc/Visual Command Reference/cat/show/assets/tech-type-elements 2024-11-20 at 16.05.05.png +0 -0
  52. pyegeria/commands/doc/Visual Command Reference/cat/show/deployed-data/deployed-data-catalogs 2024-12-17 at 15.43.27@2x.png +0 -0
  53. pyegeria/commands/doc/Visual Command Reference/cat/show/deployed-data/deployed-data-catalogs-2024-11-20 at 16.17.43@2x.png +0 -0
  54. pyegeria/commands/doc/Visual Command Reference/cat/show/deployed-data/deployed-schemas 2024-11-25 at 20.14.50@2x.png +0 -0
  55. pyegeria/commands/doc/Visual Command Reference/cat/show/deployed-data/deployed-schemas 2024-12-17 at 15.48.38@2x.png +0 -0
  56. pyegeria/commands/doc/Visual Command Reference/cat/show/deployed-data/deployed-servers 2024-11-25 at 20.21.25@2x.png +0 -0
  57. pyegeria/commands/doc/Visual Command Reference/cat/show/deployed-data/deployed-servers 2024-12-17 at 15.52.16@2x.png +0 -0
  58. pyegeria/commands/doc/Visual Command Reference/cat/show/deployed-data/deployed_databases 2024-12-16 at 16.40.31@2x.png +0 -0
  59. pyegeria/commands/doc/Visual Command Reference/cat/show/glossary/list-glossaries 2024-11-25 at 20.30.02.png +0 -0
  60. pyegeria/commands/doc/Visual Command Reference/cat/show/glossary/list-terms 2024-11-25 at 20.32.11.png +0 -0
  61. pyegeria/commands/doc/Visual Command Reference/cat/show/info/asset-types 2024-11-25 at 20.34.19@2x.png +0 -0
  62. pyegeria/commands/doc/Visual Command Reference/cat/show/info/certification-types 2024-11-25 at 20.37.07.png +0 -0
  63. pyegeria/commands/doc/Visual Command Reference/cat/show/info/collection-graph 2024-12-12 at 11.33.18@2x.png +0 -0
  64. pyegeria/commands/doc/Visual Command Reference/cat/show/info/list-collections 2024-12-10 at 14.25.51@2x.png +0 -0
  65. pyegeria/commands/doc/Visual Command Reference/cat/show/info/list-todos 2024-12-12 at 11.46.30@2x.png +0 -0
  66. pyegeria/commands/doc/Visual Command Reference/cat/show/info/list-user-ids 2024-12-12 at 11.51.09@2x.png +0 -0
  67. pyegeria/commands/doc/Visual Command Reference/cat/show/info/tech-types 2024-12-12 at 11.37.20@2x.png +0 -0
  68. pyegeria/commands/doc/Visual Command Reference/cat/show/projects/project_dependencies 2024-12-14 at 16.24.39@2x.png +0 -0
  69. pyegeria/commands/doc/Visual Command Reference/cat/show/projects/project_structure 2024-12-14 at 16.21.35@2x.png +0 -0
  70. pyegeria/commands/doc/Visual Command Reference/cat/show/projects/projects 2024-12-14 at 16.18.10@2x.png +0 -0
  71. pyegeria/commands/doc/Visual Command Reference/hey_egeria tui 2024-12-16 at 16.58.22@2x.png +0 -0
  72. pyegeria/commands/doc/Visual Command Reference/my/show/my_profile 2024-12-14 at 16.29.27@2x.png +0 -0
  73. pyegeria/commands/doc/Visual Command Reference/my/show/my_roles 2024-12-14 at 16.32.10@2x.png +0 -0
  74. pyegeria/commands/doc/Visual Command Reference/my/show/my_todos 2024-12-15 at 16.24.13@2x.png +0 -0
  75. pyegeria/commands/doc/Visual Command Reference/my/show/open_todos 2024-12-14 at 16.36.12@2x.png +0 -0
  76. pyegeria/commands/doc/Visual Command Reference/ops/show/engines/list_engine_activity compressed 2024-12-15 at 16.48.48@2x.png +0 -0
  77. pyegeria/commands/doc/Visual Command Reference/ops/show/engines/monitor_engine_activity 2024-12-15 at 16.32.55@2x.png +0 -0
  78. pyegeria/commands/doc/Visual Command Reference/ops/show/engines/monitor_engine_activity compressed 2024-12-15 at 16.38.29@2x.png +0 -0
  79. pyegeria/commands/doc/Visual Command Reference/ops/show/engines/monitor_engine_status 2024-12-15 at 16.51.26.jpeg +0 -0
  80. pyegeria/commands/doc/Visual Command Reference/ops/show/integrations/monitor_integration_daemon_status 2024-12-15 at 16.57.12@2x.png +0 -0
  81. pyegeria/commands/doc/Visual Command Reference/ops/show/integrations/monitor_integration_targets 2024-12-15 at 17.02.19@2x.png +0 -0
  82. pyegeria/commands/doc/Visual Command Reference/ops/show/platforms/monitor_platform_status 2024-12-15 at 19.53.18@2x.png +0 -0
  83. pyegeria/commands/doc/Visual Command Reference/ops/show/servers/monitor_server_status 2024-12-15 at 19.59.39@2x.png +0 -0
  84. pyegeria/commands/doc/Visual Command Reference/ops/show/servers/monitor_server_status full 2024-12-15 at 20.01.57@2x.png +0 -0
  85. pyegeria/commands/doc/Visual Command Reference/ops/show/servers/monitor_startup_servers 2024-12-15 at 19.56.07@2x.png +0 -0
  86. pyegeria/commands/doc/Visual Command Reference/tech/show/elements/get_anchored_elements 2024-12-15 at 21.25.41@2x.png +0 -0
  87. 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
  88. pyegeria/commands/doc/Visual Command Reference/tech/show/elements/info_for_guid 2024-12-16 at 11.35.29@2x.png +0 -0
  89. 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
  90. 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
  91. 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
  92. pyegeria/commands/doc/Visual Command Reference/tech/show/elements/related_elements 2024-12-16 at 14.55.01@2x.png +0 -0
  93. pyegeria/commands/doc/Visual Command Reference/tech/show/elements/show_related_specifications 2024-12-16 at 15.04.55@2x.png +0 -0
  94. pyegeria/commands/doc/Visual Command Reference/tech/show/tech-info/asset_types 2024-12-16 at 15.10.16@2x.png +0 -0
  95. 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
  96. pyegeria/commands/doc/Visual Command Reference/tech/show/tech-info/governance_action_processes 2024-12-16 at 15.13.01@2x.png +0 -0
  97. pyegeria/commands/doc/Visual Command Reference/tech/show/tech-info/registered_services 2024-12-16 at 16.44.54@2x.png +0 -0
  98. pyegeria/commands/doc/Visual Command Reference/tech/show/tech-info/relationship_types 2024-12-16 at 16.20.34@2x.png +0 -0
  99. pyegeria/commands/doc/Visual Command Reference/tech/show/tech-info/relationship_types 2024-12-19 at 10.51.54@2x.png +0 -0
  100. pyegeria/commands/doc/Visual Command Reference/tech/show/tech-info/valid_metadata_values 2024-12-16 at 15.31.56@2x.png +0 -0
  101. 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
  102. pyegeria/commands/doc/Visual Command Reference/tech/show/tech-types/list_technology_types 2024-12-16 at 15.39.20@2x.png +0 -0
  103. pyegeria/commands/doc/Visual Command Reference/tech/show/tech-types/tech_type_details 2024-12-16 at 15.37.21@2x.png +0 -0
  104. pyegeria/commands/doc/Visual Command Reference/tech/show/tech-types/tech_type_templates 2024-12-16 at 16.11.48@2x.png +0 -0
  105. pyegeria/commands/doc/glossary/basic-glossary-tui.md +109 -0
  106. pyegeria/commands/doc/glossary/images/delete-glossary-step1 2024-11-06 at 15.47.23@2x.png +0 -0
  107. pyegeria/commands/doc/glossary/images/delete-glossary-step2 2024-11-06 at 15.51.29@2x.png +0 -0
  108. pyegeria/commands/doc/glossary/images/delete-glossary-step3 2024-11-06 at 15.53.19@2x.png +0 -0
  109. pyegeria/commands/doc/glossary/images/delete-glossary-step4 2024-11-06 at 15.55.11@2x.png +0 -0
  110. pyegeria/commands/doc/glossary/images/out-create-glossary example 2024-11-05 at 20.38.04@2x.png +0 -0
  111. pyegeria/commands/doc/glossary/images/out-create-term 2024-11-06 at 20.48.29.png +0 -0
  112. pyegeria/commands/doc/glossary/images/out-delete-term 2024-11-07 at 03.57.25.png +0 -0
  113. pyegeria/commands/doc/glossary/images/out-display-terms-for-glossary-test 2024-11-06 at 20.51.28.png +0 -0
  114. pyegeria/commands/doc/glossary/images/out-export-example 2024-11-07 at 09.54.57.png +0 -0
  115. pyegeria/commands/doc/glossary/images/out-exported-terms 2024-11-06 at 21.06.32.png +0 -0
  116. pyegeria/commands/doc/glossary/images/out-glossary-list example 2024-11-05 at 20.41.02@2x.png +0 -0
  117. pyegeria/commands/doc/glossary/images/out-import-terms 2024-11-07 at 08.15.18.png +0 -0
  118. pyegeria/commands/doc/glossary/images/out-list-all-terms 2024-11-06 at 16.22.20@2x.png +0 -0
  119. pyegeria/commands/doc/glossary/images/out-list-terms-for-example 2024-11-06 at 16.40.12.png +0 -0
  120. pyegeria/commands/doc/glossary/images/out-list-terms-second 2024-11-06 at 16.45.13.png +0 -0
  121. pyegeria/commands/doc/glossary/images/out-pipx install pyegeria 2024-11-10 at 18.12.21.png +0 -0
  122. pyegeria/commands/doc/glossary/images/out-server-status-full 2024-11-10 at 18.25.14.png +0 -0
  123. pyegeria/commands/doc/glossary/images/out-servers-status 2024-11-10 at 18.15.42.png +0 -0
  124. pyegeria/commands/doc/glossary/images/out-upsert-import 2024-11-07 at 19.37.00.png +0 -0
  125. pyegeria/commands/doc/glossary/images/tui-2024-11-10 at 18.26.29.png +0 -0
  126. pyegeria/commands/doc/glossary/images/tui-create-glossary example 2024-11-05 at 20.34.24@2x.png +0 -0
  127. pyegeria/commands/doc/glossary/images/tui-create-term 2024-11-06 at 20.46.35.png +0 -0
  128. pyegeria/commands/doc/glossary/images/tui-delete-term 2024-11-07 at 03.51.57.png +0 -0
  129. pyegeria/commands/doc/glossary/images/tui-display-terms-for-example 2024-11-06 at 20.56.49.png +0 -0
  130. pyegeria/commands/doc/glossary/images/tui-export-example 2024-11-07 at 09.52.59.png +0 -0
  131. pyegeria/commands/doc/glossary/images/tui-hey-egeria 2024-11-10 at 18.31.01.png +0 -0
  132. pyegeria/commands/doc/glossary/images/tui-import-upsert-example 2024-11-07 at 10.08.37.png +0 -0
  133. pyegeria/commands/doc/glossary/images/tui-list-terms-second 2024-11-06 at 16.46.34.png +0 -0
  134. pyegeria/commands/doc/glossary/images/tui-load-archive.png +0 -0
  135. pyegeria/commands/doc/glossary/images/tui-server-status-full 2024-11-10 at 19.14.36.png +0 -0
  136. pyegeria/commands/doc/glossary/images/tui-show-glossaries 2024-11-07 at 20.00.05.png +0 -0
  137. pyegeria/commands/doc/glossary/images/tui-show-glossary-terms 2024-11-05 at 19.37.53@2x.png +0 -0
  138. pyegeria/commands/doc/glossary/images/tui-upsert 2024-11-07 at 11.49.04.png +0 -0
  139. pyegeria/commands/doc/glossary/images/upsert-example.om-terms 2024-11-07 at 11.44.05.png +0 -0
  140. pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/README.md +346 -0
  141. pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/images/CleanShot 2024-11-18 at 21.32.03@2x.png +0 -0
  142. pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/images/Xmind 1731421782704.png +0 -0
  143. pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/images/Xmind 1731422134920.png +0 -0
  144. pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/images/hey_egeria 2024-11-12 at 20.38.43.png +0 -0
  145. pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/images/hey_egeria cat 2024-11-12 at 21.41.43.png +0 -0
  146. 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
  147. 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
  148. 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
  149. 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
  150. pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/images/short-cut commands 2024-11-12 at 22.22.13.png +0 -0
  151. pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/images/tui-hey-egeria.png +0 -0
  152. pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/images/tui-integration-status-paging.png +0 -0
  153. 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
  154. 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
  155. pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/images/tui-show-server-status-full 2024-11-10.png +0 -0
  156. 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
  157. pyegeria/commands/my/README.md +17 -0
  158. pyegeria/commands/my/__init__.py +0 -0
  159. pyegeria/commands/my/list_my_profile.py +163 -0
  160. pyegeria/commands/my/list_my_roles.py +151 -0
  161. pyegeria/commands/my/monitor_my_todos.py +205 -0
  162. pyegeria/commands/my/monitor_open_todos.py +175 -0
  163. pyegeria/commands/my/todo_actions.py +242 -0
  164. pyegeria/commands/ops/README.md +24 -0
  165. pyegeria/commands/ops/__init__.py +22 -0
  166. pyegeria/commands/ops/gov_server_actions.py +177 -0
  167. pyegeria/commands/ops/list_archives.py +161 -0
  168. pyegeria/commands/ops/list_catalog_targets.py +203 -0
  169. pyegeria/commands/ops/load_archive.py +75 -0
  170. pyegeria/commands/ops/monitor_asset_events.py +107 -0
  171. pyegeria/commands/ops/monitor_engine_activity.py +270 -0
  172. pyegeria/commands/ops/monitor_engine_activity_c.py +286 -0
  173. pyegeria/commands/ops/monitor_gov_eng_status.py +288 -0
  174. pyegeria/commands/ops/monitor_integ_daemon_status.py +321 -0
  175. pyegeria/commands/ops/monitor_platform_status.py +188 -0
  176. pyegeria/commands/ops/monitor_server_startup.py +117 -0
  177. pyegeria/commands/ops/monitor_server_status.py +182 -0
  178. pyegeria/commands/ops/orig_monitor_server_list.py +140 -0
  179. pyegeria/commands/ops/orig_monitor_server_status.py +124 -0
  180. pyegeria/commands/ops/refresh_integration_daemon.py +83 -0
  181. pyegeria/commands/ops/restart_integration_daemon.py +82 -0
  182. pyegeria/commands/ops/table_integ_daemon_status.py +237 -0
  183. pyegeria/commands/ops/x_engine_actions.py +76 -0
  184. pyegeria/commands/tech/README.md +24 -0
  185. pyegeria/commands/tech/__init__.py +0 -0
  186. pyegeria/commands/tech/get_element_info.py +144 -0
  187. pyegeria/commands/tech/get_guid_info.py +134 -0
  188. pyegeria/commands/tech/get_tech_details.py +173 -0
  189. pyegeria/commands/tech/get_tech_type_template.py +166 -0
  190. pyegeria/commands/tech/list_anchored_elements.py +205 -0
  191. pyegeria/commands/tech/list_asset_types.py +123 -0
  192. pyegeria/commands/tech/list_elements.py +168 -0
  193. pyegeria/commands/tech/list_elements_for_classification.py +171 -0
  194. pyegeria/commands/tech/list_elements_x.py +191 -0
  195. pyegeria/commands/tech/list_gov_action_processes.py +139 -0
  196. pyegeria/commands/tech/list_registered_services.py +180 -0
  197. pyegeria/commands/tech/list_related_elements.py +207 -0
  198. pyegeria/commands/tech/list_related_specification.py +169 -0
  199. pyegeria/commands/tech/list_relationship_types.py +164 -0
  200. pyegeria/commands/tech/list_relationships.py +179 -0
  201. pyegeria/commands/tech/list_tech_templates.py +360 -0
  202. pyegeria/commands/tech/list_valid_metadata_values.py +178 -0
  203. pyegeria/commands/tech/table_tech_templates.py +238 -0
  204. pyegeria/commands/tech/x_list_related_elements.py +165 -0
  205. pyegeria/core_omag_server_config.py +550 -313
  206. pyegeria/create_tech_guid_lists.py +105 -0
  207. pyegeria/egeria_cat_client.py +78 -0
  208. pyegeria/egeria_client.py +117 -0
  209. pyegeria/egeria_config_client.py +45 -0
  210. pyegeria/egeria_my_client.py +56 -0
  211. pyegeria/egeria_tech_client.py +93 -0
  212. pyegeria/feedback_manager_omvs.py +4573 -0
  213. pyegeria/full_omag_server_config.py +1337 -0
  214. pyegeria/glossary_browser_omvs.py +2507 -0
  215. pyegeria/glossary_manager_omvs.py +3597 -0
  216. pyegeria/mermaid_utilities.py +218 -0
  217. pyegeria/metadata_explorer_omvs.py +2371 -0
  218. pyegeria/my_profile_omvs.py +1021 -0
  219. pyegeria/platform_services.py +259 -218
  220. pyegeria/project_manager_omvs.py +1854 -0
  221. pyegeria/registered_info.py +111 -108
  222. pyegeria/runtime_manager_omvs.py +2299 -0
  223. pyegeria/server_operations.py +178 -71
  224. pyegeria/template_manager_omvs.py +1414 -0
  225. pyegeria/utils.py +75 -85
  226. pyegeria/valid_metadata_omvs.py +1911 -0
  227. pyegeria/x_action_author_omvs.py +200 -0
  228. pyegeria-5.3.0.dev3.dist-info/METADATA +70 -0
  229. pyegeria-5.3.0.dev3.dist-info/RECORD +232 -0
  230. {pyegeria-0.2.4.dist-info → pyegeria-5.3.0.dev3.dist-info}/WHEEL +1 -1
  231. pyegeria-5.3.0.dev3.dist-info/entry_points.txt +81 -0
  232. pyegeria/config.toml +0 -11
  233. pyegeria/curation_omvs.py +0 -458
  234. pyegeria/exceptions.py +0 -382
  235. pyegeria/glossary_omvs.py +0 -639
  236. pyegeria/gov_engine.py +0 -573
  237. pyegeria-0.2.4.dist-info/METADATA +0 -57
  238. pyegeria-0.2.4.dist-info/RECORD +0 -19
  239. {pyegeria-0.2.4.dist-info/licenses → pyegeria-5.3.0.dev3.dist-info}/LICENSE +0 -0
@@ -0,0 +1,286 @@
1
+ #!/usr/bin/env python3
2
+ """
3
+ SPDX-License-Identifier: Apache-2.0
4
+ Copyright Contributors to the ODPi Egeria project.
5
+
6
+ Unit tests for the Utils helper functions using the Pytest framework.
7
+
8
+
9
+ A simple status display for Engine Actions
10
+ """
11
+
12
+ import argparse
13
+ import json
14
+ import os
15
+ import sys
16
+ import time
17
+
18
+ from rich import box
19
+ from rich.console import Console
20
+ from rich.live import Live
21
+ from rich.markdown import Markdown
22
+ from rich.table import Table
23
+
24
+ from pyegeria import AutomatedCuration
25
+ from pyegeria import (
26
+ InvalidParameterException,
27
+ PropertyServerException,
28
+ UserNotAuthorizedException,
29
+ print_exception_response,
30
+ )
31
+
32
+ EGERIA_METADATA_STORE = os.environ.get("EGERIA_METADATA_STORE", "active-metadata-store")
33
+ EGERIA_KAFKA_ENDPOINT = os.environ.get("EGERIA_KAFKA_ENDPOINT", "localhost:9092")
34
+ EGERIA_PLATFORM_URL = os.environ.get("EGERIA_PLATFORM_URL", "https://localhost:9443")
35
+ EGERIA_VIEW_SERVER = os.environ.get("EGERIA_VIEW_SERVER", "view-server")
36
+ EGERIA_VIEW_SERVER_URL = os.environ.get(
37
+ "EGERIA_VIEW_SERVER_URL", "https://localhost:9443"
38
+ )
39
+ EGERIA_ENGINE_HOST = os.environ.get("EGERIA_ENGINE_HOST", "engine-host")
40
+ EGERIA_ENGINE_HOST_URL = os.environ.get(
41
+ "EGERIA_ENGINE_HOST_URL", "https://localhost:9443"
42
+ )
43
+ EGERIA_INTEGRATION_DAEMON = os.environ.get(
44
+ "EGERIA_INTEGRATION_DAEMON", "integration_daemon"
45
+ )
46
+ EGERIA_ADMIN_USER = os.environ.get("EGERIA_ADMIN_USER", "garygeeke")
47
+ EGERIA_ADMIN_PASSWORD = os.environ.get("EGERIA_ADMIN_PASSWORD", "secret")
48
+ EGERIA_USER = os.environ.get("EGERIA_USER", "erinoverview")
49
+ EGERIA_USER_PASSWORD = os.environ.get("EGERIA_USER_PASSWORD", "secret")
50
+ EGERIA_JUPYTER = bool(os.environ.get("EGERIA_JUPYTER", "False"))
51
+ EGERIA_WIDTH = int(os.environ.get("EGERIA_WIDTH", "200"))
52
+
53
+ disable_ssl_warnings = True
54
+
55
+
56
+ def display_engine_activity_c(
57
+ row_limit: int = 0,
58
+ view_server: str = EGERIA_VIEW_SERVER,
59
+ view_url: str = EGERIA_VIEW_SERVER_URL,
60
+ user: str = EGERIA_USER,
61
+ user_pass: str = EGERIA_USER_PASSWORD,
62
+ paging: bool = True,
63
+ jupyter: bool = EGERIA_JUPYTER,
64
+ width: int = EGERIA_WIDTH,
65
+ ):
66
+ """Display governance engine activity as a table.
67
+
68
+ Parameters
69
+ ----------
70
+ row_limit : int, opt, default = 0
71
+ If non-zero, limit the number of rows returned
72
+ view_server : str
73
+ The Egeria view server name.
74
+ view_url : str
75
+ The URL for the Egeria view server.
76
+ user : str
77
+ The user name for authenticating with the Egeria server.
78
+ user_pass : str
79
+ The user password for authenticating with the Egeria server.
80
+ paging : bool, default is True
81
+ Whether to enable paging mode when displaying the table.
82
+ jupyter : bool
83
+ Indicates if the environment is a Jupyter notebook.
84
+ width : int
85
+ The width of the console for table printing.
86
+ """
87
+ g_client = AutomatedCuration(view_server, view_url, user, user_pwd=user_pass)
88
+
89
+ def generate_table() -> Table:
90
+ """Make a new table."""
91
+ table = Table(
92
+ title=f"Engine Action Status for Platform {view_url} @ {time.asctime()}",
93
+ style="bold white on black",
94
+ row_styles=["bold white on black"],
95
+ header_style="white on dark_blue",
96
+ title_style="bold white on black",
97
+ caption_style="white on black",
98
+ show_lines=True,
99
+ box=box.ROUNDED,
100
+ caption=f"Engine Status for Server '{view_server}' @ Platform - {view_url}",
101
+ expand=True,
102
+ )
103
+ table.add_column("Requested Time")
104
+ table.add_column("Core Info")
105
+ table.add_column("Target Elements")
106
+
107
+ table.add_column("Action Status")
108
+ table.add_column("Completion Time")
109
+ table.add_column("Core Results")
110
+ # table.add_column("Completion Message")
111
+
112
+ token = g_client.create_egeria_bearer_token()
113
+ action_status = g_client.get_engine_actions()
114
+
115
+ if type(action_status) is str:
116
+ requested_time = " "
117
+ start_time = " "
118
+ completion_time = " "
119
+ engine_name = " "
120
+ request_type = " "
121
+ action_status = " "
122
+ target_element = " "
123
+ process_name = " "
124
+ completion_message = " "
125
+ elif type(action_status) is list:
126
+ sorted_action_status = sorted(
127
+ action_status,
128
+ key=lambda i: i.get("requestedTime", time.asctime()),
129
+ reverse=True,
130
+ )
131
+ row_count = 0
132
+ for action in sorted_action_status:
133
+ if row_limit > 0 and row_count >= row_limit:
134
+ break
135
+ row_count += 1
136
+ requested_time = action.get("requestedTime", " ")[:-10]
137
+ start_time = action.get("startTime", " ")[:-10]
138
+ completion_time = action.get("completionTime", " ")[:-10]
139
+ completion_guards = action.get("completionGuards", " ")
140
+
141
+ engine_name = action["governanceEngineName"]
142
+ request_type = action["requestType"]
143
+ action_guid = action["elementHeader"]["guid"]
144
+ if action["actionStatus"] in (
145
+ "REQUESTED",
146
+ "APPROVED",
147
+ "WAITING",
148
+ "ACTIVATING",
149
+ ):
150
+ action_status = f"[yellow]{action['actionStatus']}"
151
+ elif action["actionStatus"] in ("IN_PROGRESS", "ACTIONED"):
152
+ action_status = f"[green]{action['actionStatus']}"
153
+ else:
154
+ action_status = f"[red]{action['actionStatus']}"
155
+
156
+ request_parameters_md = " "
157
+ request_parameters = action.get("requestParameters", "Empty")
158
+ if type(request_parameters) is dict:
159
+ for key, value in request_parameters.items():
160
+ request_parameters_md += f"\t* {key}: {value}\n"
161
+
162
+ targets = action.get("actionTargetElements", "Empty")
163
+ if type(targets) is list:
164
+ targets_md = ""
165
+ for target in targets:
166
+ t_name = target["actionTargetName"]
167
+ t_guid = target["actionTargetGUID"]
168
+ t_type = target["targetElement"]["type"]["typeName"]
169
+ targets_md += (
170
+ f"* Target Name: {t_name}\n"
171
+ f" * Target GUID: {t_guid}\n"
172
+ f" * Target Type: {t_type}\n"
173
+ )
174
+
175
+ # target_element = json.dumps(target[0]["targetElement"]["elementProperties"]["propertiesAsStrings"])
176
+ target_element = Markdown(f"{targets_md} ---\n")
177
+ else:
178
+ target_element = " "
179
+
180
+ process_name = action.get("processName", "Null")
181
+ completion_message = action.get("completionMessage", " ")
182
+ core_results_md = (
183
+ f"* Completion Guards: {completion_guards}\n"
184
+ f"* Completion Message: {completion_message}"
185
+ )
186
+ core_results_out = Markdown(core_results_md)
187
+ core_info_md = (
188
+ f"* Start Time: {start_time}\n* Engine Name: {engine_name}\n* GUID: {action_guid}\n"
189
+ f"* Request Type: {request_type}\n"
190
+ f"* Process Name: {process_name}\n"
191
+ f"---\n"
192
+ f"* Request Parameters: \n{request_parameters_md}\n"
193
+ )
194
+ core_info_out = Markdown(core_info_md)
195
+ table.add_row(
196
+ requested_time,
197
+ core_info_out,
198
+ target_element,
199
+ action_status,
200
+ completion_time,
201
+ core_results_out,
202
+ )
203
+ else:
204
+ print("Egeria integration daemon not running")
205
+ sys.exit()
206
+
207
+ return table
208
+
209
+ try:
210
+ if paging is True:
211
+ console = Console(width=width, force_terminal=not jupyter)
212
+ with console.pager():
213
+ console.print(generate_table())
214
+ else:
215
+ with Live(
216
+ generate_table(),
217
+ refresh_per_second=1,
218
+ screen=True,
219
+ vertical_overflow="visible",
220
+ ) as live:
221
+ while True:
222
+ time.sleep(2)
223
+ live.update(generate_table())
224
+
225
+ except (
226
+ InvalidParameterException,
227
+ PropertyServerException,
228
+ UserNotAuthorizedException,
229
+ ) as e:
230
+ print_exception_response(e)
231
+ except KeyboardInterrupt:
232
+ pass
233
+ finally:
234
+ g_client.close_session()
235
+
236
+
237
+ def main_live():
238
+ parser = argparse.ArgumentParser()
239
+ parser.add_argument(
240
+ "--rowlimit", default=0, help="Number of rows to return; 0 for all"
241
+ )
242
+ parser.add_argument("--server", help="Name of the server to display status for")
243
+ parser.add_argument("--url", help="URL Platform to connect to")
244
+ parser.add_argument("--userid", help="User Id")
245
+ parser.add_argument("--password", help="User Password")
246
+
247
+ args = parser.parse_args()
248
+
249
+ server = args.server if args.server is not None else EGERIA_VIEW_SERVER
250
+ url = args.url if args.url is not None else EGERIA_VIEW_SERVER_URL
251
+ userid = args.userid if args.userid is not None else EGERIA_USER
252
+ user_pass = args.password if args.password is not None else EGERIA_USER_PASSWORD
253
+ rowlimit = int(args.rowlimit) if args.rowlimit is not None else 0
254
+ display_engine_activity_c(
255
+ rowlimit, server, url, user=userid, user_pass=user_pass, paging=False
256
+ )
257
+
258
+
259
+ def main_paging():
260
+ parser = argparse.ArgumentParser()
261
+ parser.add_argument(
262
+ "--rowlimit", default=0, help="Number of rows to return; 0 for all"
263
+ )
264
+ parser.add_argument("--server", help="Name of the server to display status for")
265
+ parser.add_argument("--url", help="URL Platform to connect to")
266
+ parser.add_argument("--userid", help="User Id")
267
+ parser.add_argument("--password", help="User Password")
268
+
269
+ args = parser.parse_args()
270
+
271
+ server = args.server if args.server is not None else EGERIA_VIEW_SERVER
272
+ url = args.url if args.url is not None else EGERIA_VIEW_SERVER_URL
273
+ userid = args.userid if args.userid is not None else EGERIA_USER
274
+ user_pass = args.password if args.password is not None else EGERIA_USER_PASSWORD
275
+ rowlimit = int(args.rowlimit) if args.rowlimit is not None else 0
276
+
277
+ display_engine_activity_c(
278
+ rowlimit, server, url, user=userid, user_pass=user_pass, paging=True
279
+ )
280
+
281
+
282
+ if __name__ == "__main__":
283
+ main_live()
284
+
285
+ if __name__ == "__main_paging__":
286
+ main_paging()
@@ -0,0 +1,288 @@
1
+ #!/usr/bin/env python3
2
+ """
3
+ SPDX-License-Identifier: Apache-2.0
4
+ Copyright Contributors to the ODPi Egeria project.
5
+
6
+ Unit tests for the Utils helper functions using the Pytest framework.
7
+
8
+
9
+ A simple status display for Governance Actions
10
+ """
11
+ import argparse
12
+ import os
13
+ import time
14
+
15
+ from rich import box
16
+ from rich.console import Console
17
+ from rich.live import Live
18
+ from rich.markdown import Markdown
19
+ from rich.prompt import Prompt
20
+ from rich.table import Table
21
+
22
+ from pyegeria import (
23
+ InvalidParameterException,
24
+ PropertyServerException,
25
+ UserNotAuthorizedException,
26
+ EgeriaTech,
27
+ )
28
+
29
+ EGERIA_METADATA_STORE = os.environ.get("EGERIA_METADATA_STORE", "active-metadata-store")
30
+ EGERIA_KAFKA_ENDPOINT = os.environ.get("KAFKA_ENDPOINT", "localhost:9092")
31
+ EGERIA_PLATFORM_URL = os.environ.get("EGERIA_PLATFORM_URL", "https://localhost:9443")
32
+ EGERIA_VIEW_SERVER = os.environ.get("VIEW_SERVER", "view-server")
33
+ EGERIA_VIEW_SERVER_URL = os.environ.get(
34
+ "EGERIA_VIEW_SERVER_URL", "https://localhost:9443"
35
+ )
36
+ EGERIA_INTEGRATION_DAEMON = os.environ.get(
37
+ "EGERIA_INTEGRATION_DAEMON", "integration_daemon"
38
+ )
39
+ EGERIA_ENGINE_HOST = os.environ.get("EGERIA_ENGINE_HOST", "engine-host")
40
+ EGERIA_ENGINE_HOST_URL = os.environ.get(
41
+ "EGERIA_ENGINE_HOST_URL", "https://localhost:9443"
42
+ )
43
+ EGERIA_ADMIN_USER = os.environ.get("EGERIA_ADMIN_USER", "garygeeke")
44
+ EGERIA_ADMIN_PASSWORD = os.environ.get("EGERIA_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", "200"))
49
+
50
+
51
+ disable_ssl_warnings = True
52
+
53
+
54
+ def display_gov_eng_status(
55
+ search_list: list[str] = ["*"],
56
+ status_filter=["*"],
57
+ engine_host: str = EGERIA_ENGINE_HOST,
58
+ view_server: str = EGERIA_VIEW_SERVER,
59
+ url: str = EGERIA_VIEW_SERVER_URL,
60
+ username: str = EGERIA_USER,
61
+ user_pass: str = EGERIA_USER_PASSWORD,
62
+ paging: bool = True,
63
+ jupyter: bool = EGERIA_JUPYTER,
64
+ width: int = EGERIA_WIDTH,
65
+ sort: bool = True,
66
+ ) -> None:
67
+ """Displays the status table of the governance engines on the specified Engine Host OMAG Server
68
+
69
+ Parameters
70
+ ----------
71
+
72
+ search_list : list of str
73
+ List of governance engine names to search for. Defaults to ["*"] which returns all governance engines.
74
+ status_filter: list of str, default is all
75
+ List of status values to filter by.
76
+ engine_host : str
77
+ The host name of the governance engine.
78
+ view_server : str
79
+ The name of the view server to interact with.
80
+ url : str
81
+ The URL of the view server.
82
+ username : str
83
+ Username for authentication with the view server.
84
+ user_pass : str
85
+ Password for authentication with the view server.
86
+ paging : bool
87
+ Determines whether to use a pager or live monitor for output. Defaults to True.
88
+ jupyter : bool
89
+ Specifies if the code is running in a Jupyter environment. Defaults to EGERIA_JUPYTER.
90
+ width : int
91
+ Width of the console output. Defaults to EGERIA_WIDTH.
92
+ sort : bool
93
+ Determines whether to sort the governance engine statuses. Defaults to True.
94
+
95
+ Returns
96
+ -------
97
+
98
+ Nothing
99
+ """
100
+ console = Console(width=EGERIA_WIDTH)
101
+
102
+ s_client = EgeriaTech(view_server, url, username, user_pass)
103
+ token = s_client.create_egeria_bearer_token()
104
+
105
+ def generate_table(search_list: list[str]) -> Table:
106
+ """Make a new table."""
107
+ table = Table(
108
+ title=f"Governance Engine Status @ {time.asctime()}",
109
+ style="bold white on black",
110
+ row_styles=["bold white on black"],
111
+ header_style="white on dark_blue",
112
+ title_style="bold white on black",
113
+ caption_style="white on black",
114
+ show_lines=True,
115
+ box=box.ROUNDED,
116
+ caption=f"Server: '{engine_host}' running on {url}",
117
+ expand=True,
118
+ )
119
+ # table.footer: f"Server {view_server} on Platform {good_platform1_url}"
120
+ table.add_column("Gov Engine")
121
+ table.add_column("Gov Engine Type")
122
+ table.add_column("Gov Engine Desc")
123
+ table.add_column("Engine Status")
124
+ table.add_column("Request Types")
125
+
126
+ # eng_host_guid = s_client.get_guid_for_name(engine_host)
127
+ gov_eng_status = s_client.get_server_report(
128
+ server_guid=None, server_name=engine_host
129
+ )
130
+ eng_summaries = gov_eng_status["governanceEngineSummaries"]
131
+
132
+ if sort is True:
133
+ engine_info = sorted(
134
+ eng_summaries, key=lambda k: k.get("governanceEngineName", " ")
135
+ )
136
+ else:
137
+ engine_info = eng_summaries
138
+
139
+ for engine in engine_info:
140
+ gov_eng = engine["governanceEngineName"]
141
+
142
+ if (gov_eng not in search_list) and (search_list != ["*"]):
143
+ # if specific engines are requested and it doesn't match, then skip
144
+ continue
145
+ eng_type = engine.get("governanceEngineTypeName", " ")
146
+
147
+ eng_desc = engine.get("governanceEngineDescription", " ")
148
+ eng_req_types = engine.get("governanceRequestTypes", " ")
149
+ eng_req_type_md = " "
150
+ if type(eng_req_types) is list:
151
+ for i in eng_req_types:
152
+ eng_req_type_md += f"* {i}\n"
153
+ eng_req_type_out = Markdown(eng_req_type_md)
154
+ else:
155
+ eng_req_type_out = " "
156
+ status = engine["governanceEngineStatus"]
157
+ if (status not in status_filter) and (status_filter != ["*"]):
158
+ continue
159
+ if status in ("RUNNING"):
160
+ eng_status = f"[green]{status}"
161
+ elif status in ("FAILED"):
162
+ eng_status = f"[red]{status}"
163
+ else:
164
+ eng_status = f"[yellow]{status}"
165
+
166
+ table.add_row(gov_eng, eng_type, eng_desc, eng_status, eng_req_type_out)
167
+
168
+ return table
169
+
170
+ try:
171
+ if paging is True:
172
+ console = Console(width=width, force_terminal=not jupyter)
173
+ with console.pager():
174
+ console.print(generate_table(search_list))
175
+ else:
176
+ with Live(
177
+ generate_table(search_list),
178
+ refresh_per_second=1,
179
+ screen=True,
180
+ vertical_overflow="visible",
181
+ ) as live:
182
+ while True:
183
+ time.sleep(2)
184
+ live.update(generate_table(search_list))
185
+
186
+ except (
187
+ InvalidParameterException,
188
+ PropertyServerException,
189
+ UserNotAuthorizedException,
190
+ ) as e:
191
+ console.print_exception(show_locals=True)
192
+
193
+ except KeyboardInterrupt:
194
+ pass
195
+
196
+ finally:
197
+ s_client.close_session()
198
+
199
+
200
+ def main_live():
201
+ parser = argparse.ArgumentParser()
202
+ parser.add_argument(
203
+ "--engine_host", help="Name of the server to display status for"
204
+ )
205
+ parser.add_argument("--view_server", help="Name of the view server to use")
206
+ parser.add_argument("--url", help="URL Platform to connect to")
207
+ parser.add_argument("--userid", help="User Id")
208
+ parser.add_argument("--password", help="User Password")
209
+ # parser.add_argument("--paging", help="Paging")
210
+ args = parser.parse_args()
211
+
212
+ engine_host = (
213
+ args.engine_host if args.engine_host is not None else EGERIA_ENGINE_HOST
214
+ )
215
+ view_server = (
216
+ args.view_server if args.view_server is not None else EGERIA_VIEW_SERVER
217
+ )
218
+ url = args.url if args.url is not None else EGERIA_ENGINE_HOST_URL
219
+ userid = args.userid if args.userid is not None else EGERIA_USER
220
+ user_pass = args.password if args.password is not None else EGERIA_USER_PASSWORD
221
+ paging = False
222
+
223
+ search_list = Prompt.ask(
224
+ "Enter the list of engines you are interested in or ['*'] for all",
225
+ default=["*"],
226
+ )
227
+ status_filter = Prompt.ask(
228
+ "Enter a list of status values to filter for or ['*'] for all",
229
+ default=["*"],
230
+ )
231
+ display_gov_eng_status(
232
+ search_list,
233
+ engine_host=engine_host,
234
+ view_server=view_server,
235
+ url=url,
236
+ username=userid,
237
+ user_pass=user_pass,
238
+ paging=paging,
239
+ status_filter=status_filter,
240
+ )
241
+
242
+
243
+ def main_paging():
244
+ parser = argparse.ArgumentParser()
245
+ parser.add_argument(
246
+ "--engine_host", help="Name of the engine host to display status for"
247
+ )
248
+ parser.add_argument("--view_server", help="Name of the view server to use")
249
+ parser.add_argument("--url", help="URL of Platform to connect to")
250
+ parser.add_argument("--userid", help="User Id")
251
+ parser.add_argument("--password", help="User Password")
252
+ args = parser.parse_args()
253
+
254
+ engine_host = (
255
+ args.engine_host if args.engine_host is not None else EGERIA_ENGINE_HOST
256
+ )
257
+ view_server = (
258
+ args.view_server if args.view_server is not None else EGERIA_VIEW_SERVER
259
+ )
260
+ url = args.url if args.url is not None else EGERIA_VIEW_SERVER_URL
261
+ userid = args.userid if args.userid is not None else EGERIA_USER
262
+ user_pass = args.password if args.password is not None else EGERIA_USER_PASSWORD
263
+ paging = True
264
+ search_list = Prompt.ask(
265
+ "Enter the list of engines you are interested in or ['*'] for all",
266
+ default=["*"],
267
+ )
268
+ status_filter = Prompt.ask(
269
+ "Enter a list of status values to filter for or ['*'] for all",
270
+ default=["*"],
271
+ )
272
+ display_gov_eng_status(
273
+ search_list,
274
+ engine_host=engine_host,
275
+ view_server=view_server,
276
+ url=url,
277
+ username=userid,
278
+ user_pass=user_pass,
279
+ paging=paging,
280
+ status_filter=status_filter,
281
+ )
282
+
283
+
284
+ if __name__ == "__main__":
285
+ main_live()
286
+
287
+ if __name__ == "__main_paging__":
288
+ main_paging()