diff options
author | 2019-01-29 00:37:36 +0530 | |
---|---|---|
committer | 2019-01-29 00:54:18 +0530 | |
commit | c51c2a71c930df4ccbb87492f0450aa7db740ebe (patch) | |
tree | a4ec7542bf0b3585dd94fbb6468ce6a95ffa49d0 /veslibrary/ves_javalibrary/evel_javalib2/src/main/java/evel_javalibrary/att/com/EvelMobileFlow.java | |
parent | 493ed75799223784bdd6f9363d3bc4d189ddb370 (diff) |
VES 7.1 JAVA LIB-Agent Enhancements
HB-Fault-Measurement-Syslog-2Collector enhancements
Issue-ID: VNFSDK-362
Change-Id: I4db391ce8dbc763021ba15f6335d2df1e0b10e40
Signed-off-by: SrikanthN <sn00469487@techmahindra.com>
Diffstat (limited to 'veslibrary/ves_javalibrary/evel_javalib2/src/main/java/evel_javalibrary/att/com/EvelMobileFlow.java')
-rw-r--r-- | veslibrary/ves_javalibrary/evel_javalib2/src/main/java/evel_javalibrary/att/com/EvelMobileFlow.java | 59 |
1 files changed, 27 insertions, 32 deletions
diff --git a/veslibrary/ves_javalibrary/evel_javalib2/src/main/java/evel_javalibrary/att/com/EvelMobileFlow.java b/veslibrary/ves_javalibrary/evel_javalib2/src/main/java/evel_javalibrary/att/com/EvelMobileFlow.java index e6b7fd2..f4287e0 100644 --- a/veslibrary/ves_javalibrary/evel_javalib2/src/main/java/evel_javalibrary/att/com/EvelMobileFlow.java +++ b/veslibrary/ves_javalibrary/evel_javalib2/src/main/java/evel_javalibrary/att/com/EvelMobileFlow.java @@ -42,6 +42,7 @@ public class EvelMobileFlow extends EvelHeader { int major_version = 2;
int minor_version = 0;
+
static int EVEL_TOS_SUPPORTED = 256;
/**************************************************************************//**
* TCP flags.
@@ -187,7 +188,7 @@ public class EvelMobileFlow extends EvelHeader { EvelOptionInt dur_tunnel_failed_status;
EvelOptionString flow_activated_by;
- EvelOptionTime flow_activation_time;
+ EvelOptionString flow_activation_time;
EvelOptionString flow_deactivated_by;
EvelOptionString gtp_connection_status;
@@ -385,7 +386,7 @@ public class EvelMobileFlow extends EvelHeader { dur_connection_failed_status = new EvelOptionInt();
dur_tunnel_failed_status = new EvelOptionInt();
flow_activated_by = new EvelOptionString();
- flow_activation_time = new EvelOptionTime();
+ flow_activation_time = new EvelOptionString();
flow_deactivated_by = new EvelOptionString();
gtp_connection_status = new EvelOptionString();
gtp_tunnel_status = new EvelOptionString();
@@ -409,7 +410,7 @@ public class EvelMobileFlow extends EvelHeader { /* Mandatory fields */
/***************************************************************************/
String flow_direction;
- public MOBILE_GTP_PER_FLOW_METRICS gtp_per_flow_metrics;
+ public static MOBILE_GTP_PER_FLOW_METRICS gtp_per_flow_metrics;
String ip_protocol_type;
String ip_version;
String other_endpoint_ip_address;
@@ -498,7 +499,7 @@ public class EvelMobileFlow extends EvelHeader { /* Check preconditions. */
/***************************************************************************/
assert(flow_dir != null);
- assert(gtp_per_flow_metr != null);
+ //assert(gtp_per_flow_metr != null);
assert(ip_protocol_typ != null);
assert(ip_vers != null);
assert(other_endpoint_ip_addr != null);
@@ -690,7 +691,7 @@ public class EvelMobileFlow extends EvelHeader { * string. The caller does not need to preserve the value
* once the function returns.
*****************************************************************************/
- void evel_mobile_flow_app_prot_ver_set(String version)
+ public void evel_mobile_flow_app_prot_ver_set(String version)
{
EVEL_ENTER();
@@ -1364,7 +1365,7 @@ public class EvelMobileFlow extends EvelHeader { *****************************************************************************/
public void evel_mobile_gtp_metrics_act_time_set(
MOBILE_GTP_PER_FLOW_METRICS metrics,
- Date act_time)
+ String act_time)
{
EVEL_ENTER();
@@ -1763,31 +1764,6 @@ public class EvelMobileFlow extends EvelHeader { }
- public void evel_mobileFlow_hashMap_add(String name, String value)
- {
-
- EVEL_ENTER();
-
- /***************************************************************************/
- /* Check preconditions. */
- /***************************************************************************/
- assert(event_domain == EvelHeader.DOMAINS.EVEL_DOMAIN_THRESHOLD_CROSSING);
- assert(name != null);
- assert(value != null);
-
- if( hashMap == null )
- {
-
- hashMap = new HashMap<String,String>();
- }
-
- LOGGER.debug(MessageFormat.format("Adding name={0} value={1}", name, value));
- hashMap.put(name, value);
-
-
- EVEL_EXIT();
- }
-
/**************************************************************************//**
@@ -2028,6 +2004,7 @@ public class EvelMobileFlow extends EvelHeader { JsonObjectBuilder evelMobileFlowObject()
{
+
// double version = major_version+(double)minor_version/10;
String version = "4.0";
EVEL_ENTER();
@@ -2124,7 +2101,7 @@ public class EvelMobileFlow extends EvelHeader { {
EVEL_ENTER();
- assert(event_domain == EvelHeader.DOMAINS.EVEL_DOMAIN_STATE_CHANGE);
+ assert(event_domain == EvelHeader.DOMAINS.EVEL_DOMAIN_MOBILE_FLOW);
//encode common event header and mobile flow body
JsonObject obj = Json.createObjectBuilder()
.add("event", Json.createObjectBuilder()
@@ -2137,6 +2114,24 @@ public class EvelMobileFlow extends EvelHeader { return obj;
}
+
+ JsonObject evel_json_encode_event_batch()
+ {
+ EVEL_ENTER();
+
+ assert(event_domain == EvelHeader.DOMAINS.EVEL_DOMAIN_MOBILE_FLOW);
+ //encode common event header and mobile flow body
+ JsonObject obj = Json.createObjectBuilder()
+ // .add("event", Json.createObjectBuilder()
+ .add( "commonEventHeader",eventHeaderObject() )
+ .add( "mobileFlowFields",evelMobileFlowObject() )
+ .build();
+
+ EVEL_EXIT();
+
+ return obj;
+
+ }
}
|