Ignore:
Timestamp:
2011-08-02 10:48:16 (3 years ago)
Author:
Poul-Henning Kamp <phk@…>
Branches:
master, 4.0, experimental-ims
Children:
b5c9ba
Parents:
2c7441
git-author:
Poul-Henning Kamp <phk@…> (2011-08-02 10:48:16)
git-committer:
Poul-Henning Kamp <phk@…> (2011-08-02 10:48:16)
Message:

Cap the TTL (to param "shortlived") when we use the Transient storage
to avoid dropping an object on out of storage conditions.

I belive this...

Fixes #953

Otherwise please reopen.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • bin/varnishd/cache_center.c

    r8f85e3 rbeb0c5  
    755755                sp->obj = STV_NewObject(sp, TRANSIENT_STORAGE, l, 
    756756                    &sp->wrk->exp, nhttp); 
    757                 sp->wrk->exp.ttl = params->shortlived; 
     757                if (sp->wrk->exp.ttl > params->shortlived) 
     758                        sp->wrk->exp.ttl = params->shortlived; 
    758759        } 
    759760        if (sp->obj == NULL) { 
Note: See TracChangeset for help on using the changeset viewer.