[PATCH] add documentation about backend naming for VMOD authors

Poul-Henning Kamp phk at phk.freebsd.dk
Tue Nov 3 09:51:51 CET 2015


--------
In message <CABoVN9DOY=NUW5L6UER6y-Vc=w7j-jEKM7ue5darjtEOoTWCtQ at mail.gmail.com>, Dridi Bouke
lmoune writes:

>Hi guys,
>
>I just realized that a VCL_HasBackend (or VRT) function for VMODs to
>"ensure" uniqueness would be racy by nature. In a scenario where the
>backend name is "stolen" right after we check its availability.

The way we solve that problem in kernels is to name the VCL_HasBackend()
function VCL_CreateBackend() and allowing it to fail :-)

>After a quick glance at the thread again, it seems that non-VCL
>backends such as for instance unix-domain socket backend should
>eventually show up in the CLI and VSM.

So far I have kept the CLI away from VMODs, but that is probably
not viable in the long term.

The backend/director split is, as you point out, not clean, and
if nothing else the naming is horrible.

So I think 5.0 is going to look quite differently than 4.1 in
this area.

-- 
Poul-Henning Kamp       | UNIX since Zilog Zeus 3.20
phk at FreeBSD.ORG         | TCP/IP since RFC 956
FreeBSD committer       | BSD since 4.3-tahoe    
Never attribute to malice what can adequately be explained by incompetence.



More information about the varnish-dev mailing list