Synthetic objects

Rogier 'DocWilco' Mulhuijzen varnish at bsdchicks.com
Thu Jun 27 21:32:57 CEST 2013


If we're changing things, it would be useful to have something in synth
other than a 3 digit status code.

I wouldn't mind a 64-bit (or 32-bit if you must) argument to synth(),
either instead of the status code, or in addition to.

This would give a little more headroom for choices of synthetic bodies.


On Thu, Jun 27, 2013 at 3:28 AM, Poul-Henning Kamp <phk at phk.freebsd.dk>wrote:

>
> I think I have made up my mind about how to do synthetic objects in
> V4, but I'd like to run the idea past you guys first.
>
> In vcl_backend_(fetch|response){} you do:
>
>         return (synth(777));
>
> Then you end up in vcl_backend_synth{} where, like in vcl_error{}, you
> can flesh out the object with headers and a body.
>
> The object will have a TTL of zero by default, but you can change that
> if you want to cache the object (unless it's a pass of course).
>
> Good or bad idea ?
>
> Poul-Henning
>
> PS: Yes, I do realize that together with std.fileread() this makes
> Varnish a webserver, but I trust^H^H^H^H^Hhope that people will
> restrain themselves
>
>
> --
> 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.
>
> _______________________________________________
> 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/20130627/0f1e1622/attachment.html>


More information about the varnish-dev mailing list