Timothy Redaelli via dev <[email protected]> writes: > When --format json is passed to ovs-appctl, dpctl/show returns a JSON > object keyed by datapath name. Each entry contains "flows", "lookups" > (hits/lost/missed), and "ports" (keyed by port name, each with > "port-number" and "type"). The optional sections "masks" and "cache" > are only reported when the datapath supports them, and so are the port > "config" and "statistics" sub-objects. "cache" contains "statistics" > (hits and hit rate) and "config", an object keyed by cache level name > with the size of every level. The per packet mask hits and the cache > hit rate are omitted when no packets were looked up. > > The output_format field is added to struct dpctl_params so the handler > can select the appropriate callback (show_dpif or show_dpif_json). > The JSON accumulator is stored in dpctl_params.json, and the reply > is sent by dpctl_unixctl_handler based on whether json is set. On > error, the JSON object is discarded and a text error reply is sent. > > Since the JSON error path reuses the text error string, a failure of > dps_for_each() to enumerate the datapaths is now reported instead of > replying with an empty message. > > Example output: > {"ovs-system": {"flows": 0, > "lookups": {"hits": 0, "lost": 0, "missed": 0}, > "ports": {"br0": {"port-number": 0, > "type": "internal"}}}} > > Signed-off-by: Timothy Redaelli <[email protected]> > ---
Recheck-request: github-robot _______________________________________________ dev mailing list [email protected] https://mail.openvswitch.org/mailman/listinfo/ovs-dev
