TSHttpTxnInfoIntGet¶
Synopsis¶
#include <ts/ts.h>
-
TSReturnCode
TSHttpTxnInfoIntGet
(TSHttpTxn txnp, TSHttpTxnInfoKey key, TSMgmtInt * value)¶
Description¶
TSHttpTxnInfoIntGet()
returns arbitrary integer-typed info about a transaction as defined in
TSHttpTxnInfoKey
. The API will be part of a generic API umbrella that can support returning
arbitrary info about a transaction using custom log tags. It works on multiple hooks depending on the
requested info. For example, cache related info may be available only at or after TS_HTTP_CACHE_LOOKUP_COMPLETE_HOOK
hook.
The TSHttpTxnInfoKey
currently supports the below integer-based info about a transaction
-
TSHttpTxnInfoKey
¶ -
TS_TXN_INFO_CACHE_HIT_RAM
¶ This info is available at or after
TS_HTTP_CACHE_LOOKUP_COMPLETE_HOOK
hook. A value of1
indicates that the response is returned from RAM cache. A value of0
indicates otherwise.
-
TS_TXN_INFO_CACHE_COMPRESSED_IN_RAM
¶ This info is available at or after
TS_HTTP_CACHE_LOOKUP_COMPLETE_HOOK
hook. A value of 1 indicates that the response is returned from RAM cache and is compressed. A value of 0 indicates otherwise.
-
TS_TXN_INFO_CACHE_HIT_RWW
¶ This info is available at or after
TS_HTTP_CACHE_LOOKUP_COMPLETE_HOOK
hook. A value of 1 indicates that the response is returned via Read-While-Writer functionality. A value of 0 indicates otherwise.
-
TS_TXN_INFO_CACHE_OPEN_READ_TRIES
¶ This info is available at or after
TS_HTTP_CACHE_LOOKUP_COMPLETE_HOOK
hook. The value indicates the number of cache open read reattempts made by the transaction on cache open read failure.
-
TS_TXN_INFO_CACHE_OPEN_WRITE_TRIES
¶ This info is available at or after
TS_HTTP_CACHE_LOOKUP_COMPLETE_HOOK
hook. The value indicates the number of cache open write reattempts made by the transaction on cache open write failure.
-
TS_TXN_INFO_CACHE_VOLUME
¶ This info is available at or after
TS_HTTP_CACHE_LOOKUP_COMPLETE_HOOK
hook. The value indicates the cache volume ID used for the cache object associated with the transaction.
-
Return values¶
The API returns TS_SUCCESS
, if the requested info is supported, TS_ERROR
otherwise.