Code Review
/
oam.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
Create VES client example for domain 'notification'
[oam.git]
/
solution
/
dev
/
ves-test-collector
/
client-scripts-ves-v7
/
sendVesHeartbeat.py
diff --git
a/solution/dev/ves-test-collector/client-scripts-ves-v7/sendVesHeartbeat.py
b/solution/dev/ves-test-collector/client-scripts-ves-v7/sendVesHeartbeat.py
index
4e1ff2d
..
b2066fb
100644
(file)
--- a/
solution/dev/ves-test-collector/client-scripts-ves-v7/sendVesHeartbeat.py
+++ b/
solution/dev/ves-test-collector/client-scripts-ves-v7/sendVesHeartbeat.py
@@
-21,7
+21,7
@@
# importing the datetime, json, requests, os socket and yaml library
import json
import requests
# importing the datetime, json, requests, os socket and yaml library
import json
import requests
-from globalVesEventEmitter import getInitData
+from globalVesEventEmitter import getInitData
, saveExample
# Globals
domain = 'heartbeat'
# Globals
domain = 'heartbeat'
@@
-45,9
+45,7
@@
initData['body']['event']['commonEventHeader']['nfVendorName'] = 'O-RAN-SC OAM'
initData['body']['event']['heartbeatFields']['additionalFields']['eventTime'] = initData['eventTime']
# Save example body
initData['body']['event']['heartbeatFields']['additionalFields']['eventTime'] = initData['eventTime']
# Save example body
-outputFileName = initData['directory'] + '/json/examples/' + domain + '.json'
-with open(outputFileName, 'w') as f:
- json.dump(initData['body'], f, indent=2, sort_keys=True)
+saveExample(initData)
# Send VES Event
url = initData['config']['vesEndpoint']['url']
# Send VES Event
url = initData['config']['vesEndpoint']['url']