pyegeria 0.6.7__py3-none-any.whl → 0.7.0__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.
- examples/widgets/cat/get_project_structure.py +26 -59
- examples/widgets/cat/list_cert_types.py +1 -1
- examples/widgets/cli/egeria.py +26 -0
- examples/widgets/cli/egeria_cat.py +24 -0
- pyegeria/classification_manager_omvs.py +2332 -176
- {pyegeria-0.6.7.dist-info → pyegeria-0.7.0.dist-info}/METADATA +1 -1
- {pyegeria-0.6.7.dist-info → pyegeria-0.7.0.dist-info}/RECORD +10 -10
- {pyegeria-0.6.7.dist-info → pyegeria-0.7.0.dist-info}/LICENSE +0 -0
- {pyegeria-0.6.7.dist-info → pyegeria-0.7.0.dist-info}/WHEEL +0 -0
- {pyegeria-0.6.7.dist-info → pyegeria-0.7.0.dist-info}/entry_points.txt +0 -0
@@ -17,11 +17,6 @@ from pyegeria._client import Client, max_paging_size
|
|
17
17
|
from pyegeria._globals import enable_ssl_check, default_time_out
|
18
18
|
|
19
19
|
|
20
|
-
def jprint(info, comment=None):
|
21
|
-
if comment:
|
22
|
-
print(comment)
|
23
|
-
print(json.dumps(info, indent=2))
|
24
|
-
|
25
20
|
|
26
21
|
def query_seperator(current_string):
|
27
22
|
if current_string == "":
|
@@ -45,48 +40,48 @@ def base_path(client, view_server: str):
|
|
45
40
|
return f"{client.platform_url}/servers/{view_server}/api/open-metadata/classification-manager"
|
46
41
|
|
47
42
|
|
48
|
-
def extract_relationships_plus(element):
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
def extract_related_elements_list(element_list):
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
def related_elements_response(response: dict, detailed_response: bool):
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
def element_properties_plus(element):
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
def element_property_plus_list(element_list):
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
def element_response(response: dict, element_type: str, detailed_response: bool):
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
def elements_response(response: dict, element_type: str, detailed_response: bool):
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
43
|
+
# def extract_relationships_plus(element):
|
44
|
+
# type_name = element["relatedElement"]["type"]["typeName"]
|
45
|
+
# guid = element["relationshipHeader"]["guid"]
|
46
|
+
# properties = element["relationshipProperties"]["propertiesAsStrings"]
|
47
|
+
# name = element["relatedElement"]["uniqueName"]
|
48
|
+
# return {"name": name, "typeName": type_name, "guid": guid, "properties": properties}
|
49
|
+
#
|
50
|
+
#
|
51
|
+
# def extract_related_elements_list(element_list):
|
52
|
+
# return [extract_relationships_plus(element) for element in element_list]
|
53
|
+
#
|
54
|
+
#
|
55
|
+
# def related_elements_response(response: dict, detailed_response: bool):
|
56
|
+
# if detailed_response:
|
57
|
+
# return response
|
58
|
+
# else:
|
59
|
+
# return extract_related_elements_list(response["elements"])
|
60
|
+
#
|
61
|
+
#
|
62
|
+
# def element_properties_plus(element):
|
63
|
+
# props_plus = element["properties"]
|
64
|
+
# props_plus.update({"guid": element["elementHeader"]["guid"]})
|
65
|
+
# props_plus.update({"versions": element["elementHeader"]["versions"]})
|
66
|
+
# return props_plus
|
67
|
+
#
|
68
|
+
#
|
69
|
+
# def element_property_plus_list(element_list):
|
70
|
+
# return [element_properties_plus(element) for element in element_list]
|
71
|
+
#
|
72
|
+
#
|
73
|
+
# def element_response(response: dict, element_type: str, detailed_response: bool):
|
74
|
+
# if detailed_response:
|
75
|
+
# return response
|
76
|
+
# else:
|
77
|
+
# return element_properties_plus(response[element_type])
|
78
|
+
#
|
79
|
+
#
|
80
|
+
# def elements_response(response: dict, element_type: str, detailed_response: bool):
|
81
|
+
# if detailed_response:
|
82
|
+
# return response
|
83
|
+
# else:
|
84
|
+
# return element_property_plus_list(response[element_type])
|
90
85
|
|
91
86
|
|
92
87
|
class ClassificationManager(Client):
|
@@ -113,17 +108,19 @@ class ClassificationManager(Client):
|
|
113
108
|
"""
|
114
109
|
|
115
110
|
def __init__(self, server_name: str, platform_url: str, token: str = None, user_id: str = None,
|
116
|
-
|
111
|
+
user_pwd: str = None, verify_flag: bool = enable_ssl_check, sync_mode: bool = True, ):
|
117
112
|
self.admin_command_root: str
|
118
113
|
Client.__init__(self, server_name, platform_url, user_id=user_id, user_pwd=user_pwd, token=token,
|
119
|
-
|
114
|
+
async_mode=sync_mode, )
|
120
115
|
|
121
116
|
#
|
122
117
|
# Get elements
|
123
118
|
#
|
119
|
+
|
124
120
|
async def _async_get_elements(self, open_metadata_type_name: str = None, effective_time: str = None,
|
125
|
-
|
126
|
-
|
121
|
+
for_lineage: bool = None, for_duplicate_processing: bool = None, start_from: int = 0,
|
122
|
+
page_size: int = max_paging_size, server_name: str = None,
|
123
|
+
time_out: int = default_time_out) -> list | str:
|
127
124
|
"""
|
128
125
|
Retrieve elements of the requested type name. If no type name is specified, then any type of element may
|
129
126
|
be returned.
|
@@ -168,10 +165,10 @@ class ClassificationManager(Client):
|
|
168
165
|
|
169
166
|
possible_query_params = query_string(
|
170
167
|
[("startFrom", start_from), ("pageSize", page_size), ("forLineage", for_lineage),
|
171
|
-
|
168
|
+
("forDuplicateProcessing", for_duplicate_processing)])
|
172
169
|
|
173
170
|
body = {"class": "FindProperties", "openMetadataTypeName": open_metadata_type_name,
|
174
|
-
|
171
|
+
"effectiveTime": effective_time, }
|
175
172
|
|
176
173
|
url = f"{base_path(self, server_name)}/elements/by-type{possible_query_params}"
|
177
174
|
response: Response = await self._async_make_request("POST", url, body_slimmer(body), time_out=time_out)
|
@@ -182,8 +179,8 @@ class ClassificationManager(Client):
|
|
182
179
|
return elements
|
183
180
|
|
184
181
|
def get_elements(self, open_metadata_type_name: str = None, effective_time: str = None, for_lineage: bool = None,
|
185
|
-
|
186
|
-
|
182
|
+
for_duplicate_processing: bool = None, start_from: int = 0, page_size: int = max_paging_size,
|
183
|
+
server_name: str = None, time_out: int = default_time_out) -> list | str:
|
187
184
|
"""
|
188
185
|
Retrieve elements of the requested type name. If no type name is specified, then any type of element may
|
189
186
|
be returned.
|
@@ -227,13 +224,15 @@ class ClassificationManager(Client):
|
|
227
224
|
loop = asyncio.get_event_loop()
|
228
225
|
response = loop.run_until_complete(
|
229
226
|
self._async_get_elements(open_metadata_type_name, effective_time, for_lineage, for_duplicate_processing,
|
230
|
-
|
227
|
+
start_from, page_size, server_name, time_out))
|
231
228
|
return response
|
232
229
|
|
233
230
|
async def _async_get_elements_by_property_value(self, property_value: str, property_names: [str],
|
234
|
-
|
235
|
-
|
236
|
-
|
231
|
+
open_metadata_type_name: str = None, effective_time: str = None,
|
232
|
+
for_lineage: bool = None, for_duplicate_processing: bool = None,
|
233
|
+
start_from: int = 0, page_size: int = max_paging_size,
|
234
|
+
server_name: str = None,
|
235
|
+
time_out: int = default_time_out) -> list | str:
|
237
236
|
"""
|
238
237
|
Retrieve elements by a value found in one of the properties specified. The value must match exactly.
|
239
238
|
An open metadata type name may be supplied to restrict the results. Async version.
|
@@ -282,10 +281,10 @@ class ClassificationManager(Client):
|
|
282
281
|
|
283
282
|
possible_query_params = query_string(
|
284
283
|
[("startFrom", start_from), ("pageSize", page_size), ("forLineage", for_lineage),
|
285
|
-
|
284
|
+
("forDuplicateProcessing", for_duplicate_processing)])
|
286
285
|
|
287
286
|
body = {"class": "FindPropertyNamesProperties", "openMetadataTypeName": open_metadata_type_name,
|
288
|
-
|
287
|
+
"propertyValue": property_value, "propertyNames": property_names, "effectiveTime": effective_time, }
|
289
288
|
|
290
289
|
url = f"{base_path(self, server_name)}/elements/by-exact-property-value{possible_query_params}"
|
291
290
|
|
@@ -298,9 +297,10 @@ class ClassificationManager(Client):
|
|
298
297
|
return elements
|
299
298
|
|
300
299
|
def get_elements_by_property_value(self, property_value: str, property_names: [str],
|
301
|
-
|
302
|
-
|
303
|
-
|
300
|
+
open_metadata_type_name: str = None, effective_time: str = None,
|
301
|
+
for_lineage: bool = None, for_duplicate_processing: bool = None,
|
302
|
+
start_from: int = 0, page_size: int = max_paging_size, server_name: str = None,
|
303
|
+
time_out: int = default_time_out) -> list | str:
|
304
304
|
"""
|
305
305
|
Retrieve elements by a value found in one of the properties specified. The value must match exactly.
|
306
306
|
An open metadata type name may be supplied to restrict the results.
|
@@ -348,13 +348,16 @@ class ClassificationManager(Client):
|
|
348
348
|
loop = asyncio.get_event_loop()
|
349
349
|
response = loop.run_until_complete(
|
350
350
|
self._async_get_elements_by_property_value(property_value, property_names, open_metadata_type_name,
|
351
|
-
|
351
|
+
effective_time, for_lineage, for_duplicate_processing,
|
352
|
+
start_from, page_size, server_name, time_out))
|
352
353
|
return response
|
353
354
|
|
354
355
|
async def _async_find_elements_by_property_value(self, property_value: str, property_names: [str],
|
355
|
-
|
356
|
-
|
357
|
-
|
356
|
+
open_metadata_type_name: str = None, effective_time: str = None,
|
357
|
+
for_lineage: bool = None, for_duplicate_processing: bool = None,
|
358
|
+
start_from: int = 0, page_size: int = max_paging_size,
|
359
|
+
server_name: str = None,
|
360
|
+
time_out: int = default_time_out) -> list | str:
|
358
361
|
"""
|
359
362
|
Retrieve elements by a value found in one of the properties specified. The value must be contained in the
|
360
363
|
properties rather than needing to be an exact match. An open metadata type name may be supplied to restrict
|
@@ -404,10 +407,10 @@ class ClassificationManager(Client):
|
|
404
407
|
|
405
408
|
possible_query_params = query_string(
|
406
409
|
[("startFrom", start_from), ("pageSize", page_size), ("forLineage", for_lineage),
|
407
|
-
|
410
|
+
("forDuplicateProcessing", for_duplicate_processing)])
|
408
411
|
|
409
412
|
body = {"class": "FindPropertyNamesProperties", "openMetadataTypeName": open_metadata_type_name,
|
410
|
-
|
413
|
+
"propertyValue": property_value, "propertyNames": property_names, "effectiveTime": effective_time, }
|
411
414
|
|
412
415
|
url = f"{base_path(self, server_name)}/elements/by-property-value-search{possible_query_params}"
|
413
416
|
response: Response = await self._async_make_request("POST", url, body_slimmer(body), time_out=time_out)
|
@@ -418,9 +421,10 @@ class ClassificationManager(Client):
|
|
418
421
|
return elements
|
419
422
|
|
420
423
|
def find_elements_by_property_value(self, property_value: str, property_names: [str],
|
421
|
-
|
422
|
-
|
423
|
-
|
424
|
+
open_metadata_type_name: str = None, effective_time: str = None,
|
425
|
+
for_lineage: bool = None, for_duplicate_processing: bool = None,
|
426
|
+
start_from: int = 0, page_size: int = max_paging_size, server_name: str = None,
|
427
|
+
time_out: int = default_time_out) -> list | str:
|
424
428
|
"""
|
425
429
|
Retrieve elements by a value found in one of the properties specified. The value must be contained in the
|
426
430
|
properties rather than needing to be an exact match. An open metadata type name may be supplied to restrict
|
@@ -469,16 +473,18 @@ class ClassificationManager(Client):
|
|
469
473
|
loop = asyncio.get_event_loop()
|
470
474
|
response = loop.run_until_complete(
|
471
475
|
self._async_find_elements_by_property_value(property_value, property_names, open_metadata_type_name,
|
472
|
-
|
476
|
+
effective_time, for_lineage, for_duplicate_processing,
|
477
|
+
start_from, page_size, server_name, time_out))
|
473
478
|
return response
|
474
479
|
|
475
480
|
#
|
476
481
|
# Elements by classification
|
477
482
|
#
|
478
483
|
async def _async_get_elements_by_classification(self, classification_name: str, open_metadata_type_name: str = None,
|
479
|
-
|
480
|
-
|
481
|
-
|
484
|
+
effective_time: str = None, for_lineage: bool = None,
|
485
|
+
for_duplicate_processing: bool = None, start_from: int = 0,
|
486
|
+
page_size: int = max_paging_size, server_name: str = None,
|
487
|
+
time_out: int = default_time_out) -> list | str:
|
482
488
|
"""
|
483
489
|
Retrieve elements with the requested classification name. It is also possible to limit the results
|
484
490
|
by specifying a type name for the elements that should be returned. If no type name is specified then
|
@@ -526,10 +532,10 @@ class ClassificationManager(Client):
|
|
526
532
|
|
527
533
|
possible_query_params = query_string(
|
528
534
|
[("startFrom", start_from), ("pageSize", page_size), ("forLineage", for_lineage),
|
529
|
-
|
535
|
+
("forDuplicateProcessing", for_duplicate_processing)])
|
530
536
|
|
531
537
|
body = {"class": "FindProperties", "openMetadataTypeName": open_metadata_type_name,
|
532
|
-
|
538
|
+
"effectiveTime": effective_time, }
|
533
539
|
|
534
540
|
url = (f"{base_path(self, server_name)}/elements/by-classification/{classification_name}"
|
535
541
|
f"{possible_query_params}")
|
@@ -541,9 +547,10 @@ class ClassificationManager(Client):
|
|
541
547
|
return elements
|
542
548
|
|
543
549
|
def get_elements_by_classification(self, classification_name: str, open_metadata_type_name: str = None,
|
544
|
-
|
545
|
-
|
546
|
-
|
550
|
+
effective_time: str = None, for_lineage: bool = None,
|
551
|
+
for_duplicate_processing: bool = None, start_from: int = 0,
|
552
|
+
page_size: int = max_paging_size, server_name: str = None,
|
553
|
+
time_out: int = default_time_out) -> list | str:
|
547
554
|
"""
|
548
555
|
Retrieve elements with the requested classification name. It is also possible to limit the results
|
549
556
|
by specifying a type name for the elements that should be returned. If no type name is specified then
|
@@ -590,13 +597,20 @@ class ClassificationManager(Client):
|
|
590
597
|
loop = asyncio.get_event_loop()
|
591
598
|
response = loop.run_until_complete(
|
592
599
|
self._async_get_elements_by_classification(classification_name, open_metadata_type_name, effective_time,
|
593
|
-
|
600
|
+
for_lineage, for_duplicate_processing, start_from, page_size,
|
601
|
+
server_name, time_out))
|
594
602
|
return response
|
595
603
|
|
596
604
|
async def _async_get_elements_by_classification_with_property_value(self, classification_name: str,
|
597
|
-
|
598
|
-
|
599
|
-
|
605
|
+
property_value: str, property_names: [str],
|
606
|
+
open_metadata_type_name: str = None,
|
607
|
+
effective_time: str = None,
|
608
|
+
for_lineage: bool = None,
|
609
|
+
for_duplicate_processing: bool = None,
|
610
|
+
start_from: int = 0,
|
611
|
+
page_size: int = max_paging_size,
|
612
|
+
server_name: str = None,
|
613
|
+
time_out: int = default_time_out) -> list | str:
|
600
614
|
"""
|
601
615
|
Retrieve elements with the requested classification name and with the requested a value found in one of the
|
602
616
|
classification's properties specified. The value must match exactly. An open metadata type name may be supplied
|
@@ -648,10 +662,10 @@ class ClassificationManager(Client):
|
|
648
662
|
|
649
663
|
possible_query_params = query_string(
|
650
664
|
[("startFrom", start_from), ("pageSize", page_size), ("forLineage", for_lineage),
|
651
|
-
|
665
|
+
("forDuplicateProcessing", for_duplicate_processing)])
|
652
666
|
|
653
667
|
body = {"class": "FindPropertyNamesProperties", "openMetadataTypeName": open_metadata_type_name,
|
654
|
-
|
668
|
+
"propertyValue": property_value, "propertyNames": property_names, "effectiveTime": effective_time, }
|
655
669
|
|
656
670
|
url = (f"{base_path(self, server_name)}/elements/by-classification/{classification_name}/"
|
657
671
|
f"with-exact-property-value{possible_query_params}")
|
@@ -663,9 +677,11 @@ class ClassificationManager(Client):
|
|
663
677
|
return elements
|
664
678
|
|
665
679
|
def get_elements_by_classification_with_property_value(self, classification_name: str, property_value: str,
|
666
|
-
|
667
|
-
|
668
|
-
|
680
|
+
property_names: [str], open_metadata_type_name: str = None,
|
681
|
+
effective_time: str = None, for_lineage: bool = None,
|
682
|
+
for_duplicate_processing: bool = None, start_from: int = 0,
|
683
|
+
page_size: int = max_paging_size, server_name: str = None,
|
684
|
+
time_out: int = default_time_out) -> list | str:
|
669
685
|
"""
|
670
686
|
Retrieve elements by a value found in one of the properties specified. The value must match exactly.
|
671
687
|
An open metadata type name may be supplied to restrict the results.
|
@@ -715,14 +731,22 @@ class ClassificationManager(Client):
|
|
715
731
|
loop = asyncio.get_event_loop()
|
716
732
|
response = loop.run_until_complete(
|
717
733
|
self._async_get_elements_by_classification_with_property_value(classification_name, property_value,
|
718
|
-
|
719
|
-
|
734
|
+
property_names, open_metadata_type_name,
|
735
|
+
effective_time, for_lineage,
|
736
|
+
for_duplicate_processing, start_from,
|
737
|
+
page_size, server_name, time_out))
|
720
738
|
return response
|
721
739
|
|
722
740
|
async def _async_find_elements_by_classification_with_property_value(self, classification_name: str,
|
723
|
-
|
724
|
-
|
725
|
-
|
741
|
+
property_value: str, property_names: [str],
|
742
|
+
open_metadata_type_name: str = None,
|
743
|
+
effective_time: str = None,
|
744
|
+
for_lineage: bool = None,
|
745
|
+
for_duplicate_processing: bool = None,
|
746
|
+
start_from: int = 0,
|
747
|
+
page_size: int = max_paging_size,
|
748
|
+
server_name: str = None,
|
749
|
+
time_out: int = default_time_out) -> list | str:
|
726
750
|
"""
|
727
751
|
Retrieve elements with the requested classification name and with the requested value found in
|
728
752
|
one of the classification's properties specified. The value must only be contained in the
|
@@ -775,10 +799,10 @@ class ClassificationManager(Client):
|
|
775
799
|
|
776
800
|
possible_query_params = query_string(
|
777
801
|
[("startFrom", start_from), ("pageSize", page_size), ("forLineage", for_lineage),
|
778
|
-
|
802
|
+
("forDuplicateProcessing", for_duplicate_processing)])
|
779
803
|
|
780
804
|
body = {"class": "FindPropertyNamesProperties", "openMetadataTypeName": open_metadata_type_name,
|
781
|
-
|
805
|
+
"propertyValue": property_value, "propertyNames": property_names, "effectiveTime": effective_time, }
|
782
806
|
|
783
807
|
url = (f"{base_path(self, server_name)}/elements/by-classification/{classification_name}/"
|
784
808
|
f"with-property-value-search{possible_query_params}")
|
@@ -790,9 +814,11 @@ class ClassificationManager(Client):
|
|
790
814
|
return elements
|
791
815
|
|
792
816
|
def find_elements_by_classification_with_property_value(self, classification_name: str, property_value: str,
|
793
|
-
|
794
|
-
|
795
|
-
|
817
|
+
property_names: [str], open_metadata_type_name: str = None,
|
818
|
+
effective_time: str = None, for_lineage: bool = None,
|
819
|
+
for_duplicate_processing: bool = None, start_from: int = 0,
|
820
|
+
page_size: int = max_paging_size, server_name: str = None,
|
821
|
+
time_out: int = default_time_out) -> list | str:
|
796
822
|
"""
|
797
823
|
Retrieve elements with the requested classification name and with the requested a value found in
|
798
824
|
one of the classification's properties specified. The value must only be contained in the
|
@@ -844,17 +870,20 @@ class ClassificationManager(Client):
|
|
844
870
|
loop = asyncio.get_event_loop()
|
845
871
|
response = loop.run_until_complete(
|
846
872
|
self._async_find_elements_by_classification_with_property_value(classification_name, property_value,
|
847
|
-
|
848
|
-
|
873
|
+
property_names, open_metadata_type_name,
|
874
|
+
effective_time, for_lineage,
|
875
|
+
for_duplicate_processing, start_from,
|
876
|
+
page_size, server_name, time_out))
|
849
877
|
return response
|
850
878
|
|
851
879
|
#
|
852
880
|
# related elements
|
853
881
|
#
|
854
882
|
async def _async_get_all_related_elements(self, element_guid: str, open_metadata_type_name: str = None,
|
855
|
-
|
856
|
-
|
857
|
-
|
883
|
+
start_at_end: int = 1, effective_time: str = None,
|
884
|
+
for_lineage: bool = None, for_duplicate_processing: bool = None,
|
885
|
+
start_from: int = 0, page_size: int = max_paging_size,
|
886
|
+
server_name: str = None, time_out: int = default_time_out) -> list | str:
|
858
887
|
"""
|
859
888
|
Retrieve elements linked any relationship type name. It is also possible to limit the results by
|
860
889
|
specifying a type name for the elements that should be returned. If no type name is specified then any type of
|
@@ -904,10 +933,10 @@ class ClassificationManager(Client):
|
|
904
933
|
|
905
934
|
possible_query_params = query_string(
|
906
935
|
[("startFrom", start_from), ("pageSize", page_size), ("forLineage", for_lineage),
|
907
|
-
|
936
|
+
("forDuplicateProcessing", for_duplicate_processing), ("startAtEnd", start_at_end)])
|
908
937
|
|
909
938
|
body = {"class": "FindProperties", "openMetadataTypeName": open_metadata_type_name,
|
910
|
-
|
939
|
+
"effectiveTime": effective_time, }
|
911
940
|
|
912
941
|
url = (f"{base_path(self, server_name)}/elements/{element_guid}/by-relationship"
|
913
942
|
f"{possible_query_params}")
|
@@ -919,9 +948,10 @@ class ClassificationManager(Client):
|
|
919
948
|
return elements
|
920
949
|
|
921
950
|
def get_all_related_elements(self, element_guid: str, open_metadata_type_name: str = None, start_at_end: int = 1,
|
922
|
-
|
923
|
-
|
924
|
-
|
951
|
+
effective_time: str = None, for_lineage: bool = None,
|
952
|
+
for_duplicate_processing: bool = None, start_from: int = 0,
|
953
|
+
page_size: int = max_paging_size, server_name: str = None,
|
954
|
+
time_out: int = default_time_out) -> list | str:
|
925
955
|
"""
|
926
956
|
Retrieve elements linked via any relationship type name. It is also possible to limit the results by
|
927
957
|
specifying a type name for the elements that should be returned. If no type name is specified then any type of
|
@@ -970,13 +1000,16 @@ class ClassificationManager(Client):
|
|
970
1000
|
loop = asyncio.get_event_loop()
|
971
1001
|
response = loop.run_until_complete(
|
972
1002
|
self._async_get_all_related_elements(element_guid, open_metadata_type_name, start_at_end, effective_time,
|
973
|
-
|
1003
|
+
for_lineage, for_duplicate_processing, start_from, page_size,
|
1004
|
+
server_name, time_out))
|
974
1005
|
return response
|
975
1006
|
|
976
1007
|
async def _async_get_related_elements(self, element_guid: str, relationship_type: str,
|
977
|
-
|
978
|
-
|
979
|
-
|
1008
|
+
open_metadata_type_name: str = None, start_at_end: int = 1,
|
1009
|
+
effective_time: str = None, for_lineage: bool = None,
|
1010
|
+
for_duplicate_processing: bool = None, start_from: int = 0,
|
1011
|
+
page_size: int = max_paging_size, server_name: str = None,
|
1012
|
+
time_out: int = default_time_out) -> list | str:
|
980
1013
|
"""
|
981
1014
|
Retrieve elements linked any relationship type name. It is also possible to limit the results by
|
982
1015
|
specifying a type name for the elements that should be returned. If no type name is specified then any type of
|
@@ -1028,10 +1061,10 @@ class ClassificationManager(Client):
|
|
1028
1061
|
|
1029
1062
|
possible_query_params = query_string(
|
1030
1063
|
[("startFrom", start_from), ("pageSize", page_size), ("forLineage", for_lineage),
|
1031
|
-
|
1064
|
+
("forDuplicateProcessing", for_duplicate_processing), ("startAtEnd", start_at_end)])
|
1032
1065
|
|
1033
1066
|
body = {"class": "FindProperties", "openMetadataTypeName": open_metadata_type_name,
|
1034
|
-
|
1067
|
+
"effectiveTime": effective_time, }
|
1035
1068
|
|
1036
1069
|
url = (f"{base_path(self, server_name)}/elements/{element_guid}/by-relationship/"
|
1037
1070
|
f"{relationship_type}{possible_query_params}")
|
@@ -1043,9 +1076,10 @@ class ClassificationManager(Client):
|
|
1043
1076
|
return elements
|
1044
1077
|
|
1045
1078
|
def get_related_elements(self, element_guid: str, relationship_type: str, open_metadata_type_name: str = None,
|
1046
|
-
|
1047
|
-
|
1048
|
-
|
1079
|
+
start_at_end: int = 1, effective_time: str = None, for_lineage: bool = None,
|
1080
|
+
for_duplicate_processing: bool = None, start_from: int = 0,
|
1081
|
+
page_size: int = max_paging_size, server_name: str = None,
|
1082
|
+
time_out: int = default_time_out) -> list | str:
|
1049
1083
|
"""
|
1050
1084
|
Retrieve elements linked via any relationship type name. It is also possible to limit the results by
|
1051
1085
|
specifying a type name for the elements that should be returned. If no type name is specified then any type of
|
@@ -1096,14 +1130,19 @@ class ClassificationManager(Client):
|
|
1096
1130
|
loop = asyncio.get_event_loop()
|
1097
1131
|
response = loop.run_until_complete(
|
1098
1132
|
self._async_get_related_elements(element_guid, relationship_type, open_metadata_type_name, start_at_end,
|
1099
|
-
|
1133
|
+
effective_time, for_lineage, for_duplicate_processing, start_from,
|
1134
|
+
page_size, server_name, time_out))
|
1100
1135
|
return response
|
1101
1136
|
|
1102
1137
|
async def _async_get_related_elements_with_property_value(self, element_guid: str, relationship_type: str,
|
1103
|
-
|
1104
|
-
|
1105
|
-
|
1106
|
-
|
1138
|
+
property_value: str, property_names: [str],
|
1139
|
+
open_metadata_type_name: str = None,
|
1140
|
+
start_at_end: int = 1, effective_time: str = None,
|
1141
|
+
for_lineage: bool = None,
|
1142
|
+
for_duplicate_processing: bool = None,
|
1143
|
+
start_from: int = 0, page_size: int = max_paging_size,
|
1144
|
+
server_name: str = None,
|
1145
|
+
time_out: int = default_time_out) -> list | str:
|
1107
1146
|
"""
|
1108
1147
|
Retrieve elements linked via the requested relationship type name and with the requested a value found in one of
|
1109
1148
|
the classification's properties specified. The value must match exactly. An open metadata type name may be
|
@@ -1160,10 +1199,10 @@ class ClassificationManager(Client):
|
|
1160
1199
|
|
1161
1200
|
possible_query_params = query_string(
|
1162
1201
|
[("startFrom", start_from), ("pageSize", page_size), ("forLineage", for_lineage),
|
1163
|
-
|
1202
|
+
("forDuplicateProcessing", for_duplicate_processing), ("startAtEnd", start_at_end)])
|
1164
1203
|
|
1165
1204
|
body = {"class": "FindPropertyNamesProperties", "openMetadataTypeName": open_metadata_type_name,
|
1166
|
-
|
1205
|
+
"propertyValue": property_value, "propertyNames": property_names, "effectiveTime": effective_time, }
|
1167
1206
|
|
1168
1207
|
url = (f"{base_path(self, server_name)}/elements/{element_guid}/by-relationship/"
|
1169
1208
|
f"{relationship_type}/with-exact-property-value{possible_query_params}")
|
@@ -1176,10 +1215,12 @@ class ClassificationManager(Client):
|
|
1176
1215
|
return elements
|
1177
1216
|
|
1178
1217
|
def get_related_elements_with_property_value(self, element_guid: str, relationship_type: str, property_value: str,
|
1179
|
-
|
1180
|
-
|
1181
|
-
|
1182
|
-
|
1218
|
+
property_names: [str], open_metadata_type_name: str = None,
|
1219
|
+
start_at_end: int = 1, effective_time: str = None,
|
1220
|
+
for_lineage: bool = None, for_duplicate_processing: bool = None,
|
1221
|
+
start_from: int = 0, page_size: int = max_paging_size,
|
1222
|
+
server_name: str = None,
|
1223
|
+
time_out: int = default_time_out) -> list | str:
|
1183
1224
|
"""
|
1184
1225
|
Retrieve elements linked via the requested relationship type name and with the requested a value found in one of
|
1185
1226
|
the classification's properties specified. The value must match exactly. An open metadata type name may be
|
@@ -1234,15 +1275,20 @@ class ClassificationManager(Client):
|
|
1234
1275
|
loop = asyncio.get_event_loop()
|
1235
1276
|
response = loop.run_until_complete(
|
1236
1277
|
self._async_get_related_elements_with_property_value(element_guid, relationship_type, property_value,
|
1237
|
-
|
1238
|
-
|
1278
|
+
property_names, open_metadata_type_name, start_at_end,
|
1279
|
+
effective_time, for_lineage, for_duplicate_processing,
|
1280
|
+
start_from, page_size, server_name, time_out))
|
1239
1281
|
return response
|
1240
1282
|
|
1241
1283
|
async def _async_find_related_elements_with_property_value(self, element_guid: str, relationship_type: str,
|
1242
|
-
|
1243
|
-
|
1244
|
-
|
1245
|
-
|
1284
|
+
property_value: str, property_names: [str],
|
1285
|
+
open_metadata_type_name: str = None,
|
1286
|
+
start_at_end: int = 1, effective_time: str = None,
|
1287
|
+
for_lineage: bool = None,
|
1288
|
+
for_duplicate_processing: bool = None,
|
1289
|
+
start_from: int = 0, page_size: int = max_paging_size,
|
1290
|
+
server_name: str = None,
|
1291
|
+
time_out: int = default_time_out) -> list | str:
|
1246
1292
|
"""
|
1247
1293
|
Retrieve elements linked via the requested relationship type name and with the requested a value found in one of
|
1248
1294
|
the classification's properties specified. The value must only be contained in the properties rather than
|
@@ -1300,10 +1346,10 @@ class ClassificationManager(Client):
|
|
1300
1346
|
|
1301
1347
|
possible_query_params = query_string(
|
1302
1348
|
[("startFrom", start_from), ("pageSize", page_size), ("forLineage", for_lineage),
|
1303
|
-
|
1349
|
+
("forDuplicateProcessing", for_duplicate_processing), ("startAtEnd", start_at_end)])
|
1304
1350
|
|
1305
1351
|
body = {"class": "FindPropertyNamesProperties", "openMetadataTypeName": open_metadata_type_name,
|
1306
|
-
|
1352
|
+
"propertyValue": property_value, "propertyNames": property_names, "effectiveTime": effective_time, }
|
1307
1353
|
|
1308
1354
|
url = (f"{base_path(self, server_name)}/elements/{element_guid}/by-relationship/"
|
1309
1355
|
f"{relationship_type}/with-property-value-search{possible_query_params}")
|
@@ -1317,10 +1363,12 @@ class ClassificationManager(Client):
|
|
1317
1363
|
return elements
|
1318
1364
|
|
1319
1365
|
def find_related_elements_with_property_value(self, element_guid: str, relationship_type: str, property_value: str,
|
1320
|
-
|
1321
|
-
|
1322
|
-
|
1323
|
-
|
1366
|
+
property_names: [str], open_metadata_type_name: str = None,
|
1367
|
+
start_at_end: int = 1, effective_time: str = None,
|
1368
|
+
for_lineage: bool = None, for_duplicate_processing: bool = None,
|
1369
|
+
start_from: int = 0, page_size: int = max_paging_size,
|
1370
|
+
server_name: str = None,
|
1371
|
+
time_out: int = default_time_out) -> list | str:
|
1324
1372
|
"""
|
1325
1373
|
Retrieve elements linked via the requested relationship type name and with the requested a value found in one of
|
1326
1374
|
the classification's properties specified. The value must only be contained in the properties rather than
|
@@ -1376,16 +1424,18 @@ class ClassificationManager(Client):
|
|
1376
1424
|
loop = asyncio.get_event_loop()
|
1377
1425
|
response = loop.run_until_complete(
|
1378
1426
|
self._async_find_related_elements_with_property_value(element_guid, relationship_type, property_value,
|
1379
|
-
|
1380
|
-
|
1427
|
+
property_names, open_metadata_type_name, start_at_end,
|
1428
|
+
effective_time, for_lineage, for_duplicate_processing,
|
1429
|
+
start_from, page_size, server_name, time_out))
|
1381
1430
|
return response
|
1382
1431
|
|
1383
1432
|
#
|
1384
1433
|
# relationships
|
1385
1434
|
|
1386
1435
|
async def _async_get_relationships(self, relationship_type: str, effective_time: str = None,
|
1387
|
-
|
1388
|
-
|
1436
|
+
for_lineage: bool = None, for_duplicate_processing: bool = None,
|
1437
|
+
start_from: int = 0, page_size: int = max_paging_size, server_name: str = None,
|
1438
|
+
time_out: int = default_time_out) -> list | str:
|
1389
1439
|
"""
|
1390
1440
|
Retrieve relationships of the requested relationship type name. Async version.
|
1391
1441
|
|
@@ -1427,7 +1477,7 @@ class ClassificationManager(Client):
|
|
1427
1477
|
|
1428
1478
|
possible_query_params = query_string(
|
1429
1479
|
[("startFrom", start_from), ("pageSize", page_size), ("forLineage", for_lineage),
|
1430
|
-
|
1480
|
+
("forDuplicateProcessing", for_duplicate_processing)])
|
1431
1481
|
|
1432
1482
|
body = {"class": "FindProperties", "effectiveTime": effective_time}
|
1433
1483
|
|
@@ -1443,8 +1493,8 @@ class ClassificationManager(Client):
|
|
1443
1493
|
return rels
|
1444
1494
|
|
1445
1495
|
def get_relationships(self, relationship_type: str, effective_time: str = None, for_lineage: bool = None,
|
1446
|
-
|
1447
|
-
|
1496
|
+
for_duplicate_processing: bool = None, start_from: int = 0, page_size: int = max_paging_size,
|
1497
|
+
server_name: str = None, time_out: int = default_time_out) -> list | str:
|
1448
1498
|
"""
|
1449
1499
|
Retrieve relationships of the requested relationship type name.
|
1450
1500
|
|
@@ -1485,13 +1535,15 @@ class ClassificationManager(Client):
|
|
1485
1535
|
loop = asyncio.get_event_loop()
|
1486
1536
|
response = loop.run_until_complete(
|
1487
1537
|
self._async_get_relationships(relationship_type, effective_time, for_lineage, for_duplicate_processing,
|
1488
|
-
|
1538
|
+
start_from, page_size, server_name, time_out))
|
1489
1539
|
return response
|
1490
1540
|
|
1491
1541
|
async def _async_get_relationships_with_property_value(self, relationship_type: str, property_value: str,
|
1492
|
-
|
1493
|
-
|
1494
|
-
|
1542
|
+
property_names: [str], effective_time: str = None,
|
1543
|
+
for_lineage: bool = None,
|
1544
|
+
for_duplicate_processing: bool = None, start_from: int = 0,
|
1545
|
+
page_size: int = max_paging_size, server_name: str = None,
|
1546
|
+
time_out: int = default_time_out) -> list | str:
|
1495
1547
|
"""
|
1496
1548
|
Retrieve relationships of the requested relationship type name and with the requested a value found in
|
1497
1549
|
one of the relationship's properties specified. The value must match exactly. Async version.
|
@@ -1540,10 +1592,10 @@ class ClassificationManager(Client):
|
|
1540
1592
|
|
1541
1593
|
possible_query_params = query_string(
|
1542
1594
|
[("startFrom", start_from), ("pageSize", page_size), ("forLineage", for_lineage),
|
1543
|
-
|
1595
|
+
("forDuplicateProcessing", for_duplicate_processing)])
|
1544
1596
|
|
1545
1597
|
body = {"class": "FindPropertyNamesProperties", "propertyValue": property_value,
|
1546
|
-
|
1598
|
+
"propertyNames": property_names, "effectiveTime": effective_time, }
|
1547
1599
|
|
1548
1600
|
url = (f"{base_path(self, server_name)}/relationships/{relationship_type}/"
|
1549
1601
|
f"with-exact-property-value{possible_query_params}")
|
@@ -1556,9 +1608,10 @@ class ClassificationManager(Client):
|
|
1556
1608
|
return rels
|
1557
1609
|
|
1558
1610
|
def get_relationships_with_property_value(self, relationship_type: str, property_value: str, property_names: [str],
|
1559
|
-
|
1560
|
-
|
1561
|
-
|
1611
|
+
effective_time: str = None, for_lineage: bool = None,
|
1612
|
+
for_duplicate_processing: bool = None, start_from: int = 0,
|
1613
|
+
page_size: int = max_paging_size, server_name: str = None,
|
1614
|
+
time_out: int = default_time_out) -> list | str:
|
1562
1615
|
"""
|
1563
1616
|
Retrieve relationships of the requested relationship type name and with the requested a value found in
|
1564
1617
|
one of the relationship's properties specified. The value must match exactly.
|
@@ -1604,13 +1657,16 @@ class ClassificationManager(Client):
|
|
1604
1657
|
loop = asyncio.get_event_loop()
|
1605
1658
|
response = loop.run_until_complete(
|
1606
1659
|
self._async_get_relationships_with_property_value(relationship_type, property_value, property_names,
|
1607
|
-
|
1660
|
+
effective_time, for_lineage, for_duplicate_processing,
|
1661
|
+
start_from, page_size, server_name, time_out))
|
1608
1662
|
return response
|
1609
1663
|
|
1610
1664
|
async def _async_find_relationships_with_property_value(self, relationship_type: str, property_value: str,
|
1611
|
-
|
1612
|
-
|
1613
|
-
|
1665
|
+
property_names: [str], effective_time: str = None,
|
1666
|
+
for_lineage: bool = None,
|
1667
|
+
for_duplicate_processing: bool = None, start_from: int = 0,
|
1668
|
+
page_size: int = max_paging_size, server_name: str = None,
|
1669
|
+
time_out: int = default_time_out) -> list | str:
|
1614
1670
|
"""
|
1615
1671
|
Retrieve relationships of the requested relationship type name and with the requested a value found in one of
|
1616
1672
|
the relationship's properties specified. The value must only be contained in the properties rather than
|
@@ -1658,10 +1714,10 @@ class ClassificationManager(Client):
|
|
1658
1714
|
|
1659
1715
|
possible_query_params = query_string(
|
1660
1716
|
[("startFrom", start_from), ("pageSize", page_size), ("forLineage", for_lineage),
|
1661
|
-
|
1717
|
+
("forDuplicateProcessing", for_duplicate_processing)])
|
1662
1718
|
|
1663
1719
|
body = {"class": "FindPropertyNamesProperties", "propertyValue": property_value,
|
1664
|
-
|
1720
|
+
"propertyNames": property_names, "effectiveTime": effective_time, }
|
1665
1721
|
|
1666
1722
|
url = (f"{base_path(self, server_name)}/relationships/"
|
1667
1723
|
f"{relationship_type}/with-property-value-search{possible_query_params}")
|
@@ -1675,9 +1731,10 @@ class ClassificationManager(Client):
|
|
1675
1731
|
return rels
|
1676
1732
|
|
1677
1733
|
def find_relationships_with_property_value(self, relationship_type: str, property_value: str, property_names: [str],
|
1678
|
-
|
1679
|
-
|
1680
|
-
|
1734
|
+
effective_time: str = None, for_lineage: bool = None,
|
1735
|
+
for_duplicate_processing: bool = None, start_from: int = 0,
|
1736
|
+
page_size: int = max_paging_size, server_name: str = None,
|
1737
|
+
time_out: int = default_time_out) -> list | str:
|
1681
1738
|
"""
|
1682
1739
|
Retrieve relationships of the requested relationship type name and with the requested a value found in one of
|
1683
1740
|
the relationship's properties specified. The value must only be contained in the properties rather than
|
@@ -1726,7 +1783,8 @@ class ClassificationManager(Client):
|
|
1726
1783
|
loop = asyncio.get_event_loop()
|
1727
1784
|
response = loop.run_until_complete(
|
1728
1785
|
self._async_find_relationships_with_property_value(relationship_type, property_value, property_names,
|
1729
|
-
|
1786
|
+
effective_time, for_lineage, for_duplicate_processing,
|
1787
|
+
start_from, page_size, server_name, time_out))
|
1730
1788
|
return response
|
1731
1789
|
|
1732
1790
|
#
|
@@ -1734,8 +1792,8 @@ class ClassificationManager(Client):
|
|
1734
1792
|
#
|
1735
1793
|
|
1736
1794
|
async def _async_retrieve_instance_for_guid(self, guid: str, effective_time: str = None, for_lineage: bool = None,
|
1737
|
-
|
1738
|
-
|
1795
|
+
for_duplicate_processing: bool = None, server_name: str = None,
|
1796
|
+
time_out: int = default_time_out) -> list | str:
|
1739
1797
|
"""
|
1740
1798
|
Retrieve the header for the instance identified by the supplied unique identifier.
|
1741
1799
|
It may be an element (entity) or a relationship between elements. Async version.
|
@@ -1782,11 +1840,9 @@ class ClassificationManager(Client):
|
|
1782
1840
|
element = response.json().get('element', 'No elements found')
|
1783
1841
|
return element
|
1784
1842
|
|
1785
|
-
|
1786
|
-
|
1787
1843
|
def retrieve_instance_for_guid(self, guid: str, effective_time: str = None, for_lineage: bool = None,
|
1788
|
-
|
1789
|
-
|
1844
|
+
for_duplicate_processing: bool = None, server_name: str = None,
|
1845
|
+
time_out: int = default_time_out) -> list | str:
|
1790
1846
|
"""
|
1791
1847
|
Retrieve the header for the instance identified by the supplied unique identifier.
|
1792
1848
|
It may be an element (entity) or a relationship between elements.
|
@@ -1824,7 +1880,2107 @@ class ClassificationManager(Client):
|
|
1824
1880
|
loop = asyncio.get_event_loop()
|
1825
1881
|
response = loop.run_until_complete(
|
1826
1882
|
self._async_retrieve_instance_for_guid(guid, effective_time, for_lineage, for_duplicate_processing,
|
1827
|
-
|
1883
|
+
server_name, time_out))
|
1828
1884
|
return response
|
1829
1885
|
|
1886
|
+
#
|
1887
|
+
# Classification CRUD
|
1888
|
+
#
|
1889
|
+
|
1890
|
+
async def _async_set_confidence_classification(self, element_guid: str, body: dict, for_lineage: bool = None,
|
1891
|
+
for_duplicate_processing: bool = None, server_name: str = None,
|
1892
|
+
time_out: int = default_time_out) -> None:
|
1893
|
+
"""
|
1894
|
+
Classify/reclassify the element (typically an asset) to indicate the level of confidence that the organization
|
1895
|
+
has that the data is complete, accurate and up-to-date. The level of confidence is expressed by the
|
1896
|
+
levelIdentifier property. Async version.
|
1897
|
+
|
1898
|
+
Governance Action Classifications: https://egeria-project.org/types/4/0422-Governance-Action-Classifications/
|
1899
|
+
|
1900
|
+
Parameters
|
1901
|
+
----------
|
1902
|
+
element_guid: str
|
1903
|
+
- the identity of the element to update
|
1904
|
+
body: dict
|
1905
|
+
- a dictionary structure containing the properties to set - see note below
|
1906
|
+
for_lineage: bool, default is set by server
|
1907
|
+
- determines if elements classified as Memento should be returned - normally false
|
1908
|
+
for_duplicate_processing: bool, default is set by server
|
1909
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
1910
|
+
server_name: str, default = None
|
1911
|
+
- name of the server instances for this request.
|
1912
|
+
time_out: int, default = default_time_out
|
1913
|
+
- http request timeout for this request
|
1914
|
+
|
1915
|
+
Returns
|
1916
|
+
-------
|
1917
|
+
[dict] | str
|
1918
|
+
Returns a string if no elements found and a list of dict of elements with the results.
|
1919
|
+
|
1920
|
+
Raises
|
1921
|
+
------
|
1922
|
+
InvalidParameterException
|
1923
|
+
one of the parameters is null or invalid or
|
1924
|
+
PropertyServerException
|
1925
|
+
There is a problem adding the element properties to the metadata repository or
|
1926
|
+
UserNotAuthorizedException
|
1927
|
+
the requesting user is not authorized to issue this request.
|
1928
|
+
|
1929
|
+
Note:
|
1930
|
+
|
1931
|
+
A sample dict structure is:
|
1932
|
+
|
1933
|
+
{
|
1934
|
+
"class" : "ClassificationRequestBody",
|
1935
|
+
"effectiveTime" : "an-isoTimestamp",
|
1936
|
+
"properties" : {
|
1937
|
+
"class" : "GovernanceClassificationProperties",
|
1938
|
+
"levelIdentifier" : 0,
|
1939
|
+
"status" : 0,
|
1940
|
+
"confidence" : 0,
|
1941
|
+
"steward" : "Add value here",
|
1942
|
+
"stewardTypeName" : "Add value here",
|
1943
|
+
"stewardPropertyName" : "Add value here",
|
1944
|
+
"source" : "Add value here",
|
1945
|
+
"notes" : "Add value here"
|
1946
|
+
}
|
1947
|
+
}
|
1948
|
+
|
1949
|
+
"""
|
1950
|
+
if server_name is None:
|
1951
|
+
server_name = self.server_name
|
1952
|
+
|
1953
|
+
possible_query_params = query_string(
|
1954
|
+
[("forLineage", for_lineage), ("forDuplicateProcessing", for_duplicate_processing)])
|
1955
|
+
|
1956
|
+
url = (f"{base_path(self, server_name)}/elements/{element_guid}/confidence"
|
1957
|
+
f"{possible_query_params}")
|
1958
|
+
|
1959
|
+
await self._async_make_request("POST", url, body_slimmer(body), time_out=time_out)
|
1960
|
+
|
1961
|
+
def set_confidence_classification(self, element_guid: str, body: dict, for_lineage: bool = None,
|
1962
|
+
for_duplicate_processing: bool = None, server_name: str = None,
|
1963
|
+
time_out: int = default_time_out) -> None:
|
1964
|
+
"""
|
1965
|
+
Classify/reclassify the element (typically an asset) to indicate the level of confidence that the organization
|
1966
|
+
has that the data is complete, accurate and up-to-date. The level of confidence is expressed by the
|
1967
|
+
levelIdentifier property.
|
1968
|
+
|
1969
|
+
Governance Action Classifications: https://egeria-project.org/types/4/0422-Governance-Action-Classifications/
|
1970
|
+
|
1971
|
+
Parameters
|
1972
|
+
----------
|
1973
|
+
element_guid: str
|
1974
|
+
- the identity of the element to update
|
1975
|
+
body: dict
|
1976
|
+
- a dictionary structure containing the properties to set - see note below
|
1977
|
+
for_lineage: bool, default is set by server
|
1978
|
+
- determines if elements classified as Memento should be returned - normally false
|
1979
|
+
for_duplicate_processing: bool, default is set by server
|
1980
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
1981
|
+
server_name: str, default = None
|
1982
|
+
- name of the server instances for this request.
|
1983
|
+
time_out: int, default = default_time_out
|
1984
|
+
- http request timeout for this request
|
1985
|
+
|
1986
|
+
Returns
|
1987
|
+
-------
|
1988
|
+
[dict] | str
|
1989
|
+
Returns a string if no elements found and a list of dict of elements with the results.
|
1990
|
+
|
1991
|
+
Raises
|
1992
|
+
------
|
1993
|
+
InvalidParameterException
|
1994
|
+
one of the parameters is null or invalid or
|
1995
|
+
PropertyServerException
|
1996
|
+
There is a problem adding the element properties to the metadata repository or
|
1997
|
+
UserNotAuthorizedException
|
1998
|
+
the requesting user is not authorized to issue this request.
|
1999
|
+
|
2000
|
+
Note:
|
2001
|
+
|
2002
|
+
A sample dict structure is:
|
2003
|
+
|
2004
|
+
{
|
2005
|
+
"class" : "ClassificationRequestBody",
|
2006
|
+
"effectiveTime" : "an-isoTimestamp",
|
2007
|
+
"properties" : {
|
2008
|
+
"class" : "GovernanceClassificationProperties",
|
2009
|
+
"levelIdentifier" : 0,
|
2010
|
+
"status" : 0,
|
2011
|
+
"confidence" : 0,
|
2012
|
+
"steward" : "Add value here",
|
2013
|
+
"stewardTypeName" : "Add value here",
|
2014
|
+
"stewardPropertyName" : "Add value here",
|
2015
|
+
"source" : "Add value here",
|
2016
|
+
"notes" : "Add value here"
|
2017
|
+
}
|
2018
|
+
}
|
2019
|
+
|
2020
|
+
"""
|
2021
|
+
|
2022
|
+
loop = asyncio.get_event_loop()
|
2023
|
+
loop.run_until_complete(
|
2024
|
+
self._async_set_confidence_classification(element_guid, body, for_lineage, for_duplicate_processing,
|
2025
|
+
server_name, time_out))
|
2026
|
+
|
2027
|
+
async def _async_clear_confidence_classification(self, element_guid: str, for_lineage: bool = None,
|
2028
|
+
for_duplicate_processing: bool = None, effective_time: str = None,
|
2029
|
+
server_name: str = None,
|
2030
|
+
time_out: int = default_time_out) -> None:
|
2031
|
+
"""
|
2032
|
+
Remove the confidence classification from the element. This normally occurs when the organization has lost
|
2033
|
+
track of the level of confidence to assign to the element. Async Version.
|
2034
|
+
|
2035
|
+
Governance Action Classifications: https://egeria-project.org/types/4/0422-Governance-Action-Classifications/
|
2036
|
+
|
2037
|
+
Parameters
|
2038
|
+
----------
|
2039
|
+
element_guid: str
|
2040
|
+
- the identity of the element to update
|
2041
|
+
for_lineage: bool, default is set by server
|
2042
|
+
- determines if elements classified as Memento should be returned - normally false
|
2043
|
+
for_duplicate_processing: bool, default is set by server
|
2044
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
2045
|
+
effective_time: str, default = None
|
2046
|
+
- Time format is "YYYY-MM-DDTHH:MM:SS" (ISO 8601)
|
2047
|
+
server_name: str, default = None
|
2048
|
+
- name of the server instances for this request.
|
2049
|
+
time_out: int, default = default_time_out
|
2050
|
+
- http request timeout for this request
|
2051
|
+
|
2052
|
+
Returns
|
2053
|
+
-------
|
2054
|
+
[dict] | str
|
2055
|
+
Returns a string if no elements found and a list of dict of elements with the results.
|
2056
|
+
|
2057
|
+
Raises
|
2058
|
+
------
|
2059
|
+
InvalidParameterException
|
2060
|
+
one of the parameters is null or invalid or
|
2061
|
+
PropertyServerException
|
2062
|
+
There is a problem adding the element properties to the metadata repository or
|
2063
|
+
UserNotAuthorizedException
|
2064
|
+
the requesting user is not authorized to issue this request.
|
2065
|
+
|
2066
|
+
|
2067
|
+
"""
|
2068
|
+
if server_name is None:
|
2069
|
+
server_name = self.server_name
|
2070
|
+
|
2071
|
+
possible_query_params = query_string(
|
2072
|
+
[("forLineage", for_lineage), ("forDuplicateProcessing", for_duplicate_processing)])
|
2073
|
+
|
2074
|
+
url = (f"{base_path(self, server_name)}/elements/{element_guid}/confidence/remove"
|
2075
|
+
f"{possible_query_params}")
|
2076
|
+
body = {
|
2077
|
+
"class": "ClassificationRequestBody",
|
2078
|
+
"effectiveTime": effective_time
|
2079
|
+
}
|
2080
|
+
|
2081
|
+
await self._async_make_request("POST", url, body_slimmer(body), time_out=time_out)
|
2082
|
+
|
2083
|
+
def clear_confidence_classification(self, element_guid: str, for_lineage: bool = None,
|
2084
|
+
for_duplicate_processing: bool = None, effective_time: str = None,
|
2085
|
+
server_name: str = None,
|
2086
|
+
time_out: int = default_time_out) -> None:
|
2087
|
+
"""
|
2088
|
+
Remove the confidence classification from the element. This normally occurs when the organization has lost
|
2089
|
+
track of the level of confidence to assign to the element.
|
2090
|
+
|
2091
|
+
Governance Action Classifications: https://egeria-project.org/types/4/0422-Governance-Action-Classifications/
|
2092
|
+
|
2093
|
+
Parameters
|
2094
|
+
----------
|
2095
|
+
element_guid: str
|
2096
|
+
- the identity of the element to update
|
2097
|
+
for_lineage: bool, default is set by server
|
2098
|
+
- determines if elements classified as Memento should be returned - normally false
|
2099
|
+
for_duplicate_processing: bool, default is set by server
|
2100
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
2101
|
+
effective_time: str, default = None
|
2102
|
+
- Time format is "YYYY-MM-DDTHH:MM:SS" (ISO 8601)
|
2103
|
+
server_name: str, default = None
|
2104
|
+
- name of the server instances for this request.
|
2105
|
+
time_out: int, default = default_time_out
|
2106
|
+
- http request timeout for this request
|
2107
|
+
|
2108
|
+
Returns
|
2109
|
+
-------
|
2110
|
+
[dict] | str
|
2111
|
+
Returns a string if no elements found and a list of dict of elements with the results.
|
2112
|
+
|
2113
|
+
Raises
|
2114
|
+
------
|
2115
|
+
InvalidParameterException
|
2116
|
+
one of the parameters is null or invalid or
|
2117
|
+
PropertyServerException
|
2118
|
+
There is a problem adding the element properties to the metadata repository or
|
2119
|
+
UserNotAuthorizedException
|
2120
|
+
the requesting user is not authorized to issue this request.
|
2121
|
+
|
2122
|
+
|
2123
|
+
"""
|
2124
|
+
|
2125
|
+
loop = asyncio.get_event_loop()
|
2126
|
+
loop.run_until_complete(
|
2127
|
+
self._async_clear_confidence_classification(element_guid, for_lineage, for_duplicate_processing,
|
2128
|
+
effective_time, server_name, time_out))
|
2129
|
+
|
2130
|
+
async def _async_set_confidentiality_classification(self, element_guid: str, body: dict, for_lineage: bool = None,
|
2131
|
+
for_duplicate_processing: bool = None, server_name: str = None,
|
2132
|
+
time_out: int = default_time_out) -> None:
|
2133
|
+
"""
|
2134
|
+
Classify/reclassify the element (typically a data field, schema attribute or glossary term) to indicate the
|
2135
|
+
level of confidentiality that any data associated with the element should be given. If the classification is
|
2136
|
+
attached to a glossary term, the level of confidentiality is a suggestion for any element linked to the
|
2137
|
+
glossary term via the SemanticAssignment classification. The level of confidence is expressed by the
|
2138
|
+
levelIdentifier property. Async version.
|
2139
|
+
|
2140
|
+
Governance Action Classifications: https://egeria-project.org/types/4/0422-Governance-Action-Classifications/
|
2141
|
+
|
2142
|
+
Parameters
|
2143
|
+
----------
|
2144
|
+
element_guid: str
|
2145
|
+
- the identity of the element to update
|
2146
|
+
body: dict
|
2147
|
+
- a dictionary structure containing the properties to set - see note below
|
2148
|
+
for_lineage: bool, default is set by server
|
2149
|
+
- determines if elements classified as Memento should be returned - normally false
|
2150
|
+
for_duplicate_processing: bool, default is set by server
|
2151
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
2152
|
+
server_name: str, default = None
|
2153
|
+
- name of the server instances for this request.
|
2154
|
+
time_out: int, default = default_time_out
|
2155
|
+
- http request timeout for this request
|
2156
|
+
|
2157
|
+
Returns
|
2158
|
+
-------
|
2159
|
+
[dict] | str
|
2160
|
+
Returns a string if no elements found and a list of dict of elements with the results.
|
2161
|
+
|
2162
|
+
Raises
|
2163
|
+
------
|
2164
|
+
InvalidParameterException
|
2165
|
+
one of the parameters is null or invalid or
|
2166
|
+
PropertyServerException
|
2167
|
+
There is a problem adding the element properties to the metadata repository or
|
2168
|
+
UserNotAuthorizedException
|
2169
|
+
the requesting user is not authorized to issue this request.
|
2170
|
+
|
2171
|
+
Note:
|
2172
|
+
|
2173
|
+
A sample dict structure is:
|
2174
|
+
|
2175
|
+
{
|
2176
|
+
"class" : "ClassificationRequestBody",
|
2177
|
+
"effectiveTime" : "an-isoTimestamp",
|
2178
|
+
"properties" : {
|
2179
|
+
"class" : "GovernanceClassificationProperties",
|
2180
|
+
"levelIdentifier" : 0,
|
2181
|
+
"status" : 0,
|
2182
|
+
"confidentiality" : 0,
|
2183
|
+
"steward" : "Add value here",
|
2184
|
+
"stewardTypeName" : "Add value here",
|
2185
|
+
"stewardPropertyName" : "Add value here",
|
2186
|
+
"source" : "Add value here",
|
2187
|
+
"notes" : "Add value here"
|
2188
|
+
}
|
2189
|
+
}
|
2190
|
+
|
2191
|
+
"""
|
2192
|
+
if server_name is None:
|
2193
|
+
server_name = self.server_name
|
2194
|
+
|
2195
|
+
possible_query_params = query_string(
|
2196
|
+
[("forLineage", for_lineage), ("forDuplicateProcessing", for_duplicate_processing)])
|
2197
|
+
|
2198
|
+
url = (f"{base_path(self, server_name)}/elements/{element_guid}/confidentiality"
|
2199
|
+
f"{possible_query_params}")
|
2200
|
+
|
2201
|
+
await self._async_make_request("POST", url, body_slimmer(body), time_out=time_out)
|
2202
|
+
|
2203
|
+
def set_confidentiality_classification(self, element_guid: str, body: dict, for_lineage: bool = None,
|
2204
|
+
for_duplicate_processing: bool = None, server_name: str = None,
|
2205
|
+
time_out: int = default_time_out) -> None:
|
2206
|
+
"""
|
2207
|
+
Classify/reclassify the element (typically a data field, schema attribute or glossary term) to indicate the
|
2208
|
+
level of confidentiality that any data associated with the element should be given. If the classification is
|
2209
|
+
attached to a glossary term, the level of confidentiality is a suggestion for any element linked to the
|
2210
|
+
glossary term via the SemanticAssignment classification. The level of confidence is expressed by the
|
2211
|
+
levelIdentifier property.
|
2212
|
+
|
2213
|
+
Governance Action Classifications: https://egeria-project.org/types/4/0422-Governance-Action-Classifications/
|
2214
|
+
|
2215
|
+
Parameters
|
2216
|
+
----------
|
2217
|
+
element_guid: str
|
2218
|
+
- the identity of the element to update
|
2219
|
+
body: dict
|
2220
|
+
- a dictionary structure containing the properties to set - see note below
|
2221
|
+
for_lineage: bool, default is set by server
|
2222
|
+
- determines if elements classified as Memento should be returned - normally false
|
2223
|
+
for_duplicate_processing: bool, default is set by server
|
2224
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
2225
|
+
server_name: str, default = None
|
2226
|
+
- name of the server instances for this request.
|
2227
|
+
time_out: int, default = default_time_out
|
2228
|
+
- http request timeout for this request
|
2229
|
+
|
2230
|
+
Returns
|
2231
|
+
-------
|
2232
|
+
[dict] | str
|
2233
|
+
Returns a string if no elements found and a list of dict of elements with the results.
|
2234
|
+
|
2235
|
+
Raises
|
2236
|
+
------
|
2237
|
+
InvalidParameterException
|
2238
|
+
one of the parameters is null or invalid or
|
2239
|
+
PropertyServerException
|
2240
|
+
There is a problem adding the element properties to the metadata repository or
|
2241
|
+
UserNotAuthorizedException
|
2242
|
+
the requesting user is not authorized to issue this request.
|
2243
|
+
|
2244
|
+
Note:
|
2245
|
+
|
2246
|
+
A sample dict structure is:
|
2247
|
+
|
2248
|
+
{
|
2249
|
+
"class" : "ClassificationRequestBody",
|
2250
|
+
"effectiveTime" : "an-isoTimestamp",
|
2251
|
+
"properties" : {
|
2252
|
+
"class" : "GovernanceClassificationProperties",
|
2253
|
+
"levelIdentifier" : 0,
|
2254
|
+
"status" : 0,
|
2255
|
+
"confidentiality" : 0,
|
2256
|
+
"steward" : "Add value here",
|
2257
|
+
"stewardTypeName" : "Add value here",
|
2258
|
+
"stewardPropertyName" : "Add value here",
|
2259
|
+
"source" : "Add value here",
|
2260
|
+
"notes" : "Add value here"
|
2261
|
+
}
|
2262
|
+
}
|
2263
|
+
|
2264
|
+
"""
|
2265
|
+
|
2266
|
+
loop = asyncio.get_event_loop()
|
2267
|
+
loop.run_until_complete(
|
2268
|
+
self._async_set_confidentiality_classification(element_guid, body, for_lineage, for_duplicate_processing,
|
2269
|
+
server_name, time_out))
|
2270
|
+
|
2271
|
+
async def _async_clear_confidentiality_classification(self, element_guid: str, for_lineage: bool = None,
|
2272
|
+
for_duplicate_processing: bool = None,
|
2273
|
+
effective_time: str = None,
|
2274
|
+
server_name: str = None,
|
2275
|
+
time_out: int = default_time_out) -> None:
|
2276
|
+
"""
|
2277
|
+
Remove the confidentiality classification from the element. This normally occurs when the organization has lost
|
2278
|
+
track of the level of confidentiality to assign to the element. Async Version.
|
1830
2279
|
|
2280
|
+
Governance Action Classifications: https://egeria-project.org/types/4/0422-Governance-Action-Classifications/
|
2281
|
+
|
2282
|
+
Parameters
|
2283
|
+
----------
|
2284
|
+
element_guid: str
|
2285
|
+
- the identity of the element to update
|
2286
|
+
for_lineage: bool, default is set by server
|
2287
|
+
- determines if elements classified as Memento should be returned - normally false
|
2288
|
+
for_duplicate_processing: bool, default is set by server
|
2289
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
2290
|
+
effective_time: str, default = None
|
2291
|
+
- Time format is "YYYY-MM-DDTHH:MM:SS" (ISO 8601)
|
2292
|
+
server_name: str, default = None
|
2293
|
+
- name of the server instances for this request.
|
2294
|
+
time_out: int, default = default_time_out
|
2295
|
+
- http request timeout for this request
|
2296
|
+
|
2297
|
+
Returns
|
2298
|
+
-------
|
2299
|
+
[dict] | str
|
2300
|
+
Returns a string if no elements found and a list of dict of elements with the results.
|
2301
|
+
|
2302
|
+
Raises
|
2303
|
+
------
|
2304
|
+
InvalidParameterException
|
2305
|
+
one of the parameters is null or invalid or
|
2306
|
+
PropertyServerException
|
2307
|
+
There is a problem adding the element properties to the metadata repository or
|
2308
|
+
UserNotAuthorizedException
|
2309
|
+
the requesting user is not authorized to issue this request.
|
2310
|
+
|
2311
|
+
|
2312
|
+
"""
|
2313
|
+
if server_name is None:
|
2314
|
+
server_name = self.server_name
|
2315
|
+
|
2316
|
+
possible_query_params = query_string(
|
2317
|
+
[("forLineage", for_lineage), ("forDuplicateProcessing", for_duplicate_processing)])
|
2318
|
+
|
2319
|
+
url = (f"{base_path(self, server_name)}/elements/{element_guid}/confidentiality/remove"
|
2320
|
+
f"{possible_query_params}")
|
2321
|
+
|
2322
|
+
body = {
|
2323
|
+
"class": "ClassificationRequestBody",
|
2324
|
+
"effectiveTime": effective_time
|
2325
|
+
}
|
2326
|
+
|
2327
|
+
await self._async_make_request("POST", url, body_slimmer(body), time_out=time_out)
|
2328
|
+
|
2329
|
+
def clear_confidentiality_classification(self, element_guid: str, for_lineage: bool = None,
|
2330
|
+
for_duplicate_processing: bool = None, effective_time: str = None,
|
2331
|
+
server_name: str = None,
|
2332
|
+
time_out: int = default_time_out) -> None:
|
2333
|
+
"""
|
2334
|
+
Remove the confidentiality classification from the element. This normally occurs when the organization has lost
|
2335
|
+
track of the level of confidentiality to assign to the element.
|
2336
|
+
|
2337
|
+
Governance Action Classifications: https://egeria-project.org/types/4/0422-Governance-Action-Classifications/
|
2338
|
+
|
2339
|
+
Parameters
|
2340
|
+
----------
|
2341
|
+
element_guid: str
|
2342
|
+
- the identity of the element to update
|
2343
|
+
for_lineage: bool, default is set by server
|
2344
|
+
- determines if elements classified as Memento should be returned - normally false
|
2345
|
+
for_duplicate_processing: bool, default is set by server
|
2346
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
2347
|
+
effective_time: str, default = None
|
2348
|
+
- Time format is "YYYY-MM-DDTHH:MM:SS" (ISO 8601)
|
2349
|
+
server_name: str, default = None
|
2350
|
+
- name of the server instances for this request.
|
2351
|
+
time_out: int, default = default_time_out
|
2352
|
+
- http request timeout for this request
|
2353
|
+
|
2354
|
+
Returns
|
2355
|
+
-------
|
2356
|
+
[dict] | str
|
2357
|
+
Returns a string if no elements found and a list of dict of elements with the results.
|
2358
|
+
|
2359
|
+
Raises
|
2360
|
+
------
|
2361
|
+
InvalidParameterException
|
2362
|
+
one of the parameters is null or invalid or
|
2363
|
+
PropertyServerException
|
2364
|
+
There is a problem adding the element properties to the metadata repository or
|
2365
|
+
UserNotAuthorizedException
|
2366
|
+
the requesting user is not authorized to issue this request.
|
2367
|
+
|
2368
|
+
|
2369
|
+
"""
|
2370
|
+
|
2371
|
+
loop = asyncio.get_event_loop()
|
2372
|
+
loop.run_until_complete(
|
2373
|
+
self._async_clear_confidentiality_classification(element_guid, for_lineage, for_duplicate_processing,
|
2374
|
+
effective_time, server_name, time_out))
|
2375
|
+
|
2376
|
+
async def _async_set_criticality_classification(self, element_guid: str, body: dict, for_lineage: bool = None,
|
2377
|
+
for_duplicate_processing: bool = None, server_name: str = None,
|
2378
|
+
time_out: int = default_time_out) -> None:
|
2379
|
+
"""
|
2380
|
+
Classify/reclassify the element (typically an asset) to indicate how critical the element (or
|
2381
|
+
associated resource) is to the organization. The level of criticality is expressed by the levelIdentifier
|
2382
|
+
property. Async version.
|
2383
|
+
|
2384
|
+
Governance Action Classifications: https://egeria-project.org/types/4/0422-Governance-Action-Classifications/
|
2385
|
+
|
2386
|
+
Parameters
|
2387
|
+
----------
|
2388
|
+
element_guid: str
|
2389
|
+
- the identity of the element to update
|
2390
|
+
body: dict
|
2391
|
+
- a dictionary structure containing the properties to set - see note below
|
2392
|
+
for_lineage: bool, default is set by server
|
2393
|
+
- determines if elements classified as Memento should be returned - normally false
|
2394
|
+
for_duplicate_processing: bool, default is set by server
|
2395
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
2396
|
+
server_name: str, default = None
|
2397
|
+
- name of the server instances for this request.
|
2398
|
+
time_out: int, default = default_time_out
|
2399
|
+
- http request timeout for this request
|
2400
|
+
|
2401
|
+
Returns
|
2402
|
+
-------
|
2403
|
+
[dict] | str
|
2404
|
+
Returns a string if no elements found and a list of dict of elements with the results.
|
2405
|
+
|
2406
|
+
Raises
|
2407
|
+
------
|
2408
|
+
InvalidParameterException
|
2409
|
+
one of the parameters is null or invalid or
|
2410
|
+
PropertyServerException
|
2411
|
+
There is a problem adding the element properties to the metadata repository or
|
2412
|
+
UserNotAuthorizedException
|
2413
|
+
the requesting user is not authorized to issue this request.
|
2414
|
+
|
2415
|
+
Note:
|
2416
|
+
|
2417
|
+
A sample dict structure is:
|
2418
|
+
|
2419
|
+
{
|
2420
|
+
"class" : "ClassificationRequestBody",
|
2421
|
+
"effectiveTime" : "an-isoTimestamp",
|
2422
|
+
"properties" : {
|
2423
|
+
"class" : "GovernanceClassificationProperties",
|
2424
|
+
"levelIdentifier" : 0,
|
2425
|
+
"status" : 0,
|
2426
|
+
"criticality" : 0,
|
2427
|
+
"steward" : "Add value here",
|
2428
|
+
"stewardTypeName" : "Add value here",
|
2429
|
+
"stewardPropertyName" : "Add value here",
|
2430
|
+
"source" : "Add value here",
|
2431
|
+
"notes" : "Add value here"
|
2432
|
+
}
|
2433
|
+
}
|
2434
|
+
|
2435
|
+
"""
|
2436
|
+
if server_name is None:
|
2437
|
+
server_name = self.server_name
|
2438
|
+
|
2439
|
+
possible_query_params = query_string(
|
2440
|
+
[("forLineage", for_lineage), ("forDuplicateProcessing", for_duplicate_processing)])
|
2441
|
+
|
2442
|
+
url = (f"{base_path(self, server_name)}/elements/{element_guid}/criticality"
|
2443
|
+
f"{possible_query_params}")
|
2444
|
+
|
2445
|
+
await self._async_make_request("POST", url, body_slimmer(body), time_out=time_out)
|
2446
|
+
|
2447
|
+
def set_criticality_classification(self, element_guid: str, body: dict, for_lineage: bool = None,
|
2448
|
+
for_duplicate_processing: bool = None, server_name: str = None,
|
2449
|
+
time_out: int = default_time_out) -> None:
|
2450
|
+
"""
|
2451
|
+
Classify/reclassify the element (typically an asset) to indicate how critical the element (or
|
2452
|
+
associated resource) is to the organization. The level of criticality is expressed by the levelIdentifier
|
2453
|
+
property.
|
2454
|
+
|
2455
|
+
Governance Action Classifications: https://egeria-project.org/types/4/0422-Governance-Action-Classifications/
|
2456
|
+
|
2457
|
+
Parameters
|
2458
|
+
----------
|
2459
|
+
element_guid: str
|
2460
|
+
- the identity of the element to update
|
2461
|
+
body: dict
|
2462
|
+
- a dictionary structure containing the properties to set - see note below
|
2463
|
+
for_lineage: bool, default is set by server
|
2464
|
+
- determines if elements classified as Memento should be returned - normally false
|
2465
|
+
for_duplicate_processing: bool, default is set by server
|
2466
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
2467
|
+
server_name: str, default = None
|
2468
|
+
- name of the server instances for this request.
|
2469
|
+
time_out: int, default = default_time_out
|
2470
|
+
- http request timeout for this request
|
2471
|
+
|
2472
|
+
Returns
|
2473
|
+
-------
|
2474
|
+
[dict] | str
|
2475
|
+
Returns a string if no elements found and a list of dict of elements with the results.
|
2476
|
+
|
2477
|
+
Raises
|
2478
|
+
------
|
2479
|
+
InvalidParameterException
|
2480
|
+
one of the parameters is null or invalid or
|
2481
|
+
PropertyServerException
|
2482
|
+
There is a problem adding the element properties to the metadata repository or
|
2483
|
+
UserNotAuthorizedException
|
2484
|
+
the requesting user is not authorized to issue this request.
|
2485
|
+
|
2486
|
+
Note:
|
2487
|
+
|
2488
|
+
A sample dict structure is:
|
2489
|
+
|
2490
|
+
{
|
2491
|
+
"class" : "ClassificationRequestBody",
|
2492
|
+
"effectiveTime" : "an-isoTimestamp",
|
2493
|
+
"properties" : {
|
2494
|
+
"class" : "GovernanceClassificationProperties",
|
2495
|
+
"levelIdentifier" : 0,
|
2496
|
+
"status" : 0,
|
2497
|
+
"criticality" : 0,
|
2498
|
+
"steward" : "Add value here",
|
2499
|
+
"stewardTypeName" : "Add value here",
|
2500
|
+
"stewardPropertyName" : "Add value here",
|
2501
|
+
"source" : "Add value here",
|
2502
|
+
"notes" : "Add value here"
|
2503
|
+
}
|
2504
|
+
}
|
2505
|
+
|
2506
|
+
"""
|
2507
|
+
|
2508
|
+
loop = asyncio.get_event_loop()
|
2509
|
+
loop.run_until_complete(
|
2510
|
+
self._async_set_criticality_classification(element_guid, body, for_lineage, for_duplicate_processing,
|
2511
|
+
server_name, time_out))
|
2512
|
+
|
2513
|
+
async def _async_clear_criticality_classification(self, element_guid: str, for_lineage: bool = None,
|
2514
|
+
for_duplicate_processing: bool = None, effective_time: str = None,
|
2515
|
+
server_name: str = None,
|
2516
|
+
time_out: int = default_time_out) -> None:
|
2517
|
+
"""
|
2518
|
+
Remove the criticality classification from the element. This normally occurs when the organization has lost
|
2519
|
+
track of the level of criticality to assign to the element. Async Version.
|
2520
|
+
|
2521
|
+
Governance Action Classifications: https://egeria-project.org/types/4/0422-Governance-Action-Classifications/
|
2522
|
+
|
2523
|
+
Parameters
|
2524
|
+
----------
|
2525
|
+
element_guid: str
|
2526
|
+
- the identity of the element to update
|
2527
|
+
for_lineage: bool, default is set by server
|
2528
|
+
- determines if elements classified as Memento should be returned - normally false
|
2529
|
+
for_duplicate_processing: bool, default is set by server
|
2530
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
2531
|
+
effective_time: str, default = None
|
2532
|
+
- Time format is "YYYY-MM-DDTHH:MM:SS" (ISO 8601)
|
2533
|
+
server_name: str, default = None
|
2534
|
+
- name of the server instances for this request.
|
2535
|
+
time_out: int, default = default_time_out
|
2536
|
+
- http request timeout for this request
|
2537
|
+
|
2538
|
+
Returns
|
2539
|
+
-------
|
2540
|
+
[dict] | str
|
2541
|
+
Returns a string if no elements found and a list of dict of elements with the results.
|
2542
|
+
|
2543
|
+
Raises
|
2544
|
+
------
|
2545
|
+
InvalidParameterException
|
2546
|
+
one of the parameters is null or invalid or
|
2547
|
+
PropertyServerException
|
2548
|
+
There is a problem adding the element properties to the metadata repository or
|
2549
|
+
UserNotAuthorizedException
|
2550
|
+
the requesting user is not authorized to issue this request.
|
2551
|
+
|
2552
|
+
|
2553
|
+
"""
|
2554
|
+
if server_name is None:
|
2555
|
+
server_name = self.server_name
|
2556
|
+
|
2557
|
+
possible_query_params = query_string(
|
2558
|
+
[("forLineage", for_lineage), ("forDuplicateProcessing", for_duplicate_processing)])
|
2559
|
+
|
2560
|
+
url = (f"{base_path(self, server_name)}/elements/{element_guid}/criticality/remove"
|
2561
|
+
f"{possible_query_params}")
|
2562
|
+
|
2563
|
+
body = {
|
2564
|
+
"class": "ClassificationRequestBody",
|
2565
|
+
"effectiveTime": effective_time
|
2566
|
+
}
|
2567
|
+
|
2568
|
+
await self._async_make_request("POST", url, body_slimmer(body), time_out=time_out)
|
2569
|
+
|
2570
|
+
def clear_criticality_classification(self, element_guid: str, for_lineage: bool = None,
|
2571
|
+
for_duplicate_processing: bool = None, effective_time: str = None,
|
2572
|
+
server_name: str = None,
|
2573
|
+
time_out: int = default_time_out) -> None:
|
2574
|
+
"""
|
2575
|
+
Remove the criticality classification from the element. This normally occurs when the organization has lost
|
2576
|
+
track of the level of criticality to assign to the element.
|
2577
|
+
|
2578
|
+
Governance Action Classifications: https://egeria-project.org/types/4/0422-Governance-Action-Classifications/
|
2579
|
+
|
2580
|
+
Parameters
|
2581
|
+
----------
|
2582
|
+
element_guid: str
|
2583
|
+
- the identity of the element to update
|
2584
|
+
for_lineage: bool, default is set by server
|
2585
|
+
- determines if elements classified as Memento should be returned - normally false
|
2586
|
+
for_duplicate_processing: bool, default is set by server
|
2587
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
2588
|
+
effective_time: str, default = None
|
2589
|
+
- Time format is "YYYY-MM-DDTHH:MM:SS" (ISO 8601)
|
2590
|
+
server_name: str, default = None
|
2591
|
+
- name of the server instances for this request.
|
2592
|
+
time_out: int, default = default_time_out
|
2593
|
+
- http request timeout for this request
|
2594
|
+
|
2595
|
+
Returns
|
2596
|
+
-------
|
2597
|
+
[dict] | str
|
2598
|
+
Returns a string if no elements found and a list of dict of elements with the results.
|
2599
|
+
|
2600
|
+
Raises
|
2601
|
+
------
|
2602
|
+
InvalidParameterException
|
2603
|
+
one of the parameters is null or invalid or
|
2604
|
+
PropertyServerException
|
2605
|
+
There is a problem adding the element properties to the metadata repository or
|
2606
|
+
UserNotAuthorizedException
|
2607
|
+
the requesting user is not authorized to issue this request.
|
2608
|
+
|
2609
|
+
|
2610
|
+
"""
|
2611
|
+
|
2612
|
+
loop = asyncio.get_event_loop()
|
2613
|
+
loop.run_until_complete(
|
2614
|
+
self._async_clear_criticality_classification(element_guid, for_lineage, for_duplicate_processing,
|
2615
|
+
effective_time, server_name, time_out))
|
2616
|
+
|
2617
|
+
async def _async_add_gov_definition_to_element(self, definition_guid: str, element_guid: str,
|
2618
|
+
effective_time: str = None, for_lineage: bool = None,
|
2619
|
+
for_duplicate_processing: bool = None, server_name: str = None,
|
2620
|
+
time_out: int = default_time_out) -> None:
|
2621
|
+
"""
|
2622
|
+
Link a governance definition to an element using the GovernedBy relationship. Async version.
|
2623
|
+
|
2624
|
+
Governance Definitions: https://egeria-project.org/types/4/0401-Governance-Definitions/
|
2625
|
+
|
2626
|
+
Parameters
|
2627
|
+
----------
|
2628
|
+
definition_guid: str
|
2629
|
+
- identity of the governance definition to add
|
2630
|
+
element_guid: str
|
2631
|
+
- the identity of the element to update
|
2632
|
+
effective_time: str, default is None
|
2633
|
+
- None means ignore, otherwise the time that the element must be effective
|
2634
|
+
for_lineage: bool, default is set by server
|
2635
|
+
- determines if elements classified as Memento should be returned - normally false
|
2636
|
+
for_duplicate_processing: bool, default is set by server
|
2637
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
2638
|
+
server_name: str, default = None
|
2639
|
+
- name of the server instances for this request.
|
2640
|
+
time_out: int, default = default_time_out
|
2641
|
+
- http request timeout for this request
|
2642
|
+
|
2643
|
+
Returns
|
2644
|
+
-------
|
2645
|
+
None
|
2646
|
+
|
2647
|
+
Raises
|
2648
|
+
------
|
2649
|
+
InvalidParameterException
|
2650
|
+
one of the parameters is null or invalid or
|
2651
|
+
PropertyServerException
|
2652
|
+
There is a problem adding the element properties to the metadata repository or
|
2653
|
+
UserNotAuthorizedException
|
2654
|
+
the requesting user is not authorized to issue this request.
|
2655
|
+
|
2656
|
+
"""
|
2657
|
+
if server_name is None:
|
2658
|
+
server_name = self.server_name
|
2659
|
+
|
2660
|
+
possible_query_params = query_string(
|
2661
|
+
[("forLineage", for_lineage), ("forDuplicateProcessing", for_duplicate_processing)])
|
2662
|
+
|
2663
|
+
url = (f"{base_path(self, server_name)}/elements/{element_guid}/governed-by/definition/{definition_guid}"
|
2664
|
+
f"{possible_query_params}")
|
2665
|
+
|
2666
|
+
body = {"class": "RelationshipRequestBody", "effectiveTime": effective_time}
|
2667
|
+
|
2668
|
+
await self._async_make_request("POST", url, body_slimmer(body), time_out=time_out)
|
2669
|
+
|
2670
|
+
def add_gov_definition_to_element(self, definition_guid: str, element_guid: str, effective_time: str = None,
|
2671
|
+
for_lineage: bool = None, for_duplicate_processing: bool = None,
|
2672
|
+
server_name: str = None, time_out: int = default_time_out) -> None:
|
2673
|
+
"""
|
2674
|
+
Link a governance definition to an element using the GovernedBy relationship.
|
2675
|
+
|
2676
|
+
Governance Definition: https://egeria-project.org/types/4/0401-Governance-Definitions/
|
2677
|
+
|
2678
|
+
Parameters
|
2679
|
+
----------
|
2680
|
+
definition_guid: str
|
2681
|
+
- identity of the governance definition to add
|
2682
|
+
element_guid: str
|
2683
|
+
- the identity of the element to update
|
2684
|
+
effective_time: str, default is None
|
2685
|
+
- None means ignore, otherwise the time that the element must be effective
|
2686
|
+
for_lineage: bool, default is set by server
|
2687
|
+
- determines if elements classified as Memento should be returned - normally false
|
2688
|
+
for_duplicate_processing: bool, default is set by server
|
2689
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
2690
|
+
server_name: str, default = None
|
2691
|
+
- name of the server instances for this request.
|
2692
|
+
time_out: int, default = default_time_out
|
2693
|
+
- http request timeout for this request
|
2694
|
+
|
2695
|
+
Returns
|
2696
|
+
-------
|
2697
|
+
None
|
2698
|
+
|
2699
|
+
Raises
|
2700
|
+
------
|
2701
|
+
InvalidParameterException
|
2702
|
+
one of the parameters is null or invalid or
|
2703
|
+
PropertyServerException
|
2704
|
+
There is a problem adding the element properties to the metadata repository or
|
2705
|
+
UserNotAuthorizedException
|
2706
|
+
the requesting user is not authorized to issue this request.
|
2707
|
+
|
2708
|
+
"""
|
2709
|
+
|
2710
|
+
loop = asyncio.get_event_loop()
|
2711
|
+
loop.run_until_complete(
|
2712
|
+
self._async_add_gov_definition_to_element(definition_guid, element_guid, effective_time, for_lineage,
|
2713
|
+
for_duplicate_processing, server_name, time_out))
|
2714
|
+
|
2715
|
+
async def _async_clear_gov_definition_from_element(self, definition_guid, element_guid: str,
|
2716
|
+
for_lineage: bool = None, for_duplicate_processing: bool = None,
|
2717
|
+
effective_time: str = None, server_name: str = None,
|
2718
|
+
time_out: int = default_time_out) -> None:
|
2719
|
+
"""
|
2720
|
+
Remove the GovernedBy relationship between a governance definition and an element. Async Version.
|
2721
|
+
|
2722
|
+
Governance Action Classifications: https://egeria-project.org/types/4/0422-Governance-Action-Classifications/
|
2723
|
+
|
2724
|
+
Parameters
|
2725
|
+
----------
|
2726
|
+
definition_guid: str
|
2727
|
+
- identity of the governance definition to add
|
2728
|
+
element_guid: str
|
2729
|
+
- the identity of the element to update
|
2730
|
+
for_lineage: bool, default is set by server
|
2731
|
+
- determines if elements classified as Memento should be returned - normally false
|
2732
|
+
for_duplicate_processing: bool, default is set by server
|
2733
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
2734
|
+
effective_time: str, default = None
|
2735
|
+
- Time format is "YYYY-MM-DDTHH:MM:SS" (ISO 8601)
|
2736
|
+
server_name: str, default = None
|
2737
|
+
- name of the server instances for this request.
|
2738
|
+
time_out: int, default = default_time_out
|
2739
|
+
- http request timeout for this request
|
2740
|
+
|
2741
|
+
Returns
|
2742
|
+
-------
|
2743
|
+
[dict] | str
|
2744
|
+
Returns a string if no elements found and a list of dict of elements with the results.
|
2745
|
+
|
2746
|
+
Raises
|
2747
|
+
------
|
2748
|
+
InvalidParameterException
|
2749
|
+
one of the parameters is null or invalid or
|
2750
|
+
PropertyServerException
|
2751
|
+
There is a problem adding the element properties to the metadata repository or
|
2752
|
+
UserNotAuthorizedException
|
2753
|
+
the requesting user is not authorized to issue this request.
|
2754
|
+
|
2755
|
+
|
2756
|
+
"""
|
2757
|
+
if server_name is None:
|
2758
|
+
server_name = self.server_name
|
2759
|
+
|
2760
|
+
possible_query_params = query_string(
|
2761
|
+
[("forLineage", for_lineage), ("forDuplicateProcessing", for_duplicate_processing)])
|
2762
|
+
|
2763
|
+
url = (f"{base_path(self, server_name)}/elements/{element_guid}/governed-by/definition/"
|
2764
|
+
f"{definition_guid}/remove{possible_query_params}")
|
2765
|
+
|
2766
|
+
body = {
|
2767
|
+
"class": "ClassificationRequestBody",
|
2768
|
+
"effectiveTime": effective_time
|
2769
|
+
}
|
2770
|
+
|
2771
|
+
await self._async_make_request("POST", url, body_slimmer(body), time_out=time_out)
|
2772
|
+
|
2773
|
+
def clear_gov_definition_from_element(self, definition_guid, element_guid: str, for_lineage: bool = None,
|
2774
|
+
for_duplicate_processing: bool = None, effective_time: str = None,
|
2775
|
+
server_name: str = None,
|
2776
|
+
time_out: int = default_time_out) -> None:
|
2777
|
+
"""
|
2778
|
+
Remove the GovernedBy relationship between a governance definition and an element. Async Version.
|
2779
|
+
|
2780
|
+
Governance Action Classifications: https://egeria-project.org/types/4/0422-Governance-Action-Classifications/
|
2781
|
+
|
2782
|
+
Parameters
|
2783
|
+
----------
|
2784
|
+
definition_guid: str
|
2785
|
+
- identity of the governance definition to add
|
2786
|
+
element_guid: str
|
2787
|
+
- the identity of the element to update
|
2788
|
+
for_lineage: bool, default is set by server
|
2789
|
+
- determines if elements classified as Memento should be returned - normally false
|
2790
|
+
for_duplicate_processing: bool, default is set by server
|
2791
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
2792
|
+
effective_time: str, default = None
|
2793
|
+
- Time format is "YYYY-MM-DDTHH:MM:SS" (ISO 8601)
|
2794
|
+
server_name: str, default = None
|
2795
|
+
- name of the server instances for this request.
|
2796
|
+
time_out: int, default = default_time_out
|
2797
|
+
- http request timeout for this request
|
2798
|
+
|
2799
|
+
Returns
|
2800
|
+
-------
|
2801
|
+
[dict] | str
|
2802
|
+
Returns a string if no elements found and a list of dict of elements with the results.
|
2803
|
+
|
2804
|
+
Raises
|
2805
|
+
------
|
2806
|
+
InvalidParameterException
|
2807
|
+
one of the parameters is null or invalid or
|
2808
|
+
PropertyServerException
|
2809
|
+
There is a problem adding the element properties to the metadata repository or
|
2810
|
+
UserNotAuthorizedException
|
2811
|
+
the requesting user is not authorized to issue this request.
|
2812
|
+
|
2813
|
+
|
2814
|
+
"""
|
2815
|
+
|
2816
|
+
loop = asyncio.get_event_loop()
|
2817
|
+
loop.run_until_complete(
|
2818
|
+
self._async_clear_criticality_classification(element_guid, for_lineage, for_duplicate_processing,
|
2819
|
+
effective_time, server_name, time_out))
|
2820
|
+
|
2821
|
+
async def _async_add_ownership_to_element(self, element_guid: str, body: dict, for_lineage: bool = None,
|
2822
|
+
for_duplicate_processing: bool = None, server_name: str = None,
|
2823
|
+
time_out: int = default_time_out) -> None:
|
2824
|
+
"""
|
2825
|
+
Add or replace the ownership classification for an element. Async version.
|
2826
|
+
|
2827
|
+
Ownership: https://egeria-project.org/types/4/0445-Governance-Roles/
|
2828
|
+
|
2829
|
+
Parameters
|
2830
|
+
----------
|
2831
|
+
element_guid: str
|
2832
|
+
- the identity of the element to update
|
2833
|
+
body: dict
|
2834
|
+
- structure containing ownership information - see Notes
|
2835
|
+
for_lineage: bool, default is set by server
|
2836
|
+
- determines if elements classified as Memento should be returned - normally false
|
2837
|
+
for_duplicate_processing: bool, default is set by server
|
2838
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
2839
|
+
server_name: str, default = None
|
2840
|
+
- name of the server instances for this request.
|
2841
|
+
time_out: int, default = default_time_out
|
2842
|
+
- http request timeout for this request
|
2843
|
+
|
2844
|
+
Returns
|
2845
|
+
-------
|
2846
|
+
None
|
2847
|
+
|
2848
|
+
Raises
|
2849
|
+
------
|
2850
|
+
InvalidParameterException
|
2851
|
+
one of the parameters is null or invalid or
|
2852
|
+
PropertyServerException
|
2853
|
+
There is a problem adding the element properties to the metadata repository or
|
2854
|
+
UserNotAuthorizedException
|
2855
|
+
the requesting user is not authorized to issue this request.
|
2856
|
+
|
2857
|
+
Notes
|
2858
|
+
-----
|
2859
|
+
|
2860
|
+
{
|
2861
|
+
"class" : "ClassificationRequestBody",
|
2862
|
+
"effectiveTime" : "an isoTimestamp",
|
2863
|
+
"properties" : {
|
2864
|
+
"class" : "OwnerProperties",
|
2865
|
+
"owner" : "Add value here",
|
2866
|
+
"ownerTypeName" : "Add value here",
|
2867
|
+
"ownerPropertyName" : "Add value here"
|
2868
|
+
}
|
2869
|
+
}
|
2870
|
+
|
2871
|
+
"""
|
2872
|
+
if server_name is None:
|
2873
|
+
server_name = self.server_name
|
2874
|
+
|
2875
|
+
possible_query_params = query_string(
|
2876
|
+
[("forLineage", for_lineage), ("forDuplicateProcessing", for_duplicate_processing)])
|
2877
|
+
|
2878
|
+
url = (f"{base_path(self, server_name)}/elements/{element_guid}/ownership"
|
2879
|
+
f"{possible_query_params}")
|
2880
|
+
|
2881
|
+
await self._async_make_request("POST", url, body_slimmer(body), time_out=time_out)
|
2882
|
+
|
2883
|
+
def add_ownership_to_element(self, element_guid: str, body: dict, for_lineage: bool = None,
|
2884
|
+
for_duplicate_processing: bool = None, server_name: str = None,
|
2885
|
+
time_out: int = default_time_out) -> None:
|
2886
|
+
"""
|
2887
|
+
Add or replace the ownership classification for an element.
|
2888
|
+
|
2889
|
+
Ownership: https://egeria-project.org/types/4/0445-Governance-Roles/
|
2890
|
+
|
2891
|
+
Parameters
|
2892
|
+
----------
|
2893
|
+
element_guid: str
|
2894
|
+
- the identity of the element to update
|
2895
|
+
body: dict
|
2896
|
+
- structure containing ownership information - see Notes
|
2897
|
+
for_lineage: bool, default is set by server
|
2898
|
+
- determines if elements classified as Memento should be returned - normally false
|
2899
|
+
for_duplicate_processing: bool, default is set by server
|
2900
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
2901
|
+
server_name: str, default = None
|
2902
|
+
- name of the server instances for this request.
|
2903
|
+
time_out: int, default = default_time_out
|
2904
|
+
- http request timeout for this request
|
2905
|
+
|
2906
|
+
Returns
|
2907
|
+
-------
|
2908
|
+
None
|
2909
|
+
|
2910
|
+
Raises
|
2911
|
+
------
|
2912
|
+
InvalidParameterException
|
2913
|
+
one of the parameters is null or invalid or
|
2914
|
+
PropertyServerException
|
2915
|
+
There is a problem adding the element properties to the metadata repository or
|
2916
|
+
UserNotAuthorizedException
|
2917
|
+
the requesting user is not authorized to issue this request.
|
2918
|
+
|
2919
|
+
Notes
|
2920
|
+
-----
|
2921
|
+
|
2922
|
+
{
|
2923
|
+
"class" : "ClassificationRequestBody",
|
2924
|
+
"effectiveTime" : "an isoTimestamp",
|
2925
|
+
"properties" : {
|
2926
|
+
"class" : "OwnerProperties",
|
2927
|
+
"owner" : "Add value here",
|
2928
|
+
"ownerTypeName" : "Add value here",
|
2929
|
+
"ownerPropertyName" : "Add value here"
|
2930
|
+
}
|
2931
|
+
}
|
2932
|
+
|
2933
|
+
"""
|
2934
|
+
|
2935
|
+
loop = asyncio.get_event_loop()
|
2936
|
+
loop.run_until_complete(
|
2937
|
+
self._async_add_ownership_to_element(element_guid, body, for_lineage, for_duplicate_processing, server_name,
|
2938
|
+
time_out))
|
2939
|
+
|
2940
|
+
async def _async_clear_ownership_from_element(self, element_guid: str, for_lineage: bool = None,
|
2941
|
+
for_duplicate_processing: bool = None, effective_time: str = None,
|
2942
|
+
server_name: str = None,
|
2943
|
+
time_out: int = default_time_out) -> None:
|
2944
|
+
"""
|
2945
|
+
Remove the ownership classification from an element. Async version.
|
2946
|
+
|
2947
|
+
Ownership: https://egeria-project.org/types/4/0445-Governance-Roles/
|
2948
|
+
|
2949
|
+
Parameters
|
2950
|
+
----------
|
2951
|
+
element_guid: str
|
2952
|
+
- the identity of the element to update
|
2953
|
+
for_lineage: bool, default is set by server
|
2954
|
+
- determines if elements classified as Memento should be returned - normally false
|
2955
|
+
for_duplicate_processing: bool, default is set by server
|
2956
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
2957
|
+
effective_time: str, default = None
|
2958
|
+
- Time format is "YYYY-MM-DDTHH:MM:SS" (ISO 8601)
|
2959
|
+
server_name: str, default = None
|
2960
|
+
- name of the server instances for this request.
|
2961
|
+
time_out: int, default = default_time_out
|
2962
|
+
- http request timeout for this request
|
2963
|
+
|
2964
|
+
Returns
|
2965
|
+
-------
|
2966
|
+
None
|
2967
|
+
|
2968
|
+
Raises
|
2969
|
+
------
|
2970
|
+
InvalidParameterException
|
2971
|
+
one of the parameters is null or invalid or
|
2972
|
+
PropertyServerException
|
2973
|
+
There is a problem adding the element properties to the metadata repository or
|
2974
|
+
UserNotAuthorizedException
|
2975
|
+
the requesting user is not authorized to issue this request.
|
2976
|
+
|
2977
|
+
|
2978
|
+
"""
|
2979
|
+
if server_name is None:
|
2980
|
+
server_name = self.server_name
|
2981
|
+
|
2982
|
+
possible_query_params = query_string(
|
2983
|
+
[("forLineage", for_lineage), ("forDuplicateProcessing", for_duplicate_processing)])
|
2984
|
+
|
2985
|
+
url = (f"{base_path(self, server_name)}/elements/{element_guid}/ownership/remove"
|
2986
|
+
f"{possible_query_params}")
|
2987
|
+
|
2988
|
+
body = {
|
2989
|
+
"class": "ClassificationRequestBody",
|
2990
|
+
"effectiveTime": effective_time
|
2991
|
+
}
|
2992
|
+
|
2993
|
+
await self._async_make_request("POST", url, body_slimmer(body), time_out=time_out)
|
2994
|
+
|
2995
|
+
def clear_ownership_from_element(self, element_guid: str, for_lineage: bool = None,
|
2996
|
+
for_duplicate_processing: bool = None, effective_time: str = None,
|
2997
|
+
server_name: str = None,
|
2998
|
+
time_out: int = default_time_out) -> None:
|
2999
|
+
"""
|
3000
|
+
Remove the ownership classification from an element.
|
3001
|
+
|
3002
|
+
Ownership: https://egeria-project.org/types/4/0445-Governance-Roles/
|
3003
|
+
|
3004
|
+
Parameters
|
3005
|
+
----------
|
3006
|
+
element_guid: str
|
3007
|
+
- the identity of the element to update
|
3008
|
+
for_lineage: bool, default is set by server
|
3009
|
+
- determines if elements classified as Memento should be returned - normally false
|
3010
|
+
for_duplicate_processing: bool, default is set by server
|
3011
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
3012
|
+
effective_time: str, default = None
|
3013
|
+
- Time format is "YYYY-MM-DDTHH:MM:SS" (ISO 8601)
|
3014
|
+
server_name: str, default = None
|
3015
|
+
- name of the server instances for this request.
|
3016
|
+
time_out: int, default = default_time_out
|
3017
|
+
- http request timeout for this request
|
3018
|
+
|
3019
|
+
Returns
|
3020
|
+
-------
|
3021
|
+
None
|
3022
|
+
|
3023
|
+
Raises
|
3024
|
+
------
|
3025
|
+
InvalidParameterException
|
3026
|
+
one of the parameters is null or invalid or
|
3027
|
+
PropertyServerException
|
3028
|
+
There is a problem adding the element properties to the metadata repository or
|
3029
|
+
UserNotAuthorizedException
|
3030
|
+
the requesting user is not authorized to issue this request.
|
3031
|
+
|
3032
|
+
|
3033
|
+
"""
|
3034
|
+
|
3035
|
+
loop = asyncio.get_event_loop()
|
3036
|
+
loop.run_until_complete(
|
3037
|
+
self._async_clear_ownership_from_element(element_guid, for_lineage, for_duplicate_processing,
|
3038
|
+
effective_time, server_name,
|
3039
|
+
time_out))
|
3040
|
+
|
3041
|
+
async def _async_set_retention_classification(self, element_guid: str, body: dict, for_lineage: bool = None,
|
3042
|
+
for_duplicate_processing: bool = None, server_name: str = None,
|
3043
|
+
time_out: int = default_time_out) -> None:
|
3044
|
+
"""
|
3045
|
+
Classify/reclassify the element (typically an asset) to indicate how long the element (or associated resource)
|
3046
|
+
is to be retained by the organization. The policy to apply to the element/resource is captured by the retentionBasis
|
3047
|
+
property. The dates after which the element/resource is archived and then deleted are specified in the archiveAfter and deleteAfter
|
3048
|
+
properties respectively. Async version
|
3049
|
+
|
3050
|
+
Governance Action Classifications: https://egeria-project.org/types/4/0422-Governance-Action-Classifications/
|
3051
|
+
|
3052
|
+
Parameters
|
3053
|
+
----------
|
3054
|
+
element_guid: str
|
3055
|
+
- the identity of the element to update
|
3056
|
+
body: dict
|
3057
|
+
- a dictionary structure containing the properties to set - see note below
|
3058
|
+
for_lineage: bool, default is set by server
|
3059
|
+
- determines if elements classified as Memento should be returned - normally false
|
3060
|
+
for_duplicate_processing: bool, default is set by server
|
3061
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
3062
|
+
server_name: str, default = None
|
3063
|
+
- name of the server instances for this request.
|
3064
|
+
time_out: int, default = default_time_out
|
3065
|
+
- http request timeout for this request
|
3066
|
+
|
3067
|
+
Returns
|
3068
|
+
-------
|
3069
|
+
[dict] | str
|
3070
|
+
Returns a string if no elements found and a list of dict of elements with the results.
|
3071
|
+
|
3072
|
+
Raises
|
3073
|
+
------
|
3074
|
+
InvalidParameterException
|
3075
|
+
one of the parameters is null or invalid or
|
3076
|
+
PropertyServerException
|
3077
|
+
There is a problem adding the element properties to the metadata repository or
|
3078
|
+
UserNotAuthorizedException
|
3079
|
+
the requesting user is not authorized to issue this request.
|
3080
|
+
|
3081
|
+
Note:
|
3082
|
+
|
3083
|
+
A sample dict structure is:
|
3084
|
+
|
3085
|
+
{
|
3086
|
+
"class" : "ClassificationRequestBody",
|
3087
|
+
"effectiveTime" : "an isoTimestamp",
|
3088
|
+
"properties" : {
|
3089
|
+
"class" : "RetentionClassificationProperties",
|
3090
|
+
"retentionBasis" : 0,
|
3091
|
+
"status" : 0,
|
3092
|
+
"confidence" : 0,
|
3093
|
+
"associatedGUID" : "Add value here",
|
3094
|
+
"archiveAfter" : "{{$isoTimestamp}}",
|
3095
|
+
"deleteAfter" : "{{$isoTimestamp}}",
|
3096
|
+
"steward" : "Add value here",
|
3097
|
+
"stewardTypeName" : "Add value here",
|
3098
|
+
"stewardPropertyName" : "Add value here",
|
3099
|
+
"source" : "Add value here",
|
3100
|
+
"notes" : "Add value here"
|
3101
|
+
}
|
3102
|
+
}
|
3103
|
+
|
3104
|
+
"""
|
3105
|
+
if server_name is None:
|
3106
|
+
server_name = self.server_name
|
3107
|
+
|
3108
|
+
possible_query_params = query_string(
|
3109
|
+
[("forLineage", for_lineage), ("forDuplicateProcessing", for_duplicate_processing)])
|
3110
|
+
|
3111
|
+
url = (f"{base_path(self, server_name)}/elements/{element_guid}/retention"
|
3112
|
+
f"{possible_query_params}")
|
3113
|
+
|
3114
|
+
await self._async_make_request("POST", url, body_slimmer(body), time_out=time_out)
|
3115
|
+
|
3116
|
+
def set_retention_classification(self, element_guid: str, body: dict, for_lineage: bool = None,
|
3117
|
+
for_duplicate_processing: bool = None, server_name: str = None,
|
3118
|
+
time_out: int = default_time_out) -> None:
|
3119
|
+
"""
|
3120
|
+
Classify/reclassify the element (typically an asset) to indicate how long the element (or associated resource)
|
3121
|
+
is to be retained by the organization. The policy to apply to the element/resource is captured by the retentionBasis
|
3122
|
+
property. The dates after which the element/resource is archived and then deleted are specified in the archiveAfter and deleteAfter
|
3123
|
+
properties respectively. Async version
|
3124
|
+
|
3125
|
+
Governance Action Classifications: https://egeria-project.org/types/4/0422-Governance-Action-Classifications/
|
3126
|
+
|
3127
|
+
Parameters
|
3128
|
+
----------
|
3129
|
+
element_guid: str
|
3130
|
+
- the identity of the element to update
|
3131
|
+
body: dict
|
3132
|
+
- a dictionary structure containing the properties to set - see note below
|
3133
|
+
for_lineage: bool, default is set by server
|
3134
|
+
- determines if elements classified as Memento should be returned - normally false
|
3135
|
+
for_duplicate_processing: bool, default is set by server
|
3136
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
3137
|
+
server_name: str, default = None
|
3138
|
+
- name of the server instances for this request.
|
3139
|
+
time_out: int, default = default_time_out
|
3140
|
+
- http request timeout for this request
|
3141
|
+
|
3142
|
+
Returns
|
3143
|
+
-------
|
3144
|
+
[dict] | str
|
3145
|
+
Returns a string if no elements found and a list of dict of elements with the results.
|
3146
|
+
|
3147
|
+
Raises
|
3148
|
+
------
|
3149
|
+
InvalidParameterException
|
3150
|
+
one of the parameters is null or invalid or
|
3151
|
+
PropertyServerException
|
3152
|
+
There is a problem adding the element properties to the metadata repository or
|
3153
|
+
UserNotAuthorizedException
|
3154
|
+
the requesting user is not authorized to issue this request.
|
3155
|
+
|
3156
|
+
Note:
|
3157
|
+
|
3158
|
+
A sample dict structure is:
|
3159
|
+
|
3160
|
+
{
|
3161
|
+
"class" : "ClassificationRequestBody",
|
3162
|
+
"effectiveTime" : "an isoTimestamp",
|
3163
|
+
"properties" : {
|
3164
|
+
"class" : "RetentionClassificationProperties",
|
3165
|
+
"retentionBasis" : 0,
|
3166
|
+
"status" : 0,
|
3167
|
+
"confidence" : 0,
|
3168
|
+
"associatedGUID" : "Add value here",
|
3169
|
+
"archiveAfter" : "{{$isoTimestamp}}",
|
3170
|
+
"deleteAfter" : "{{$isoTimestamp}}",
|
3171
|
+
"steward" : "Add value here",
|
3172
|
+
"stewardTypeName" : "Add value here",
|
3173
|
+
"stewardPropertyName" : "Add value here",
|
3174
|
+
"source" : "Add value here",
|
3175
|
+
"notes" : "Add value here"
|
3176
|
+
}
|
3177
|
+
}
|
3178
|
+
"""
|
3179
|
+
|
3180
|
+
loop = asyncio.get_event_loop()
|
3181
|
+
loop.run_until_complete(
|
3182
|
+
self._async_set_retention_classification(element_guid, body, for_lineage, for_duplicate_processing,
|
3183
|
+
server_name, time_out))
|
3184
|
+
|
3185
|
+
async def _async_clear_retention_classification(self, element_guid: str, for_lineage: bool = None,
|
3186
|
+
for_duplicate_processing: bool = None, effective_time: str = None,
|
3187
|
+
server_name: str = None,
|
3188
|
+
time_out: int = default_time_out) -> None:
|
3189
|
+
"""
|
3190
|
+
Remove the retention classification from the element. This normally occurs when the organization has lost
|
3191
|
+
track of the level of retention to assign to the element. Async Version.
|
3192
|
+
|
3193
|
+
Governance Action Classifications: https://egeria-project.org/types/4/0422-Governance-Action-Classifications/
|
3194
|
+
|
3195
|
+
Parameters
|
3196
|
+
----------
|
3197
|
+
element_guid: str
|
3198
|
+
- the identity of the element to update
|
3199
|
+
for_lineage: bool, default is set by server
|
3200
|
+
- determines if elements classified as Memento should be returned - normally false
|
3201
|
+
for_duplicate_processing: bool, default is set by server
|
3202
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
3203
|
+
effective_time: str, default = None
|
3204
|
+
- Time format is "YYYY-MM-DDTHH:MM:SS" (ISO 8601)
|
3205
|
+
server_name: str, default = None
|
3206
|
+
- name of the server instances for this request.
|
3207
|
+
time_out: int, default = default_time_out
|
3208
|
+
- http request timeout for this request
|
3209
|
+
|
3210
|
+
Returns
|
3211
|
+
-------
|
3212
|
+
[dict] | str
|
3213
|
+
Returns a string if no elements found and a list of dict of elements with the results.
|
3214
|
+
|
3215
|
+
Raises
|
3216
|
+
------
|
3217
|
+
InvalidParameterException
|
3218
|
+
one of the parameters is null or invalid or
|
3219
|
+
PropertyServerException
|
3220
|
+
There is a problem adding the element properties to the metadata repository or
|
3221
|
+
UserNotAuthorizedException
|
3222
|
+
the requesting user is not authorized to issue this request.
|
3223
|
+
|
3224
|
+
|
3225
|
+
"""
|
3226
|
+
if server_name is None:
|
3227
|
+
server_name = self.server_name
|
3228
|
+
|
3229
|
+
possible_query_params = query_string(
|
3230
|
+
[("forLineage", for_lineage), ("forDuplicateProcessing", for_duplicate_processing)])
|
3231
|
+
|
3232
|
+
url = (f"{base_path(self, server_name)}/elements/{element_guid}/retention/remove"
|
3233
|
+
f"{possible_query_params}")
|
3234
|
+
|
3235
|
+
body = {
|
3236
|
+
"class": "ClassificationRequestBody",
|
3237
|
+
"effectiveTime": effective_time
|
3238
|
+
}
|
3239
|
+
|
3240
|
+
await self._async_make_request("POST", url, body_slimmer(body), time_out=time_out)
|
3241
|
+
|
3242
|
+
def clear_retention_classification(self, element_guid: str, for_lineage: bool = None,
|
3243
|
+
for_duplicate_processing: bool = None, effective_time: str = None,
|
3244
|
+
server_name: str = None,
|
3245
|
+
time_out: int = default_time_out) -> None:
|
3246
|
+
"""
|
3247
|
+
Remove the retention classification from the element. This normally occurs when the organization has lost
|
3248
|
+
track of the level of retention to assign to the element.
|
3249
|
+
|
3250
|
+
Governance Action Classifications: https://egeria-project.org/types/4/0422-Governance-Action-Classifications/
|
3251
|
+
|
3252
|
+
Parameters
|
3253
|
+
----------
|
3254
|
+
element_guid: str
|
3255
|
+
- the identity of the element to update
|
3256
|
+
for_lineage: bool, default is set by server
|
3257
|
+
- determines if elements classified as Memento should be returned - normally false
|
3258
|
+
for_duplicate_processing: bool, default is set by server
|
3259
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
3260
|
+
effective_time: str, default = None
|
3261
|
+
- Time format is "YYYY-MM-DDTHH:MM:SS" (ISO 8601)
|
3262
|
+
server_name: str, default = None
|
3263
|
+
- name of the server instances for this request.
|
3264
|
+
time_out: int, default = default_time_out
|
3265
|
+
- http request timeout for this request
|
3266
|
+
|
3267
|
+
Returns
|
3268
|
+
-------
|
3269
|
+
[dict] | str
|
3270
|
+
Returns a string if no elements found and a list of dict of elements with the results.
|
3271
|
+
|
3272
|
+
Raises
|
3273
|
+
------
|
3274
|
+
InvalidParameterException
|
3275
|
+
one of the parameters is null or invalid or
|
3276
|
+
PropertyServerException
|
3277
|
+
There is a problem adding the element properties to the metadata repository or
|
3278
|
+
UserNotAuthorizedException
|
3279
|
+
the requesting user is not authorized to issue this request.
|
3280
|
+
|
3281
|
+
|
3282
|
+
"""
|
3283
|
+
|
3284
|
+
loop = asyncio.get_event_loop()
|
3285
|
+
loop.run_until_complete(
|
3286
|
+
self._async_clear_retention_classification(element_guid, for_lineage, for_duplicate_processing,
|
3287
|
+
effective_time, server_name,
|
3288
|
+
time_out))
|
3289
|
+
|
3290
|
+
async def _async_set_security_tags_classification(self, element_guid: str, body: dict, for_lineage: bool = None,
|
3291
|
+
for_duplicate_processing: bool = None, server_name: str = None,
|
3292
|
+
time_out: int = default_time_out) -> None:
|
3293
|
+
"""
|
3294
|
+
Add or replace the security tags for an element. Async versuib,
|
3295
|
+
|
3296
|
+
Security Tags: https://egeria-project.org/types/4/0423-Security-Definitions/
|
3297
|
+
|
3298
|
+
Parameters
|
3299
|
+
----------
|
3300
|
+
element_guid: str
|
3301
|
+
- the identity of the element to update
|
3302
|
+
body: dict
|
3303
|
+
- a dictionary structure containing the properties to set - see note below
|
3304
|
+
for_lineage: bool, default is set by server
|
3305
|
+
- determines if elements classified as Memento should be returned - normally false
|
3306
|
+
for_duplicate_processing: bool, default is set by server
|
3307
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
3308
|
+
server_name: str, default = None
|
3309
|
+
- name of the server instances for this request.
|
3310
|
+
time_out: int, default = default_time_out
|
3311
|
+
- http request timeout for this request
|
3312
|
+
|
3313
|
+
Returns
|
3314
|
+
-------
|
3315
|
+
[dict] | str
|
3316
|
+
Returns a string if no elements found and a list of dict of elements with the results.
|
3317
|
+
|
3318
|
+
Raises
|
3319
|
+
------
|
3320
|
+
InvalidParameterException
|
3321
|
+
one of the parameters is null or invalid or
|
3322
|
+
PropertyServerException
|
3323
|
+
There is a problem adding the element properties to the metadata repository or
|
3324
|
+
UserNotAuthorizedException
|
3325
|
+
the requesting user is not authorized to issue this request.
|
3326
|
+
|
3327
|
+
Note:
|
3328
|
+
|
3329
|
+
A sample dict structure is:
|
3330
|
+
|
3331
|
+
{
|
3332
|
+
"class" : "ClassificationRequestBody",
|
3333
|
+
"effectiveTime" : "an isoTimestamp",
|
3334
|
+
"properties" : {
|
3335
|
+
"class" : "SecurityTagsProperties",
|
3336
|
+
"securityLabels" : [ "Label1", "Label2" ],
|
3337
|
+
"securityProperties" : {
|
3338
|
+
"propertyName1" : "add property value here",
|
3339
|
+
"propertyName2" : "add property value here"
|
3340
|
+
},
|
3341
|
+
"accessGroups" : {
|
3342
|
+
"groupName1" : [ "operation1", "operation2" ],
|
3343
|
+
"groupName2" : [ "operation1", "operation3" ]
|
3344
|
+
}
|
3345
|
+
}
|
3346
|
+
}
|
3347
|
+
|
3348
|
+
|
3349
|
+
"""
|
3350
|
+
if server_name is None:
|
3351
|
+
server_name = self.server_name
|
3352
|
+
|
3353
|
+
possible_query_params = query_string(
|
3354
|
+
[("forLineage", for_lineage), ("forDuplicateProcessing", for_duplicate_processing)])
|
3355
|
+
|
3356
|
+
url = (f"{base_path(self, server_name)}/elements/{element_guid}/security-tags"
|
3357
|
+
f"{possible_query_params}")
|
3358
|
+
|
3359
|
+
await self._async_make_request("POST", url, body_slimmer(body), time_out=time_out)
|
3360
|
+
|
3361
|
+
def set_security_tags_classification(self, element_guid: str, body: dict, for_lineage: bool = None,
|
3362
|
+
for_duplicate_processing: bool = None, server_name: str = None,
|
3363
|
+
time_out: int = default_time_out) -> None:
|
3364
|
+
"""
|
3365
|
+
Add or replace the security tags for an element. Async versuib,
|
3366
|
+
|
3367
|
+
Security Tags: https://egeria-project.org/types/4/0423-Security-Definitions/
|
3368
|
+
|
3369
|
+
Parameters
|
3370
|
+
----------
|
3371
|
+
element_guid: str
|
3372
|
+
- the identity of the element to update
|
3373
|
+
body: dict
|
3374
|
+
- a dictionary structure containing the properties to set - see note below
|
3375
|
+
for_lineage: bool, default is set by server
|
3376
|
+
- determines if elements classified as Memento should be returned - normally false
|
3377
|
+
for_duplicate_processing: bool, default is set by server
|
3378
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
3379
|
+
server_name: str, default = None
|
3380
|
+
- name of the server instances for this request.
|
3381
|
+
time_out: int, default = default_time_out
|
3382
|
+
- http request timeout for this request
|
3383
|
+
|
3384
|
+
Returns
|
3385
|
+
-------
|
3386
|
+
[dict] | str
|
3387
|
+
Returns a string if no elements found and a list of dict of elements with the results.
|
3388
|
+
|
3389
|
+
Raises
|
3390
|
+
------
|
3391
|
+
InvalidParameterException
|
3392
|
+
one of the parameters is null or invalid or
|
3393
|
+
PropertyServerException
|
3394
|
+
There is a problem adding the element properties to the metadata repository or
|
3395
|
+
UserNotAuthorizedException
|
3396
|
+
the requesting user is not authorized to issue this request.
|
3397
|
+
|
3398
|
+
Note:
|
3399
|
+
|
3400
|
+
A sample dict structure is:
|
3401
|
+
|
3402
|
+
{
|
3403
|
+
"class" : "ClassificationRequestBody",
|
3404
|
+
"effectiveTime" : "an isoTimestamp",
|
3405
|
+
"properties" : {
|
3406
|
+
"class" : "SecurityTagsProperties",
|
3407
|
+
"securityLabels" : [ "Label1", "Label2" ],
|
3408
|
+
"securityProperties" : {
|
3409
|
+
"propertyName1" : "add property value here",
|
3410
|
+
"propertyName2" : "add property value here"
|
3411
|
+
},
|
3412
|
+
"accessGroups" : {
|
3413
|
+
"groupName1" : [ "operation1", "operation2" ],
|
3414
|
+
"groupName2" : [ "operation1", "operation3" ]
|
3415
|
+
}
|
3416
|
+
}
|
3417
|
+
}
|
3418
|
+
|
3419
|
+
|
3420
|
+
"""
|
3421
|
+
|
3422
|
+
loop = asyncio.get_event_loop()
|
3423
|
+
loop.run_until_complete(
|
3424
|
+
self._async_set_security_tags_classification(element_guid, body, for_lineage, for_duplicate_processing,
|
3425
|
+
server_name, time_out))
|
3426
|
+
|
3427
|
+
async def _async_clear_security_tags_classification(self, element_guid: str, for_lineage: bool = None,
|
3428
|
+
for_duplicate_processing: bool = None,
|
3429
|
+
effective_time: str = None, server_name: str = None,
|
3430
|
+
time_out: int = default_time_out) -> None:
|
3431
|
+
"""
|
3432
|
+
Remove the security-tags classification from the element.
|
3433
|
+
|
3434
|
+
Security Tags: https://egeria-project.org/types/4/0423-Security-Definitions/
|
3435
|
+
|
3436
|
+
Parameters
|
3437
|
+
----------
|
3438
|
+
element_guid: str
|
3439
|
+
- the identity of the element to update
|
3440
|
+
for_lineage: bool, default is set by server
|
3441
|
+
- determines if elements classified as Memento should be returned - normally false
|
3442
|
+
for_duplicate_processing: bool, default is set by server
|
3443
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
3444
|
+
server_name: str, default = None
|
3445
|
+
- name of the server instances for this request.
|
3446
|
+
time_out: int, default = default_time_out
|
3447
|
+
- http request timeout for this request
|
3448
|
+
|
3449
|
+
Returns
|
3450
|
+
-------
|
3451
|
+
None
|
3452
|
+
|
3453
|
+
Raises
|
3454
|
+
------
|
3455
|
+
InvalidParameterException
|
3456
|
+
one of the parameters is null or invalid or
|
3457
|
+
PropertyServerException
|
3458
|
+
There is a problem adding the element properties to the metadata repository or
|
3459
|
+
UserNotAuthorizedException
|
3460
|
+
the requesting user is not authorized to issue this request.
|
3461
|
+
|
3462
|
+
|
3463
|
+
"""
|
3464
|
+
if server_name is None:
|
3465
|
+
server_name = self.server_name
|
3466
|
+
|
3467
|
+
possible_query_params = query_string(
|
3468
|
+
[("forLineage", for_lineage), ("forDuplicateProcessing", for_duplicate_processing)])
|
3469
|
+
|
3470
|
+
url = (f"{base_path(self, server_name)}/elements/{element_guid}/security-tags/remove"
|
3471
|
+
f"{possible_query_params}")
|
3472
|
+
|
3473
|
+
body = {
|
3474
|
+
"class": "ClassificationRequestBody",
|
3475
|
+
"effectiveTime": effective_time
|
3476
|
+
}
|
3477
|
+
|
3478
|
+
await self._async_make_request("POST", url, body_slimmer(body), time_out=time_out)
|
3479
|
+
|
3480
|
+
def clear_security_tags_classification(self, element_guid: str, for_lineage: bool = None,
|
3481
|
+
for_duplicate_processing: bool = None, effective_time: str = None,
|
3482
|
+
server_name: str = None,
|
3483
|
+
time_out: int = default_time_out) -> None:
|
3484
|
+
"""
|
3485
|
+
Remove the security-tags classification from the element.
|
3486
|
+
|
3487
|
+
Security Tags: https://egeria-project.org/types/4/0423-Security-Definitions/
|
3488
|
+
|
3489
|
+
Parameters
|
3490
|
+
----------
|
3491
|
+
element_guid: str
|
3492
|
+
- the identity of the element to update
|
3493
|
+
for_lineage: bool, default is set by server
|
3494
|
+
- determines if elements classified as Memento should be returned - normally false
|
3495
|
+
for_duplicate_processing: bool, default is set by server
|
3496
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
3497
|
+
effective_time: str, default = None
|
3498
|
+
- Time format is "YYYY-MM-DDTHH:MM:SS" (ISO 8601)
|
3499
|
+
server_name: str, default = None
|
3500
|
+
- name of the server instances for this request.
|
3501
|
+
time_out: int, default = default_time_out
|
3502
|
+
- http request timeout for this request
|
3503
|
+
|
3504
|
+
Returns
|
3505
|
+
-------
|
3506
|
+
None
|
3507
|
+
|
3508
|
+
Raises
|
3509
|
+
------
|
3510
|
+
InvalidParameterException
|
3511
|
+
one of the parameters is null or invalid or
|
3512
|
+
PropertyServerException
|
3513
|
+
There is a problem adding the element properties to the metadata repository or
|
3514
|
+
UserNotAuthorizedException
|
3515
|
+
the requesting user is not authorized to issue this request.
|
3516
|
+
|
3517
|
+
|
3518
|
+
"""
|
3519
|
+
|
3520
|
+
loop = asyncio.get_event_loop()
|
3521
|
+
loop.run_until_complete(
|
3522
|
+
self._async_clear_security_tags_classification(element_guid, for_lineage, for_duplicate_processing,
|
3523
|
+
effective_time, server_name, time_out))
|
3524
|
+
|
3525
|
+
async def _async_setup_semantic_assignment(self, glossary_term_guid: str, element_guid: str, body: dict,
|
3526
|
+
for_lineage: bool = None, for_duplicate_processing: bool = None,
|
3527
|
+
server_name: str = None, time_out: int = default_time_out) -> None:
|
3528
|
+
"""
|
3529
|
+
Create a semantic assignment relationship between a glossary term and an element (normally a schema attribute,
|
3530
|
+
data field or asset). This relationship indicates that the data associated with the element meaning matches
|
3531
|
+
the description in the glossary term. Async version
|
3532
|
+
|
3533
|
+
Semantic Assignments: https://egeria-project.org/types/3/0370-Semantic-Assignment/
|
3534
|
+
|
3535
|
+
Parameters
|
3536
|
+
----------
|
3537
|
+
glossary_term_guid: str
|
3538
|
+
- identity of glossary to assign
|
3539
|
+
element_guid: str
|
3540
|
+
- the identity of the element to update
|
3541
|
+
body: dict
|
3542
|
+
- a dictionary structure containing the properties to set - see note below
|
3543
|
+
for_lineage: bool, default is set by server
|
3544
|
+
- determines if elements classified as Memento should be returned - normally false
|
3545
|
+
for_duplicate_processing: bool, default is set by server
|
3546
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
3547
|
+
server_name: str, default = None
|
3548
|
+
- name of the server instances for this request.
|
3549
|
+
time_out: int, default = default_time_out
|
3550
|
+
- http request timeout for this request
|
3551
|
+
|
3552
|
+
Returns
|
3553
|
+
-------
|
3554
|
+
None
|
3555
|
+
|
3556
|
+
Raises
|
3557
|
+
------
|
3558
|
+
InvalidParameterException
|
3559
|
+
one of the parameters is null or invalid or
|
3560
|
+
PropertyServerException
|
3561
|
+
There is a problem adding the element properties to the metadata repository or
|
3562
|
+
UserNotAuthorizedException
|
3563
|
+
the requesting user is not authorized to issue this request.
|
3564
|
+
|
3565
|
+
Note:
|
3566
|
+
|
3567
|
+
A sample dict structure is:
|
3568
|
+
|
3569
|
+
{
|
3570
|
+
"class" : "RelationshipRequestBody",
|
3571
|
+
"effectiveTime" : "an isoTimestamp",
|
3572
|
+
"relationshipProperties" : {
|
3573
|
+
"class": "SemanticAssignmentProperties",
|
3574
|
+
"expression" : "add value here",
|
3575
|
+
"description" : "add value here",
|
3576
|
+
"status" : "VALIDATED",
|
3577
|
+
"confidence" : 100,
|
3578
|
+
"createdBy" : "add value here",
|
3579
|
+
"steward" : "add value here",
|
3580
|
+
"source" : "add value here"
|
3581
|
+
}
|
3582
|
+
}
|
3583
|
+
|
3584
|
+
|
3585
|
+
"""
|
3586
|
+
if server_name is None:
|
3587
|
+
server_name = self.server_name
|
3588
|
+
|
3589
|
+
possible_query_params = query_string(
|
3590
|
+
[("forLineage", for_lineage), ("forDuplicateProcessing", for_duplicate_processing)])
|
3591
|
+
|
3592
|
+
url = (f"{base_path(self, server_name)}/elements/{element_guid}/semantic-assignment/terms"
|
3593
|
+
f"/{glossary_term_guid}{possible_query_params}")
|
3594
|
+
|
3595
|
+
await self._async_make_request("POST", url, body_slimmer(body), time_out=time_out)
|
3596
|
+
|
3597
|
+
def setup_semantic_assignment(self, glossary_term_guid: str, element_guid: str, body: dict,
|
3598
|
+
for_lineage: bool = None, for_duplicate_processing: bool = None,
|
3599
|
+
server_name: str = None, time_out: int = default_time_out) -> None:
|
3600
|
+
"""
|
3601
|
+
Create a semantic assignment relationship between a glossary term and an element (normally a schema attribute,
|
3602
|
+
data field or asset). This relationship indicates that the data associated with the element meaning matches
|
3603
|
+
the description in the glossary term.
|
3604
|
+
|
3605
|
+
Semantic Assignments: https://egeria-project.org/types/3/0370-Semantic-Assignment/
|
3606
|
+
|
3607
|
+
Parameters
|
3608
|
+
----------
|
3609
|
+
glossary_term_guid: str
|
3610
|
+
- identity of glossary to assign
|
3611
|
+
element_guid: str
|
3612
|
+
- the identity of the element to update
|
3613
|
+
body: dict
|
3614
|
+
- a dictionary structure containing the properties to set - see note below
|
3615
|
+
for_lineage: bool, default is set by server
|
3616
|
+
- determines if elements classified as Memento should be returned - normally false
|
3617
|
+
for_duplicate_processing: bool, default is set by server
|
3618
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
3619
|
+
server_name: str, default = None
|
3620
|
+
- name of the server instances for this request.
|
3621
|
+
time_out: int, default = default_time_out
|
3622
|
+
- http request timeout for this request
|
3623
|
+
|
3624
|
+
Returns
|
3625
|
+
-------
|
3626
|
+
None
|
3627
|
+
|
3628
|
+
Raises
|
3629
|
+
------
|
3630
|
+
InvalidParameterException
|
3631
|
+
one of the parameters is null or invalid or
|
3632
|
+
PropertyServerException
|
3633
|
+
There is a problem adding the element properties to the metadata repository or
|
3634
|
+
UserNotAuthorizedException
|
3635
|
+
the requesting user is not authorized to issue this request.
|
3636
|
+
|
3637
|
+
Note:
|
3638
|
+
|
3639
|
+
A sample dict structure is:
|
3640
|
+
|
3641
|
+
{
|
3642
|
+
"class" : "RelationshipRequestBody",
|
3643
|
+
"effectiveTime" : "an isoTimestamp",
|
3644
|
+
"relationshipProperties" : {
|
3645
|
+
"class": "SemanticAssignmentProperties",
|
3646
|
+
"expression" : "add value here",
|
3647
|
+
"description" : "add value here",
|
3648
|
+
"status" : "VALIDATED",
|
3649
|
+
"confidence" : 100,
|
3650
|
+
"createdBy" : "add value here",
|
3651
|
+
"steward" : "add value here",
|
3652
|
+
"source" : "add value here"
|
3653
|
+
}
|
3654
|
+
}
|
3655
|
+
|
3656
|
+
"""
|
3657
|
+
|
3658
|
+
loop = asyncio.get_event_loop()
|
3659
|
+
loop.run_until_complete(
|
3660
|
+
self._async_setup_semantic_assignment(glossary_term_guid, element_guid, body, for_lineage,
|
3661
|
+
for_duplicate_processing, server_name, time_out))
|
3662
|
+
|
3663
|
+
async def _async_clear_semantic_assignment_classification(self, glossary_term_guid: str, element_guid: str,
|
3664
|
+
for_lineage: bool = None,
|
3665
|
+
for_duplicate_processing: bool = None,
|
3666
|
+
effective_time: str = None,
|
3667
|
+
server_name: str = None,
|
3668
|
+
time_out: int = default_time_out) -> None:
|
3669
|
+
"""
|
3670
|
+
Remove the semantic_assignment classification from the element. Async version.
|
3671
|
+
|
3672
|
+
Security Tags: https://egeria-project.org/types/4/0423-Security-Definitions/
|
3673
|
+
|
3674
|
+
Parameters
|
3675
|
+
----------
|
3676
|
+
glossary_term_guid: str
|
3677
|
+
- identity of glossary to remove
|
3678
|
+
element_guid: str
|
3679
|
+
- the identity of the element to update
|
3680
|
+
for_lineage: bool, default is set by server
|
3681
|
+
- determines if elements classified as Memento should be returned - normally false
|
3682
|
+
for_duplicate_processing: bool, default is set by server
|
3683
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
3684
|
+
effective_time: str, default = None
|
3685
|
+
- Time format is "YYYY-MM-DDTHH:MM:SS" (ISO 8601)
|
3686
|
+
server_name: str, default = None
|
3687
|
+
- name of the server instances for this request.
|
3688
|
+
time_out: int, default = default_time_out
|
3689
|
+
- http request timeout for this request
|
3690
|
+
|
3691
|
+
Returns
|
3692
|
+
-------
|
3693
|
+
None
|
3694
|
+
|
3695
|
+
Raises
|
3696
|
+
------
|
3697
|
+
InvalidParameterException
|
3698
|
+
one of the parameters is null or invalid or
|
3699
|
+
PropertyServerException
|
3700
|
+
There is a problem adding the element properties to the metadata repository or
|
3701
|
+
UserNotAuthorizedException
|
3702
|
+
the requesting user is not authorized to issue this request.
|
3703
|
+
|
3704
|
+
"""
|
3705
|
+
if server_name is None:
|
3706
|
+
server_name = self.server_name
|
3707
|
+
|
3708
|
+
possible_query_params = query_string(
|
3709
|
+
[("forLineage", for_lineage), ("forDuplicateProcessing", for_duplicate_processing)])
|
3710
|
+
|
3711
|
+
url = (f"{base_path(self, server_name)}/elements/{element_guid}/semantic-assignment/terms/"
|
3712
|
+
f"{glossary_term_guid}/remove{possible_query_params}")
|
3713
|
+
|
3714
|
+
body = {
|
3715
|
+
"class": "ClassificationRequestBody",
|
3716
|
+
"effectiveTime": effective_time
|
3717
|
+
}
|
3718
|
+
|
3719
|
+
await self._async_make_request("POST", url, body_slimmer(body), time_out=time_out)
|
3720
|
+
|
3721
|
+
def clear_semantic_assignment_classification(self, glossary_term_guid: str, element_guid: str,
|
3722
|
+
for_lineage: bool = None, for_duplicate_processing: bool = None,
|
3723
|
+
effective_time: str = None,
|
3724
|
+
server_name: str = None, time_out: int = default_time_out) -> None:
|
3725
|
+
"""
|
3726
|
+
Remove the semantic_assignment classification from the element.
|
3727
|
+
|
3728
|
+
Security Tags: https://egeria-project.org/types/4/0423-Security-Definitions/
|
3729
|
+
|
3730
|
+
Parameters
|
3731
|
+
----------
|
3732
|
+
glossary_term_guid: str
|
3733
|
+
- identity of glossary to remove
|
3734
|
+
element_guid: str
|
3735
|
+
- the identity of the element to update
|
3736
|
+
for_lineage: bool, default is set by server
|
3737
|
+
- determines if elements classified as Memento should be returned - normally false
|
3738
|
+
for_duplicate_processing: bool, default is set by server
|
3739
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
3740
|
+
effective_time: str, default = None
|
3741
|
+
- Time format is "YYYY-MM-DDTHH:MM:SS" (ISO 8601)
|
3742
|
+
server_name: str, default = None
|
3743
|
+
- name of the server instances for this request.
|
3744
|
+
time_out: int, default = default_time_out
|
3745
|
+
- http request timeout for this request
|
3746
|
+
|
3747
|
+
Returns
|
3748
|
+
-------
|
3749
|
+
None
|
3750
|
+
|
3751
|
+
Raises
|
3752
|
+
------
|
3753
|
+
InvalidParameterException
|
3754
|
+
one of the parameters is null or invalid or
|
3755
|
+
PropertyServerException
|
3756
|
+
There is a problem adding the element properties to the metadata repository or
|
3757
|
+
UserNotAuthorizedException
|
3758
|
+
the requesting user is not authorized to issue this request.
|
3759
|
+
|
3760
|
+
|
3761
|
+
"""
|
3762
|
+
|
3763
|
+
loop = asyncio.get_event_loop()
|
3764
|
+
loop.run_until_complete(
|
3765
|
+
self._async_clear_semantic_assignment_classification(glossary_term_guid, element_guid, for_lineage,
|
3766
|
+
for_duplicate_processing, effective_time, server_name,
|
3767
|
+
time_out))
|
3768
|
+
|
3769
|
+
async def _async_add_element_to_subject_area(self, element_guid: str, body: dict, for_lineage: bool = None,
|
3770
|
+
for_duplicate_processing: bool = None, server_name: str = None,
|
3771
|
+
time_out: int = default_time_out) -> None:
|
3772
|
+
"""
|
3773
|
+
Classify the element to assert that the definitions it represents are part of a subject area definition. Async
|
3774
|
+
|
3775
|
+
Subject Areas: https://egeria-project.org/types/4/0425-Subject-Areas/
|
3776
|
+
|
3777
|
+
Parameters
|
3778
|
+
----------
|
3779
|
+
element_guid: str
|
3780
|
+
- the identity of the element to update
|
3781
|
+
body: dict
|
3782
|
+
- a dictionary structure containing the properties to set - see note below
|
3783
|
+
for_lineage: bool, default is set by server
|
3784
|
+
- determines if elements classified as Memento should be returned - normally false
|
3785
|
+
for_duplicate_processing: bool, default is set by server
|
3786
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
3787
|
+
server_name: str, default = None
|
3788
|
+
- name of the server instances for this request.
|
3789
|
+
time_out: int, default = default_time_out
|
3790
|
+
- http request timeout for this request
|
3791
|
+
|
3792
|
+
Returns
|
3793
|
+
-------
|
3794
|
+
None
|
3795
|
+
|
3796
|
+
Raises
|
3797
|
+
------
|
3798
|
+
InvalidParameterException
|
3799
|
+
one of the parameters is null or invalid or
|
3800
|
+
PropertyServerException
|
3801
|
+
There is a problem adding the element properties to the metadata repository or
|
3802
|
+
UserNotAuthorizedException
|
3803
|
+
the requesting user is not authorized to issue this request.
|
3804
|
+
|
3805
|
+
Note:
|
3806
|
+
|
3807
|
+
A sample dict structure is:
|
3808
|
+
|
3809
|
+
{
|
3810
|
+
"class" : "ClassificationRequestBody",
|
3811
|
+
"effectiveTime" : "an isoTimestamp",
|
3812
|
+
"properties" : {
|
3813
|
+
"class" : "SubjectAreaMemberProperties",
|
3814
|
+
"subjectAreaName" : "Add value here"
|
3815
|
+
}
|
3816
|
+
}
|
3817
|
+
|
3818
|
+
|
3819
|
+
"""
|
3820
|
+
if server_name is None:
|
3821
|
+
server_name = self.server_name
|
3822
|
+
|
3823
|
+
possible_query_params = query_string(
|
3824
|
+
[("forLineage", for_lineage), ("forDuplicateProcessing", for_duplicate_processing)])
|
3825
|
+
|
3826
|
+
url = (f"{base_path(self, server_name)}/elements/{element_guid}/subject-area-member"
|
3827
|
+
f"{possible_query_params}")
|
3828
|
+
|
3829
|
+
await self._async_make_request("POST", url, body_slimmer(body), time_out=time_out)
|
3830
|
+
|
3831
|
+
def add_element_to_subject_area(self, element_guid: str, body: dict, for_lineage: bool = None,
|
3832
|
+
for_duplicate_processing: bool = None, server_name: str = None,
|
3833
|
+
time_out: int = default_time_out) -> None:
|
3834
|
+
"""
|
3835
|
+
Classify the element to assert that the definitions it represents are part of a subject area definition. Async
|
3836
|
+
|
3837
|
+
Subject Areas: https://egeria-project.org/types/4/0425-Subject-Areas/
|
3838
|
+
|
3839
|
+
Parameters
|
3840
|
+
----------
|
3841
|
+
element_guid: str
|
3842
|
+
- the identity of the element to update
|
3843
|
+
body: dict
|
3844
|
+
- a dictionary structure containing the properties to set - see note below
|
3845
|
+
for_lineage: bool, default is set by server
|
3846
|
+
- determines if elements classified as Memento should be returned - normally false
|
3847
|
+
for_duplicate_processing: bool, default is set by server
|
3848
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
3849
|
+
server_name: str, default = None
|
3850
|
+
- name of the server instances for this request.
|
3851
|
+
time_out: int, default = default_time_out
|
3852
|
+
- http request timeout for this request
|
3853
|
+
|
3854
|
+
Returns
|
3855
|
+
-------
|
3856
|
+
None
|
3857
|
+
|
3858
|
+
Raises
|
3859
|
+
------
|
3860
|
+
InvalidParameterException
|
3861
|
+
one of the parameters is null or invalid or
|
3862
|
+
PropertyServerException
|
3863
|
+
There is a problem adding the element properties to the metadata repository or
|
3864
|
+
UserNotAuthorizedException
|
3865
|
+
the requesting user is not authorized to issue this request.
|
3866
|
+
|
3867
|
+
Note:
|
3868
|
+
|
3869
|
+
A sample dict structure is:
|
3870
|
+
|
3871
|
+
{
|
3872
|
+
"class" : "ClassificationRequestBody",
|
3873
|
+
"effectiveTime" : "an isoTimestamp",
|
3874
|
+
"properties" : {
|
3875
|
+
"class" : "SubjectAreaMemberProperties",
|
3876
|
+
"subjectAreaName" : "Add value here"
|
3877
|
+
}
|
3878
|
+
}
|
3879
|
+
|
3880
|
+
|
3881
|
+
"""
|
3882
|
+
|
3883
|
+
loop = asyncio.get_event_loop()
|
3884
|
+
loop.run_until_complete(
|
3885
|
+
self._async_add_element_to_subject_area(element_guid, body, for_lineage, for_duplicate_processing,
|
3886
|
+
server_name, time_out))
|
3887
|
+
|
3888
|
+
async def _async_remove_element_from_subject_area(self, element_guid: str, for_lineage: bool = None,
|
3889
|
+
for_duplicate_processing: bool = None, effective_time: str = None,
|
3890
|
+
server_name: str = None,
|
3891
|
+
time_out: int = default_time_out) -> None:
|
3892
|
+
"""
|
3893
|
+
Remove the subject area designation from the identified element. Async version.
|
3894
|
+
|
3895
|
+
Subject Areas: https://egeria-project.org/types/4/0425-Subject-Areas/
|
3896
|
+
|
3897
|
+
Parameters
|
3898
|
+
----------
|
3899
|
+
element_guid: str
|
3900
|
+
- the identity of the element to update
|
3901
|
+
for_lineage: bool, default is set by server
|
3902
|
+
- determines if elements classified as Memento should be returned - normally false
|
3903
|
+
for_duplicate_processing: bool, default is set by server
|
3904
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
3905
|
+
effective_time: str, default = None
|
3906
|
+
- Time format is "YYYY-MM-DDTHH:MM:SS" (ISO 8601)
|
3907
|
+
server_name: str, default = None
|
3908
|
+
- name of the server instances for this request.
|
3909
|
+
time_out: int, default = default_time_out
|
3910
|
+
- http request timeout for this request
|
3911
|
+
|
3912
|
+
Returns
|
3913
|
+
-------
|
3914
|
+
None
|
3915
|
+
|
3916
|
+
Raises
|
3917
|
+
------
|
3918
|
+
InvalidParameterException
|
3919
|
+
one of the parameters is null or invalid or
|
3920
|
+
PropertyServerException
|
3921
|
+
There is a problem adding the element properties to the metadata repository or
|
3922
|
+
UserNotAuthorizedException
|
3923
|
+
the requesting user is not authorized to issue this request.
|
3924
|
+
|
3925
|
+
|
3926
|
+
"""
|
3927
|
+
if server_name is None:
|
3928
|
+
server_name = self.server_name
|
3929
|
+
|
3930
|
+
possible_query_params = query_string(
|
3931
|
+
[("forLineage", for_lineage), ("forDuplicateProcessing", for_duplicate_processing)])
|
3932
|
+
|
3933
|
+
url = (f"{base_path(self, server_name)}/elements/{element_guid}/subject-area-member"
|
3934
|
+
f"/remove{possible_query_params}")
|
3935
|
+
|
3936
|
+
body = {
|
3937
|
+
"class": "ClassificationRequestBody",
|
3938
|
+
"effectiveTime": effective_time
|
3939
|
+
}
|
3940
|
+
|
3941
|
+
await self._async_make_request("POST", url, body_slimmer(body), time_out=time_out)
|
3942
|
+
|
3943
|
+
def remove_element_from_subject_area(self, element_guid: str, for_lineage: bool = None,
|
3944
|
+
for_duplicate_processing: bool = None, effective_time: str = None,
|
3945
|
+
server_name: str = None,
|
3946
|
+
time_out: int = default_time_out) -> None:
|
3947
|
+
"""
|
3948
|
+
Remove the subject area designation from the identified element.
|
3949
|
+
|
3950
|
+
Subject Areas: https://egeria-project.org/types/4/0425-Subject-Areas/
|
3951
|
+
|
3952
|
+
Parameters
|
3953
|
+
----------
|
3954
|
+
element_guid: str
|
3955
|
+
- the identity of the element to update
|
3956
|
+
for_lineage: bool, default is set by server
|
3957
|
+
- determines if elements classified as Memento should be returned - normally false
|
3958
|
+
for_duplicate_processing: bool, default is set by server
|
3959
|
+
- Normally false. Set true when the caller is part of a deduplication function
|
3960
|
+
effective_time: str, default = None
|
3961
|
+
- Time format is "YYYY-MM-DDTHH:MM:SS" (ISO 8601)
|
3962
|
+
server_name: str, default = None
|
3963
|
+
- name of the server instances for this request.
|
3964
|
+
time_out: int, default = default_time_out
|
3965
|
+
- http request timeout for this request
|
3966
|
+
|
3967
|
+
Returns
|
3968
|
+
-------
|
3969
|
+
None
|
3970
|
+
|
3971
|
+
Raises
|
3972
|
+
------
|
3973
|
+
InvalidParameterException
|
3974
|
+
one of the parameters is null or invalid or
|
3975
|
+
PropertyServerException
|
3976
|
+
There is a problem adding the element properties to the metadata repository or
|
3977
|
+
UserNotAuthorizedException
|
3978
|
+
the requesting user is not authorized to issue this request.
|
3979
|
+
|
3980
|
+
|
3981
|
+
"""
|
3982
|
+
|
3983
|
+
loop = asyncio.get_event_loop()
|
3984
|
+
loop.run_until_complete(
|
3985
|
+
self._async_remove_element_from_subject_area(element_guid, for_lineage, for_duplicate_processing,
|
3986
|
+
effective_time, server_name, time_out))
|