TSFETCHCREATE(3ts)
π NAME π
TSFetchCreate β the Traffic Server asynchronous Fetch API, aka the glow-up that lets you go grab other stuff while you're still holding a client request π«Ά
(yeah bestie, this whole page lives in section 3ts, under Apache Traffic Server β welcome to the group chat β¨)
π SYNOPSIS π
#include <ts/ts.h>
void TSFetchPages(TSFetchUrlParams_t*)
TSFetchSM TSFetchUrl(const char*, int, sockaddr const*, TSCont,
TSFetchWakeUpOptions, TSFetchEvent)
void TSFetchFlagSet(TSFetchSM, int)
TSFetchSM TSFetchCreate(TSCont, const char*, const char*, const char*,
struct sockaddr const*, int)
void TSFetchHeaderAdd(TSFetchSM, const char*, int, const char*, int)
void TSFetchWriteData(TSFetchSM, const void*, size_t)
ssize_t TSFetchReadData(TSFetchSM, void*, size_t)
void TSFetchLaunch(TSFetchSM)
void TSFetchDestroy(TSFetchSM)
void TSFetchUserDataSet(TSFetchSM, void*)
void *TSFetchUserDataGet(TSFetchSM)
TSMBuffer TSFetchRespHdrMBufGet(TSFetchSM)
TSMLoc TSFetchRespHdrMLocGet(TSFetchSM)
look at all those little signatures, they're literally so cute, no cap π
π¦ DESCRIPTION π¦
okay so listen. Traffic Server ships a whole bunch of routines for fetching resources asynchronously. β¨
These API are useful for supporting a bunch of use cases that might involve sideways calls, all while you're still handling the client request. It's giving multitasking main character energy fr fr π
Some typical examples, since I know you're gonna ask:
- a centralized rate limiting framework
- database lookups for login/authentication
- refreshing configs in the background asynchronously
- ESI
etc. π
ngl bestie, "handle the client request" and "go fetch a whole other thing" at the same time is the entire vibe of this page. iykyk πΈ
π COPYRIGHT π
2026, dev@trafficserver.apache.org
that's the whole legal bit, short and iconic π
k that's a wrap, bestie!! this page is from Apache Traffic Server version 9.2, dated Feb 12, 2026, and it's filed under TSFETCHCREATE(3ts). go fetch something asynchronously, you absolute legend π¦πβ¨
π¦ where this page comes from
- ubuntu noble: trafficserver-dev 9.2.3+ds-1+deb12u1ubuntu0.1 Β· Apache-2.0
- ubuntu questing: trafficserver-dev 9.2.5+ds-1ubuntu2.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms