Table of Contents
Reference
Wiki page DCAE mS Deployment (Standalone instantiation)
Sending Alarm Event to VES
Example of alarm event sent from VFC EMS driver: sampleems
...
ubuntu@vm03-dcae-controller:~$ curl -i -X POST -d @sampleems --header "Content-Type: application/json" http://localhost:8080/eventListener/v5 -k
Receiving Event Sent by VES
Use browser to listen to DMAAP event topic, you may need to send REST request twice (the first one is register user)
...
["{\"VESversion\":\"v5\",\"event\":{\"commonEventHeader\":{\"sourceId\":\"VNF_194.15.13.138\",\"startEpochMicrosec\":1501518702,\"eventId\":\"1501489595451\",\"nfcNamingCode\":\"\",\"reportingEntityId\":\"0000ZTHX1\",\"internalHeaderFields\":{\"collectorTimeStamp\":\"Thu, 10 19 2017 01:02:04 GMT\"},\"eventType\":\"applicationVnf\",\"priority\":\"High\",\"version\":3,\"reportingEntityName\":\"0000ZTHX1\",\"sequence\":960,\"domain\":\"fault\",\"lastEpochMicrosec\":1501518702,\"eventName\":\"Slave MPU is offline\",\"sourceName\":\"VNF_194.15.13.138\",\"nfNamingCode\":\"\"},\"faultFields\":{\"eventSeverity\":\"CRITICAL\",\"alarmCondition\":\"The slave MPU board is offline or abnormal\",\"faultFieldsVersion\":2,\"eventCategory\":\"equipmentAlarm\",\"specificProblem\":\"The slave MPU board is offline or abnormal\",\"alarmInterfaceA\":\"VNF_194.15.13.138\",\"alarmAdditionalInformation\":[{\"name\":\"specificProblemID\",\"value\":\"315\"},{\"name\":\"objectUID\",\"value\":\"0000ZTHX1PGWGJI6V1\"},{\"name\":\"locationInfo\",\"value\":\"MPU_22_20_0\"},{\"name\":\"addInfo\",\"value\":\"Aid:17;AlarmCode:110010;AlarmReasonCode:110010;Remark:\\\"DeployUnit=22,Node=21,SubNode=0\\\";\"}],\"eventSourceType\":\"PgwFunction\",\"vfStatus\":\"Active\"}}}"]
VES Guidelines for VNF Vendors and Developers
Following are the Guidelines for VNF Vendors and Developers
...
The VES/bldjobs/Makefile shows how the library code is packaged transferred
...
The vFW Makefile shows how agent is compiled from the Library https://gerrit.onap.org/r/gitweb?p=demo.git;a=blob;f=vnfs/VESreporting_vFW/Makefile;h=77ca5742e50d4b983736a79bbcac196a72e01667;hb=1f53eac7594b43be307224098432694d35503ae5
Go-client.sh script shows how it is invoked at runtime with DCAE IP Address and Port number passed from HEAT template into /opt/config
[demo.git] / vnfs / VESreporting_vLB / go-client.sh
...
6 ./vpp_measurement_reporter $DCAE_COLLECTOR_IP $DCAE_COLLECTOR_PORT eth1
Do you confirm that no VES agent is automatically onboarded on VNF creation..not needed to get a valid heat template?
If it not in the heat used for the deployment of the VNF, we must deploy the agent manually?
While the VES code provides guidelines about installation and deployment of VES agent: options are with VNF Vendor.
There could be variety of deployments with different Linux flavors.
Automated installation could pull VES Library from Repository(Nexus) and install into /usr/lib
Install agent in Vendor code and invoke agent start in /etc/rc scripts. All this at VNF creation time.
Or VES Library and Agent could be built into VNF OS QCOW2 or other Images.
What is the procedure?
I got the yaml description of the event for ONAP, I need to declare it only on the agent side.
...
The Library .so or .jar needs to be linked with your Agent or VNF Application code.
Latest C Library
Latest Java Library
Then lookup sample agent code in C or Java. Sample Makefile framework for C and Maven framework for Java is provided.
...
Lookup the Yaml event in the VES Library API functions in evel.h or Java classes
1. Create your Event from the sample code provided.
...
EvelScalingMeasurement sm = new EvelScalingMeasurement(10.0,"Measurements_vVNF", "vmname_ip");
2. Populate the mandatory and optional fields for the Event in Library API with your reporting data
C:
132 evel_measurement_vnic_use_add(vpp_m, /* Pointer to the measurement */
...
AgentMain.evel_post_event(sm);