TSHttpTxnIsInternal
Test whether a request is internally-generated.
概要
#include <ts/ts.h>
解説
TSHttpTxnIsInternal() tests whether a HTTP transaction
was originated within Traffic Server.
TSHttpSsnIsInternal() tests whether a HTTP session
was originated within Traffic Server.
Return Values
Both these APIs return a int, indicating whether the
request was internal (1) or not (0).
例
The ESI plugin uses TSHttpTxnIsInternal() to ignore requests that is
had generated while fetching portions of an ESI document:
  header_obtained = is_cache_txn ? TSHttpTxnCachedRespGet(txnp, &bufp, &hdr_loc) : TSHttpTxnServerRespGet(txnp, &bufp, &hdr_loc);
  if (header_obtained != TS_SUCCESS) {
    TSError("[esi][%s] Couldn't get txn header for URL [%s]", __FUNCTION__, request_url.c_str());
    return false;
参考
TSAPI(3ts)