File tree Expand file tree Collapse file tree 3 files changed +5
-5
lines changed
Expand file tree Collapse file tree 3 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -88,8 +88,8 @@ func PBFlowToMap(flow *pbflow.Record) config.GenericMap {
8888 out ["PktDropLatestDropCause" ] = pktDropCauseToStr (flow .GetPktDropLatestDropCause ())
8989 }
9090
91- if flow .TimeFlowRtt .AsDuration ().Milliseconds () != 0 {
92- out ["TimeFlowRttMs " ] = flow .TimeFlowRtt .AsDuration ().Milliseconds ()
91+ if flow .TimeFlowRtt .AsDuration ().Nanoseconds () != 0 {
92+ out ["TimeFlowRttNs " ] = flow .TimeFlowRtt .AsDuration ().Nanoseconds ()
9393 }
9494 return out
9595}
Original file line number Diff line number Diff line change @@ -93,7 +93,7 @@ func TestDecodeProtobuf(t *testing.T) {
9393 "DnsId" : uint32 (1 ),
9494 "DnsFlags" : uint32 (0x8001 ),
9595 "DnsFlagsResponseCode" : "FormErr" ,
96- "TimeFlowRttMs " : someDuration .Milliseconds (),
96+ "TimeFlowRttNs " : someDuration .Nanoseconds (),
9797 }, out )
9898}
9999
@@ -171,7 +171,7 @@ func TestPBFlowToMap(t *testing.T) {
171171 "DnsId" : uint32 (1 ),
172172 "DnsFlags" : uint32 (0x80 ),
173173 "DnsFlagsResponseCode" : "NoError" ,
174- "TimeFlowRttMs " : someDuration .Milliseconds (),
174+ "TimeFlowRttNs " : someDuration .Nanoseconds (),
175175 }, out )
176176
177177}
Original file line number Diff line number Diff line change @@ -251,7 +251,7 @@ parameters:
251251 "DnsId" : float64 (1 ),
252252 "DnsFlags" : float64 (0x80 ),
253253 "DnsFlagsResponseCode" : "NoError" ,
254- "TimeFlowRttMs " : float64 (someDuration .Milliseconds ()),
254+ "TimeFlowRttNs " : float64 (someDuration .Nanoseconds ()),
255255 }, capturedRecord )
256256}
257257
You can’t perform that action at this time.
0 commit comments