pyegeria 5.2__py3-none-any.whl → 5.2.0.1__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 (117) hide show
  1. pyegeria/__init__.py +0 -2
  2. pyegeria/_client.py +2 -7
  3. pyegeria/asset_catalog_omvs.py +0 -34
  4. pyegeria/classification_manager_omvs.py +3 -2
  5. pyegeria/collection_manager_omvs.py +45 -92
  6. pyegeria/commands/README.md +1 -2
  7. pyegeria/commands/cat/__init__.py +5 -1
  8. pyegeria/commands/cat/get_collection.py +14 -23
  9. pyegeria/commands/cat/get_tech_type_elements.py +1 -1
  10. pyegeria/commands/cat/glossary_actions.py +8 -28
  11. pyegeria/commands/cat/list_assets.py +17 -8
  12. pyegeria/commands/cat/list_collections.py +5 -10
  13. pyegeria/commands/cat/list_deployed_catalogs.py +2 -4
  14. pyegeria/commands/cat/list_deployed_database_schemas.py +14 -8
  15. pyegeria/commands/cat/list_deployed_databases.py +3 -2
  16. pyegeria/commands/cat/list_tech_types.py +24 -36
  17. pyegeria/commands/cat/list_terms.py +2 -4
  18. pyegeria/commands/cli/egeria.py +117 -106
  19. pyegeria/commands/cli/egeria_cat.py +54 -53
  20. pyegeria/commands/cli/egeria_my.py +33 -25
  21. pyegeria/commands/cli/egeria_ops.py +40 -38
  22. pyegeria/commands/cli/egeria_tech.py +41 -55
  23. pyegeria/commands/cli/ops_config.py +1 -3
  24. pyegeria/commands/doc/Visual Command Reference/cat/show/deployed-data/CleanShot 2024-11-20 at 16.17.43@2x.png +0 -0
  25. pyegeria/commands/doc/{README.md → command-overview.md} +5 -50
  26. pyegeria/commands/doc/hey_egeria: a pyegeria command line interface/{README.md → hey_egeria: overview.md } +1 -1
  27. pyegeria/commands/my/monitor_my_todos.py +5 -17
  28. pyegeria/commands/my/monitor_open_todos.py +1 -1
  29. pyegeria/commands/ops/monitor_asset_events.py +22 -27
  30. pyegeria/commands/ops/monitor_engine_activity_c.py +1 -1
  31. pyegeria/commands/ops/monitor_gov_eng_status.py +4 -31
  32. pyegeria/commands/ops/monitor_integ_daemon_status.py +14 -17
  33. pyegeria/commands/ops/monitor_platform_status.py +1 -1
  34. pyegeria/commands/ops/orig_monitor_server_status.py +21 -36
  35. pyegeria/commands/ops/refresh_integration_daemon.py +1 -1
  36. pyegeria/commands/ops/restart_integration_daemon.py +1 -1
  37. pyegeria/commands/tech/get_tech_details.py +42 -79
  38. pyegeria/commands/tech/get_tech_type_template.py +53 -69
  39. pyegeria/commands/tech/list_anchored_elements.py +15 -18
  40. pyegeria/commands/tech/list_elements_x.py +4 -7
  41. pyegeria/commands/tech/list_registered_services.py +1 -1
  42. pyegeria/commands/tech/list_relationship_types.py +21 -19
  43. pyegeria/commands/tech/list_relationships.py +3 -7
  44. pyegeria/commands/tech/table_tech_templates.py +1 -3
  45. pyegeria/create_tech_guid_lists.py +2 -2
  46. pyegeria/egeria_client.py +0 -2
  47. pyegeria/egeria_tech_client.py +0 -5
  48. pyegeria/glossary_manager_omvs.py +7 -101
  49. pyegeria/server_operations.py +4 -4
  50. pyegeria/template_manager_omvs.py +3 -1
  51. pyegeria/valid_metadata_omvs.py +1 -1
  52. {pyegeria-5.2.dist-info → pyegeria-5.2.0.1.dist-info}/METADATA +5 -3
  53. pyegeria-5.2.0.1.dist-info/RECORD +176 -0
  54. {pyegeria-5.2.dist-info → pyegeria-5.2.0.1.dist-info}/entry_points.txt +0 -2
  55. pyegeria/commands/cat/list_tech_type_elements.py +0 -190
  56. pyegeria/commands/cli/egeria_login_tui.py +0 -313
  57. pyegeria/commands/cli/txt_custom_v2.tcss +0 -19
  58. pyegeria/commands/doc/Visual Command Reference/README.md +0 -511
  59. pyegeria/commands/doc/Visual Command Reference/cat/show/deployed-data/deployed-data-catalogs 2024-12-17 at 15.43.27@2x.png +0 -0
  60. pyegeria/commands/doc/Visual Command Reference/cat/show/deployed-data/deployed-schemas 2024-11-25 at 20.14.50@2x.png +0 -0
  61. pyegeria/commands/doc/Visual Command Reference/cat/show/deployed-data/deployed-schemas 2024-12-17 at 15.48.38@2x.png +0 -0
  62. pyegeria/commands/doc/Visual Command Reference/cat/show/deployed-data/deployed-servers 2024-11-25 at 20.21.25@2x.png +0 -0
  63. pyegeria/commands/doc/Visual Command Reference/cat/show/deployed-data/deployed-servers 2024-12-17 at 15.52.16@2x.png +0 -0
  64. pyegeria/commands/doc/Visual Command Reference/cat/show/deployed-data/deployed_databases 2024-12-16 at 16.40.31@2x.png +0 -0
  65. pyegeria/commands/doc/Visual Command Reference/cat/show/glossary/list-glossaries 2024-11-25 at 20.30.02.png +0 -0
  66. pyegeria/commands/doc/Visual Command Reference/cat/show/glossary/list-terms 2024-11-25 at 20.32.11.png +0 -0
  67. pyegeria/commands/doc/Visual Command Reference/cat/show/info/asset-types 2024-11-25 at 20.34.19@2x.png +0 -0
  68. pyegeria/commands/doc/Visual Command Reference/cat/show/info/certification-types 2024-11-25 at 20.37.07.png +0 -0
  69. pyegeria/commands/doc/Visual Command Reference/cat/show/info/collection-graph 2024-12-12 at 11.33.18@2x.png +0 -0
  70. pyegeria/commands/doc/Visual Command Reference/cat/show/info/list-collections 2024-12-10 at 14.25.51@2x.png +0 -0
  71. pyegeria/commands/doc/Visual Command Reference/cat/show/info/list-todos 2024-12-12 at 11.46.30@2x.png +0 -0
  72. pyegeria/commands/doc/Visual Command Reference/cat/show/info/list-user-ids 2024-12-12 at 11.51.09@2x.png +0 -0
  73. pyegeria/commands/doc/Visual Command Reference/cat/show/info/tech-types 2024-12-12 at 11.37.20@2x.png +0 -0
  74. pyegeria/commands/doc/Visual Command Reference/cat/show/projects/project_dependencies 2024-12-14 at 16.24.39@2x.png +0 -0
  75. pyegeria/commands/doc/Visual Command Reference/cat/show/projects/project_structure 2024-12-14 at 16.21.35@2x.png +0 -0
  76. pyegeria/commands/doc/Visual Command Reference/cat/show/projects/projects 2024-12-14 at 16.18.10@2x.png +0 -0
  77. pyegeria/commands/doc/Visual Command Reference/hey_egeria tui 2024-12-16 at 16.58.22@2x.png +0 -0
  78. pyegeria/commands/doc/Visual Command Reference/my/show/my_profile 2024-12-14 at 16.29.27@2x.png +0 -0
  79. pyegeria/commands/doc/Visual Command Reference/my/show/my_roles 2024-12-14 at 16.32.10@2x.png +0 -0
  80. pyegeria/commands/doc/Visual Command Reference/my/show/my_todos 2024-12-15 at 16.24.13@2x.png +0 -0
  81. pyegeria/commands/doc/Visual Command Reference/my/show/open_todos 2024-12-14 at 16.36.12@2x.png +0 -0
  82. pyegeria/commands/doc/Visual Command Reference/ops/show/engines/list_engine_activity compressed 2024-12-15 at 16.48.48@2x.png +0 -0
  83. pyegeria/commands/doc/Visual Command Reference/ops/show/engines/monitor_engine_activity 2024-12-15 at 16.32.55@2x.png +0 -0
  84. pyegeria/commands/doc/Visual Command Reference/ops/show/engines/monitor_engine_activity compressed 2024-12-15 at 16.38.29@2x.png +0 -0
  85. pyegeria/commands/doc/Visual Command Reference/ops/show/engines/monitor_engine_status 2024-12-15 at 16.51.26.jpeg +0 -0
  86. pyegeria/commands/doc/Visual Command Reference/ops/show/integrations/monitor_integration_daemon_status 2024-12-15 at 16.57.12@2x.png +0 -0
  87. pyegeria/commands/doc/Visual Command Reference/ops/show/integrations/monitor_integration_targets 2024-12-15 at 17.02.19@2x.png +0 -0
  88. pyegeria/commands/doc/Visual Command Reference/ops/show/platforms/monitor_platform_status 2024-12-15 at 19.53.18@2x.png +0 -0
  89. pyegeria/commands/doc/Visual Command Reference/ops/show/servers/monitor_server_status 2024-12-15 at 19.59.39@2x.png +0 -0
  90. pyegeria/commands/doc/Visual Command Reference/ops/show/servers/monitor_server_status full 2024-12-15 at 20.01.57@2x.png +0 -0
  91. pyegeria/commands/doc/Visual Command Reference/ops/show/servers/monitor_startup_servers 2024-12-15 at 19.56.07@2x.png +0 -0
  92. pyegeria/commands/doc/Visual Command Reference/tech/show/elements/get_anchored_elements 2024-12-15 at 21.25.41@2x.png +0 -0
  93. 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
  94. pyegeria/commands/doc/Visual Command Reference/tech/show/elements/info_for_guid 2024-12-16 at 11.35.29@2x.png +0 -0
  95. 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
  96. 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
  97. 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
  98. pyegeria/commands/doc/Visual Command Reference/tech/show/elements/related_elements 2024-12-16 at 14.55.01@2x.png +0 -0
  99. pyegeria/commands/doc/Visual Command Reference/tech/show/elements/show_related_specifications 2024-12-16 at 15.04.55@2x.png +0 -0
  100. pyegeria/commands/doc/Visual Command Reference/tech/show/tech-info/asset_types 2024-12-16 at 15.10.16@2x.png +0 -0
  101. 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
  102. pyegeria/commands/doc/Visual Command Reference/tech/show/tech-info/governance_action_processes 2024-12-16 at 15.13.01@2x.png +0 -0
  103. pyegeria/commands/doc/Visual Command Reference/tech/show/tech-info/registered_services 2024-12-16 at 16.44.54@2x.png +0 -0
  104. pyegeria/commands/doc/Visual Command Reference/tech/show/tech-info/relationship_types 2024-12-16 at 16.20.34@2x.png +0 -0
  105. pyegeria/commands/doc/Visual Command Reference/tech/show/tech-info/relationship_types 2024-12-19 at 10.51.54@2x.png +0 -0
  106. pyegeria/commands/doc/Visual Command Reference/tech/show/tech-info/valid_metadata_values 2024-12-16 at 15.31.56@2x.png +0 -0
  107. 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
  108. pyegeria/commands/doc/Visual Command Reference/tech/show/tech-types/list_technology_types 2024-12-16 at 15.39.20@2x.png +0 -0
  109. pyegeria/commands/doc/Visual Command Reference/tech/show/tech-types/tech_type_details 2024-12-16 at 15.37.21@2x.png +0 -0
  110. pyegeria/commands/doc/Visual Command Reference/tech/show/tech-types/tech_type_templates 2024-12-16 at 16.11.48@2x.png +0 -0
  111. pyegeria/metadata_explorer_omvs.py +0 -2371
  112. pyegeria-5.2.dist-info/RECORD +0 -232
  113. /pyegeria/commands/doc/Visual Command Reference/cat/show/assets/{asset-graph 2024-11-20 at 15.56.42.png → Asset-graph 2024-11-20 at 15.56.42.png} +0 -0
  114. /pyegeria/commands/doc/Visual Command Reference/cat/show/assets/{assets-in-domain 2024-11-20 at 15.49.55@2x.png → Assets-in-domain 2024-11-20 at 15.49.55@2x.png} +0 -0
  115. /pyegeria/commands/doc/Visual Command Reference/cat/show/{deployed-data/deployed-data-catalogs-2024-11-20 at 16.17.43@2x.png → assets/deployed-catalogs 2024-11-20 at 16.17.43@2x.png} +0 -0
  116. {pyegeria-5.2.dist-info → pyegeria-5.2.0.1.dist-info}/LICENSE +0 -0
  117. {pyegeria-5.2.dist-info → pyegeria-5.2.0.1.dist-info}/WHEEL +0 -0
@@ -9,9 +9,6 @@ A command line interface for Egeria Data techs.
9
9
  This is an emerging capability based on the **click** package. Feedback welcome!
10
10
 
11
11
  """
12
- import os
13
- import sys
14
-
15
12
  import click
16
13
  from trogon import tui
17
14
 
@@ -26,7 +23,7 @@ from pyegeria.commands.tech.list_relationship_types import display_relationship_
26
23
  from pyegeria.commands.tech.list_tech_templates import display_templates_spec
27
24
  from pyegeria.commands.tech.list_valid_metadata_values import display_metadata_values
28
25
  from pyegeria.commands.tech.get_tech_type_template import template_viewer
29
- from pyegeria.commands.tech.list_anchored_elements import display_anchored_elements
26
+ from pyegeria.commands.tech.list_anchored_elements import display_element_graph
30
27
  from pyegeria.commands.tech.list_elements import list_elements
31
28
 
32
29
  from pyegeria.commands.tech.get_element_info import display_elements
@@ -64,81 +61,87 @@ from pyegeria.commands.tech.get_tech_type_template import template_viewer
64
61
  @click.group()
65
62
  @click.option(
66
63
  "--server",
67
- default=os.environ.get("EGERIA_METADATA_STORE", "active-metadata-store"),
64
+ default="active-metadata-store",
65
+ envvar="EGERIA_METADATA_STORE",
68
66
  help="Egeria metadata store to work with",
69
67
  )
70
68
  @click.option(
71
69
  "--url",
72
- default=os.environ.get("EGERIA_PLATFORM_URL", "https://localhost:9443"),
70
+ default="https://localhost:9443",
71
+ envvar="EGERIA_PLATFORM_URL",
73
72
  help="URL of Egeria metadata store platform to connect to",
74
73
  )
75
74
  @click.option(
76
- "--integration_daemon",
77
- default=os.environ.get("EGERIA_INTEGRATION_DAEMON", "integration-daemon"),
75
+ "--integration-daemon",
76
+ default="integration-daemon",
77
+ envvar="EGERIA_INTEGRATION_DAEMON",
78
78
  help="Egeria integration daemon to work with",
79
79
  )
80
80
  @click.option(
81
81
  "--integration_daemon_url",
82
- default=os.environ.get("EGERIA_INTEGRATION_DAEMON_URL", "https://localhost:9443"),
82
+ default="https://localhost:9443",
83
+ envvar="EGERIA_INTEGRATION_DAEMON_URL",
83
84
  help="URL of Egeria integration daemon platform to connect to",
84
85
  )
85
86
  @click.option(
86
87
  "--view_server",
87
- default=os.environ.get("EGERIA_VIEW_SERVER", "view-server"),
88
+ default="view-server",
89
+ envvar="EGERIA_VIEW_SERVER",
88
90
  help="Egeria view server to work with",
89
91
  )
90
92
  @click.option(
91
93
  "--view_server_url",
92
- default=os.environ.get("EGERIA_VIEW_SERVER_URL", "https://localhost:9443"),
94
+ default="https://localhost:9443",
95
+ envvar="EGERIA_VIEW_SERVER_URL",
93
96
  help="URL of Egeria view server platform to connect to",
94
97
  )
95
98
  @click.option(
96
99
  "--engine_host",
97
- default=os.environ.get("EGERIA_ENGINE_HOST", "engine-host"),
100
+ default="engine-host",
101
+ envvar="EGERIA_ENGINE_HOST",
98
102
  help="Egeria engine host to work with",
99
103
  )
100
104
  @click.option(
101
105
  "--engine_host_url",
102
- default=os.environ.get("EGERIA_ENGINE_HOST_URL", "https://localhost:9443"),
106
+ default="https://localhost:9443",
107
+ envvar="EGERIA_ENGINE_HOST_URL",
103
108
  help="URL of Egeria engine host platform to connect to",
104
109
  )
105
110
  @click.option(
106
111
  "--admin_user",
107
- default=os.environ.get("EGERIA_ADMIN_USER", "garygeeke"),
112
+ default="garygeeke",
113
+ envvar="EGERIA_ADMIN_USER",
108
114
  help="Egeria admin user",
109
115
  )
110
116
  @click.option(
111
117
  "--admin_user_password",
112
- default=os.environ.get("EGERIA_ADMIN_PASSWORD", "secret"),
118
+ default="secret",
119
+ envvar="EGERIA_ADMIN_PASSWORD",
113
120
  help="Egeria admin password",
114
121
  )
115
122
  @click.option(
116
- "--userid",
117
- default=os.environ.get("EGERIA_USER", "peterprofile"),
118
- help="Egeria user",
123
+ "--userid", default="peterprofile", envvar="EGERIA_USER", help="Egeria user"
119
124
  )
120
125
  @click.option(
121
126
  "--password",
122
- default=os.environ.get("EGERIA_USER_PASSWORD", "secret"),
127
+ default="secret",
128
+ envvar="EGERIA_PASSWORD",
123
129
  help="Egeria user password",
124
130
  )
125
131
  @click.option("--timeout", default=60, help="Number of seconds to wait")
126
132
  @click.option(
127
133
  "--jupyter",
128
134
  is_flag=True,
129
- default=os.environ.get("EGERIA_JUPYTER", "False"),
135
+ default=False,
136
+ envvar="EGERIA_JUPYTER",
130
137
  help="Enable for rendering in a Jupyter terminal",
131
138
  )
132
139
  @click.option(
133
140
  "--width",
134
- default=os.environ.get("EGERIA_WIDTH", "200"),
141
+ default=200,
142
+ envvar="EGERIA_WIDTH",
135
143
  help="Screen width, in characters, to use",
136
144
  )
137
- @click.option(
138
- "--home_glossary_guid",
139
- default=os.environ.get("EGERIA_HOME_GLOSSARY_GUID", None),
140
- help="Glossary guid to use as the home glossary",
141
- )
142
145
  @click.pass_context
143
146
  def cli(
144
147
  ctx,
@@ -210,8 +213,8 @@ def show_elements(ctx):
210
213
  @show_elements.command("guid-info")
211
214
  @click.argument("guid", nargs=1)
212
215
  @click.pass_context
213
- def show_guid_info(ctx, guid):
214
- """Display guid information
216
+ def show_guid_infos(ctx, guid):
217
+ """Display a live status view of known platforms
215
218
 
216
219
  Usage: show guid-info <a guid>
217
220
 
@@ -237,39 +240,22 @@ def show_related_specifications(ctx, element_guid):
237
240
  )
238
241
 
239
242
 
240
- @show_elements.command("anchored-elements")
243
+ @show_elements.command("element-graph")
241
244
  @click.pass_context
245
+ @click.option("--search-string", help="value we are searching for")
242
246
  @click.option(
243
- "--search-string",
244
- default="SoftwareCapability",
245
- help="value we are searching for",
246
- )
247
- @click.option(
248
- "--prop-list",
249
- default="anchorDomainName",
250
- help="List of properties we are searching",
247
+ "--prop-list", default="anchorTypeName", help="List of properties we are searching"
251
248
  )
252
- def list_anchored_elements(ctx, search_string: str, prop_list: str):
249
+ def list_element_graph(ctx, search_string: str, prop_list: str):
253
250
  """List elements with the specified properties"""
254
251
  c = ctx.obj
255
- # put guards around this to make it a list?
256
- if type(prop_list) is str:
257
- property_names = prop_list.split(",")
258
- elif type(prop_list) is list:
259
- property_names = prop_list
260
- else:
261
- property_names = []
262
- print(f"\nError --> Invalid property list - must be a string or list")
263
- sys.exit(4)
264
-
265
- display_anchored_elements(
252
+ display_element_graph(
266
253
  search_string,
267
- property_names,
254
+ prop_list,
268
255
  c.view_server,
269
256
  c.view_server_url,
270
257
  c.userid,
271
258
  c.password,
272
- c.timeout,
273
259
  c.jupyter,
274
260
  c.width,
275
261
  )
@@ -381,7 +367,7 @@ def show_registered_services(ctx, services):
381
367
 
382
368
  @show_info.command("relationship-types")
383
369
  @click.option(
384
- "--om-type",
370
+ "--rel-type",
385
371
  default="AssetOwner",
386
372
  help="Relationship type to get information about",
387
373
  )
@@ -414,7 +400,7 @@ def show_relationship_types(ctx, rel_type):
414
400
  )
415
401
  @click.pass_context
416
402
  def show_elements_by_classification(ctx, om_type, classification):
417
- """Show elements by classification"""
403
+ """Show information about the specified relationship type"""
418
404
  c = ctx.obj
419
405
  list_classified_elements(
420
406
  om_type,
@@ -444,8 +430,8 @@ def show_elements_by_classification(ctx, om_type, classification):
444
430
  help="Relationship type to follow.",
445
431
  )
446
432
  @click.pass_context
447
- def show_related_elements(ctx, element_guid, om_type, rel_type):
448
- """Show information about related elements"""
433
+ def show_relationship_types(ctx, element_guid, om_type, rel_type):
434
+ """Show information about the specified relationship type"""
449
435
  c = ctx.obj
450
436
  list_related_elements(
451
437
  element_guid,
@@ -8,7 +8,7 @@ class Config(object):
8
8
  url: str = None,
9
9
  view_server: str = "view-server",
10
10
  view_server_url: str = "https://localhost:9443",
11
- integration_daemon: str = "integration_daemon",
11
+ integration_daemon: str = "integration-daemon",
12
12
  integration_daemon_url: str = "https://localhost:9443",
13
13
  engine_host: str = "engine-host",
14
14
  engine_host_url: str = "https://localhost:9443",
@@ -19,7 +19,6 @@ class Config(object):
19
19
  timeout: int = 30,
20
20
  jupyter: bool = False,
21
21
  width: int = 200,
22
- home_glossary_guid: str = None,
23
22
  ):
24
23
  self.metadata_store = server
25
24
  self.metadata_store_url = url
@@ -38,7 +37,6 @@ class Config(object):
38
37
  self.width = width
39
38
  self.server = server
40
39
  self.url = url
41
- self.home_glossary_guid = home_glossary_guid
42
40
 
43
41
 
44
42
  pass_config = click.make_pass_decorator(Config)
@@ -1,60 +1,18 @@
1
1
  <!-- SPDX-License-Identifier: CC-BY-4.0 -->
2
2
  <!-- Copyright Contributors to the Egeria project. -->
3
-
4
3
  # Overview
5
4
 
6
- **hey_egeria** is a friendly, easy to use, command line interface (CLI) for Egeria with both a scriptable component and a textual user
7
- interface to guide
8
- users through the different commands and options. This interface is being actively maintained and enhanced. There are
9
- currently about 70 commands in the interface and new ones are added based on perceived need and community feedback.
10
-
11
- The CLI is written in python using the [click](https://click.palletsprojects.com/en/stable/) package
12
- with [trogon](https://github.com/Textualize/trogon)
13
- providing the textual user interface. The commands are written using [pyegeria](https://github.com/odpi/egeria-python)
14
- or
15
- https://pypi.org/project/pyegeria/. Commands are also available standalone. Simple standalone installation instructions
16
- are
17
- documented at [pyegeria](https://egeria-project.org/concepts/pyegeria). pyegeria and hey_egeria are pre-installed within
18
- the **Egeria Workspaces** environment - [Egeria Workspaces](https://github.com/odpi/egeria-workspaces).
19
-
20
5
  # Command Line Interfaces
21
- ## Commands
22
- A command line interface provides a simple language for users to invoke commands. In the case of **hey_egeria**, once it
23
- is installed, you can
24
- start simply by typing `hey_egeria` on the command line and it will provide a list of options and commands that you can
25
- use to interact with it. Commands are often arranged hierarchically - so, for instance if we type just `hey_egeria`, the
26
- command options presented to us are:
27
-
28
- ```aiignore
29
- Commands:
30
- cat Commands for all users
31
- my Work with my information
32
- ops Commands to understand and manage operations
33
- tech Commands for tech Users
34
- tui Open Textual TUI
35
- ```
36
6
 
37
- "cat", "my", "ops", and "tech" represent groups of commands oriented towards particular roles. If a user wants to only
38
- use commands from a single role they can use a variant of hey_egeria that follows the pattern `hey_egeria_xxx`. So,
39
- for example, `hey_egeria_cat` is the entry point for general catalog users.
7
+ ## hey_egeria
40
8
 
41
- Within each of these categories, commands are further split between **show** and **tell**. **Show** commands display
42
- information to the user on the terminal and **tell** commands instruct Egeria to take some action. Commands may be further
43
- sub-divided into topics.
9
+ ## hey_egeria_cat
44
10
 
45
- So for example the command to display the status of the Egeria Platform is:
11
+ ## hey_egeria_my
46
12
 
47
- `hey_egeria ops show platforms status`
13
+ ## hey_egeria_ops
48
14
 
49
- And the command to list all glossaries is:
50
-
51
- `hey_egeria cat show glossary glossaries`
52
-
53
- ## Options & Parameters
54
-
55
- Each command has a number of optional, and often some mandatory parameters. There are really two groups of options.
56
- * General options - that are present for every command. Sensible defaults based on environment variables are set for each.
57
- * Command specific optons & parameters
15
+ ## hey_egeria_tech
58
16
 
59
17
  # Command Reference
60
18
 
@@ -137,9 +95,6 @@ Each command has a number of optional, and often some mandatory parameters. Ther
137
95
  | start_daemon | Start or restart an OMAG server from its known configuration | | | ✓ | | |
138
96
  | stop_daemon | Stop an OMAG server daemon | | | ✓ | | |
139
97
 
140
-
141
- # Visual Command Reference
142
- A visual command reference of all the `hey_egeria` **show** commands can be found [Visual Command Reference](https://github.com/odpi/egeria-python/tree/main/pyegeria/commands/doc/Visual%20Command%20Reference)
143
98
  ----
144
99
  License: [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/),
145
100
  Copyright Contributors to the Egeria project.
@@ -271,7 +271,7 @@ Here is a list of the variables and their defaults:
271
271
  | EGERIA_ADMIN_PASSWORD | secret | --admin_user_password | Admin password |
272
272
  | EGERIA_ENGINE_HOST | engine-host | --engine_host | Egeria Engine host to use for governance actions/processes |
273
273
  | EGERIA_ENGINE_HOST_URL | https://localhost:9443 | --engine_host_url | Platform URL where Engine host is running |
274
- | EGERIA_INTEGRATION_DAEMON | integration-daemon | --integration_daemon | Egeria integration daemon to use |
274
+ | EGERIA_INTEGRATION_DAEMON | integration-daemon | --integration-daemon | Egeria integration daemon to use |
275
275
  | EGERIA_INTEGRATION_DAEMON_URL | https://localhost:9443 | --integration_daemon_url | Platform URL where Integration daemon is running |
276
276
  | EGERIA_VIEW_SERVER | view-server | --view_server | Egeria view server to use |
277
277
  | EGERIA_VIEW_SERVER_URL | https://localhost:9443 | --view_server_url | Platform URL where view server is running |
@@ -14,7 +14,6 @@ import time
14
14
 
15
15
  from rich import box
16
16
  from rich.live import Live
17
- from rich.markdown import Markdown
18
17
  from rich.table import Table
19
18
  from rich.console import Console
20
19
 
@@ -66,7 +65,7 @@ def display_my_todos(
66
65
  return
67
66
 
68
67
  for item in todo_items:
69
- assigned_actors = ''
68
+ assigned_actors = [" "]
70
69
  if todo_items is None:
71
70
  name = " "
72
71
  type_name = " "
@@ -89,8 +88,7 @@ def display_my_todos(
89
88
  status = props.get("toDoStatus")
90
89
 
91
90
  for actor in item["assignedActors"]:
92
- assigned_actors+=f"{actor.get("uniqueName", "NoOne")}\n"
93
- assigned_actors_out = Markdown(assigned_actors)
91
+ assigned_actors.append(actor.get("uniqueName", "NoOne"))
94
92
  if status in ("WAITING", "OPEN"):
95
93
  status = f"[yellow]{status}"
96
94
  elif status in ("INPROGRESS", "COMPLETE"):
@@ -108,7 +106,7 @@ def display_my_todos(
108
106
  due,
109
107
  completed,
110
108
  status,
111
- assigned_actors_out,
109
+ str(assigned_actors),
112
110
  )
113
111
 
114
112
  def generate_table() -> Table:
@@ -139,19 +137,9 @@ def display_my_todos(
139
137
  my_title = my_profile["profileProperties"].get("jobTitle", "No Title")
140
138
  user_ids = []
141
139
  for id in my_ids:
142
- user_ids.append(id["userIdentity"]["properties"].get("userid", "NoOne"))
143
- add_rows(
144
- table,
145
- id["userIdentity"]["elementHeader"]["guid"],
146
- id["userIdentity"]["properties"]["userId"],
147
- )
148
-
140
+ user_ids.append(id["userIdentity"]["properties"].get("userId", "NoOne"))
149
141
  add_rows(table, my_guid, user_ids)
150
142
 
151
- # user_id_guid = my_profile["userIdentity"]["guid"]
152
- # user_id_name = my_profile["userIdentity"]["properties"]["userid"]
153
- # add_rows(table, user_id_guid, user_id_name)
154
-
155
143
  my_roles = my_profile["roles"]
156
144
  if type(my_roles) is list:
157
145
  for role in my_roles:
@@ -191,7 +179,7 @@ def main():
191
179
 
192
180
  server = args.server if args.server is not None else EGERIA_VIEW_SERVER
193
181
  url = args.url if args.url is not None else EGERIA_PLATFORM_URL
194
- userid = args.userid if args.userid is not None else "peterprofile"
182
+ userid = args.userid if args.userid is not None else EGERIA_USER
195
183
  user_pass = args.password if args.password is not None else EGERIA_USER_PASSWORD
196
184
 
197
185
  try:
@@ -114,7 +114,7 @@ def display_todos(
114
114
  if type(assigned_actors) is list:
115
115
  for actor in assigned_actors:
116
116
  actor_guid = actor["guid"]
117
- assigned += f"{m_client.get_actor_for_guid(actor_guid)} \n ({actor_guid}"
117
+ assigned += f"* {m_client.get_actor_for_guid(actor_guid)} "
118
118
  assigned_out = Markdown(assigned)
119
119
 
120
120
  if status in ("WAITING", "OPEN"):
@@ -18,22 +18,20 @@ from rich.markdown import Markdown
18
18
  from confluent_kafka import Consumer, KafkaException
19
19
 
20
20
  EGERIA_METADATA_STORE = os.environ.get("EGERIA_METADATA_STORE", "active-metadata-store")
21
- EGERIA_KAFKA_ENDPOINT = os.environ.get("KAFKA_ENDPOINT", "localhost:9192")
22
- EGERIA_PLATFORM_URL = os.environ.get("EGERIA_PLATFORM_URL", "https://localhost:9443")
23
- EGERIA_VIEW_SERVER = os.environ.get("VIEW_SERVER", "view-server")
24
- EGERIA_VIEW_SERVER_URL = os.environ.get(
25
- "EGERIA_VIEW_SERVER_URL", "https://localhost:9443"
26
- )
27
- EGERIA_INTEGRATION_DAEMON = os.environ.get("INTEGRATION_DAEMON", "integration-daemon")
28
- EGERIA_ADMIN_USER = os.environ.get("ADMIN_USER", "garygeeke")
29
- EGERIA_ADMIN_PASSWORD = os.environ.get("ADMIN_PASSWORD", "secret")
30
- EGERIA_USER = os.environ.get("EGERIA_USER", "erinoverview")
31
- EGERIA_USER_PASSWORD = os.environ.get("EGERIA_USER_PASSWORD", "secret")
32
- EGERIA_JUPYTER = os.environ.get("EGERIA_JUPYTER", False)
33
- EGERIA_WIDTH = os.environ.get("EGERIA_WIDTH", 200)
34
-
21
+ EGERIA_KAFKA_ENDPOINT = os.environ.get('KAFKA_ENDPOINT', 'localhost:9192')
22
+ EGERIA_PLATFORM_URL = os.environ.get('EGERIA_PLATFORM_URL', 'https://localhost:9443')
23
+ EGERIA_VIEW_SERVER = os.environ.get('VIEW_SERVER', 'view-server')
24
+ EGERIA_VIEW_SERVER_URL = os.environ.get('EGERIA_VIEW_SERVER_URL', 'https://localhost:9443')
25
+ EGERIA_INTEGRATION_DAEMON = os.environ.get('INTEGRATION_DAEMON', 'integration-daemon')
26
+ EGERIA_ADMIN_USER = os.environ.get('ADMIN_USER', 'garygeeke')
27
+ EGERIA_ADMIN_PASSWORD = os.environ.get('ADMIN_PASSWORD', 'secret')
28
+ EGERIA_USER = os.environ.get('EGERIA_USER', 'erinoverview')
29
+ EGERIA_USER_PASSWORD = os.environ.get('EGERIA_USER_PASSWORD', 'secret')
30
+ EGERIA_JUPYTER = os.environ.get('EGERIA_JUPYTER', False)
31
+ EGERIA_WIDTH = os.environ.get('EGERIA_WIDTH', 200)
35
32
 
36
33
  def main(ep: str = EGERIA_KAFKA_ENDPOINT):
34
+
37
35
  disable_ssl_warnings = True
38
36
  console = Console(width=200)
39
37
  now = datetime.now()
@@ -43,18 +41,16 @@ def main(ep: str = EGERIA_KAFKA_ENDPOINT):
43
41
 
44
42
  # Define the Kafka consumer configuration.
45
43
  config = {
46
- "bootstrap.servers": ep, # replace with your Kafka broker(s)
47
- "group.id": f"view_asset_events:{current_time}", # replace with your consumer group
48
- "auto.offset.reset": earliest_latest, # can be set to 'earliest' or 'latest'
44
+ 'bootstrap.servers': ep, # replace with your Kafka broker(s)
45
+ 'group.id': f"view_asset_events:{current_time}", # replace with your consumer group
46
+ 'auto.offset.reset': earliest_latest # can be set to 'earliest' or 'latest'
49
47
  }
50
48
  print(f"Kafka config is {json.dumps(config)}")
51
49
  # Initialize a Kafka consumer.
52
50
  consumer = Consumer(config)
53
51
 
54
52
  # Subscribe to a Kafka topic.
55
- consumer.subscribe(
56
- ["egeria.omag.server.active-metadata-store.omas.assetconsumer.outTopic"]
57
- ) # replace with your Kafka topic
53
+ consumer.subscribe(['egeria.omag.server.active-metadata-store.omas.assetconsumer.outTopic']) # replace with your Kafka topic
58
54
 
59
55
  try:
60
56
  while True:
@@ -79,11 +75,11 @@ def main(ep: str = EGERIA_KAFKA_ENDPOINT):
79
75
  for key in element_properties_keys:
80
76
  value = element_properties[key]
81
77
  props += f"* {key}: {value}\n"
82
- console.rule(style="[bold red]")
83
- console.rule(
84
- f"\tMessage TimeStamp: {event_time}\t eventType: {event_type}\t typeName: {type_name}\t guid: {guid}"
85
- )
86
- msg = f"properties: \n[bright white on black]{props}\n\n"
78
+ console.rule(style= "[bold red]")
79
+ console.rule(f"\tMessage TimeStamp: {event_time}\t eventType: {event_type}\t typeName: {type_name}\t guid: {guid}")
80
+ msg = (
81
+
82
+ f"properties: \n[bright white on black]{props}\n\n")
87
83
  msg = Markdown(msg)
88
84
 
89
85
  console.print(msg)
@@ -95,7 +91,6 @@ def main(ep: str = EGERIA_KAFKA_ENDPOINT):
95
91
  # Close down consumer to commit final offsets.
96
92
  consumer.close()
97
93
 
98
-
99
94
  if __name__ == "__main__":
100
95
  parser = argparse.ArgumentParser()
101
96
 
@@ -104,4 +99,4 @@ if __name__ == "__main__":
104
99
 
105
100
  ep = args.ep if args.ep is not None else EGERIA_KAFKA_ENDPOINT
106
101
 
107
- main(ep)
102
+ main(ep)
@@ -41,7 +41,7 @@ EGERIA_ENGINE_HOST_URL = os.environ.get(
41
41
  "EGERIA_ENGINE_HOST_URL", "https://localhost:9443"
42
42
  )
43
43
  EGERIA_INTEGRATION_DAEMON = os.environ.get(
44
- "EGERIA_INTEGRATION_DAEMON", "integration_daemon"
44
+ "EGERIA_INTEGRATION_DAEMON", "integration-daemon"
45
45
  )
46
46
  EGERIA_ADMIN_USER = os.environ.get("EGERIA_ADMIN_USER", "garygeeke")
47
47
  EGERIA_ADMIN_PASSWORD = os.environ.get("EGERIA_ADMIN_PASSWORD", "secret")
@@ -34,7 +34,7 @@ EGERIA_VIEW_SERVER_URL = os.environ.get(
34
34
  "EGERIA_VIEW_SERVER_URL", "https://localhost:9443"
35
35
  )
36
36
  EGERIA_INTEGRATION_DAEMON = os.environ.get(
37
- "EGERIA_INTEGRATION_DAEMON", "integration_daemon"
37
+ "EGERIA_INTEGRATION_DAEMON", "integration-daemon"
38
38
  )
39
39
  EGERIA_ENGINE_HOST = os.environ.get("EGERIA_ENGINE_HOST", "engine-host")
40
40
  EGERIA_ENGINE_HOST_URL = os.environ.get(
@@ -53,7 +53,6 @@ disable_ssl_warnings = True
53
53
 
54
54
  def display_gov_eng_status(
55
55
  search_list: list[str] = ["*"],
56
- status_filter=["*"],
57
56
  engine_host: str = EGERIA_ENGINE_HOST,
58
57
  view_server: str = EGERIA_VIEW_SERVER,
59
58
  url: str = EGERIA_VIEW_SERVER_URL,
@@ -68,11 +67,8 @@ def display_gov_eng_status(
68
67
 
69
68
  Parameters
70
69
  ----------
71
-
72
70
  search_list : list of str
73
71
  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
72
  engine_host : str
77
73
  The host name of the governance engine.
78
74
  view_server : str
@@ -154,8 +150,6 @@ def display_gov_eng_status(
154
150
  else:
155
151
  eng_req_type_out = " "
156
152
  status = engine["governanceEngineStatus"]
157
- if (status not in status_filter) and (status_filter != ["*"]):
158
- continue
159
153
  if status in ("RUNNING"):
160
154
  eng_status = f"[green]{status}"
161
155
  elif status in ("FAILED"):
@@ -224,19 +218,8 @@ def main_live():
224
218
  "Enter the list of engines you are interested in or ['*'] for all",
225
219
  default=["*"],
226
220
  )
227
- status_filter = Prompt.ask(
228
- "Enter a list of status values to filter for or ['*'] for all",
229
- default=["*"],
230
- )
231
221
  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,
222
+ search_list, engine_host, view_server, url, userid, user_pass, paging
240
223
  )
241
224
 
242
225
 
@@ -265,19 +248,9 @@ def main_paging():
265
248
  "Enter the list of engines you are interested in or ['*'] for all",
266
249
  default=["*"],
267
250
  )
268
- status_filter = Prompt.ask(
269
- "Enter a list of status values to filter for or ['*'] for all",
270
- default=["*"],
271
- )
251
+
272
252
  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,
253
+ search_list, engine_host, view_server, url, userid, user_pass, paging
281
254
  )
282
255
 
283
256