VFP and VDP configurations

Reza Naghibi reza at varnish-software.com
Tue Dec 19 16:18:21 UTC 2017


>  A user doesn't have a means to add VFPs or VDPs via VCL

Well, I guess I meant like this:

    beresp.do_esi = true

In effect, the above statement adds the ESI VDP to the beresp. ESI would
not be part of the "builtin" VDPs in this new scheme, rather, its just a
plain old user VDP. Builtins, as I have defined it, are VDPs which are
always available to be used transparent to the user. So in your case,
switching out ESI would be done like this:

    import my_parallel_esi;

    sub vcl_backend_response
    {
        add_vfp(my_parallel_esi.init());
        // Do not use beresp.do_esi
    }

Because no other ESI VDP was added, my_parallel_esi will be the only one to
run.

> Are we considering ways for a VFP/VDP defined in a VMOD to replace one of
the builtins?

I see no reason why not.

--
Reza Naghibi
Varnish Software

On Tue, Dec 19, 2017 at 7:29 AM, Geoff Simmons <geoff at uplex.de> wrote:

> On 12/10/2017 06:36 PM, Reza Naghibi wrote:
> > Basically, the user adds VFP
> > processors via VCL as usual with an optional position.
>
> What did you mean here by "as usual"? A user doesn't have a means to add
> VFPs or VDPs via VCL -- I thought that this discussion is about how that
> would work.
>
> >    - Varnish has access to builtin VFPs. These VFPs are always available
> >    and are used to fill in any gaps when it cannot find a way to match
> and
> >    output and input when constructing the chain.
>
> Are we considering ways for a VFP/VDP defined in a VMOD to replace one
> of the builtins?
>
> ... assuming that the same thoughts apply to VDPs, and that esi and
> gzip/gunzip are among the builtin VDPs ...
>
> As we've talked about before, I'd like to take a shot at a VDP for
> parallel ESIs. It seems to me that the pesi VDP wouldn't be worked into
> the chain, but would rather substitute the builtin esi VDP in the chain.
>
> So it would be something along the lines of:
>
> sub vcl_deliver {
>         replace_vdp(esi, pesi.vdp());
>         # ...
> }
>
>
> Best,
> Geoff
> --
> ** * * UPLEX - Nils Goroll Systemoptimierung
>
> Scheffelstraße 32
> 22301 Hamburg
>
> Tel +49 40 2880 5731
> Mob +49 176 636 90917
> Fax +49 40 42949753
>
> http://uplex.de
>
>
> _______________________________________________
> varnish-dev mailing list
> varnish-dev at varnish-cache.org
> https://www.varnish-cache.org/lists/mailman/listinfo/varnish-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.varnish-cache.org/lists/pipermail/varnish-dev/attachments/20171219/0eb0bac5/attachment.html>


More information about the varnish-dev mailing list