Need some understanding on expiry thread
Prem Kumar
n.premkumar.me at gmail.com
Thu Jul 26 14:18:59 UTC 2018
Sorry to ask again.if the exp_inser add oc in to heap thru inbox with
insert flag during fetch.Assume if oc is expired and
And exp_expire will take the oc from binheap and mark as null as show in
last mail.
After it will skip the derefcoreobj().
Thanks,
Prem
On Thu, 26 Jul 2018 at 7:51 AM, Guillaume Quintard <
guillaume at varnish-software.com> wrote:
> assigned to null -> yes because you don't care about it, HSH_Derefobjcore
> will be called from the mailbox in the next while iteration of exp_thread
>
>
> --
> Guillaume Quintard
>
> On Wed, Jul 25, 2018 at 7:01 PM, Prem Kumar <n.premkumar.me at gmail.com>
> wrote:
>
>> Thanks.
>> But it is assigned to null and not being deleted from heap. moreover
>> HSH_Derefobjcore will not be called and not be freed ultimately.
>>
>>
>> Thank
>>
>> On Thu, 26 Jul 2018 at 2:56 AM, Guillaume Quintard <
>> guillaume at varnish-software.com> wrote:
>>
>>> Hi,
>>>
>>> There are people better suited to answer this, but hopefully, they'll
>>> yell if I'm saying anything stupid.
>>>
>>> After a cursory glance at the code, I'd say that objcores can be expired
>>> either from the inbox or from the binheap and that if you find a "posted"
>>> oc on the binheap, it's the inbox turf, so we null the oc to not handle it
>>> in the rest of the function.
>>>
>>> --
>>> Guillaume Quintard
>>>
>>> On Wed, Jul 25, 2018 at 9:49 AM, Prem Kumar <n.premkumar.me at gmail.com>
>>> wrote:
>>>
>>>> exp_expire(struct exp_priv *ep, double now)
>>>> {
>>>> ..
>>>> if (oc->timer_when > now)
>>>> return (oc->timer_when);
>>>>
>>>>
>>>>
>>>>
>>>> if (oc->exp_flags & OC_EF_POSTED) {
>>>> oc->exp_flags |= OC_EF_REMOVE;
>>>> oc = NULL;
>>>> } else {
>>>>
>>>>
>>>> why do we need to set to oc to NULL after marking it as NULL. How does
>>>> the object will be removed from hash and free'd from respective storage
>>>> backend.
>>>>
>>>>
>>>> Thanks,
>>>> Prem
>>>>
>>>> _______________________________________________
>>>> varnish-misc mailing list
>>>> varnish-misc at varnish-cache.org
>>>> https://www.varnish-cache.org/lists/mailman/listinfo/varnish-misc
>>>>
>>>>
>>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.varnish-cache.org/lists/pipermail/varnish-misc/attachments/20180726/4bf1226d/attachment-0001.html>
More information about the varnish-misc
mailing list