trace2: increment event format version

In 64bc752 (trace2: add trace2_child_ready() to report on background children, 2021-09-20), we added a new "child_ready" event. In Documentation/technical/api-trace2.txt, we promise that adding a new event type will result in incrementing the trace2 event format version number, but this was not done. Correct this in code & docs. Signed-off-by: Josh Steadmon <steadmon@google.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Josh Steadmon committed Nov 11, 2021 at 14:34 UTC 04480e67fe7a0a8c111becd43b114ce634e4a7e8
2 files changed +3 -3
Documentation/technical/api-trace2.txt
+2 -2
@@ -128,7 +128,7 @@ yields
128
129 ------------
130 $ cat ~/log.event
131 -{"event":"version","sid":"sid":"20190408T191610.507018Z-H9b68c35f-P000059a8","thread":"main","time":"2019-01-16T17:28:42.620713Z","file":"common-main.c","line":38,"evt":"2","exe":"2.20.1.155.g426c96fcdb"}
131 +{"event":"version","sid":"sid":"20190408T191610.507018Z-H9b68c35f-P000059a8","thread":"main","time":"2019-01-16T17:28:42.620713Z","file":"common-main.c","line":38,"evt":"3","exe":"2.20.1.155.g426c96fcdb"}
132 {"event":"start","sid":"20190408T191610.507018Z-H9b68c35f-P000059a8","thread":"main","time":"2019-01-16T17:28:42.621027Z","file":"common-main.c","line":39,"t_abs":0.001173,"argv":["git","version"]}
133 {"event":"cmd_name","sid":"20190408T191610.507018Z-H9b68c35f-P000059a8","thread":"main","time":"2019-01-16T17:28:42.621122Z","file":"git.c","line":432,"name":"version","hierarchy":"version"}
134 {"event":"exit","sid":"20190408T191610.507018Z-H9b68c35f-P000059a8","thread":"main","time":"2019-01-16T17:28:42.621236Z","file":"git.c","line":662,"t_abs":0.001227,"code":0}
@@ -391,7 +391,7 @@ only present on the "start" and "atexit" events.
391 {
392 "event":"version",
393 ...
394 - "evt":"2", # EVENT format version
394 + "evt":"3", # EVENT format version
395 "exe":"2.20.1.155.g426c96fcdb" # git version
396 }
397 ------------
trace2/tr2_tgt_event.c
+1 -1
@@ -20,7 +20,7 @@ static struct tr2_dst tr2dst_event = { TR2_SYSENV_EVENT, 0, 0, 0, 0 };
20 * a new field to an existing event, do not require an increment to the EVENT
21 * format version.
22 */
23 -#define TR2_EVENT_VERSION "2"
23 +#define TR2_EVENT_VERSION "3"
24
25 /*
26 * Region nesting limit for messages written to the event target.