[master] ad37cd85a varnishncsa: Skip irrelevant transactions (again)

Dridi Boukelmoune dridi.boukelmoune at gmail.com
Wed Jan 20 16:50:07 UTC 2021

commit ad37cd85ada72a4704aaa7e9489cd7ce79c0e149
Author: Dridi Boukelmoune <dridi.boukelmoune at gmail.com>
Date:   Wed Jan 20 17:27:46 2021 +0100

    varnishncsa: Skip irrelevant transactions (again)
    This was already the behavior before #3468, but then the filtering was
    moved to libvarnishapi to prevent varnishncsa from duplicating the logic
    behind transaction collection.
    Unfortunately, despite libvarnishapi's effort to not consider a client or
    backend transaction without a Begin tag as a candidate, a transaction
    missing one will get a synthetic Begin prior to dispatch.
    Regardless, that would have only applied to vxid grouping so even if
    varnishncsa was presented by default with only relevant transactions, it
    could still see incomplete transactions in request grouping panic for
    the same reason.
    Fixes #3501

diff --git a/bin/varnishncsa/varnishncsa.c b/bin/varnishncsa/varnishncsa.c
index bec52e87e..21d95e952 100644
--- a/bin/varnishncsa/varnishncsa.c
+++ b/bin/varnishncsa/varnishncsa.c
@@ -897,7 +897,8 @@ dispatch_f(struct VSL_data *vsl, struct VSL_transaction * const pt[],
 		} else if (t->type == VSL_t_bereq) {
 			CTX.side = "b";
 		} else
-			WRONG("unexpected");
+			continue;
 		CTX.hitmiss = "-";
 		CTX.handling = "-";
 		CTX.vxid = t->vxid;

More information about the varnish-commit mailing list