Skip to content

introduce telemetry library

Kevin Laatz dpdk-dev 7 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v8 Latest13 patches 8 repliesIn review
  2. v713 patches 6 repliesSuperseded
  3. v613 patches 4 repliesSuperseded
Earlier versions · 4
VersionPostedPatchesRepliesStatus
v513 patches12 repliesSuperseded
v413 patches16 repliesSuperseded
v312 patches2 repliesSuperseded
v210 patches14 repliesSuperseded

Changes in v8 from the cover letter

- Added missing experimental tags
- Added Gaetan's Ack from ML

Patches in v8 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/13eal: add option register infrastructurelib/librte_eal/bsdapp/eal/Makefile lib/librte_eal/bsdapp/eal/eal.c lib/librte_eal/common/Makefile +7 more+170 -20 replies
2/13eal: make get runtime dir function publiclib/librte_eal/bsdapp/eal/eal.c lib/librte_eal/common/eal_filesystem.h lib/librte_eal/common/include/rte_eal.h +2 more+20 -90 replies
3/13telemetry: initial telemetry infrastructureconfig/common_base lib/Makefile lib/librte_telemetry/Makefile +7 more+249 -11 reply
4/13telemetry: add initial connection socketlib/librte_telemetry/rte_telemetry.c lib/librte_telemetry/rte_telemetry_internal.h+229 -00 replies
5/13telemetry: add client feature and socketslib/librte_telemetry/meson.build lib/librte_telemetry/rte_telemetry.c lib/librte_telemetry/rte_telemetry_internal.h +1 more+395 -46 replies
6/13telemetry: add parser for client socket messageslib/librte_telemetry/Makefile lib/librte_telemetry/meson.build lib/librte_telemetry/rte_telemetry.c +3 more+606 -20 replies
7/13telemetry: update metrics before sending statslib/librte_telemetry/rte_telemetry.c lib/librte_telemetry/rte_telemetry_internal.h lib/librte_telemetry/rte_telemetry_parser.c+155 -00 replies
8/13telemetry: format json response when sending statslib/librte_telemetry/rte_telemetry.c+307 -20 replies
9/13telemetry: add tests for telemetry apilib/librte_telemetry/Makefile lib/librte_telemetry/meson.build lib/librte_telemetry/rte_telemetry.c +6 more+1284 -20 replies
10/13telemetry: add ability to disable selftestlib/librte_telemetry/rte_telemetry.c+13 -100 replies
11/13doc: add telemetry documentationMAINTAINERS doc/guides/howto/index.rst doc/guides/howto/telemetry.rst +1 more+97 -01 reply
12/13usertools: add client python script for telemetryusertools/dpdk-telemetry-client.py+116 -00 replies
13/13build: add dependency on telemetry to apps in mesonapp/meson.build app/pdump/meson.build app/proc-info/meson.build +6 more+12 -70 replies

Reviews trailers per patch

All 13 patches have a Reviewed-by or Acked-by of their own; the series has one for all of them.

PatchHarry van HaarenGaetan RivetMarko Kovacevic
SeriesA-b A-b A-b A-b A-b A-b A-b A-b A-b A-b A-b A-b A-b A-b A-b A-b A-b A-b A-b A-b A-b A-b A-b A-b A-b A-b A-b A-b
1/13A-b A-b
2/13A-b
3/13A-b
4/13A-b
5/13A-b
6/13A-b
7/13A-b
8/13A-b
9/13A-b
10/13A-b
11/13A-b A-b
12/13A-b
13/13A-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 3 reviewers.

Read the v8 thread

Cover letter [PATCH v8 00/13] introduce telemetry library

This patchset introduces a Telemetry library for DPDK Service Assurance. This library provides an easy way to query DPDK Ethdev metrics.

The telemetry library provides a method for a service assurance component to retrieve metrics from a DPDK packet forwarding application. Communicating from the service assurance component to DPDK is done using a UNIX domain socket, passing a JSON formatted string. A reply is sent (again a JSON formatted string) of the current DPDK metrics.

The telemetry component makes use of the existing rte_metrics library to query values. The values to be transmitted via the telemetry infrastructure must be present in the Metrics library. Currently the ethdev values are pushed to the metrics library, and the queried from there there is an open question on how applications would like this to occur. Currently only ethdev to metrics functionality is implemented, however other subsystems like crypto, eventdev, keepalive etc can use similar mechanisms.

Exposing DPDK Telemetry via a socket interface enables service assurance agents like collectd to consume data from DPDK. This is vital for monitoring, fault-detection, and error reporting. A collectd plugin has been created to interact with the DPDK Telemetry component, showing how it can be used in practice. The collectd plugin will be upstreamed to collectd at a later stage. A small python script is provided in ./usertools/telemetry_client.py to quick-start using DPDK Telemetry.

Note: Despite opterr being set to 0, --telemetry said to be 'unrecognized' as a startup print. This is a cosmetic issue and will be addressed in the future.

---
v2:
- Reworked telemetry as part of EAL instead of using vdev (Gaetan)
- Refactored rte_telemetry_command (Gaetan)
- Added MAINTAINERS file entry (Stephen)
- Updated docs to reflect vdev to eal rework
- Removed collectd patch from patchset (Thomas)
- General code clean up from v1 feedback

v3:
- Reworked registering with eal and moved to rte_param (Gaetan)
- Added BSD implementation for rte_param (Gaetan)
- Updated the paths to align with the new runtime file location (Mattias)
- Fixed pointer checks to align with the coding style 1.8.1 (Mattias)
- Added missing decref's and close's (Mattias)
- Fixed runtime issue in Meson (was not recognising flag due to linking)
- More general clean up

v4:
- Added Doxygen comments for rte_param.h (Thomas)
- Made eal_get_runtime_dir a public function to use outside of EAL (Thomas)
- Reworked telemetry to get path using rte_eal_get_runtime_dir (Thomas)
- Fixed checkpatch coding style error

v5:
- Moved the BUF_SIZE define to fix build (Harry)
- Set default config for telemetry to 'n' (Harry)
- Improved Doxygen comments (Thomas)
- Cleaned up rte_param struct (Thomas)

v6:
- Renamed rte_param to rte_option (Thomas)
- Moved internal functions to eal_private.h (Gaetan)
- Added fail check for pthread_attr_init() (Mattias)
- Changed socket implementation to SOCK_SEQPACKET (Mattias)
- Added check to avoid option duplicates (Gaetan)
- Removed telemetry example from Doxygen comment (Gaetan)
- General Doxygen clean-up (Thomas)
- General code clean-up (Mattias)

v7:
- Fix object leak (Mattias)
- General clean-up (Mattias)
- Fix rte_option header define
- Added release note update
- Rebased

v8:
- Added missing experimental tags
- Added Gaetan's Ack from ML

Ciara Power, Brian Archbold and Kevin Laatz (10):
telemetry: initial telemetry infrastructure
telemetry: add initial connection socket
telemetry: add client feature and sockets
telemetry: add parser for client socket messages
telemetry: update metrics before sending stats
telemetry: format json response when sending stats
telemetry: add tests for telemetry api
telemetry: add ability to disable selftest
doc: add telemetry documentation
usertools: add client python script for telemetry

Kevin Laatz (3):
eal: add option register infrastructure
eal: make get runtime dir function public
build: add dependency on telemetry to apps in meson

 MAINTAINERS                                       |    5 +
 app/meson.build                                   |    4 +-
 app/pdump/meson.build                             |    2 +-
 app/proc-info/meson.build                         |    2 +-
 app/test-bbdev/meson.build                        |    2 +-
 app/test-crypto-perf/meson.build                  |    2 +-
 app/test-pmd/meson.build                          |    2 +-
 config/common_base                                |    5 +
 config/meson.build                                |    3 +
 doc/guides/howto/index.rst                        |    1 +
 doc/guides/howto/telemetry.rst                    |   85 +
 doc/guides/rel_notes/release_18_11.rst            |    6 +
 lib/Makefile                                      |    2 +
 lib/librte_eal/bsdapp/eal/Makefile                |    1 +
 lib/librte_eal/bsdapp/eal/eal.c                   |   16 +-
 lib/librte_eal/common/Makefile                    |    1 +
 lib/librte_eal/common/eal_filesystem.h            |   15 +-
 lib/librte_eal/common/eal_private.h               |   21 +
 lib/librte_eal/common/include/rte_eal.h           |    9 +
 lib/librte_eal/common/include/rte_option.h        |   63 +
 lib/librte_eal/common/meson.build                 |    2 +
 lib/librte_eal/common/rte_option.c                |   54 +
 lib/librte_eal/linuxapp/eal/Makefile              |    1 +
 lib/librte_eal/linuxapp/eal/eal.c                 |   16 +-
 lib/librte_eal/rte_eal_version.map                |    2 +
 lib/librte_telemetry/Makefile                     |   30 +
 lib/librte_telemetry/meson.build                  |    9 +
 lib/librte_telemetry/rte_telemetry.c              | 1815 +++++++++++++++++++++
 lib/librte_telemetry/rte_telemetry.h              |   57 +
 lib/librte_telemetry/rte_telemetry_internal.h     |   81 +
 lib/librte_telemetry/rte_telemetry_parser.c       |  586 +++++++
 lib/librte_telemetry/rte_telemetry_parser.h       |   13 +
 lib/librte_telemetry/rte_telemetry_parser_test.c  |  534 ++++++
 lib/librte_telemetry/rte_telemetry_parser_test.h  |   39 +
 lib/librte_telemetry/rte_telemetry_socket_tests.h |   36 +
 lib/librte_telemetry/rte_telemetry_version.map    |    9 +
 lib/meson.build                                   |    3 +-
 meson.build                                       |    1 +
 mk/rte.app.mk                                     |    1 +
 usertools/dpdk-telemetry-client.py                |  116 ++
 40 files changed, 3633 insertions(+), 19 deletions(-)
 create mode 100644 doc/guides/howto/telemetry.rst
 create mode 100644 lib/librte_eal/common/include/rte_option.h
 create mode 100644 lib/librte_eal/common/rte_option.c
 create mode 100644 lib/librte_telemetry/Makefile
 create mode 100644 lib/librte_telemetry/meson.build
 create mode 100644 lib/librte_telemetry/rte_telemetry.c
 create mode 100644 lib/librte_telemetry/rte_telemetry.h
 create mode 100644 lib/librte_telemetry/rte_telemetry_internal.h
 create mode 100644 lib/librte_telemetry/rte_telemetry_parser.c
 create mode 100644 lib/librte_telemetry/rte_telemetry_parser.h
 create mode 100644 lib/librte_telemetry/rte_telemetry_parser_test.c
 create mode 100644 lib/librte_telemetry/rte_telemetry_parser_test.h
 create mode 100644 lib/librte_telemetry/rte_telemetry_socket_tests.h
 create mode 100644 lib/librte_telemetry/rte_telemetry_version.map
 create mode 100644 usertools/dpdk-telemetry-client.py
Signature · 1 line
2.9.5