But isn't an example using kruft also kruft?

I think the only scenario for this is you hook a continuation globally on
SSN_START.  You poke and prod the particular session and decide there is a
reason to sett hooks for each transaction in the session.  The alternative
is the have a global hook for TXN_START.  Looking at the two examples, the
handling code for SSN_START unconditionally adds the TXN_START hook.  So
they seem to be pointlessly added complexity.

traffic_dump, in its SSN_START global hook, does some error checking before
setting a hook for all transactions in the session.  But it's not clear
that's a big improvement over doing the checks in a global TXN_START hook.
Seems like this is kruft if we can't think of a clear example where it's
crucial.

On Thu, Jul 11, 2019 at 5:11 PM Leif Hedstrom <zw...@apache.org> wrote:

>
>
> > On Jul 11, 2019, at 3:58 PM, Walt Karas <wka...@verizonmedia.com.INVALID>
> wrote:
> >
> > Should we deprecate this API function?
> >
> > The only core plugin that uses it is traffic_dump (experimental).  I
> don't
> > see it used anywhere in VzM internal plugins.  Anyone using it in their
> > internal plugins?  (Zwoop of course can't say without being disappeared
> to
> > a blacksite, which actually would probably be nice, in a warm climate
> with
> > good beaches and drinks with little umbrellas in them.)
>
> It seems this is somewhere between a global hook and a remap / txn hook?
> I.e. it’s not quite global, but applies to every transaction on this
> session?
>
> That  seems potentially useful, but I don’t know of any actual usage
> either. I did notice there’s one example plugin using it as well.
>
> — Leif
>
> >
> > I'm trying to muck around in the CPPAPI again.  The existence of this
> call
> > implies a need for a new SessionPlugin type, which I fear would just be
> > unused kruft.
>
>

Reply via email to