trafficserver-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alan Carroll <>
Subject Re: poll external server
Date Thu, 21 Jan 2016 15:03:05 GMT
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.

    On Wednesday, January 20, 2016 5:55 PM, Dk Jack <> wrote:

I am new to ATS and I am trying to write a plugin. My plugin needs to do
two things:

1) Periodically poll an external server and get some info and cache the
info locally.
2) Use this cached info while processing the traffic.

I couldn't find a straight forward example to do #1. Could someone more
point me in the correct direction. Any help is appreciated. Thanks.


  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message