mason/.perl-lib/TrivGal.pm, mason/dhandler: Rescale images lazily.
If `TrivGal::Image::scale' can't find an existing scaled image, then by
default it just returns immediately with a `?scale=...' link. The code
acting on this parameter now passes an additional FORCEP argument to
`TrivGal::Image::scale' to get it to actually generate the scaled
version. Once the scaled version exists, `TrivGal::Image::scale'
returns a direct link to it rather than the `?scale=...' link, which
saves a redirect round trip.
This has two main effects.
* Firstly, and most importantly, it allows the main HTML to be served
up immediately, without waiting for the (rather time-consuming)
image scaling to happen; and it also allows the scaling to happen
with a certain amount of parallelism.
* Secondly, it also isolates failures (e.g., due to exceeding memory
limits) to individual images.