DO NOT MERGE IpConnectivity metrics: add version number

This patch adds a version field to ipconnectivity.proto and populates it
to 2, which is the logical version number for NYC-MR2.

Test: IpConnectivity{EventBuilder,Metrics}Test pass
Bug: 32127906

(cherry picked from commit d680d4c856f54bea0c60dea74ba4204822391e49)

Change-Id: I5f37633afd9ec82f5402c5b6670fe2febae82a14
This commit is contained in:
Hugo Benichi
2016-10-13 13:16:16 +09:00
parent 47230f539a
commit 62e743bc9d
2 changed files with 24 additions and 12 deletions

View File

@@ -71,7 +71,8 @@ public class IpConnectivityEventBuilderTest extends TestCase {
" transport_types: 3", " transport_types: 3",
" >", " >",
" time_ms: 1", " time_ms: 1",
">"); ">",
"version: 2");
verifySerialization(want, ev); verifySerialization(want, ev);
} }
@@ -93,7 +94,8 @@ public class IpConnectivityEventBuilderTest extends TestCase {
" state_transition: \"SomeState\"", " state_transition: \"SomeState\"",
" >", " >",
" time_ms: 1", " time_ms: 1",
">"); ">",
"version: 2");
verifySerialization(want, ev); verifySerialization(want, ev);
} }
@@ -114,7 +116,8 @@ public class IpConnectivityEventBuilderTest extends TestCase {
" state_transition: \"\"", " state_transition: \"\"",
" >", " >",
" time_ms: 1", " time_ms: 1",
">"); ">",
"version: 2");
verifySerialization(want, ev); verifySerialization(want, ev);
} }
@@ -160,7 +163,8 @@ public class IpConnectivityEventBuilderTest extends TestCase {
" return_codes: 178", " return_codes: 178",
" >", " >",
" time_ms: 1", " time_ms: 1",
">"); ">",
"version: 2");
verifySerialization(want, ev); verifySerialization(want, ev);
} }
@@ -181,7 +185,8 @@ public class IpConnectivityEventBuilderTest extends TestCase {
" latency_ms: 5678", " latency_ms: 5678",
" >", " >",
" time_ms: 1", " time_ms: 1",
">"); ">",
"version: 2");
verifySerialization(want, ev); verifySerialization(want, ev);
} }
@@ -200,7 +205,8 @@ public class IpConnectivityEventBuilderTest extends TestCase {
" if_name: \"wlan0\"", " if_name: \"wlan0\"",
" >", " >",
" time_ms: 1", " time_ms: 1",
">"); ">",
"version: 2");
verifySerialization(want, ev); verifySerialization(want, ev);
} }
@@ -223,7 +229,8 @@ public class IpConnectivityEventBuilderTest extends TestCase {
" >", " >",
" >", " >",
" time_ms: 1", " time_ms: 1",
">"); ">",
"version: 2");
verifySerialization(want, ev); verifySerialization(want, ev);
} }
@@ -248,7 +255,8 @@ public class IpConnectivityEventBuilderTest extends TestCase {
" probe_result: 204", " probe_result: 204",
" probe_type: 1", " probe_type: 1",
" >", " >",
">"); ">",
"version: 2");
verifySerialization(want, ev); verifySerialization(want, ev);
} }
@@ -274,7 +282,8 @@ public class IpConnectivityEventBuilderTest extends TestCase {
" program_length: 2048", " program_length: 2048",
" >", " >",
" time_ms: 1", " time_ms: 1",
">"); ">",
"version: 2");
verifySerialization(want, ev); verifySerialization(want, ev);
} }
@@ -305,7 +314,8 @@ public class IpConnectivityEventBuilderTest extends TestCase {
" zero_lifetime_ras: 1", " zero_lifetime_ras: 1",
" >", " >",
" time_ms: 1", " time_ms: 1",
">"); ">",
"version: 2");
verifySerialization(want, ev); verifySerialization(want, ev);
} }
@@ -332,7 +342,8 @@ public class IpConnectivityEventBuilderTest extends TestCase {
" router_lifetime: 2000", " router_lifetime: 2000",
" >", " >",
" time_ms: 1", " time_ms: 1",
">"); ">",
"version: 2");
verifySerialization(want, ev); verifySerialization(want, ev);
} }

View File

@@ -204,7 +204,8 @@ public class IpConnectivityMetricsTest extends TestCase {
" router_lifetime: 2000", " router_lifetime: 2000",
" >", " >",
" time_ms: 700", " time_ms: 700",
">"); ">",
"version: 2");
verifySerialization(want, getdump("flush")); verifySerialization(want, getdump("flush"));
} }