From 36de463f4d35103936646e94a797d204389003a4 Mon Sep 17 00:00:00 2001 From: Joel Takvorian Date: Tue, 11 Apr 2023 18:44:49 +0200 Subject: [PATCH] Update json doc (#325) * Update json doc * remove cross-ref link --- docs/flows-format.adoc | 75 +++++++++++++++++++++++++++++++++++++- hack/asciidoc-flows-gen.sh | 2 +- 2 files changed, 75 insertions(+), 2 deletions(-) diff --git a/docs/flows-format.adoc b/docs/flows-format.adoc index f3d9abc6d..e84916178 100644 --- a/docs/flows-format.adoc +++ b/docs/flows-format.adoc @@ -47,10 +47,19 @@ Destination owner, such as Deployment, StatefulSet, etc. FlowDirection:: -• *FlowDirection*: <> +• *FlowDirection*: `FlowDirection` (see the following section, Enumeration: FlowDirection) Flow direction from the node observation point +''' + +_RecordType:: + +• `Optional` *_RecordType*: `RecordType` + +Type of record: 'flowLog' for regular flow logs, or 'allConnections', +'newConnection', 'heartbeat', 'endConnection' for conversation tracking + == Fields @@ -191,6 +200,14 @@ L4 protocol ''' +Interface:: + +• `Optional` *Interface*: `string` + +Network interface + +''' + Packets:: • *Packets*: `number` @@ -199,6 +216,22 @@ Number of packets in this flow ''' +Packets_AB:: + +• `Optional` *Packets_AB*: `number` + +In conversation tracking, A to B packets counter per conversation + +''' + +Packets_BA:: + +• `Optional` *Packets_BA*: `number` + +In conversation tracking, B to A packets counter per conversation + +''' + Bytes:: • *Bytes*: `number` @@ -207,6 +240,22 @@ Number of bytes in this flow ''' +Bytes_AB:: + +• `Optional` *Bytes_AB*: `number` + +In conversation tracking, A to B bytes counter per conversation + +''' + +Bytes_BA:: + +• `Optional` *Bytes_BA*: `number` + +In conversation tracking, B to A bytes counter per conversation + +''' + TimeFlowStartMs:: • *TimeFlowStartMs*: `number` @@ -229,6 +278,30 @@ TimeReceived:: Timestamp when this flow was received and processed by the flow collector, in seconds +''' + +_HashId:: + +• `Optional` *_HashId*: `string` + +In conversation tracking, the conversation identifier + +''' + +_IsFirst:: + +• `Optional` *_IsFirst*: `string` + +In conversation tracking, a flag identifying the first flow + +''' + +numFlowLogs:: + +• `Optional` *numFlowLogs*: `number` + +In conversation tracking, a counter of flow logs per conversation + == Enumeration: FlowDirection diff --git a/hack/asciidoc-flows-gen.sh b/hack/asciidoc-flows-gen.sh index 1ba49238d..aa9a47733 100755 --- a/hack/asciidoc-flows-gen.sh +++ b/hack/asciidoc-flows-gen.sh @@ -13,7 +13,7 @@ kramdoc -o - <(curl -fsSL ${MD_SOURCE}/interfaces/Labels.md) \ | sed -r 's/^= /== /' \ | sed -r 's/Interface: //' \ | sed -r '/Properties/d' \ - | sed -r 's~xref:.*FlowDirection\.adoc\[`FlowDirection`\]~<>~' >> $ADOC + | sed -r 's~xref:.*FlowDirection\.adoc\[`FlowDirection`\]~`FlowDirection` (see the following section, Enumeration: FlowDirection)~' >> $ADOC # Fields echo -e "\n" >> $ADOC