VES EVEL Library VES 5.4.1 enhancements
[demo.git] / vnfs / VES5.0 / evel / evel-library / code / evel_library / evel.h
index 8f49798..8cdc4b5 100644 (file)
@@ -1429,6 +1429,8 @@ typedef struct copyright {
  *
  * @param   fqdn    The API's FQDN or IP address.
  * @param   port    The API's port.
+ * @param   bakup_fqdn    The API's FQDN or IP address.
+ * @param   bakup_port    The API's port.
  * @param   path    The optional path (may be NULL).
  * @param   topic   The optional topic part of the URL (may be NULL).
  * @param   ring_buf_size   Ring buffer size (>=100) ~ Avg Messages in 1hr
@@ -1441,7 +1443,10 @@ typedef struct copyright {
  * @param   verify_host        SSL verification of host 0 or 1
  * @param   username  Username for Basic Authentication of requests.
  * @param   password  Password for Basic Authentication of requests.
- * @param   source_ip The ip of node we represent.(NULL for default ip)
+ * @param   bakup_username  Username for Basic Authentication of Bakup FQDN.
+ * @param   bakup_password  Password for Basic Authentication of Bakup FQDN.
+ * @param   source_ip       The ip of node we represent.(NULL for default ip)
+ * @param   bakup_source_ip The ip bakup fqdn interface.(NULL for default ip)
  * @param   source_type The kind of node we represent.
  * @param   role    The role this node undertakes.
  * @param   verbosity  0 for normal operation, positive values for chattier
@@ -1453,6 +1458,8 @@ typedef struct copyright {
  *****************************************************************************/
 EVEL_ERR_CODES evel_initialize(const char * const fqdn,
                                int port,
+                               const char * const bakup_fqdn,
+                               int bakup_port,
                                const char * const path,
                                const char * const topic,
                                int ring_buf_size,
@@ -1465,7 +1472,10 @@ EVEL_ERR_CODES evel_initialize(const char * const fqdn,
                                long verify_host,
                                const char * const username,
                                const char * const password,
+                               const char * const bakup_username,
+                               const char * const bakup_password,
                                const char * const source_ip,
+                               const char * const bakup_source_ip,
                                EVEL_SOURCE_TYPES source_type,
                                const char * const role,
                                int verbosity
@@ -1612,6 +1622,22 @@ EVENT_HEADER * evel_new_heartbeat(void);
  *****************************************************************************/
 EVENT_HEADER * evel_new_heartbeat_nameid(const char* ev_name, const char *ev_id);
 
+/**************************************************************************//**
+ * Create a new Heartbeat fields event.
+ *
+ * @note    The mandatory fields on the Heartbeat fields must be supplied to
+ *          this factory function and are immutable once set.  Optional fields
+ *          have explicit setter functions, but again values may only be set
+ *          once so that the event has immutable properties.
+ * @param ev_name  Unique Event Name confirming Domain AsdcModel Description
+ * @param ev_id    A universal identifier of the event for: troubleshooting correlation, analysis, etc
+ * @param interval    heartbeat interval
+ * @returns pointer to the newly manufactured ::EVENT_HEARTBEAT_FIELD.  If the event
+ *          is not used (i.e. posted) it must be released using
+ *          ::evel_free_hrtbt_field.
+ * @retval  NULL  Failed to create the event.
+ *****************************************************************************/
+EVENT_HEARTBEAT_FIELD * evel_new_heartbeat_field(int interval,const char* ev_name, const char *ev_id);
 
 /**************************************************************************//**
  * Free an event header.
@@ -1695,6 +1721,17 @@ void evel_last_epoch_set(EVENT_HEADER * const header,
 void evel_reporting_entity_name_set(EVENT_HEADER * const header,
                                     const char * const entity_name);
 
+/**************************************************************************//**
+ * Set the Source Name property of the event header.
+ *
+ * @note The Source Name defaults to the OpenStack VM Name.
+ *
+ * @param header        Pointer to the ::EVENT_HEADER.
+ * @param entity_name   The source name to set.
+ *****************************************************************************/
+void evel_source_name_set(EVENT_HEADER * const header,
+                          const char * const source_name);
+
 /**************************************************************************//**
  * Set the Reporting Entity Id property of the event header.
  *
@@ -1706,6 +1743,17 @@ void evel_reporting_entity_name_set(EVENT_HEADER * const header,
 void evel_reporting_entity_id_set(EVENT_HEADER * const header,
                                   const char * const entity_id);
 
+/**************************************************************************//**
+ * Set the Source Id property of the event header.
+ *
+ * @note The Source Id defaults to the OpenStack VM UUID.
+ *
+ * @param header        Pointer to the ::EVENT_HEADER.
+ * @param entity_id     The Source id to set.
+ *****************************************************************************/
+void evel_source_id_set(EVENT_HEADER * const header,
+                        const char * const source_id);
+
 /**************************************************************************//**
  * Set the NFC Naming code property of the event header.
  *