[ovs-dev] [PATCH v12 6/6] ofproto: Add JSON output for 'dpif/show' command.

2024-05-16 Thread jmeng
From: Jakob Meng The 'dpif/show' command now supports machine-readable JSON output in addition to the plain-text output for humans. An example would be: ovs-appctl --format json dpif/show Reported-at: https://bugzilla.redhat.com/1824861 Signed-off-by: Jakob Meng --- NEWS

[ovs-dev] [PATCH v12 4/6] python: Add option for pretty-printing JSON output to appctl.py.

2024-05-16 Thread jmeng
From: Jakob Meng With the '--pretty' option, appctl.py will now print JSON output in a more readable fashion, i.e. with additional line breaks, spaces and sorted dictionary keys. The pretty-printed output from appctl.py is not strictly the same as with ovs-appctl because of both use different

[ovs-dev] [PATCH v12 5/6] vswitchd: Add JSON output for 'list-commands' command.

2024-05-16 Thread jmeng
From: Jakob Meng The 'list-commands' command now supports machine-readable JSON output in addition to the plain-text output for humans. Reported-at: https://bugzilla.redhat.com/1824861 Signed-off-by: Jakob Meng --- NEWS | 1 + lib/unixctl.c | 44

[ovs-dev] [PATCH v12 3/6] appctl: Add option '--pretty' for pretty-printing JSON output.

2024-05-16 Thread jmeng
From: Jakob Meng With the '--pretty' option, ovs-appctl will now print JSON output in a more readable fashion, i.e. with additional line breaks, spaces and sorted dictionary keys. Signed-off-by: Jakob Meng --- Documentation/ref/ovs-appctl.8.rst | 7 ++ NEWS

[ovs-dev] [PATCH v12 1/6] Add global option for JSON output to ovs-appctl.

2024-05-16 Thread jmeng
From: Jakob Meng For monitoring systems such as Prometheus it would be beneficial if OVS would expose statistics in a machine-readable format. This patch introduces support for different output formats to ovs-appctl. It gains a global option '-f,--format' which changes it to print a JSON

[ovs-dev] [PATCH v12 0/6] Add global option to output JSON from ovs-appctl cmds.

2024-05-16 Thread jmeng
From: Jakob Meng v12 has one tiny change compared to v11 [0]: diff --git a/utilities/ovs-appctl.c b/utilities/ovs-appctl.c Signed-off-by: Jakob Meng index 2ade64336..3b76740ea 100644 --- a/utilities/ovs-appctl.c +++ b/utilities/ovs-appctl.c @@ -88,6 +88,7 @@ main(int argc, char *argv[])

[ovs-dev] [PATCH v12 2/6] python: Add option for JSON output to unixctl classes and appctl.py.

2024-05-16 Thread jmeng
From: Jakob Meng This patch introduces support for different output formats to Python Unixctl* classes and appctl.py, similar to what the previous commit did for ovs-appctl. In particular, tests/appctl.py gains a global option '-f,--format' which allows users to request JSON instead of

[ovs-dev] [PATCH v11 1/6] Add global option for JSON output to ovs-appctl.

2024-05-16 Thread jmeng
From: Jakob Meng For monitoring systems such as Prometheus it would be beneficial if OVS would expose statistics in a machine-readable format. This patch introduces support for different output formats to ovs-appctl. It gains a global option '-f,--format' which changes it to print a JSON

[ovs-dev] [PATCH v11 5/6] vswitchd: Add JSON output for 'list-commands' command.

2024-05-16 Thread jmeng
From: Jakob Meng The 'list-commands' command now supports machine-readable JSON output in addition to the plain-text output for humans. Reported-at: https://bugzilla.redhat.com/1824861 Signed-off-by: Jakob Meng --- NEWS | 1 + lib/unixctl.c | 44

[ovs-dev] [PATCH v11 6/6] ofproto: Add JSON output for 'dpif/show' command.

2024-05-16 Thread jmeng
From: Jakob Meng The 'dpif/show' command now supports machine-readable JSON output in addition to the plain-text output for humans. An example would be: ovs-appctl --format json dpif/show Reported-at: https://bugzilla.redhat.com/1824861 Signed-off-by: Jakob Meng --- NEWS

[ovs-dev] [PATCH v11 4/6] python: Add option for pretty-printing JSON output to appctl.py.

2024-05-16 Thread jmeng
From: Jakob Meng With the '--pretty' option, appctl.py will now print JSON output in a more readable fashion, i.e. with additional line breaks, spaces and sorted dictionary keys. The pretty-printed output from appctl.py is not strictly the same as with ovs-appctl because of both use different

[ovs-dev] [PATCH v11 2/6] python: Add option for JSON output to unixctl classes and appctl.py.

2024-05-16 Thread jmeng
From: Jakob Meng This patch introduces support for different output formats to Python Unixctl* classes and appctl.py, similar to what the previous commit did for ovs-appctl. In particular, tests/appctl.py gains a global option '-f,--format' which allows users to request JSON instead of

[ovs-dev] [PATCH v11 3/6] appctl: Add option '--pretty' for pretty-printing JSON output.

2024-05-16 Thread jmeng
From: Jakob Meng With the '--pretty' option, ovs-appctl will now print JSON output in a more readable fashion, i.e. with additional line breaks, spaces and sorted dictionary keys. Signed-off-by: Jakob Meng --- Documentation/ref/ovs-appctl.8.rst | 7 ++ NEWS

[ovs-dev] [PATCH v11 0/6] Add global option to output JSON from ovs-appctl cmds.

2024-05-16 Thread jmeng
From: Jakob Meng v11 has one tiny change compared to v10 [0]: * Added a missing newline at the end of utilities/ovs-appctl.c. [0] https://patchwork.ozlabs.org/project/openvswitch/list/?series=407002=both=* Jakob Meng (6): Add global option for JSON output to ovs-appctl. python: Add

[ovs-dev] [PATCH v10 6/6] ofproto: Add JSON output for 'dpif/show' command.

2024-05-16 Thread jmeng
From: Jakob Meng The 'dpif/show' command now supports machine-readable JSON output in addition to the plain-text output for humans. An example would be: ovs-appctl --format json dpif/show Reported-at: https://bugzilla.redhat.com/1824861 Signed-off-by: Jakob Meng --- NEWS

[ovs-dev] [PATCH v10 4/6] python: Add option for pretty-printing JSON output to appctl.py.

2024-05-16 Thread jmeng
From: Jakob Meng With the '--pretty' option, appctl.py will now print JSON output in a more readable fashion, i.e. with additional line breaks, spaces and sorted dictionary keys. The pretty-printed output from appctl.py is not strictly the same as with ovs-appctl because of both use different

[ovs-dev] [PATCH v10 2/6] python: Add option for JSON output to unixctl classes and appctl.py.

2024-05-16 Thread jmeng
From: Jakob Meng This patch introduces support for different output formats to Python Unixctl* classes and appctl.py, similar to what the previous commit did for ovs-appctl. In particular, tests/appctl.py gains a global option '-f,--format' which allows users to request JSON instead of

[ovs-dev] [PATCH v10 0/6] Add global option to output JSON from ovs-appctl cmds.

2024-05-16 Thread jmeng
From: Jakob Meng v10 addresses all of Ilya's comments for v9 [0], most importantly: * Output formatting has been moved from unixctl_client_transact() in unixctl.c to ovs-appctl.c; same for Python code. * unixctl_command_reply_error() will never wrap plain-text in JSON. *

[ovs-dev] [PATCH v10 5/6] vswitchd: Add JSON output for 'list-commands' command.

2024-05-16 Thread jmeng
From: Jakob Meng The 'list-commands' command now supports machine-readable JSON output in addition to the plain-text output for humans. Reported-at: https://bugzilla.redhat.com/1824861 Signed-off-by: Jakob Meng --- NEWS | 1 + lib/unixctl.c | 44

[ovs-dev] [PATCH v10 1/6] Add global option for JSON output to ovs-appctl.

2024-05-16 Thread jmeng
From: Jakob Meng For monitoring systems such as Prometheus it would be beneficial if OVS would expose statistics in a machine-readable format. This patch introduces support for different output formats to ovs-appctl. It gains a global option '-f,--format' which changes it to print a JSON

[ovs-dev] [PATCH v10 3/6] appctl: Add option '--pretty' for pretty-printing JSON output.

2024-05-16 Thread jmeng
From: Jakob Meng With the '--pretty' option, ovs-appctl will now print JSON output in a more readable fashion, i.e. with additional line breaks, spaces and sorted dictionary keys. Signed-off-by: Jakob Meng --- Documentation/ref/ovs-appctl.8.rst | 7 ++ NEWS

[ovs-dev] [PATCH v9 4/6] python: Add option '--pretty' for pretty-printing JSON output.

2024-04-12 Thread jmeng
From: Jakob Meng With the '--pretty' option, appctl.py will now print JSON output in a more readable fashion, i.e. with additional line breaks, spaces and sorted dictionary keys. The pretty-printed output from appctl.py is not strictly the same as with ovs-appctl because of both use different

[ovs-dev] [PATCH v9 2/6] python: Add global option for JSON output to Python tools.

2024-04-12 Thread jmeng
From: Jakob Meng This patch introduces support for different output formats to the Python code, as did the previous commit for ovs-xxx tools like 'ovs-appctl --format json dpif/show'. In particular, tests/appctl.py gains a global option '-f,--format' which allows users to request JSON instead of

[ovs-dev] [PATCH v9 5/6] vswitchd: Add JSON output for 'list-commands' command.

2024-04-12 Thread jmeng
From: Jakob Meng The 'list-commands' command now supports machine-readable JSON output in addition to the plain-text output for humans. Reported-at: https://bugzilla.redhat.com/1824861 Signed-off-by: Jakob Meng --- NEWS | 1 + lib/unixctl.c | 46

[ovs-dev] [PATCH v9 3/6] appctl: Add option '--pretty' for pretty-printing JSON output.

2024-04-12 Thread jmeng
From: Jakob Meng With the '--pretty' option, ovs-appctl will now print JSON output in a more readable fashion, i.e. with additional line breaks, spaces and sorted dictionary keys. Signed-off-by: Jakob Meng --- NEWS | 3 +++ lib/unixctl.c | 6 +++--- lib/unixctl.h

[ovs-dev] [PATCH v9 6/6] ofproto: Add JSON output for 'dpif/show' command.

2024-04-12 Thread jmeng
From: Jakob Meng The 'dpif/show' command now supports machine-readable JSON output in addition to the plain-text output for humans. An example would be: ovs-appctl --format json dpif/show Reported-at: https://bugzilla.redhat.com/1824861 Signed-off-by: Jakob Meng --- NEWS

[ovs-dev] [PATCH v9 1/6] Add global option for JSON output to ovs-appctl.

2024-04-12 Thread jmeng
From: Jakob Meng For monitoring systems such as Prometheus it would be beneficial if OVS would expose statistics in a machine-readable format. This patch introduces support for different output formats to ovs-xxx tools, in particular ovs-appctl. The latter gains a global option '-f,--format'

[ovs-dev] [PATCH v9 0/6] Add global option to output JSON from ovs-appctl cmds.

2024-04-12 Thread jmeng
From: Jakob Meng Changes compared to v8 [0]: * Use "unsigned int" for format_flags variable in pretty patch for ovs-appctl. * Fix --pretty option in appctl.py. [0] https://patchwork.ozlabs.org/project/openvswitch/list/?series=402629=both=* Jakob Meng (6): Add global option for JSON output

[ovs-dev] [PATCH v8 5/6] vswitchd: Add JSON output for 'list-commands' command.

2024-04-11 Thread jmeng
From: Jakob Meng The 'list-commands' command now supports machine-readable JSON output in addition to the plain-text output for humans. Reported-at: https://bugzilla.redhat.com/1824861 Signed-off-by: Jakob Meng --- NEWS | 1 + lib/unixctl.c | 46

[ovs-dev] [PATCH v8 6/6] ofproto: Add JSON output for 'dpif/show' command.

2024-04-11 Thread jmeng
From: Jakob Meng The 'dpif/show' command now supports machine-readable JSON output in addition to the plain-text output for humans. An example would be: ovs-appctl --format json dpif/show Reported-at: https://bugzilla.redhat.com/1824861 Signed-off-by: Jakob Meng --- NEWS

[ovs-dev] [PATCH v8 4/6] python: Add option '--pretty' for pretty-printing JSON output.

2024-04-11 Thread jmeng
From: Jakob Meng With the '--pretty' option, appctl.py will now print JSON output in a more readable fashion, i.e. with additional line breaks, spaces and sorted dictionary keys. The pretty-printed output from appctl.py is not strictly the same as with ovs-appctl because of both use different

[ovs-dev] [PATCH v8 1/6] Add global option for JSON output to ovs-appctl.

2024-04-11 Thread jmeng
From: Jakob Meng For monitoring systems such as Prometheus it would be beneficial if OVS would expose statistics in a machine-readable format. This patch introduces support for different output formats to ovs-xxx tools, in particular ovs-appctl. The latter gains a global option '-f,--format'

[ovs-dev] [PATCH v8 3/6] appctl: Add option '--pretty' for pretty-printing JSON output.

2024-04-11 Thread jmeng
From: Jakob Meng With the '--pretty' option, ovs-appctl will now print JSON output in a more readable fashion, i.e. with additional line breaks, spaces and sorted dictionary keys. Signed-off-by: Jakob Meng --- NEWS | 3 +++ lib/unixctl.c | 6 +++--- lib/unixctl.h

[ovs-dev] [PATCH v8 2/6] python: Add global option for JSON output to Python tools.

2024-04-11 Thread jmeng
From: Jakob Meng This patch introduces support for different output formats to the Python code, as did the previous commit for ovs-xxx tools like 'ovs-appctl --format json dpif/show'. In particular, tests/appctl.py gains a global option '-f,--format' which allows users to request JSON instead of

[ovs-dev] [PATCH v8 0/6] Add global option to output JSON from ovs-appctl cmds.

2024-04-11 Thread jmeng
From: Jakob Meng This patch series is based on v7 [0] but applies three fundamental changes: * When JSON output is requested but a command has not implemented JSON printing yet, the plain-text output will be wrapped in a JSON object anyway. The main reason is that commands, which have already

[ovs-dev] [PATCH v2] dpif-netdev: Increase MAX_RECIRC_DEPTH to 8.

2024-01-26 Thread jmeng
From: Jakob Meng In a scenario where OVN does load balancing and then SNAT with a OVS userspace datapath [0], the recirc_depth may be greater than 6. In that case, ovs-vswitchd might drop packets and raise warnings: dpif_netdev|WARN|Packet dropped. Max recirculation depth exceeded.

[ovs-dev] [PATCH] dpif-netdev: Increase MAX_RECIRC_DEPTH to 8.

2024-01-26 Thread jmeng
From: Jakob Meng In a scenario where OVN does load balancing and then SNAT with a OVS userspace datapath [0], the recirc_depth may be greater than 6. In that case, ovs-vswitchd might drop packets and raise warnings: dpif_netdev|WARN|Packet dropped. Max recirculation depth exceeded.

[ovs-dev] [PATCH v7 5/6] appctl: Add option '--pretty' for pretty-printing JSON output.

2024-01-18 Thread jmeng
From: Jakob Meng Signed-off-by: Jakob Meng --- NEWS | 3 +++ lib/unixctl.c | 4 ++-- lib/unixctl.h | 1 + tests/pmd.at | 29 +++-- utilities/ovs-appctl.c | 22 +++--- 5 files changed, 52 insertions(+), 7

[ovs-dev] [PATCH v7 1/6] Add global option for JSON output to ovs-appctl.

2024-01-18 Thread jmeng
From: Jakob Meng For monitoring systems such as Prometheus it would be beneficial if OVS would expose statistics in a machine-readable format. This patch introduces support for different output formats to ovs-xxx tools. They gain a global option '-f,--format' which allows users to request JSON

[ovs-dev] [PATCH v7 4/6] ofproto: Add JSON output for 'dpif/show' command.

2024-01-18 Thread jmeng
From: Jakob Meng The 'dpif/show' command now supports machine-readable JSON output in addition to the plain-text output for humans. An example would be: ovs-appctl --format json dpif/show Reported-at: https://bugzilla.redhat.com/1824861 Signed-off-by: Jakob Meng --- ofproto/ofproto-dpif.c

[ovs-dev] [PATCH v7 6/6] appctl: Add tests for unsupported output formats.

2024-01-18 Thread jmeng
From: Jakob Meng Signed-off-by: Jakob Meng --- tests/pmd.at| 5 + tests/unixctl-py.at | 7 +++ 2 files changed, 12 insertions(+) diff --git a/tests/pmd.at b/tests/pmd.at index cff80da15..82a514f36 100644 --- a/tests/pmd.at +++ b/tests/pmd.at @@ -105,6 +105,11 @@ pmd thread

[ovs-dev] [PATCH v7 2/6] python: Add global option for JSON output to Python tools.

2024-01-18 Thread jmeng
From: Jakob Meng This patch introduces support for different output formats to the Python code, as did the previous commit for ovs-xxx tools like 'ovs-appctl --format json dpif/show'. In particular, tests/appctl.py gains a global option '-f,--format' which allows users to request JSON instead of

[ovs-dev] [PATCH v7 0/6] Add global option to output JSON from ovs-appctl cmds.

2024-01-18 Thread jmeng
From: Jakob Meng Same as v6 [0] but rebased to latest master. [0] https://patchwork.ozlabs.org/project/openvswitch/list/?series=390996=both=* Jakob Meng (6): Add global option for JSON output to ovs-appctl. python: Add global option for JSON output to Python tools. Migrate commands to

[ovs-dev] [PATCH v6 4/6] ofproto: Add JSON output for 'dpif/show' command.

2024-01-18 Thread jmeng
From: Jakob Meng The 'dpif/show' command now supports machine-readable JSON output in addition to the plain-text output for humans. An example would be: ovs-appctl --format json dpif/show Reported-at: https://bugzilla.redhat.com/1824861 Signed-off-by: Jakob Meng --- ofproto/ofproto-dpif.c

[ovs-dev] [PATCH v6 2/6] python: Add global option for JSON output to Python tools.

2024-01-18 Thread jmeng
From: Jakob Meng This patch introduces support for different output formats to the Python code, as did the previous commit for ovs-xxx tools like 'ovs-appctl --format json dpif/show'. In particular, tests/appctl.py gains a global option '-f,--format' which allows users to request JSON instead of

[ovs-dev] [PATCH v6 6/6] appctl: Add tests for unsupported output formats.

2024-01-18 Thread jmeng
From: Jakob Meng Signed-off-by: Jakob Meng --- tests/pmd.at| 5 + tests/unixctl-py.at | 7 +++ 2 files changed, 12 insertions(+) diff --git a/tests/pmd.at b/tests/pmd.at index cff80da15..82a514f36 100644 --- a/tests/pmd.at +++ b/tests/pmd.at @@ -105,6 +105,11 @@ pmd thread

[ovs-dev] [PATCH v6 5/6] appctl: Add option '--pretty' for pretty-printing JSON output.

2024-01-18 Thread jmeng
From: Jakob Meng Signed-off-by: Jakob Meng --- NEWS | 3 +++ lib/unixctl.c | 4 ++-- lib/unixctl.h | 1 + tests/pmd.at | 29 +++-- utilities/ovs-appctl.c | 22 +++--- 5 files changed, 52 insertions(+), 7

[ovs-dev] [PATCH v6 0/6] Add global option to output JSON from ovs-appctl cmds.

2024-01-18 Thread jmeng
From: Jakob Meng Compared to the previous patch series v5 [0] this v6 fixes missing command callbacks in third patch only, i.e. in ipsec/ovs-monitor-ipsec.in and vtep/ovs-vtep.in. [0] https://patchwork.ozlabs.org/project/openvswitch/list/?series=390829=both=* Jakob Meng (6): Add global

[ovs-dev] [PATCH v6 1/6] Add global option for JSON output to ovs-appctl.

2024-01-18 Thread jmeng
From: Jakob Meng For monitoring systems such as Prometheus it would be beneficial if OVS would expose statistics in a machine-readable format. This patch introduces support for different output formats to ovs-xxx tools. They gain a global option '-f,--format' which allows users to request JSON

[ovs-dev] [PATCH v5 6/6] appctl: Add tests for unsupported output formats.

2024-01-17 Thread jmeng
From: Jakob Meng Signed-off-by: Jakob Meng --- tests/pmd.at| 5 + tests/unixctl-py.at | 7 +++ 2 files changed, 12 insertions(+) diff --git a/tests/pmd.at b/tests/pmd.at index cff80da15..82a514f36 100644 --- a/tests/pmd.at +++ b/tests/pmd.at @@ -105,6 +105,11 @@ pmd thread

[ovs-dev] [PATCH v5 5/6] appctl: Add option '--pretty' for pretty-printing JSON output.

2024-01-17 Thread jmeng
From: Jakob Meng Signed-off-by: Jakob Meng --- NEWS | 3 +++ lib/unixctl.c | 4 ++-- lib/unixctl.h | 1 + tests/pmd.at | 29 +++-- utilities/ovs-appctl.c | 22 +++--- 5 files changed, 52 insertions(+), 7

[ovs-dev] [PATCH v5 4/6] ofproto: Add JSON output for 'dpif/show' command.

2024-01-17 Thread jmeng
From: Jakob Meng The 'dpif/show' command now supports machine-readable JSON output in addition to the plain-text output for humans. An example would be: ovs-appctl --format json dpif/show Reported-at: https://bugzilla.redhat.com/1824861 Signed-off-by: Jakob Meng --- ofproto/ofproto-dpif.c

[ovs-dev] [PATCH v5 2/6] python: Add global option for JSON output to Python tools.

2024-01-17 Thread jmeng
From: Jakob Meng This patch introduces support for different output formats to the Python code, as did the previous commit for ovs-xxx tools like 'ovs-appctl --format json dpif/show'. In particular, tests/appctl.py gains a global option '-f,--format' which allows users to request JSON instead of

[ovs-dev] [PATCH v5 1/6] Add global option for JSON output to ovs-appctl.

2024-01-17 Thread jmeng
From: Jakob Meng For monitoring systems such as Prometheus it would be beneficial if OVS would expose statistics in a machine-readable format. This patch introduces support for different output formats to ovs-xxx tools. They gain a global option '-f,--format' which allows users to request JSON

[ovs-dev] [PATCH v5 0/6] Add global option to output JSON from ovs-appctl cmds.

2024-01-17 Thread jmeng
From: Jakob Meng This patch series builds upon [0] and primarily incorporates Ilya's suggestions [1]: * In contrast to previous revisions, the JSON-RPC API is now left unmodified. * Instead a new 'set-options' command (unixctl_set_options callback) has been introduced. It allows to change the

[ovs-dev] [PATCH v4 6/6] unixctl: Pass output format as command args via JSON-RPC API.

2023-11-16 Thread jmeng
From: Jakob Meng A previous patch had changed the JSON-RPC API in lib/unixctl.* (and its Python counterpart) in order to allow transporting the requested output format from ovs-xxx tools to ovs-vswitchd across unix sockets: The meaning of 'method' and 'params' had be changed: 'method' would be

[ovs-dev] [PATCH v4 2/6] python: Add global option for JSON output to Python tools.

2023-11-16 Thread jmeng
From: Jakob Meng This patch introduces support for different output formats to the Python code, as did the previous commit for ovs-xxx tools like 'ovs-appctl --format json dpif/show'. In particular, tests/appctl.py gains a global option '-f,--format' which allows users to request JSON instead of

[ovs-dev] [PATCH v4 4/6] ofproto: Add JSON output for 'dpif/show' command.

2023-11-16 Thread jmeng
From: Jakob Meng The 'dpif/show' command now supports machine-readable JSON output in addition to the plain-text output for humans. An example would be: ovs-appctl --format json dpif/show Reported-at: https://bugzilla.redhat.com/1824861 Signed-off-by: Jakob Meng --- ofproto/ofproto-dpif.c

[ovs-dev] [PATCH v4 5/6] appctl: Add option '--pretty' for pretty-printing JSON output.

2023-11-16 Thread jmeng
From: Jakob Meng Signed-off-by: Jakob Meng --- NEWS | 3 +++ lib/unixctl.c | 4 ++-- lib/unixctl.h | 2 +- tests/pmd.at | 2 +- utilities/ovs-appctl.c | 19 +-- 5 files changed, 24 insertions(+), 6 deletions(-) diff --git

[ovs-dev] [PATCH v4 1/6] Add global option for JSON output to ovs-appctl.

2023-11-16 Thread jmeng
From: Jakob Meng For monitoring systems such as Prometheus it would be beneficial if OVS would expose statistics in a machine-readable format. This patch introduces support for different output formats to ovs-xxx tools. They gain a global option '-f,--format' which allows users to request JSON

[ovs-dev] [PATCH v4 0/6] Add global option to output JSON from ovs-appctl cmds.

2023-11-16 Thread jmeng
From: Jakob Meng This patch series builds upon [0] and brings the following changes: * Last patch in series shows how output format and other args could be passed via JSON-RPC API without the indirection introduced in the first patch (at the cost of inferiour error handling) * By default, the

[ovs-dev] [PATCH v8 3/3] netdev-dpdk: Sync and clean {get, set}_config() callbacks.

2023-11-13 Thread jmeng
From: Jakob Meng For better usability, the function pairs get_config() and set_config() for netdevs should be symmetric: Options which are accepted by set_config() should be returned by get_config() and the latter should output valid options for set_config() only. This patch moves key-value

[ovs-dev] [PATCH v8 1/3] netdev-dummy: Sync and clean {get, set}_config() callbacks.

2023-11-13 Thread jmeng
From: Jakob Meng For better usability, the function pairs get_config() and set_config() for netdevs should be symmetric: Options which are accepted by set_config() should be returned by get_config() and the latter should output valid options for set_config() only. This patch also moves key-value

[ovs-dev] [PATCH v8 2/3] netdev-afxdp: Sync and clean {get, set}_config() callbacks.

2023-11-13 Thread jmeng
From: Jakob Meng For better usability, the function pairs get_config() and set_config() for netdevs should be symmetric: Options which are accepted by set_config() should be returned by get_config() and the latter should output valid options for set_config() only. This patch also moves key-value

[ovs-dev] [PATCH v8 0/3] netdev: Sync and clean {get, set}_config() callbacks.

2023-11-13 Thread jmeng
From: Jakob Meng This patch series incorporates Ilya's comments for v7 and has been rebased to master: * fixed afxdp status descriptions in vswitchd/vswitch.xml * be consistent with rx/Rx/RX/tx/Tx/TX in vswitchd/vswitch.xml Jakob Meng (3): netdev-dummy: Sync and clean {get,set}_config()

[ovs-dev] [PATCH v7 3/3] netdev-dpdk: Sync and clean {get, set}_config() callbacks.

2023-10-30 Thread jmeng
From: Jakob Meng For better usability, the function pairs get_config() and set_config() for netdevs should be symmetric: Options which are accepted by set_config() should be returned by get_config() and the latter should output valid options for set_config() only. This patch moves key-value

[ovs-dev] [PATCH v7 2/3] netdev-afxdp: Sync and clean {get, set}_config() callbacks.

2023-10-30 Thread jmeng
From: Jakob Meng For better usability, the function pairs get_config() and set_config() for netdevs should be symmetric: Options which are accepted by set_config() should be returned by get_config() and the latter should output valid options for set_config() only. This patch also moves key-value

[ovs-dev] [PATCH v7 0/3] netdev: Sync and clean {get, set}_config() callbacks.

2023-10-30 Thread jmeng
From: Jakob Meng This patch series incorporates Ilya's and Kevin's change requests for v6: * added NEWS suggestion to netdev-dpdk patch * netdev-dpdk patch with NEWS entry has been put at the end of the series * get_config shuffle in dpdk_class, dpdk_vhost_class and dpdk_vhost_client_class has

[ovs-dev] [PATCH v7 1/3] netdev-dummy: Sync and clean {get, set}_config() callbacks.

2023-10-30 Thread jmeng
From: Jakob Meng For better usability, the function pairs get_config() and set_config() for netdevs should be symmetric: Options which are accepted by set_config() should be returned by get_config() and the latter should output valid options for set_config() only. This patch also moves key-value

[ovs-dev] [PATCH v2 1/1] python: Remove duplicate UnixctlClient implementation.

2023-10-30 Thread jmeng
From: Jakob Meng The unixctl implementation in Python has been split into three parts in the past. During this process the UnixctlClient was duplicated, in python/ovs/unixctl/client.py and python/ovs/unixctl/server.py. This patch removes the duplicate from the latter. Fixes: 53cf9963ccc6

[ovs-dev] [PATCH v2 0/1] python: Remove duplicate UnixctlClient implementation.

2023-10-30 Thread jmeng
From: Jakob Meng Only change from v1 is that the "Fixes" tag in the commit message is not abbreviated anymore. Jakob Meng (1): python: Remove duplicate UnixctlClient implementation. python/ovs/unixctl/server.py | 44 1 file changed, 44 deletions(-) --

[ovs-dev] [PATCH v3] editorconfig: Remove [*] section and trim_trailing_whitespace.

2023-10-27 Thread jmeng
From: Jakob Meng Wildcard sections [*] and [**] are unsafe because properties cannot be applied safely to any filetype in general. For example, IDEs like Visual Studio Code and KDevelop store configuration files in subfolders like .vscode or .kdev4. Properties from wildcard sections also apply

[ovs-dev] [PATCH] python: Remove duplicate UnixctlClient implementation.

2023-10-26 Thread jmeng
From: Jakob Meng The unixctl implementation in Python has been split into three parts in the past. During this process the UnixctlClient was duplicated, in python/ovs/unixctl/client.py and python/ovs/unixctl/server.py. This patch removes the duplicate from the latter. Fixes: 53cf9963ccc6

[ovs-dev] [PATCH v2] editorconfig: Remove [*] section and trim_trailing_whitespace.

2023-10-26 Thread jmeng
From: Jakob Meng Wildcard sections [*] and [**] are unsafe because properties cannot be applied safely to any filetype in general. For example, IDEs like Visual Studio Code and KDevelop store configuration files in subfolders like .vscode or .kdev4. Properties from wildcard sections also apply

[ovs-dev] [PATCH] editorconfig: Leave *.patch and *.diff files untouched.

2023-10-25 Thread jmeng
From: Jakob Meng A patch created with 'git format-patch' can contain trailing spaces. When editing a patch, e.g. to fix a typo in the title, the trailing spaces should not be removed. This becomes tricky when editors like Kate identify a space followed by form feed as a trailing space and remove

[ovs-dev] [RFC v3 1/4] Add global option for JSON output to ovs-appctl/dpctl.

2023-10-25 Thread jmeng
From: Jakob Meng For monitoring systems such as Prometheus it would be beneficial if OVS and OVS-DPDK would expose statistics in a machine-readable format. This patch introduces support for different output formats to ovs-xxx tools. They gain a global option '-f,--format' which allows users to

[ovs-dev] [RFC v3 2/4] python: Add global option for JSON output to Python tools.

2023-10-25 Thread jmeng
From: Jakob Meng This patch introduces support for different output formats to the Python code, as did the previous commit for ovs-xxx tools like 'ovs-appctl --format json dpif/show'. In particular, tests/appctl.py gains a global option '-f,--format' which allows users to request JSON instead of

[ovs-dev] [RFC v3 4/4] ofproto: Add JSON output for 'dpif/show' command.

2023-10-25 Thread jmeng
From: Jakob Meng The 'dpif/show' command now supports machine-readable JSON output in addition to the plain-text output for humans. An example would be: ovs-appctl --format json dpif/show Reported-at: https://bugzilla.redhat.com/1824861 Signed-off-by: Jakob Meng --- ofproto/ofproto-dpif.c

[ovs-dev] [RFC v3 0/4] Add global option to output JSON from ovs-appctl cmds.

2023-10-25 Thread jmeng
From: Jakob Meng Add global option to output JSON from ovs-appctl cmds. This patch is an update of [0] with the following major changes: * The JSON-RPC API change is now backward compatible. One can use an updated client (ovs-appctl/dpctl) with an old server (ovs-vswitchd) and vice versa.

[ovs-dev] [RFC v2 0/1] Add global option to output JSON from ovs-appctl cmds.

2023-10-20 Thread jmeng
From: Jakob Meng Follow up to [0] which fixes line endings. https://patchwork.ozlabs.org/project/openvswitch/patch/20231020093954.1410995-1-jm...@redhat.com/ Jakob Meng (1): Add global option to output JSON from ovs-appctl cmds. lib/bfd.c | 16 ++- lib/cfm.c

[ovs-dev] [RFC v2 1/1] Add command args to output JSON from ovs-appctl commands.

2023-10-20 Thread jmeng
From: Jakob Meng For monitoring systems such as Prometheus it would be beneficial if OVS and OVS-DPDK would expose statistics in a machine-readable format. Several approaches like UNIX socket, OVSDB queries and JSON output from ovs-xxx tools have been proposed [0],[1]. This proof of concept

[ovs-dev] [RFC v2 0/1] Add command args to output JSON from ovs-appctl commands.

2023-10-20 Thread jmeng
From: Jakob Meng This is a follow up with small changes to the previous RFC [0]: * Nasty double-free bug has been fixed. * Formatting has been updated to satisfy 0-day Robot. However, 0-day Robot will still complain because it interprets the command help "[(-o|--output=)text|json]" as a cast 

[ovs-dev] [PATCH v6 3/3] netdev-afxdp: Sync and clean {get, set}_config() callbacks.

2023-10-13 Thread jmeng
From: Jakob Meng For better usability, the function pairs get_config() and set_config() for netdevs should be symmetric: Options which are accepted by set_config() should be returned by get_config() and the latter should output valid options for set_config() only. This patch also moves key-value

[ovs-dev] [PATCH v6 1/3] netdev-dpdk: Sync and clean {get, set}_config() callbacks.

2023-10-13 Thread jmeng
From: Jakob Meng For better usability, the function pairs get_config() and set_config() for netdevs should be symmetric: Options which are accepted by set_config() should be returned by get_config() and the latter should output valid options for set_config() only. This patch moves key-value

[ovs-dev] [PATCH v6 2/3] netdev-dummy: Sync and clean {get, set}_config() callbacks.

2023-10-13 Thread jmeng
From: Jakob Meng For better usability, the function pairs get_config() and set_config() for netdevs should be symmetric: Options which are accepted by set_config() should be returned by get_config() and the latter should output valid options for set_config() only. This patch also moves key-value

[ovs-dev] [PATCH v6 0/3] netdev: Sync and clean {get, set}_config() callbacks.

2023-10-13 Thread jmeng
From: Jakob Meng For better usability, the function pairs get_config() and set_config() for netdevs should be symmetric: Options which are accepted by set_config() should be returned by get_config() and the latter should output valid options for set_config() only. This patch series moves

[ovs-dev] [PATCH] [RFC] Add options to output JSON from ovs-appctl commands.

2023-10-12 Thread jmeng
From: Jakob Meng For monitoring systems such as Prometheus it would be beneficial if OVS and OVS-DPDK would expose statistics in a machine-readable format. Several approaches like UNIX socket, OVSDB queries and JSON output from ovs-xxx tools have been proposed [0],[1]. This proof of concept

[ovs-dev] [PATCH v5] netdev: Sync'ed and cleaned {get, set}_config().

2023-10-11 Thread jmeng
From: Jakob Meng For better usability, the function pairs get_config() and set_config() for each netdev should be symmetric: Options which are accepted by set_config() should be returned by get_config() and the latter should output valid options for set_config() only. This patch moves key-value

[ovs-dev] [PATCH v3 2/3] netdev-dpdk: Update docs for interface info in vswitchd/vswitch.xml.

2023-10-06 Thread jmeng
From: Jakob Meng The status options pci-vendor_id and pci-device_id for dpdk netdevs have been replaced by bus_info. This patch updates the documentation in vswitchd/vswitch.xml accordingly. Fixes: a77c7796f23a ("dpdk: Update to use v22.11.1.") Signed-off-by: Jakob Meng Acked-by: Eelco

[ovs-dev] [PATCH v3 3/3] netdev-dpdk: Document rx-steering status options.

2023-10-06 Thread jmeng
From: Jakob Meng Fixes: fc06ea9a1883 ("netdev-dpdk: Add custom rx-steering configuration.") Signed-off-by: Jakob Meng --- vswitchd/vswitch.xml | 14 ++ 1 file changed, 14 insertions(+) diff --git a/vswitchd/vswitch.xml b/vswitchd/vswitch.xml index 006d1e6a4..1e2a1267d 100644 ---

[ovs-dev] [PATCH v3 1/3] netdev-dpdk: Document status options for VF MAC address.

2023-10-06 Thread jmeng
From: Jakob Meng Fixes: f4336f504b17 ("netdev-dpdk: Add option to configure VF MAC address. ") Signed-off-by: Jakob Meng --- vswitchd/vswitch.xml | 4 1 file changed, 4 insertions(+) diff --git a/vswitchd/vswitch.xml b/vswitchd/vswitch.xml index cfcde34ff..797fb05bf 100644 ---

[ovs-dev] [PATCH 2/3 v2] netdev-dpdk: Update docs for interface info in vswitchd/vswitch.xml.

2023-10-06 Thread jmeng
From: Jakob Meng The status options pci-vendor_id and pci-device_id for dpdk netdevs have been replaced by bus_info. This patch updates the documentation in vswitchd/vswitch.xml accordingly. Fixes: a77c7796f23a ("dpdk: Update to use v22.11.1.") Signed-off-by: Jakob Meng Acked-by: Eelco

[ovs-dev] [PATCH, v4] netdev: Sync'ed and cleaned {get, set}_config().

2023-10-04 Thread jmeng
From: Jakob Meng For better usability, the function pairs get_config() and set_config() for each netdev should be symmetric: Options which are accepted by set_config() should be returned by get_config() and the latter should output valid options for set_config() only. This patch moves key-value

[ovs-dev] [PATCH 3/3] netdev-dpdk: Document rx-steering status options.

2023-10-04 Thread jmeng
From: Jakob Meng Fixes: fc06ea9a1883 ("netdev-dpdk: Add custom rx-steering configuration.") --- vswitchd/vswitch.xml | 14 ++ 1 file changed, 14 insertions(+) diff --git a/vswitchd/vswitch.xml b/vswitchd/vswitch.xml index 006d1e6a4..1e2a1267d 100644 --- a/vswitchd/vswitch.xml +++

[ovs-dev] [PATCH 2/3] netdev-dpdk: Fixed DPDK specific interface status options.

2023-10-04 Thread jmeng
From: Jakob Meng The status options pci-vendor_id and pci-device_id for dpdk netdevs have been replaced by bus_info. This patch updates the documentation in vswitchd/vswitch.xml accordingly. Fixes: a77c7796f23a ("dpdk: Update to use v22.11.1.") --- vswitchd/vswitch.xml | 9 +++-- 1 file

[ovs-dev] [PATCH 1/3] netdev-dpdk: Document status options for VF MAC address.

2023-10-04 Thread jmeng
From: Jakob Meng Fixes: f4336f504b17 ("netdev-dpdk: Add option to configure VF MAC address. ") --- vswitchd/vswitch.xml | 4 1 file changed, 4 insertions(+) diff --git a/vswitchd/vswitch.xml b/vswitchd/vswitch.xml index cfcde34ff..797fb05bf 100644 --- a/vswitchd/vswitch.xml +++

[ovs-dev] [PATCH, v3] netdev: Sync'ed and cleaned {get, set}_config().

2023-09-27 Thread jmeng
From: Jakob Meng For better usability, the function pairs get_config() and set_config() for each netdev should be symmetric: Options which are accepted by set_config() should be returned by get_config() and the latter should output valid options for set_config() only. This patch moves key-value

[ovs-dev] [PATCH] netdev: Fixed DPDK specific interface status options.

2023-09-27 Thread jmeng
From: Jakob Meng The documentation in vswitchd/vswitch.xml for status columns has been updated to reflect recent and not so recent changes to dpdk netdevs. For example, status columns pci-vendor_id and pci-device_id have been replaced with bus_info in order to sync changes from [0]. [0]

[ovs-dev] [PATCH, v2] netdev: Sync'ed and cleaned {get, set}_config() and get_status()

2023-09-27 Thread jmeng
From: Jakob Meng For better usability, the function pairs get_config() and set_config() for each netdev should be symmetric: Options which are accepted by set_config() should be returned by get_config() and the latter should output valid options for set_config() only. This patch moves key-value