trafficserver-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dnj <>
Subject Re: poll external server
Date Thu, 21 Jan 2016 19:51:52 GMT
I did see ats_pagespeed. I was looking for a socket interface and not a file interface. 

> On Jan 21, 2016, at 9:36 AM, Leif Hedstrom <> wrote:
>> On Jan 21, 2016, at 8:03 AM, Alan Carroll <>
>> The closest I could find is ats_pagespeed.This doesn't poll an external server but
it does poll a configuration file. Basically you set up a thread using TSThreadCreate(), have
it do the polling, and then communicate its results back via thread safe containers. I think
the pagespeed one works by creating a duplicate structure on configuration change, then atomically
swapping pointers. You still need to reference count so the old structure can be cleaned up.
Thread safe queues would work as well.
> Fwiw, The health_check plugin does the same (has a thread checking to changes on the
file system).
> — Leif

View raw message