Traffic Server SDK API header file. More...
#include "apidefs.h"
Go to the source code of this file.
Defines | |
#define | TSmalloc(s) _TSmalloc ((s), TS_RES_MEM_PATH) |
#define | TSrealloc(p, s) _TSrealloc ((p), (s), TS_RES_MEM_PATH) |
#define | TSstrdup(p) _TSstrdup ((p), -1, TS_RES_MEM_PATH) |
#define | TSstrndup(p, n) _TSstrdup ((p), (n), TS_RES_MEM_PATH) |
#define | TSstrlcpy(d, s, l) _TSstrlcpy ((d), (s), (l)) |
#define | TSstrlcat(d, s, l) _TSstrlcat ((d), (s), (l)) |
#define | TSfree(p) _TSfree (p) |
#define | TSReleaseAssert(EX) ( (void)((EX) ? (void)0 : _TSReleaseAssert(#EX, __FILE__, __LINE__)) ) |
#define | TSAssert(EX) (void)((EX) || (_TSAssert(#EX, __FILE__, __LINE__))) |
#define | TSDEBUG if (diags_on_for_plugins) TSDebug |
Typedefs | |
typedef struct tsapi_textlogobject * | TSTextLogObject |
This type represents a custom log file that you create with TSTextLogObjectCreate(). | |
typedef void(* | TSRecordDumpCb )(TSRecordType rec_type, void *edata, int registered, const char *name, TSRecordDataType data_type, TSRecordData *datum) |
Enumerations | |
enum | TSStatPersistence { TS_STAT_PERSISTENT = 1, TS_STAT_NON_PERSISTENT } |
enum | TSStatSync { TS_STAT_SYNC_SUM = 0, TS_STAT_SYNC_COUNT, TS_STAT_SYNC_AVG, TS_STAT_SYNC_TIMEAVG } |
enum | { TS_LOG_MODE_ADD_TIMESTAMP = 1, TS_LOG_MODE_DO_NOT_RENAME = 2, TS_LOG_MODE_INVALID_FLAG = 4 } |
The following enum values are flags, so they should be powers of two. More... | |
Functions | |
tsapi void * | _TSmalloc (size_t size, const char *path) |
tsapi void * | _TSrealloc (void *ptr, size_t size, const char *path) |
tsapi char * | _TSstrdup (const char *str, int64_t length, const char *path) |
tsapi size_t | _TSstrlcpy (char *dst, const char *str, size_t siz) |
tsapi size_t | _TSstrlcat (char *dst, const char *str, size_t siz) |
tsapi void | _TSfree (void *ptr) |
tsapi TSReturnCode | TSHandleMLocRelease (TSMBuffer bufp, TSMLoc parent, TSMLoc mloc) |
Releases the TSMLoc mloc created from the TSMLoc parent. | |
tsapi const char * | TSInstallDirGet (void) |
Gets the path of the directory in which Traffic Server is installed. | |
tsapi const char * | TSConfigDirGet (void) |
Gets the path of the directory of Traffic Server configuration. | |
tsapi const char * | TSPluginDirGet (void) |
Gets the path of the plugin directory relative to the Traffic Server install directory. | |
tsapi const char * | TSTrafficServerVersionGet (void) |
Gets the version of Traffic Server currently running. | |
int | TSTrafficServerVersionGetMajor (void) |
Get the major version of Traffic Server currently running. | |
int | TSTrafficServerVersionGetMinor (void) |
Get the minor version of Traffic Server currently running. | |
int | TSTrafficServerVersionGetPatch (void) |
Get the patch version of Traffic Server currently running. | |
tsapi TSReturnCode | TSPluginRegister (TSSDKVersion sdk_version, TSPluginRegistrationInfo *plugin_info) |
This function registers your plugin with a particular version of Traffic Server SDK. | |
tsapi TSFile | TSfopen (const char *filename, const char *mode) |
Opens a file for reading or writing and returns a descriptor for accessing the file. | |
tsapi void | TSfclose (TSFile filep) |
Closes the file to which filep points and frees the data structures and buffers associated with it. | |
tsapi size_t | TSfread (TSFile filep, void *buf, size_t length) |
Attempts to read length bytes of data from the file pointed to by filep into the buffer buf. | |
tsapi size_t | TSfwrite (TSFile filep, const void *buf, size_t length) |
Attempts to write length bytes of data from the buffer buf to the file filep. | |
tsapi void | TSfflush (TSFile filep) |
Flushes pending data that has been buffered up in memory from previous calls to TSfwrite(). | |
tsapi char * | TSfgets (TSFile filep, char *buf, size_t length) |
Reads a line from the file pointed to by filep into the buffer buf. | |
tsapi void | TSError (const char *fmt,...) TS_PRINTFLIKE(1 |
Writes printf-style error messages to the Traffic Server error log. | |
tsapi void tsapi void | _TSReleaseAssert (const char *txt, const char *f, int l) TS_NORETURN |
tsapi int | _TSAssert (const char *txt, const char *f, int l) |
tsapi TSMBuffer | TSMBufferCreate (void) |
Creates a new marshal buffer and initializes the reference count to 1. | |
tsapi TSReturnCode | TSMBufferDestroy (TSMBuffer bufp) |
Ignores the reference count and destroys the marshal buffer bufp. | |
tsapi TSReturnCode | TSUrlCreate (TSMBuffer bufp, TSMLoc *locp) |
Creates a new URL within the marshal buffer bufp. | |
tsapi TS_DEPRECATED TSReturnCode | TSUrlDestroy (TSMBuffer bufp, TSMLoc offset) |
Destroys the URL located at url_loc within the marshal buffer bufp. | |
tsapi TSReturnCode | TSUrlClone (TSMBuffer dest_bufp, TSMBuffer src_bufp, TSMLoc src_url, TSMLoc *locp) |
Copies the URL located at src_url within src_bufp to a URL location within the marshal buffer dest_bufp, and returns the TSMLoc location of the copied URL. | |
tsapi TSReturnCode | TSUrlCopy (TSMBuffer dest_bufp, TSMLoc dest_offset, TSMBuffer src_bufp, TSMLoc src_offset) |
Copies the contents of the URL at location src_loc within the marshal buffer src_bufp to the location dest_loc within the marshal buffer dest_bufp. | |
tsapi void | TSUrlPrint (TSMBuffer bufp, TSMLoc offset, TSIOBuffer iobufp) |
Formats a URL stored in an TSMBuffer into an TSIOBuffer. | |
tsapi TSParseResult | TSUrlParse (TSMBuffer bufp, TSMLoc offset, const char **start, const char *end) |
Parses a URL. | |
tsapi int | TSUrlLengthGet (TSMBuffer bufp, TSMLoc offset) |
Calculates the length of the URL located at url_loc within the marshal buffer bufp if it were returned as a string. | |
tsapi char * | TSUrlStringGet (TSMBuffer bufp, TSMLoc offset, int *length) |
Constructs a string representation of the URL located at url_loc within bufp. | |
tsapi const char * | TSUrlSchemeGet (TSMBuffer bufp, TSMLoc offset, int *length) |
Retrieves the scheme portion of the URL located at url_loc within the marshal buffer bufp. | |
tsapi TSReturnCode | TSUrlSchemeSet (TSMBuffer bufp, TSMLoc offset, const char *value, int length) |
Sets the scheme portion of the URL located at url_loc within the marshal buffer bufp to the string value. | |
tsapi const char * | TSUrlUserGet (TSMBuffer bufp, TSMLoc offset, int *length) |
Retrieves the user portion of the URL located at url_loc within bufp. | |
tsapi TSReturnCode | TSUrlUserSet (TSMBuffer bufp, TSMLoc offset, const char *value, int length) |
Sets the user portion of the URL located at url_loc within bufp to the string value. | |
tsapi const char * | TSUrlPasswordGet (TSMBuffer bufp, TSMLoc offset, int *length) |
Retrieves the password portion of the URL located at url_loc within bufp. | |
tsapi TSReturnCode | TSUrlPasswordSet (TSMBuffer bufp, TSMLoc offset, const char *value, int length) |
Sets the password portion of the URL located at url_loc within bufp to the string value. | |
tsapi const char * | TSUrlHostGet (TSMBuffer bufp, TSMLoc offset, int *length) |
Retrieves the host portion of the URL located at url_loc within bufp. | |
tsapi TSReturnCode | TSUrlHostSet (TSMBuffer bufp, TSMLoc offset, const char *value, int length) |
Sets the host portion of the URL at url_loc to the string value. | |
tsapi int | TSUrlPortGet (TSMBuffer bufp, TSMLoc offset) |
Retrieves the port portion of the URL located at url_loc. | |
tsapi TSReturnCode | TSUrlPortSet (TSMBuffer bufp, TSMLoc offset, int port) |
Sets the port portion of the URL located at url_loc. | |
tsapi const char * | TSUrlPathGet (TSMBuffer bufp, TSMLoc offset, int *length) |
Retrieves the path portion of the URL located at url_loc within bufp. | |
tsapi TSReturnCode | TSUrlPathSet (TSMBuffer bufp, TSMLoc offset, const char *value, int length) |
Sets the path portion of the URL located at url_loc within bufp to the string value. | |
tsapi int | TSUrlFtpTypeGet (TSMBuffer bufp, TSMLoc offset) |
Retrieves the FTP type of the URL located at url_loc within bufp. | |
tsapi TSReturnCode | TSUrlFtpTypeSet (TSMBuffer bufp, TSMLoc offset, int type) |
Sets the FTP type portion of the URL located at url_loc within bufp to the value type. | |
tsapi const char * | TSUrlHttpParamsGet (TSMBuffer bufp, TSMLoc offset, int *length) |
Retrieves the HTTP params portion of the URL located at url_loc within bufp. | |
tsapi TSReturnCode | TSUrlHttpParamsSet (TSMBuffer bufp, TSMLoc offset, const char *value, int length) |
Sets the HTTP params portion of the URL located at url_loc within bufp to the string value. | |
tsapi const char * | TSUrlHttpQueryGet (TSMBuffer bufp, TSMLoc offset, int *length) |
Retrieves the HTTP query portion of the URL located at url_loc within bufp. | |
tsapi TSReturnCode | TSUrlHttpQuerySet (TSMBuffer bufp, TSMLoc offset, const char *value, int length) |
Sets the HTTP query portion of the URL located at url_loc within bufp to value. | |
tsapi const char * | TSUrlHttpFragmentGet (TSMBuffer bufp, TSMLoc offset, int *length) |
Retrieves the HTTP fragment portion of the URL located at url_loc within bufp. | |
tsapi TSReturnCode | TSUrlHttpFragmentSet (TSMBuffer bufp, TSMLoc offset, const char *value, int length) |
Sets the HTTP fragment portion of the URL located at url_loc within bufp to value. | |
tsapi TSReturnCode | TSStringPercentEncode (const char *str, int str_len, char *dst, size_t dst_size, size_t *length, const unsigned char *map) |
Perform percent-encoding of the string in the buffer, storing the new string in the destination buffer. | |
tsapi TSReturnCode | TSUrlPercentEncode (TSMBuffer bufp, TSMLoc offset, char *dst, size_t dst_size, size_t *length, const unsigned char *map) |
Similar to TSStringPercentEncode(), but works on a URL object. | |
tsapi TSReturnCode | TSStringPercentDecode (const char *str, size_t str_len, char *dst, size_t dst_size, size_t *length) |
Perform percent-decoding of the string in the buffer, writing to the output buffer. | |
tsapi TSMimeParser | TSMimeParserCreate (void) |
Creates a MIME parser. | |
tsapi void | TSMimeParserClear (TSMimeParser parser) |
Clears the specified MIME parser so that it can be used again. | |
tsapi void | TSMimeParserDestroy (TSMimeParser parser) |
Destroys the specified MIME parser and frees the associated memory. | |
tsapi TSReturnCode | TSMimeHdrCreate (TSMBuffer bufp, TSMLoc *locp) |
Creates a new MIME header within bufp. | |
tsapi TSReturnCode | TSMimeHdrDestroy (TSMBuffer bufp, TSMLoc offset) |
Destroys the MIME header located at hdr_loc within bufp. | |
tsapi TSReturnCode | TSMimeHdrClone (TSMBuffer dest_bufp, TSMBuffer src_bufp, TSMLoc src_hdr, TSMLoc *locp) |
Copies a specified MIME header to a specified marshal buffer, and returns the location of the copied MIME header within the destination marshal buffer. | |
tsapi TSReturnCode | TSMimeHdrCopy (TSMBuffer dest_bufp, TSMLoc dest_offset, TSMBuffer src_bufp, TSMLoc src_offset) |
Copies the contents of the MIME header located at src_loc within src_bufp to the MIME header located at dest_loc within dest_bufp. | |
tsapi void | TSMimeHdrPrint (TSMBuffer bufp, TSMLoc offset, TSIOBuffer iobufp) |
Formats the MIME header located at hdr_loc within bufp into the TSIOBuffer iobufp. | |
tsapi TSParseResult | TSMimeHdrParse (TSMimeParser parser, TSMBuffer bufp, TSMLoc offset, const char **start, const char *end) |
Parses a MIME header. | |
tsapi int | TSMimeHdrLengthGet (TSMBuffer bufp, TSMLoc offset) |
Calculates the length of the MIME header located at hdr_loc if it were returned as a string. | |
tsapi TSReturnCode | TSMimeHdrFieldsClear (TSMBuffer bufp, TSMLoc offset) |
Removes and destroys all the MIME fields within the MIME header located at hdr_loc within the marshal buffer bufp. | |
tsapi int | TSMimeHdrFieldsCount (TSMBuffer bufp, TSMLoc offset) |
Returns a count of the number of MIME fields within the MIME header located at hdr_loc within the marshal buffer bufp. | |
tsapi TSMLoc | TSMimeHdrFieldGet (TSMBuffer bufp, TSMLoc hdr, int idx) |
Retrieves the location of a specified MIME field within the MIME header located at hdr_loc within bufp. | |
tsapi TSMLoc | TSMimeHdrFieldFind (TSMBuffer bufp, TSMLoc hdr, const char *name, int length) |
Retrieves the TSMLoc location of a specified MIME field from within the MIME header located at hdr. | |
tsapi TSReturnCode | TSMimeHdrFieldAppend (TSMBuffer bufp, TSMLoc hdr, TSMLoc field) |
Returns the TSMLoc location of a specified MIME field from within the MIME header located at hdr. | |
tsapi TSReturnCode | TSMimeHdrFieldRemove (TSMBuffer bufp, TSMLoc hdr, TSMLoc field) |
Removes the MIME field located at field within bufp from the header located at hdr within bufp. | |
tsapi TSReturnCode | TSMimeHdrFieldCreate (TSMBuffer bufp, TSMLoc hdr, TSMLoc *locp) |
tsapi TSReturnCode | TSMimeHdrFieldCreateNamed (TSMBuffer bufp, TSMLoc mh_mloc, const char *name, int name_len, TSMLoc *locp) |
tsapi TSReturnCode | TSMimeHdrFieldDestroy (TSMBuffer bufp, TSMLoc hdr, TSMLoc field) |
Destroys the MIME field located at field within bufp. | |
tsapi TSReturnCode | TSMimeHdrFieldClone (TSMBuffer dest_bufp, TSMLoc dest_hdr, TSMBuffer src_bufp, TSMLoc src_hdr, TSMLoc src_field, TSMLoc *locp) |
tsapi TSReturnCode | TSMimeHdrFieldCopy (TSMBuffer dest_bufp, TSMLoc dest_hdr, TSMLoc dest_field, TSMBuffer src_bufp, TSMLoc src_hdr, TSMLoc src_field) |
tsapi TSReturnCode | TSMimeHdrFieldCopyValues (TSMBuffer dest_bufp, TSMLoc dest_hdr, TSMLoc dest_field, TSMBuffer src_bufp, TSMLoc src_hdr, TSMLoc src_field) |
tsapi TSMLoc | TSMimeHdrFieldNext (TSMBuffer bufp, TSMLoc hdr, TSMLoc field) |
tsapi TSMLoc | TSMimeHdrFieldNextDup (TSMBuffer bufp, TSMLoc hdr, TSMLoc field) |
tsapi int | TSMimeHdrFieldLengthGet (TSMBuffer bufp, TSMLoc hdr, TSMLoc field) |
tsapi const char * | TSMimeHdrFieldNameGet (TSMBuffer bufp, TSMLoc hdr, TSMLoc field, int *length) |
tsapi TSReturnCode | TSMimeHdrFieldNameSet (TSMBuffer bufp, TSMLoc hdr, TSMLoc field, const char *name, int length) |
tsapi TSReturnCode | TSMimeHdrFieldValuesClear (TSMBuffer bufp, TSMLoc hdr, TSMLoc field) |
tsapi int | TSMimeHdrFieldValuesCount (TSMBuffer bufp, TSMLoc hdr, TSMLoc field) |
tsapi const char * | TSMimeHdrFieldValueStringGet (TSMBuffer bufp, TSMLoc hdr, TSMLoc field, int idx, int *value_len_ptr) |
tsapi int | TSMimeHdrFieldValueIntGet (TSMBuffer bufp, TSMLoc hdr, TSMLoc field, int idx) |
tsapi int64_t | TSMimeHdrFieldValueInt64Get (TSMBuffer bufp, TSMLoc hdr, TSMLoc field, int idx) |
tsapi unsigned int | TSMimeHdrFieldValueUintGet (TSMBuffer bufp, TSMLoc hdr, TSMLoc field, int idx) |
tsapi time_t | TSMimeHdrFieldValueDateGet (TSMBuffer bufp, TSMLoc hdr, TSMLoc field) |
tsapi TSReturnCode | TSMimeHdrFieldValueStringSet (TSMBuffer bufp, TSMLoc hdr, TSMLoc field, int idx, const char *value, int length) |
tsapi TSReturnCode | TSMimeHdrFieldValueIntSet (TSMBuffer bufp, TSMLoc hdr, TSMLoc field, int idx, int value) |
tsapi TSReturnCode | TSMimeHdrFieldValueInt64Set (TSMBuffer bufp, TSMLoc hdr, TSMLoc field, int idx, int64_t value) |
tsapi TSReturnCode | TSMimeHdrFieldValueUintSet (TSMBuffer bufp, TSMLoc hdr, TSMLoc field, int idx, unsigned int value) |
tsapi TSReturnCode | TSMimeHdrFieldValueDateSet (TSMBuffer bufp, TSMLoc hdr, TSMLoc field, time_t value) |
tsapi TSReturnCode | TSMimeHdrFieldValueAppend (TSMBuffer bufp, TSMLoc hdr, TSMLoc field, int idx, const char *value, int length) |
tsapi TSReturnCode | TSMimeHdrFieldValueStringInsert (TSMBuffer bufp, TSMLoc hdr, TSMLoc field, int idx, const char *value, int length) |
tsapi TSReturnCode | TSMimeHdrFieldValueIntInsert (TSMBuffer bufp, TSMLoc hdr, TSMLoc field, int idx, int value) |
tsapi TSReturnCode | TSMimeHdrFieldValueUintInsert (TSMBuffer bufp, TSMLoc hdr, TSMLoc field, int idx, unsigned int value) |
tsapi TSReturnCode | TSMimeHdrFieldValueDateInsert (TSMBuffer bufp, TSMLoc hdr, TSMLoc field, time_t value) |
tsapi TSReturnCode | TSMimeHdrFieldValueDelete (TSMBuffer bufp, TSMLoc hdr, TSMLoc field, int idx) |
tsapi TSHttpParser | TSHttpParserCreate (void) |
tsapi void | TSHttpParserClear (TSHttpParser parser) |
tsapi void | TSHttpParserDestroy (TSHttpParser parser) |
tsapi TSParseResult | TSHttpHdrParseReq (TSHttpParser parser, TSMBuffer bufp, TSMLoc offset, const char **start, const char *end) |
Parses an HTTP request header. | |
tsapi TSParseResult | TSHttpHdrParseResp (TSHttpParser parser, TSMBuffer bufp, TSMLoc offset, const char **start, const char *end) |
tsapi TSMLoc | TSHttpHdrCreate (TSMBuffer bufp) |
tsapi void | TSHttpHdrDestroy (TSMBuffer bufp, TSMLoc offset) |
Destroys the HTTP header located at hdr_loc within the marshal buffer bufp. | |
tsapi TSReturnCode | TSHttpHdrClone (TSMBuffer dest_bufp, TSMBuffer src_bufp, TSMLoc src_hdr, TSMLoc *locp) |
tsapi TSReturnCode | TSHttpHdrCopy (TSMBuffer dest_bufp, TSMLoc dest_offset, TSMBuffer src_bufp, TSMLoc src_offset) |
Copies the contents of the HTTP header located at src_loc within src_bufp to the HTTP header located at dest_loc within dest_bufp. | |
tsapi void | TSHttpHdrPrint (TSMBuffer bufp, TSMLoc offset, TSIOBuffer iobufp) |
tsapi int | TSHttpHdrLengthGet (TSMBuffer bufp, TSMLoc offset) |
tsapi TSHttpType | TSHttpHdrTypeGet (TSMBuffer bufp, TSMLoc offset) |
tsapi TSReturnCode | TSHttpHdrTypeSet (TSMBuffer bufp, TSMLoc offset, TSHttpType type) |
tsapi int | TSHttpHdrVersionGet (TSMBuffer bufp, TSMLoc offset) |
tsapi TSReturnCode | TSHttpHdrVersionSet (TSMBuffer bufp, TSMLoc offset, int ver) |
tsapi const char * | TSHttpHdrMethodGet (TSMBuffer bufp, TSMLoc offset, int *length) |
tsapi TSReturnCode | TSHttpHdrMethodSet (TSMBuffer bufp, TSMLoc offset, const char *value, int length) |
tsapi TSReturnCode | TSHttpHdrUrlGet (TSMBuffer bufp, TSMLoc offset, TSMLoc *locp) |
tsapi TSReturnCode | TSHttpHdrUrlSet (TSMBuffer bufp, TSMLoc offset, TSMLoc url) |
tsapi TSHttpStatus | TSHttpHdrStatusGet (TSMBuffer bufp, TSMLoc offset) |
tsapi TSReturnCode | TSHttpHdrStatusSet (TSMBuffer bufp, TSMLoc offset, TSHttpStatus status) |
tsapi const char * | TSHttpHdrReasonGet (TSMBuffer bufp, TSMLoc offset, int *length) |
tsapi TSReturnCode | TSHttpHdrReasonSet (TSMBuffer bufp, TSMLoc offset, const char *value, int length) |
tsapi const char * | TSHttpHdrReasonLookup (TSHttpStatus status) |
tsapi TSThread | TSThreadCreate (TSThreadFunc func, void *data) |
tsapi TSThread | TSThreadInit (void) |
tsapi void | TSThreadDestroy (TSThread thread) |
tsapi TSThread | TSThreadSelf (void) |
tsapi TSMutex | TSMutexCreate (void) |
tsapi void | TSMutexLock (TSMutex mutexp) |
tsapi TSReturnCode | TSMutexLockTry (TSMutex mutexp) |
tsapi void | TSMutexUnlock (TSMutex mutexp) |
tsapi TSCacheKey | TSCacheKeyCreate (void) |
Creates (allocates memory for) a new cache key. | |
tsapi TSReturnCode | TSCacheKeyDigestSet (TSCacheKey key, const char *input, int length) |
Generates a key for an object to be cached (written to the cache). | |
tsapi TSReturnCode | TSCacheKeyDigestFromUrlSet (TSCacheKey key, TSMLoc url) |
tsapi TSReturnCode | TSCacheKeyHostNameSet (TSCacheKey key, const char *hostname, int host_len) |
Associates a host name to the cache key. | |
tsapi TSReturnCode | TSCacheKeyPinnedSet (TSCacheKey key, time_t pin_in_cache) |
tsapi TSReturnCode | TSCacheKeyDestroy (TSCacheKey key) |
Destroys a cache key. | |
tsapi TSReturnCode | TSCacheUrlSet (TSHttpTxn txnp, const char *url, int length) |
tsapi unsigned int | TSConfigSet (unsigned int id, void *data, TSConfigDestroyFunc funcp) |
tsapi TSConfig | TSConfigGet (unsigned int id) |
tsapi void | TSConfigRelease (unsigned int id, TSConfig configp) |
tsapi void * | TSConfigDataGet (TSConfig configp) |
tsapi void | TSMgmtUpdateRegister (TSCont contp, const char *plugin_name) |
tsapi TSReturnCode | TSMgmtIntGet (const char *var_name, TSMgmtInt *result) |
tsapi TSReturnCode | TSMgmtCounterGet (const char *var_name, TSMgmtCounter *result) |
tsapi TSReturnCode | TSMgmtFloatGet (const char *var_name, TSMgmtFloat *result) |
tsapi TSReturnCode | TSMgmtStringGet (const char *var_name, TSMgmtString *result) |
tsapi TSCont | TSContCreate (TSEventFunc funcp, TSMutex mutexp) |
tsapi void | TSContDestroy (TSCont contp) |
tsapi void | TSContDataSet (TSCont contp, void *data) |
tsapi void * | TSContDataGet (TSCont contp) |
tsapi TSAction | TSContSchedule (TSCont contp, TSHRTime timeout, TSThreadPool tp) |
tsapi TSAction | TSContScheduleEvery (TSCont contp, TSHRTime every, TSThreadPool tp) |
tsapi TSAction | TSHttpSchedule (TSCont contp, TSHttpTxn txnp, TSHRTime timeout) |
tsapi int | TSContCall (TSCont contp, TSEvent event, void *edata) |
tsapi TSMutex | TSContMutexGet (TSCont contp) |
tsapi void | TSLifecycleHookAdd (TSLifecycleHookID id, TSCont contp) |
tsapi void | TSHttpHookAdd (TSHttpHookID id, TSCont contp) |
tsapi void | TSHttpSsnHookAdd (TSHttpSsn ssnp, TSHttpHookID id, TSCont contp) |
tsapi void | TSHttpSsnReenable (TSHttpSsn ssnp, TSEvent event) |
tsapi int | TSHttpSsnTransactionCount (TSHttpSsn ssnp) |
tsapi void | TSHttpTxnHookAdd (TSHttpTxn txnp, TSHttpHookID id, TSCont contp) |
tsapi TSHttpSsn | TSHttpTxnSsnGet (TSHttpTxn txnp) |
tsapi TSReturnCode | TSHttpTxnClientReqGet (TSHttpTxn txnp, TSMBuffer *bufp, TSMLoc *offset) |
tsapi TSReturnCode | TSHttpTxnClientRespGet (TSHttpTxn txnp, TSMBuffer *bufp, TSMLoc *offset) |
tsapi TSReturnCode | TSHttpTxnServerReqGet (TSHttpTxn txnp, TSMBuffer *bufp, TSMLoc *offset) |
tsapi TSReturnCode | TSHttpTxnServerRespGet (TSHttpTxn txnp, TSMBuffer *bufp, TSMLoc *offset) |
tsapi TSReturnCode | TSHttpTxnCachedReqGet (TSHttpTxn txnp, TSMBuffer *bufp, TSMLoc *offset) |
tsapi TSReturnCode | TSHttpTxnCachedRespGet (TSHttpTxn txnp, TSMBuffer *bufp, TSMLoc *offset) |
tsapi TSReturnCode | TSHttpTxnPristineUrlGet (TSHttpTxn txnp, TSMBuffer *bufp, TSMLoc *url_loc) |
tsapi char * | TSHttpTxnEffectiveUrlStringGet (TSHttpTxn txnp, int *length) |
Get the effective URL for the transaction. | |
tsapi void | TSHttpTxnRespCacheableSet (TSHttpTxn txnp, int flag) |
tsapi void | TSHttpTxnReqCacheableSet (TSHttpTxn txnp, int flag) |
tsapi TSReturnCode | TSHttpTxnServerRespNoStoreSet (TSHttpTxn txnp, int flag) |
Set flag indicating whether or not to cache the server response for given TSHttpTxn. | |
tsapi TSReturnCode | TSFetchPageRespGet (TSHttpTxn txnp, TSMBuffer *bufp, TSMLoc *offset) |
tsapi char * | TSFetchRespGet (TSHttpTxn txnp, int *length) |
tsapi TSReturnCode | TSHttpTxnCacheLookupStatusGet (TSHttpTxn txnp, int *lookup_status) |
tsapi TSReturnCode | TSHttpTxnTransformRespGet (TSHttpTxn txnp, TSMBuffer *bufp, TSMLoc *offset) |
tsapi void | TSHttpTxnClientIncomingPortSet (TSHttpTxn txnp, int port) |
tsapi void * | TSHttpSsnSSLConnectionGet (TSHttpSsn ssnp) |
Get SSL object of this session. | |
tsapi struct sockaddr const * | TSHttpTxnClientAddrGet (TSHttpTxn txnp) |
Get client address for transaction txnp. | |
tsapi struct sockaddr const * | TSHttpTxnIncomingAddrGet (TSHttpTxn txnp) |
Get the incoming address. | |
tsapi struct sockaddr const * | TSHttpTxnServerAddrGet (TSHttpTxn txnp) |
Get the origin server address. | |
tsapi TSReturnCode | TSHttpTxnServerAddrSet (TSHttpTxn txnp, struct sockaddr const *addr) |
Set the origin server address. | |
tsapi struct sockaddr const * | TSHttpTxnNextHopAddrGet (TSHttpTxn txnp) |
Get the next hop address. | |
tsapi TSReturnCode | TSHttpTxnClientFdGet (TSHttpTxn txnp, int *fdp) |
tsapi TSReturnCode | TSHttpTxnOutgoingAddrSet (TSHttpTxn txnp, struct sockaddr const *addr) |
tsapi TSReturnCode | TSHttpTxnOutgoingTransparencySet (TSHttpTxn txnp, int flag) |
tsapi struct sockaddr const * | TSHttpSsnClientAddrGet (TSHttpSsn ssnp) |
tsapi struct sockaddr const * | TSHttpSsnIncomingAddrGet (TSHttpSsn ssnp) |
tsapi TSReturnCode | TSHttpSsnClientFdGet (TSHttpSsn ssnp, int *fdp) |
tsapi TSReturnCode | TSHttpTxnClientPacketMarkSet (TSHttpTxn txnp, int mark) |
Change packet firewall mark for the client side connection. | |
tsapi TSReturnCode | TSHttpTxnServerPacketMarkSet (TSHttpTxn txnp, int mark) |
Change packet firewall mark for the server side connection. | |
tsapi TSReturnCode | TSHttpTxnClientPacketTosSet (TSHttpTxn txnp, int tos) |
Change packet TOS for the client side connection. | |
tsapi TSReturnCode | TSHttpTxnServerPacketTosSet (TSHttpTxn txnp, int tos) |
Change packet TOS for the server side connection. | |
tsapi void | TSHttpTxnErrorBodySet (TSHttpTxn txnp, char *buf, size_t buflength, char *mimetype) |
Sets an error type body to a transaction. | |
tsapi TSReturnCode | TSHttpTxnParentProxyGet (TSHttpTxn txnp, char **hostname, int *port) |
Retrieves the parent proxy hostname and port, if parent proxying is enabled. | |
tsapi void | TSHttpTxnParentProxySet (TSHttpTxn txnp, char *hostname, int port) |
Sets the parent proxy name and port. | |
tsapi void | TSHttpTxnUntransformedRespCache (TSHttpTxn txnp, int on) |
tsapi void | TSHttpTxnTransformedRespCache (TSHttpTxn txnp, int on) |
tsapi void | TSHttpTxnReenable (TSHttpTxn txnp, TSEvent event) |
Notifies the HTTP transaction txnp that the plugin is finished processing the current hook. | |
tsapi TSReturnCode | TSHttpCacheReenable (TSCacheTxn txnp, const TSEvent event, const void *data, const uint64_t size) |
tsapi void | TSHttpTxnArgSet (TSHttpTxn txnp, int arg_idx, void *arg) |
tsapi void * | TSHttpTxnArgGet (TSHttpTxn txnp, int arg_idx) |
tsapi void | TSHttpSsnArgSet (TSHttpSsn ssnp, int arg_idx, void *arg) |
tsapi void * | TSHttpSsnArgGet (TSHttpSsn ssnp, int arg_idx) |
tsapi TSReturnCode | TSHttpArgIndexReserve (const char *name, const char *description, int *arg_idx) |
tsapi TSReturnCode | TSHttpArgIndexNameLookup (const char *name, int *arg_idx, const char **description) |
tsapi TSReturnCode | TSHttpArgIndexLookup (int arg_idx, const char **name, const char **description) |
tsapi void | TSHttpTxnSetHttpRetStatus (TSHttpTxn txnp, TSHttpStatus http_retstatus) |
tsapi void | TSHttpTxnActiveTimeoutSet (TSHttpTxn txnp, int timeout) |
timeout is in msec overrides as proxy.config.http.transaction_active_timeout_out | |
tsapi void | TSHttpTxnConnectTimeoutSet (TSHttpTxn txnp, int timeout) |
timeout is in msec overrides as proxy.config.http.connect_attempts_timeout | |
tsapi void | TSHttpTxnDNSTimeoutSet (TSHttpTxn txnp, int timeout) |
timeout is in msec overrides as proxy.config.dns.lookup_timeout | |
tsapi void | TSHttpTxnNoActivityTimeoutSet (TSHttpTxn txnp, int timeout) |
timeout is in msec overrides as proxy.config.http.transaction_no_activity_timeout_out | |
tsapi TSServerState | TSHttpTxnServerStateGet (TSHttpTxn txnp) |
tsapi void | TSHttpTxnDebugSet (TSHttpTxn txnp, int on) |
Set the transaction specific debugging flag for this transaction. | |
tsapi int | TSHttpTxnDebugGet (TSHttpTxn txnp) |
Returns the transaction specific debugging flag for this transaction. | |
tsapi void | TSHttpSsnDebugSet (TSHttpSsn ssnp, int on) |
Set the session specific debugging flag for this client session. | |
tsapi int | TSHttpSsnDebugGet (TSHttpSsn ssnp, int *on) |
Returns the transaction specific debugging flag for this client session. | |
tsapi void | TSHttpTxnIntercept (TSCont contp, TSHttpTxn txnp) |
Allows a plugin take over the servicing of the request as though it was the origin server. | |
tsapi void | TSHttpTxnServerIntercept (TSCont contp, TSHttpTxn txnp) |
Allows a plugin take over the servicing of the request as though it was the origin server. | |
tsapi TSVConn | TSHttpConnectWithPluginId (struct sockaddr const *addr, char const *tag, int64_t id) |
Allows the plugin to initiate an http connection. | |
tsapi TSVConn | TSHttpConnect (struct sockaddr const *addr) |
Backwards compatible version. | |
tsapi TSVConn | TSHttpConnectTransparent (struct sockaddr const *client_addr, struct sockaddr const *server_addr) |
Allows the plugin to initiate a transparent http connection. | |
tsapi void | TSFetchUrl (const char *request, int request_len, struct sockaddr const *addr, TSCont contp, TSFetchWakeUpOptions callback_options, TSFetchEvent event) |
tsapi void | TSFetchPages (TSFetchUrlParams_t *params) |
tsapi TSReturnCode | TSHttpIsInternalRequest (TSHttpTxn txnp) |
tsapi TSReturnCode | TSHttpIsInternalSession (TSHttpSsn ssnp) |
tsapi TSReturnCode | TSHttpAltInfoClientReqGet (TSHttpAltInfo infop, TSMBuffer *bufp, TSMLoc *offset) |
tsapi TSReturnCode | TSHttpAltInfoCachedReqGet (TSHttpAltInfo infop, TSMBuffer *bufp, TSMLoc *offset) |
tsapi TSReturnCode | TSHttpAltInfoCachedRespGet (TSHttpAltInfo infop, TSMBuffer *bufp, TSMLoc *offset) |
tsapi void | TSHttpAltInfoQualitySet (TSHttpAltInfo infop, float quality) |
tsapi void | TSActionCancel (TSAction actionp) |
tsapi int | TSActionDone (TSAction actionp) |
tsapi TSVIO | TSVConnReadVIOGet (TSVConn connp) |
tsapi TSVIO | TSVConnWriteVIOGet (TSVConn connp) |
tsapi int | TSVConnClosedGet (TSVConn connp) |
tsapi TSVIO | TSVConnRead (TSVConn connp, TSCont contp, TSIOBuffer bufp, int64_t nbytes) |
tsapi TSVIO | TSVConnWrite (TSVConn connp, TSCont contp, TSIOBufferReader readerp, int64_t nbytes) |
tsapi void | TSVConnClose (TSVConn connp) |
tsapi void | TSVConnAbort (TSVConn connp, int error) |
tsapi void | TSVConnShutdown (TSVConn connp, int read, int write) |
tsapi int64_t | TSVConnCacheObjectSizeGet (TSVConn connp) |
tsapi TSVConn | TSTransformCreate (TSEventFunc event_funcp, TSHttpTxn txnp) |
tsapi TSVConn | TSTransformOutputVConnGet (TSVConn connp) |
tsapi struct sockaddr const * | TSNetVConnRemoteAddrGet (TSVConn vc) |
tsapi TSAction | TSNetConnect (TSCont contp, struct sockaddr const *to) |
Opens a network connection to the host specified by ip on the port specified by port. | |
tsapi TSAction | TSNetAccept (TSCont contp, int port, int domain, int accept_threads) |
tsapi TSReturnCode | TSNetAcceptNamedProtocol (TSCont contp, const char *protocol) |
Listen on all SSL ports for connections for the specified protocol name. | |
tsapi TSPortDescriptor | TSPortDescriptorParse (const char *descriptor) |
Create a new port from the string specification used by the proxy.config.http.server_ports configuration value. | |
tsapi TSReturnCode | TSPortDescriptorAccept (TSPortDescriptor, TSCont) |
Start listening on the given port descriptor. | |
tsapi TSAction | TSHostLookup (TSCont contp, const char *hostname, size_t namelen) |
tsapi struct sockaddr const * | TSHostLookupResultAddrGet (TSHostLookupResult lookup_result) |
tsapi TSAction | TSCacheRead (TSCont contp, TSCacheKey key) |
Asks the Traffic Server cache if the object corresponding to key exists in the cache and can be read. | |
tsapi TSAction | TSCacheWrite (TSCont contp, TSCacheKey key) |
Asks the Traffic Server cache if contp can start writing the object (corresponding to key) to the cache. | |
tsapi TSAction | TSCacheRemove (TSCont contp, TSCacheKey key) |
Removes the object corresponding to key from the cache. | |
tsapi TSReturnCode | TSCacheReady (int *is_ready) |
tsapi TSAction | TSCacheScan (TSCont contp, TSCacheKey key, int KB_per_second) |
tsapi void | TSVIOReenable (TSVIO viop) |
tsapi TSIOBuffer | TSVIOBufferGet (TSVIO viop) |
tsapi TSIOBufferReader | TSVIOReaderGet (TSVIO viop) |
tsapi int64_t | TSVIONBytesGet (TSVIO viop) |
tsapi void | TSVIONBytesSet (TSVIO viop, int64_t nbytes) |
tsapi int64_t | TSVIONDoneGet (TSVIO viop) |
tsapi void | TSVIONDoneSet (TSVIO viop, int64_t ndone) |
tsapi int64_t | TSVIONTodoGet (TSVIO viop) |
tsapi TSMutex | TSVIOMutexGet (TSVIO viop) |
tsapi TSCont | TSVIOContGet (TSVIO viop) |
tsapi TSVConn | TSVIOVConnGet (TSVIO viop) |
tsapi TSIOBuffer | TSIOBufferCreate (void) |
tsapi TSIOBuffer | TSIOBufferSizedCreate (TSIOBufferSizeIndex index) |
Creates a new TSIOBuffer of the specified size. | |
tsapi int64_t | TSIOBufferWaterMarkGet (TSIOBuffer bufp) |
The watermark of an TSIOBuffer is the minimum number of bytes of data that have to be in the buffer before calling back any continuation that has initiated a read operation on this buffer. | |
tsapi void | TSIOBufferWaterMarkSet (TSIOBuffer bufp, int64_t water_mark) |
The watermark of an TSIOBuffer is the minimum number of bytes of data that have to be in the buffer before calling back any continuation that has initiated a read operation on this buffer. | |
tsapi void | TSIOBufferDestroy (TSIOBuffer bufp) |
tsapi TSIOBufferBlock | TSIOBufferStart (TSIOBuffer bufp) |
tsapi int64_t | TSIOBufferCopy (TSIOBuffer bufp, TSIOBufferReader readerp, int64_t length, int64_t offset) |
tsapi int64_t | TSIOBufferWrite (TSIOBuffer bufp, const void *buf, int64_t length) |
Writes length bytes of data contained in the string buf to the TSIOBuffer bufp. | |
tsapi void | TSIOBufferProduce (TSIOBuffer bufp, int64_t nbytes) |
tsapi TSIOBufferBlock | TSIOBufferBlockNext (TSIOBufferBlock blockp) |
tsapi const char * | TSIOBufferBlockReadStart (TSIOBufferBlock blockp, TSIOBufferReader readerp, int64_t *avail) |
tsapi int64_t | TSIOBufferBlockReadAvail (TSIOBufferBlock blockp, TSIOBufferReader readerp) |
tsapi char * | TSIOBufferBlockWriteStart (TSIOBufferBlock blockp, int64_t *avail) |
tsapi int64_t | TSIOBufferBlockWriteAvail (TSIOBufferBlock blockp) |
tsapi TSIOBufferReader | TSIOBufferReaderAlloc (TSIOBuffer bufp) |
tsapi TSIOBufferReader | TSIOBufferReaderClone (TSIOBufferReader readerp) |
tsapi void | TSIOBufferReaderFree (TSIOBufferReader readerp) |
tsapi TSIOBufferBlock | TSIOBufferReaderStart (TSIOBufferReader readerp) |
tsapi void | TSIOBufferReaderConsume (TSIOBufferReader readerp, int64_t nbytes) |
tsapi int64_t | TSIOBufferReaderAvail (TSIOBufferReader readerp) |
tsapi struct sockaddr const * | TSNetVConnLocalAddrGet (TSVConn vc) |
tsapi TSReturnCode | TSMgmtStringCreate (TSRecordType rec_type, const char *name, const TSMgmtString data_default, TSRecordUpdateType update_type, TSRecordCheckType check_type, const char *check_regex, TSRecordAccessType access_type) |
tsapi TSReturnCode | TSMgmtIntCreate (TSRecordType rec_type, const char *name, TSMgmtInt data_default, TSRecordUpdateType update_type, TSRecordCheckType check_type, const char *check_regex, TSRecordAccessType access_type) |
tsapi int | TSStatCreate (const char *the_name, TSRecordDataType the_type, TSStatPersistence persist, TSStatSync sync) |
tsapi void | TSStatIntIncrement (int the_stat, TSMgmtInt amount) |
tsapi void | TSStatIntDecrement (int the_stat, TSMgmtInt amount) |
tsapi TSMgmtInt | TSStatIntGet (int the_stat) |
tsapi void | TSStatIntSet (int the_stat, TSMgmtInt value) |
tsapi TSReturnCode | TSStatFindName (const char *name, int *idp) |
tsapi int | TSIsDebugTagSet (const char *t) |
tsapi void | TSDebug (const char *tag, const char *format_str,...) TS_PRINTFLIKE(2 |
tsapi void tsapi void | TSDebugSpecific (int debug_flag, const char *tag, const char *format_str,...) TS_PRINTFLIKE(3 |
Output a debug line even if the debug tag is turned off, as long as debugging is enabled. | |
tsapi void | TSRecordDump (int rec_type, TSRecordDumpCb callback, void *edata) |
tsapi TSReturnCode | TSTextLogObjectCreate (const char *filename, int mode, TSTextLogObject *new_log_obj) |
Creates a new custom log file that your plugin can write to. | |
tsapi TSReturnCode | TSTextLogObjectWrite (TSTextLogObject the_object, const char *format,...) TS_PRINTFLIKE(2 |
Writes a printf-style formatted statement to an TSTextLogObject (a plugin custom log). | |
tsapi TSReturnCode tsapi void | TSTextLogObjectFlush (TSTextLogObject the_object) |
This immediately flushes the contents of the log write buffer for the_object to disk. | |
tsapi TSReturnCode | TSTextLogObjectDestroy (TSTextLogObject the_object) |
Destroys a log object and releases the memory allocated to it. | |
tsapi void | TSTextLogObjectHeaderSet (TSTextLogObject the_object, const char *header) |
Set log header. | |
tsapi TSReturnCode | TSTextLogObjectRollingEnabledSet (TSTextLogObject the_object, int rolling_enabled) |
Enable/disable rolling. | |
tsapi void | TSTextLogObjectRollingIntervalSecSet (TSTextLogObject the_object, int rolling_interval_sec) |
Set the rolling interval. | |
tsapi void | TSTextLogObjectRollingOffsetHrSet (TSTextLogObject the_object, int rolling_offset_hr) |
Set the rolling offset. | |
tsapi TSReturnCode | TSAIORead (int fd, off_t offset, char *buf, size_t buffSize, TSCont contp) |
Async disk IO read. | |
tsapi char * | TSAIOBufGet (TSAIOCallback data) |
Async disk IO buffer get. | |
tsapi int | TSAIONBytesGet (TSAIOCallback data) |
Async disk IO get number of bytes. | |
tsapi TSReturnCode | TSAIOWrite (int fd, off_t offset, char *buf, size_t bufSize, TSCont contp) |
Async disk IO write. | |
tsapi TSReturnCode | TSAIOThreadNumSet (int thread_num) |
Async disk IO set number of threads. | |
tsapi TSReturnCode | TSHttpTxnAborted (TSHttpTxn txnp) |
Check if transaction was aborted (due client/server errors etc. | |
tsapi TSVConn | TSVConnCreate (TSEventFunc event_funcp, TSMutex mutexp) |
tsapi TSVConn | TSVConnFdCreate (int fd) |
tsapi int | TSHttpTxnClientReqHdrBytesGet (TSHttpTxn txnp) |
tsapi int64_t | TSHttpTxnClientReqBodyBytesGet (TSHttpTxn txnp) |
tsapi int | TSHttpTxnServerReqHdrBytesGet (TSHttpTxn txnp) |
tsapi int64_t | TSHttpTxnServerReqBodyBytesGet (TSHttpTxn txnp) |
tsapi int | TSHttpTxnPushedRespHdrBytesGet (TSHttpTxn txnp) |
tsapi int64_t | TSHttpTxnPushedRespBodyBytesGet (TSHttpTxn txnp) |
tsapi int | TSHttpTxnServerRespHdrBytesGet (TSHttpTxn txnp) |
tsapi int64_t | TSHttpTxnServerRespBodyBytesGet (TSHttpTxn txnp) |
tsapi int | TSHttpTxnClientRespHdrBytesGet (TSHttpTxn txnp) |
tsapi int64_t | TSHttpTxnClientRespBodyBytesGet (TSHttpTxn txnp) |
tsapi void | TSVConnInactivityTimeoutSet (TSVConn connp, TSHRTime timeout) |
tsapi void | TSVConnInactivityTimeoutCancel (TSVConn connp) |
tsapi void | TSVConnActiveTimeoutSet (TSVConn connp, TSHRTime timeout) |
tsapi void | TSVConnActiveTimeoutCancel (TSVConn connp) |
tsapi void | TSSkipRemappingSet (TSHttpTxn txnp, int flag) |
tsapi TSReturnCode | TSHttpTxnConfigIntSet (TSHttpTxn txnp, TSOverridableConfigKey conf, TSMgmtInt value) |
tsapi TSReturnCode | TSHttpTxnConfigIntGet (TSHttpTxn txnp, TSOverridableConfigKey conf, TSMgmtInt *value) |
tsapi TSReturnCode | TSHttpTxnConfigFloatSet (TSHttpTxn txnp, TSOverridableConfigKey conf, TSMgmtFloat value) |
tsapi TSReturnCode | TSHttpTxnConfigFloatGet (TSHttpTxn txnp, TSOverridableConfigKey conf, TSMgmtFloat *value) |
tsapi TSReturnCode | TSHttpTxnConfigStringSet (TSHttpTxn txnp, TSOverridableConfigKey conf, const char *value, int length) |
tsapi TSReturnCode | TSHttpTxnConfigStringGet (TSHttpTxn txnp, TSOverridableConfigKey conf, const char **value, int *length) |
tsapi TSReturnCode | TSHttpTxnConfigFind (const char *name, int length, TSOverridableConfigKey *conf, TSRecordDataType *type) |
tsapi TSReturnCode | TSHttpTxnFollowRedirect (TSHttpTxn txnp, int on) |
This API informs the core to try to follow redirections (e.g. | |
tsapi void | TSHttpTxnRedirectUrlSet (TSHttpTxn txnp, const char *url, const int url_len) |
This is a generalization of the TSHttpTxnFollowRedirect(), but gives finer control over the behavior. | |
tsapi TS_DEPRECATED void | TSRedirectUrlSet (TSHttpTxn txnp, const char *url, const int url_len) |
tsapi const char * | TSHttpTxnRedirectUrlGet (TSHttpTxn txnp, int *url_len_ptr) |
Return the current (if set) redirection URL string. | |
tsapi TS_DEPRECATED const char * | TSRedirectUrlGet (TSHttpTxn txnp, int *url_len_ptr) |
tsapi int | TSHttpTxnRedirectRetries (TSHttpTxn txnp) |
Return the number of redirection retries we have done. | |
tsapi int | TSHttpCurrentClientConnectionsGet (void) |
tsapi int | TSHttpCurrentActiveClientConnectionsGet (void) |
tsapi int | TSHttpCurrentIdleClientConnectionsGet (void) |
tsapi int | TSHttpCurrentCacheConnectionsGet (void) |
tsapi int | TSHttpCurrentServerConnectionsGet (void) |
tsapi TSReturnCode | TSHttpTxnCachedRespModifiableGet (TSHttpTxn txnp, TSMBuffer *bufp, TSMLoc *offset) |
tsapi TSReturnCode | TSHttpTxnCacheLookupStatusSet (TSHttpTxn txnp, int cachelookup) |
tsapi TSReturnCode | TSHttpTxnCacheLookupUrlGet (TSHttpTxn txnp, TSMBuffer bufp, TSMLoc obj) |
tsapi TSReturnCode | TSHttpTxnPrivateSessionSet (TSHttpTxn txnp, int private_session) |
tsapi int | TSHttpTxnBackgroundFillStarted (TSHttpTxn txnp) |
tsapi TSReturnCode | TSBase64Decode (const char *str, size_t str_len, unsigned char *dst, size_t dst_size, size_t *length) |
tsapi TSReturnCode | TSBase64Encode (const char *str, size_t str_len, char *dst, size_t dst_size, size_t *length) |
tsapi TSReturnCode | TSHttpTxnMilestoneGet (TSHttpTxn txnp, TSMilestonesType milestone, TSHRTime *time) |
Return the particular milestone timer for the transaction. | |
tsapi int | TSHttpTxnIsCacheable (TSHttpTxn txnp, TSMBuffer request, TSMBuffer response) |
Test whether a request / response header pair would be cacheable under the current configuration. | |
tsapi const char * | TSHttpServerStateNameLookup (TSServerState state) |
Return a string respresentation for a TSServerState value. | |
tsapi const char * | TSHttpHookNameLookup (TSHttpHookID hook) |
Return a string respresentation for a TSHttpHookID value. | |
tsapi const char * | TSHttpEventNameLookup (TSEvent event) |
Return a string respresentation for a TSEvent value. | |
Variables | |
tsapi void tsapi void int | diags_on_for_plugins |
Traffic Server SDK API header file.
Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Developers, when adding a new element to an enum, append it. DO NOT insert it. Otherwise, binary compatibility of plugins will be broken!
Definition in file ts.h.
#define TSAssert | ( | EX | ) | (void)((EX) || (_TSAssert(#EX, __FILE__, __LINE__))) |
Definition at line 268 of file ts.h.
Referenced by log_test_handler(), mytest_handler(), spdy_prepare_status_response_and_clean_request(), synclient_txn_close(), synclient_txn_connect_handler(), synclient_txn_delete(), synclient_txn_main_handler(), synclient_txn_read_response(), synclient_txn_read_response_handler(), synclient_txn_send_request(), synclient_txn_send_request_to_vc(), synclient_txn_write_request(), synclient_txn_write_request_handler(), synserver_accept_handler(), synserver_delete(), synserver_start(), synserver_stop(), synserver_txn_close(), synserver_txn_main_handler(), synserver_txn_read_request(), synserver_txn_read_request_handler(), synserver_txn_write_response(), and synserver_txn_write_response_handler().
#define TSDEBUG if (diags_on_for_plugins) TSDebug |
#define TSfree | ( | p | ) | _TSfree (p) |
Definition at line 48 of file ts.h.
Referenced by altinfo_hook_handler(), cache_handler(), cache_hook_handler(), config_destroy_func(), cont_data_handler(), log_test_handler(), my_data_destroy(), mytest_handler(), SDK_API_HttpHookAdd(), SDK_API_HttpSsn(), SDK_API_TSHttpHdr(), SDK_API_TSHttpHdrParse(), SDK_API_TSMimeHdrField(), SDK_API_TSMimeHdrParse(), SDK_API_TSUrl(), SDK_API_TSUrlParse(), ssn_handler(), synclient_txn_delete(), synserver_delete(), synserver_txn_close(), synserver_txn_write_response(), and transform_hook_handler().
#define TSmalloc | ( | s | ) | _TSmalloc ((s), TS_RES_MEM_PATH) |
Definition at line 42 of file ts.h.
Referenced by convert_http_hdr_to_string(), convert_mime_hdr_to_string(), generate_request(), generate_response(), my_data_alloc(), SDK_API_HttpAltInfo(), SDK_API_HttpHookAdd(), SDK_API_HttpSsn(), SDK_API_HttpTxnCache(), SDK_API_HttpTxnTransform(), SDK_API_TSCache(), SDK_API_TSConfig(), SDK_API_TSContDataGet(), SDK_API_TSHttpConnectIntercept(), SDK_API_TSHttpConnectServerIntercept(), SDK_API_TSHttpHdr(), SDK_API_TSMimeHdrField(), SDK_API_TSTextLog(), SDK_API_TSUrl(), synclient_txn_create(), synserver_accept_handler(), synserver_create(), and test_url_print().
#define TSrealloc | ( | p, | ||
s | ||||
) | _TSrealloc ((p), (s), TS_RES_MEM_PATH) |
#define TSReleaseAssert | ( | EX | ) | ( (void)((EX) ? (void)0 : _TSReleaseAssert(#EX, __FILE__, __LINE__)) ) |
Definition at line 265 of file ts.h.
Referenced by cache_handler(), cont_test_handler(), and SpdyNV::SpdyNV().
#define TSstrdup | ( | p | ) | _TSstrdup ((p), -1, TS_RES_MEM_PATH) |
Definition at line 44 of file ts.h.
Referenced by SDK_API_TSTextLog(), and ssn_handler().
#define TSstrndup | ( | p, | ||
n | ||||
) | _TSstrdup ((p), (n), TS_RES_MEM_PATH) |
typedef void(* TSRecordDumpCb)(TSRecordType rec_type, void *edata, int registered, const char *name, TSRecordDataType data_type, TSRecordData *datum) |
typedef struct tsapi_textlogobject* TSTextLogObject |
This type represents a custom log file that you create with TSTextLogObjectCreate().
Your plugin writes entries into this log file using TSTextLogObjectWrite().
anonymous enum |
The following enum values are flags, so they should be powers of two.
With the exception of TS_LOG_MODE_INVALID_FLAG, they are all used to configure the creation of an TSTextLogObject through the mode argument to TSTextLogObjectCreate(). TS_LOG_MODE_INVALID_FLAG is used internally to check the validity of this argument. Insert new flags before TS_LOG_MODE_INVALID_FLAG, and set TS_LOG_MODE_INVALID_FLAG to the largest power of two of the enum.
enum TSStatPersistence |
enum TSStatSync |
tsapi int _TSAssert | ( | const char * | txt, | |
const char * | f, | |||
int | l | |||
) |
tsapi void _TSfree | ( | void * | ptr | ) |
Definition at line 1656 of file InkAPI.cc.
References ats_free().
tsapi void* _TSmalloc | ( | size_t | size, | |
const char * | path | |||
) |
Definition at line 1625 of file InkAPI.cc.
References ats_malloc().
tsapi void* _TSrealloc | ( | void * | ptr, | |
size_t | size, | |||
const char * | path | |||
) |
Definition at line 1631 of file InkAPI.cc.
References ats_realloc().
tsapi void tsapi void _TSReleaseAssert | ( | const char * | txt, | |
const char * | f, | |||
int | l | |||
) |
Definition at line 402 of file InkAPI.cc.
References _ink_assert().
tsapi char* _TSstrdup | ( | const char * | str, | |
int64_t | length, | |||
const char * | path | |||
) |
Definition at line 1638 of file InkAPI.cc.
References _xstrdup().
tsapi size_t _TSstrlcat | ( | char * | dst, | |
const char * | str, | |||
size_t | siz | |||
) |
Definition at line 1650 of file InkAPI.cc.
References ink_strlcat().
tsapi size_t _TSstrlcpy | ( | char * | dst, | |
const char * | str, | |||
size_t | siz | |||
) |
Definition at line 1644 of file InkAPI.cc.
References ink_strlcpy().
tsapi void TSActionCancel | ( | TSAction | actionp | ) |
Definition at line 6122 of file InkAPI.cc.
References a, Action::cancel(), Action::continuation, EVENT_IMMEDIATE, and INKContInternal::handle_event_count().
Referenced by SDK_API_TSActionCancel(), synclient_txn_delete(), and synserver_stop().
tsapi int TSActionDone | ( | TSAction | actionp | ) |
Definition at line 6141 of file InkAPI.cc.
References ACTION_RESULT_DONE.
Referenced by SDK_API_TSActionCancel(), synclient_txn_delete(), and synserver_stop().
tsapi char* TSAIOBufGet | ( | TSAIOCallback | data | ) |
Async disk IO buffer get.
Definition at line 7437 of file InkAPI.cc.
References ink_aiocb::aio_buf, and AIOCallback::aiocb.
tsapi int TSAIONBytesGet | ( | TSAIOCallback | data | ) |
Async disk IO get number of bytes.
Definition at line 7444 of file InkAPI.cc.
References AIOCallback::aio_result.
tsapi TSReturnCode TSAIORead | ( | int | fd, | |
off_t | offset, | |||
char * | buf, | |||
size_t | buffSize, | |||
TSCont | contp | |||
) |
Async disk IO read.
Definition at line 7411 of file InkAPI.cc.
References AIOCallback::action, ink_aiocb::aio_buf, ink_aiocb::aio_fildes, ink_aiocb::aio_nbytes, ink_aiocb::aio_offset, AIOCallback::aiocb, ink_aio_read(), Continuation::mutex, new_AIOCallback(), sdk_assert, sdk_sanity_check_iocore_structure(), AIOCallback::thread, and TS_SUCCESS.
tsapi TSReturnCode TSAIOThreadNumSet | ( | int | thread_num | ) |
Async disk IO set number of threads.
Definition at line 7475 of file InkAPI.cc.
References ink_aio_thread_num_set(), and TS_SUCCESS.
tsapi TSReturnCode TSAIOWrite | ( | int | fd, | |
off_t | offset, | |||
char * | buf, | |||
size_t | bufSize, | |||
TSCont | contp | |||
) |
Async disk IO write.
Definition at line 7451 of file InkAPI.cc.
References ink_aio_write(), Continuation::mutex, new_AIOCallback(), sdk_assert, sdk_sanity_check_iocore_structure(), sdk_sanity_check_null_ptr(), and TS_SUCCESS.
tsapi TSReturnCode TSBase64Decode | ( | const char * | str, | |
size_t | str_len, | |||
unsigned char * | dst, | |||
size_t | dst_size, | |||
size_t * | length | |||
) |
Definition at line 1667 of file InkAPI.cc.
References ats_base64_decode(), sdk_assert, sdk_sanity_check_null_ptr(), and TS_SUCCESS.
Referenced by SDK_API_ENCODING().
tsapi TSReturnCode TSBase64Encode | ( | const char * | str, | |
size_t | str_len, | |||
char * | dst, | |||
size_t | dst_size, | |||
size_t * | length | |||
) |
Definition at line 1676 of file InkAPI.cc.
References ats_base64_encode(), sdk_assert, sdk_sanity_check_null_ptr(), and TS_SUCCESS.
Referenced by SDK_API_ENCODING().
tsapi TSCacheKey TSCacheKeyCreate | ( | void | ) |
Creates (allocates memory for) a new cache key.
Definition at line 3896 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_cachekey(), and TS_SUCCESS.
Referenced by SDK_API_TSCache().
tsapi TSReturnCode TSCacheKeyDestroy | ( | TSCacheKey | key | ) |
Destroys a cache key.
You must destroy cache keys when you are finished with them, i.e. after all reads and writes are completed.
key | to be destroyed. |
Definition at line 3988 of file InkAPI.cc.
References ats_free(), CACHE_INFO_MAGIC_ALIVE, CacheInfo::hostname, CacheInfo::magic, sdk_assert, sdk_sanity_check_cachekey(), and TS_SUCCESS.
Referenced by cache_handler(), and SDK_API_TSCache().
tsapi TSReturnCode TSCacheKeyDigestFromUrlSet | ( | TSCacheKey | key, | |
TSMLoc | url | |||
) |
Definition at line 3921 of file InkAPI.cc.
References CACHE_INFO_MAGIC_ALIVE, sdk_assert, sdk_sanity_check_cachekey(), TS_SUCCESS, and url_MD5_get().
tsapi TSReturnCode TSCacheKeyDigestSet | ( | TSCacheKey | key, | |
const char * | input, | |||
int | length | |||
) |
Generates a key for an object to be cached (written to the cache).
key | to be associated with the cached object. Before calling TSCacheKeySetDigest() you must create the key with TSCacheKeyCreate(). | |
input | string that uniquely identifies the object. In most cases, it is the URL of the object. | |
length | of the string input. |
Definition at line 3906 of file InkAPI.cc.
References CACHE_INFO_MAGIC_ALIVE, CacheInfo::cache_key, CacheInfo::magic, sdk_assert, sdk_sanity_check_cachekey(), sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by SDK_API_TSCache().
tsapi TSReturnCode TSCacheKeyHostNameSet | ( | TSCacheKey | key, | |
const char * | hostname, | |||
int | host_len | |||
) |
Associates a host name to the cache key.
Use this function if the cache has been partitioned by hostname. The hostname tells the cache which volume to use for the object.
key | of the cached object. | |
hostname | to associate with the cache key. | |
host_len | length of the string hostname. |
Definition at line 3956 of file InkAPI.cc.
References ats_malloc(), CACHE_INFO_MAGIC_ALIVE, CacheInfo::hostname, CacheInfo::len, memcpy, sdk_assert, sdk_sanity_check_cachekey(), sdk_sanity_check_null_ptr(), and TS_SUCCESS.
tsapi TSReturnCode TSCacheKeyPinnedSet | ( | TSCacheKey | key, | |
time_t | pin_in_cache | |||
) |
Definition at line 3975 of file InkAPI.cc.
References CACHE_INFO_MAGIC_ALIVE, CacheInfo::pin_in_cache, sdk_assert, sdk_sanity_check_cachekey(), and TS_SUCCESS.
tsapi TSAction TSCacheRead | ( | TSCont | contp, | |
TSCacheKey | key | |||
) |
Asks the Traffic Server cache if the object corresponding to key exists in the cache and can be read.
If the object can be read, the Traffic Server cache calls the continuation contp back with the event TS_EVENT_CACHE_OPEN_READ. In this case, the cache also passes contp a cache vconnection and contp can then initiate a read operation on that vconnection using TSVConnRead.
If the object cannot be read, the cache calls contp back with the event TS_EVENT_CACHE_OPEN_READ_FAILED. The user (contp) has the option to cancel the action returned by TSCacheRead. Note that reentrant calls are possible, i.e. the cache can call back the user (contp) in the same call.
contp | continuation to be called back if a read operation is permissible. | |
key | cache key corresponding to the object to be read. |
Definition at line 6590 of file InkAPI.cc.
References CacheInfo::cache_key, cacheProcessor, FORCE_PLUGIN_MUTEX, CacheInfo::frag_type, CacheInfo::hostname, CacheInfo::len, CacheProcessor::open_read(), sdk_assert, sdk_sanity_check_cachekey(), sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by cache_handler().
tsapi TSReturnCode TSCacheReady | ( | int * | is_ready | ) |
Definition at line 6557 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_null_ptr(), TS_CACHE_DATA_TYPE_NONE, TS_SUCCESS, and TSCacheDataTypeReady().
Referenced by SDK_API_TSCache().
tsapi TSAction TSCacheRemove | ( | TSCont | contp, | |
TSCacheKey | key | |||
) |
Removes the object corresponding to key from the cache.
If the object was removed successfully, the cache calls contp back with the event TS_EVENT_CACHE_REMOVE. If the object was not found in the cache, the cache calls contp back with the event TS_EVENT_CACHE_REMOVE_FAILED.
In both of these callbacks, the user (contp) does not have to do anything. The user does not get any vconnection from the cache, since no data needs to be transferred. When the cache calls contp back with TS_EVENT_CACHE_REMOVE, the remove has already been commited.
contp | continuation that the cache calls back reporting the success or failure of the remove. | |
key | cache key corresponding to the object to be removed. |
Definition at line 6619 of file InkAPI.cc.
References CacheInfo::cache_key, cacheProcessor, FORCE_PLUGIN_MUTEX, CacheInfo::frag_type, CacheInfo::hostname, CacheInfo::len, CacheProcessor::remove(), sdk_assert, sdk_sanity_check_cachekey(), sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by cache_handler().
tsapi TSAction TSCacheScan | ( | TSCont | contp, | |
TSCacheKey | key, | |||
int | KB_per_second | |||
) |
Definition at line 6633 of file InkAPI.cc.
References cacheProcessor, FORCE_PLUGIN_MUTEX, CacheInfo::hostname, CacheInfo::len, CacheProcessor::scan(), sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
tsapi TSReturnCode TSCacheUrlSet | ( | TSHttpTxn | txnp, | |
const char * | url, | |||
int | length | |||
) |
Definition at line 7092 of file InkAPI.cc.
References HttpTransact::State::cache_info, Debug, sdk_assert, sdk_sanity_check_txn(), HttpSM::t_state, and TS_SUCCESS.
tsapi TSAction TSCacheWrite | ( | TSCont | contp, | |
TSCacheKey | key | |||
) |
Asks the Traffic Server cache if contp can start writing the object (corresponding to key) to the cache.
If the object can be written, the cache calls contp back with the event TS_EVENT_CACHE_OPEN_WRITE. In this case, the cache also passes contp a cache vconnection and contp can then initiate a write operation on that vconnection using TSVConnWrite. The object is not committed to the cache until the vconnection is closed. When all data has been transferred, the user (contp) must do an TSVConnClose. In case of any errors, the user MUST do an TSVConnAbort(contp, 0).
If the object cannot be written, the cache calls contp back with the event TS_EVENT_CACHE_OPEN_WRITE_FAILED. This can happen, for example, if there is another object with the same key being written to the cache. The user (contp) has the option to cancel the action returned by TSCacheWrite.
Note that reentrant calls are possible, i.e. the cache can call back the user (contp) in the same call.
contp | continuation that the cache calls back (telling it whether the write operation can proceed or not). | |
key | cache key corresponding to the object to be cached. |
Definition at line 6604 of file InkAPI.cc.
References CacheInfo::cache_key, cacheProcessor, FORCE_PLUGIN_MUTEX, CacheInfo::frag_type, CacheInfo::hostname, CacheInfo::len, CacheProcessor::open_write(), CacheInfo::pin_in_cache, sdk_assert, sdk_sanity_check_cachekey(), sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by SDK_API_TSCache().
tsapi void* TSConfigDataGet | ( | TSConfig | configp | ) |
Definition at line 4140 of file InkAPI.cc.
References INKConfigImpl::mdata.
Referenced by SDK_API_TSConfig().
tsapi const char* TSConfigDirGet | ( | void | ) |
Gets the path of the directory of Traffic Server configuration.
Definition at line 1721 of file InkAPI.cc.
References Layout::get(), and Layout::sysconfdir.
Referenced by SDK_API_TSfopen().
tsapi TSConfig TSConfigGet | ( | unsigned int | id | ) |
Definition at line 4128 of file InkAPI.cc.
Referenced by SDK_API_TSConfig().
tsapi void TSConfigRelease | ( | unsigned int | id, | |
TSConfig | configp | |||
) |
Definition at line 4134 of file InkAPI.cc.
Referenced by SDK_API_TSConfig().
tsapi unsigned int TSConfigSet | ( | unsigned int | id, | |
void * | data, | |||
TSConfigDestroyFunc | funcp | |||
) |
Definition at line 4119 of file InkAPI.cc.
References INKConfigImpl::m_destroy_func, and INKConfigImpl::mdata.
Referenced by SDK_API_TSConfig().
Definition at line 4360 of file InkAPI.cc.
References Continuation::handleEvent().
Referenced by handle_transform(), SDK_API_TSContCreate(), synclient_txn_send_request_to_vc(), and transformtest_transform().
tsapi TSCont TSContCreate | ( | TSEventFunc | funcp, | |
TSMutex | mutexp | |||
) |
Definition at line 4200 of file InkAPI.cc.
References INKContInternal::init(), INKContAllocator, sdk_assert, sdk_sanity_check_mutex(), and TS_SUCCESS.
Referenced by SDK_API_HttpAltInfo(), SDK_API_HttpHookAdd(), SDK_API_HttpSsn(), SDK_API_HttpTxnCache(), SDK_API_HttpTxnTransform(), SDK_API_TSActionCancel(), SDK_API_TSCache(), SDK_API_TSContCreate(), SDK_API_TSContDataGet(), SDK_API_TSContMutexGet(), SDK_API_TSContSchedule(), SDK_API_TSHttpConnectIntercept(), SDK_API_TSHttpConnectServerIntercept(), SDK_API_TSNetVConn(), SDK_API_TSPortDescriptor(), SDK_API_TSTextLog(), PrefetchProcessor::start(), synclient_txn_send_request(), synclient_txn_send_request_to_vc(), synserver_accept_handler(), synserver_create(), UDPClientTestInit(), and UDPTestInit().
tsapi void* TSContDataGet | ( | TSCont | contp | ) |
Definition at line 4233 of file InkAPI.cc.
References INKContInternal::mdata, sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by altinfo_hook_handler(), cache_handler(), cache_hook_handler(), client_handler(), cont_data_handler(), cont_test_handler(), handle_transform(), log_test_handler(), mytest_handler(), server_handler(), ssn_handler(), synclient_txn_close(), synclient_txn_connect_handler(), synclient_txn_main_handler(), synclient_txn_read_response(), synclient_txn_read_response_handler(), synclient_txn_write_request(), synclient_txn_write_request_handler(), synserver_accept_handler(), synserver_txn_close(), synserver_txn_main_handler(), synserver_txn_read_request(), synserver_txn_read_request_handler(), synserver_txn_write_response(), synserver_txn_write_response_handler(), transform_hook_handler(), and transformtest_transform().
tsapi void TSContDataSet | ( | TSCont | contp, | |
void * | data | |||
) |
Definition at line 4223 of file InkAPI.cc.
References INKContInternal::mdata, sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by altinfo_hook_handler(), cache_hook_handler(), mytest_handler(), SDK_API_HttpAltInfo(), SDK_API_HttpHookAdd(), SDK_API_HttpSsn(), SDK_API_HttpTxnCache(), SDK_API_HttpTxnTransform(), SDK_API_TSCache(), SDK_API_TSContDataGet(), SDK_API_TSHttpConnectIntercept(), SDK_API_TSHttpConnectServerIntercept(), SDK_API_TSNetVConn(), SDK_API_TSPortDescriptor(), SDK_API_TSTextLog(), ssn_handler(), synclient_txn_send_request(), synclient_txn_send_request_to_vc(), synserver_accept_handler(), synserver_create(), transform_add(), and transform_hook_handler().
tsapi void TSContDestroy | ( | TSCont | contp | ) |
Definition at line 4213 of file InkAPI.cc.
References INKContInternal::destroy(), sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by action_cancel_handler(), client_handler(), cont_data_handler(), cont_schedule_handler(), SDK_API_TSContCreate(), SDK_API_TSContMutexGet(), server_handler(), synclient_txn_close(), synserver_delete(), synserver_txn_close(), and transformtest_transform().
Definition at line 4367 of file InkAPI.cc.
References Continuation::mutex, sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by cache_handler(), SDK_API_TSContMutexGet(), and TSTransformCreate().
tsapi TSAction TSContSchedule | ( | TSCont | contp, | |
TSHRTime | timeout, | |||
TSThreadPool | tp | |||
) |
Referenced by altinfo_hook_handler(), cache_handler(), cache_hook_handler(), cont_test_handler(), INKContInternal::destroy(), mytest_handler(), SDK_API_HttpAltInfo(), SDK_API_HttpHookAdd(), SDK_API_HttpSsn(), SDK_API_HttpTxnCache(), SDK_API_HttpTxnTransform(), SDK_API_TSActionCancel(), SDK_API_TSContDataGet(), SDK_API_TSContSchedule(), SDK_API_TSHttpConnectIntercept(), SDK_API_TSHttpConnectServerIntercept(), SDK_API_TSTextLog(), ssn_handler(), and transform_hook_handler().
tsapi TSAction TSContScheduleEvery | ( | TSCont | contp, | |
TSHRTime | every, | |||
TSThreadPool | tp | |||
) |
tsapi void TSDebug | ( | const char * | tag, | |
const char * | format_str, | |||
... | ||||
) |
tsapi void tsapi void TSDebugSpecific | ( | int | debug_flag, | |
const char * | tag, | |||
const char * | format_str, | |||
... | ||||
) |
Output a debug line even if the debug tag is turned off, as long as debugging is enabled.
Could be used as follows:
TSDebugSpecifc(TSHttpTxnDebugGet(txn), "plugin_tag" , "Hello World from transaction %p", txn);
will be printed if the plugin_tag is enabled or the transaction specific debugging is turned on for txn.
debug_flag | boolean flag. | |
tag | Debug tag for the line. | |
format | Format string. | |
... | Format arguments. |
tsapi void TSError | ( | const char * | fmt, | |
... | ||||
) |
Writes printf-style error messages to the Traffic Server error log.
One advantage of TSError over printf is that each call is atomically placed into the error log and is not garbled with other error entries. This is not an issue in single-threaded programs but is a definite nuisance in multi-threaded programs.
fmt | printf format description. | |
... | argument for the printf format description. |
tsapi void TSfclose | ( | TSFile | filep | ) |
Closes the file to which filep points and frees the data structures and buffers associated with it.
If the file was opened for writing, any pending data is flushed.
filep | file to be closed. |
Definition at line 1811 of file InkAPI.cc.
References FileImpl::fclose().
Referenced by log_test_handler(), and SDK_API_TSfopen().
tsapi TSReturnCode TSFetchPageRespGet | ( | TSHttpTxn | txnp, | |
TSMBuffer * | bufp, | |||
TSMLoc * | offset | |||
) |
Definition at line 7231 of file InkAPI.cc.
References HTTPHdr::m_http, sdk_assert, sdk_sanity_check_mbuffer(), sdk_sanity_check_null_ptr(), TS_SUCCESS, and HTTPHdr::valid().
tsapi void TSFetchPages | ( | TSFetchUrlParams_t * | params | ) |
Definition at line 7251 of file InkAPI.cc.
References ClassAllocator< C >::alloc(), ats_ip_sa_cast(), TSFetchUrlParams::contp, TSFetchUrlParams::events, FetchSM::httpConnect(), FetchSM::init(), TSFetchUrlParams::ip, TSFetchUrlParams::next, TSFetchUrlParams::options, TSFetchUrlParams::request, and TSFetchUrlParams::request_len.
tsapi char* TSFetchRespGet | ( | TSHttpTxn | txnp, | |
int * | length | |||
) |
Definition at line 7223 of file InkAPI.cc.
References FetchSM::resp_get(), sdk_assert, sdk_sanity_check_null_ptr(), and TS_SUCCESS.
tsapi void TSFetchUrl | ( | const char * | request, | |
int | request_len, | |||
struct sockaddr const * | addr, | |||
TSCont | contp, | |||
TSFetchWakeUpOptions | callback_options, | |||
TSFetchEvent | event | |||
) |
tsapi void TSfflush | ( | TSFile | filep | ) |
Flushes pending data that has been buffered up in memory from previous calls to TSfwrite().
filep | file to flush. |
Definition at line 1833 of file InkAPI.cc.
References FileImpl::fflush().
Referenced by SDK_API_TSfopen().
tsapi char* TSfgets | ( | TSFile | filep, | |
char * | buf, | |||
size_t | length | |||
) |
Reads a line from the file pointed to by filep into the buffer buf.
Lines are terminated by a line feed character, '
'. The line placed in the buffer includes the line feed character and is terminated with a NULL. If the line is longer than length bytes then only the first length-minus-1 bytes are placed in buf.
filep | file to read from. | |
buf | buffer to read into. | |
length | size of the buffer to read into. |
Definition at line 1840 of file InkAPI.cc.
References FileImpl::fgets().
Referenced by log_test_handler(), and SDK_API_TSfopen().
tsapi TSFile TSfopen | ( | const char * | filename, | |
const char * | mode | |||
) |
Opens a file for reading or writing and returns a descriptor for accessing the file.
The current implementation cannot open a file for both reading or writing. See the SDK Programmer's Guide for sample code.
filename | file to be opened. | |
mode | specifies whether to open the file for reading or writing. If mode is "r" then the file is opened for reading. If mode is "w" then the file is opened for writing. Currently "r" and "w" are the only two valid modes for opening a file. |
Definition at line 1797 of file InkAPI.cc.
References FileImpl::fopen().
Referenced by log_test_handler(), and SDK_API_TSfopen().
tsapi size_t TSfread | ( | TSFile | filep, | |
void * | buf, | |||
size_t | length | |||
) |
Attempts to read length bytes of data from the file pointed to by filep into the buffer buf.
filep | name of the file to read from. | |
buf | buffer to read into. | |
length | amount of data to read, in bytes. |
Definition at line 1819 of file InkAPI.cc.
References FileImpl::fread().
Referenced by SDK_API_TSfopen().
tsapi size_t TSfwrite | ( | TSFile | filep, | |
const void * | buf, | |||
size_t | length | |||
) |
Attempts to write length bytes of data from the buffer buf to the file filep.
Make sure that filep is open for writing. You might want to check the number of bytes written (TSfwrite() returns this value) against the value of length. If it is less, there might be insufficient space on disk, for example.
filep | file to write into. | |
buf | buffer containing the data to be written. | |
length | amount of data to write to filep, in bytes. |
Definition at line 1826 of file InkAPI.cc.
References FileImpl::fwrite().
Referenced by SDK_API_TSfopen().
tsapi TSReturnCode TSHandleMLocRelease | ( | TSMBuffer | bufp, | |
TSMLoc | parent, | |||
TSMLoc | mloc | |||
) |
Releases the TSMLoc mloc created from the TSMLoc parent.
If there is no parent TSMLoc, use TS_NULL_MLOC.
bufp | marshal buffer containing the TSMLoc handle to be released. | |
parent | location of the parent object from which the handle was created. | |
mloc | location of the handle to be released. |
Definition at line 1853 of file InkAPI.cc.
References HDR_HEAP_OBJ_FIELD_SDK_HANDLE, HDR_HEAP_OBJ_HTTP_HEADER, HDR_HEAP_OBJ_MIME_HEADER, HDR_HEAP_OBJ_URL, ink_release_assert, HdrHeapObjImpl::m_type, sdk_assert, sdk_free_field_handle(), sdk_sanity_check_field_handle(), sdk_sanity_check_mbuffer(), TS_ERROR, TS_NULL_MLOC, and TS_SUCCESS.
Referenced by cache_hook_handler(), get_request_id(), SDK_API_TSHttpHdr(), SDK_API_TSHttpHdrParse(), SDK_API_TSMimeHdrField(), SDK_API_TSMimeHdrParse(), SDK_API_TSUrl(), SDK_API_TSUrlParse(), SpdyNV::SpdyNV(), and transform_hook_handler().
Definition at line 6530 of file InkAPI.cc.
References FORCE_PLUGIN_MUTEX, HostDBProcessor::getbyname_re(), hostDBProcessor, sdk_assert, sdk_sanity_check_continuation(), sdk_sanity_check_null_ptr(), and TS_SUCCESS.
tsapi struct sockaddr const* TSHostLookupResultAddrGet | ( | TSHostLookupResult | lookup_result | ) | [read] |
Definition at line 6543 of file InkAPI.cc.
References HostDBInfo::ip, sdk_assert, sdk_sanity_check_hostlookup_structure(), and TS_SUCCESS.
tsapi TSReturnCode TSHttpAltInfoCachedReqGet | ( | TSHttpAltInfo | infop, | |
TSMBuffer * | bufp, | |||
TSMLoc * | offset | |||
) |
Definition at line 6009 of file InkAPI.cc.
References HttpAltInfo::m_cached_req, HTTPHdr::m_http, sdk_assert, sdk_sanity_check_alt_info(), sdk_sanity_check_mbuffer(), and TS_SUCCESS.
Referenced by altinfo_hook_handler().
tsapi TSReturnCode TSHttpAltInfoCachedRespGet | ( | TSHttpAltInfo | infop, | |
TSMBuffer * | bufp, | |||
TSMLoc * | offset | |||
) |
Definition at line 6022 of file InkAPI.cc.
References HttpAltInfo::m_cached_resp, HTTPHdr::m_http, sdk_assert, sdk_sanity_check_alt_info(), sdk_sanity_check_mbuffer(), and TS_SUCCESS.
Referenced by altinfo_hook_handler().
tsapi TSReturnCode TSHttpAltInfoClientReqGet | ( | TSHttpAltInfo | infop, | |
TSMBuffer * | bufp, | |||
TSMLoc * | offset | |||
) |
Definition at line 5996 of file InkAPI.cc.
References HttpAltInfo::m_client_req, HTTPHdr::m_http, sdk_assert, sdk_sanity_check_alt_info(), sdk_sanity_check_mbuffer(), and TS_SUCCESS.
Referenced by altinfo_hook_handler().
tsapi void TSHttpAltInfoQualitySet | ( | TSHttpAltInfo | infop, | |
float | quality | |||
) |
Definition at line 6035 of file InkAPI.cc.
References HttpAltInfo::m_qvalue, sdk_assert, sdk_sanity_check_alt_info(), and TS_SUCCESS.
Referenced by altinfo_hook_handler().
tsapi TSReturnCode TSHttpArgIndexLookup | ( | int | arg_idx, | |
const char ** | name, | |||
const char ** | description | |||
) |
Definition at line 5563 of file InkAPI.cc.
References _STATE_ARG_TABLE::description, _STATE_ARG_TABLE::name, sdk_sanity_check_null_ptr(), state_arg_table, and TS_SUCCESS.
tsapi TSReturnCode TSHttpArgIndexNameLookup | ( | const char * | name, | |
int * | arg_idx, | |||
const char ** | description | |||
) |
Definition at line 5578 of file InkAPI.cc.
References _STATE_ARG_TABLE::description, next_argv_index, sdk_assert, sdk_sanity_check_null_ptr(), state_arg_table, and TS_SUCCESS.
tsapi TSReturnCode TSHttpArgIndexReserve | ( | const char * | name, | |
const char * | description, | |||
int * | arg_idx | |||
) |
Definition at line 5544 of file InkAPI.cc.
References ats_strdup, _STATE_ARG_TABLE::description, HTTP_SSN_TXN_MAX_USER_ARG, _STATE_ARG_TABLE::name, _STATE_ARG_TABLE::name_len, next_argv_index, sdk_assert, sdk_sanity_check_null_ptr(), state_arg_table, and TS_SUCCESS.
tsapi TSReturnCode TSHttpCacheReenable | ( | TSCacheTxn | txnp, | |
const TSEvent | event, | |||
const void * | data, | |||
const uint64_t | size | |||
) |
tsapi TSVConn TSHttpConnect | ( | struct sockaddr const * | addr | ) |
Backwards compatible version.
This provides a tag of "plugin" and an id of 0.
Referenced by SDK_API_TSHttpConnectIntercept(), and SDK_API_TSHttpConnectServerIntercept().
tsapi TSVConn TSHttpConnectTransparent | ( | struct sockaddr const * | client_addr, | |
struct sockaddr const * | server_addr | |||
) |
Allows the plugin to initiate a transparent http connection.
This operates identically to TSHttpConnect except that it is treated as an intercepted transparent connection by the session and transaction state machines.
client_addr | the address that the resulting connection will be seen as coming from | |
server_addr | the address that the resulting connection will be seen as attempting to connect to when intercepted | |
vc | will be set to point to the new TSVConn on success. |
tsapi TSVConn TSHttpConnectWithPluginId | ( | struct sockaddr const * | addr, | |
char const * | tag, | |||
int64_t | id | |||
) |
Allows the plugin to initiate an http connection.
The TSVConn the plugin receives as the result of successful operates identically to one created through TSNetConnect. Aside from allowing the plugin to set the client ip and port for logging, the functionality of TSHttpConnect() is identical to connecting to localhost on the proxy port with TSNetConnect(). TSHttpConnect() is more efficient than TSNetConnect() to localhost since it avoids the overhead of passing the data through the operating system.
This returns a VConn that connected to the transaction.
addr | Target address of the origin server. | |
tag | A logging tag that can be accessed via the pitag field. May be NULL . | |
id | A logging id that can be access via the piid field. |
Referenced by FetchSM::httpConnect(), and TSHttpConnect().
tsapi int TSHttpCurrentActiveClientConnectionsGet | ( | void | ) |
Definition at line 5952 of file InkAPI.cc.
References http_current_active_client_connections_stat, and HTTP_READ_DYN_SUM.
tsapi int TSHttpCurrentCacheConnectionsGet | ( | void | ) |
Definition at line 5976 of file InkAPI.cc.
References http_current_cache_connections_stat, and HTTP_READ_DYN_SUM.
tsapi int TSHttpCurrentClientConnectionsGet | ( | void | ) |
Definition at line 5943 of file InkAPI.cc.
References http_current_client_connections_stat, and HTTP_READ_DYN_SUM.
tsapi int TSHttpCurrentIdleClientConnectionsGet | ( | void | ) |
Definition at line 5961 of file InkAPI.cc.
References http_current_active_client_connections_stat, http_current_client_connections_stat, and HTTP_READ_DYN_SUM.
tsapi int TSHttpCurrentServerConnectionsGet | ( | void | ) |
Definition at line 5985 of file InkAPI.cc.
References http_current_server_connections_stat, and HTTP_READ_GLOBAL_DYN_SUM.
tsapi const char* TSHttpEventNameLookup | ( | TSEvent | event | ) |
Return a string respresentation for a TSEvent value.
This is useful for plugin debugging.
event | the value of this TSHttpHookID |
Definition at line 8623 of file InkAPI.cc.
References HttpDebugNames::get_event_name().
Referenced by SDK_API_DEBUG_NAME_LOOKUPS().
tsapi TSReturnCode TSHttpHdrClone | ( | TSMBuffer | dest_bufp, | |
TSMBuffer | src_bufp, | |||
TSMLoc | src_hdr, | |||
TSMLoc * | locp | |||
) |
Definition at line 3484 of file InkAPI.cc.
References HDR_HEAP_OBJ_HTTP_HEADER, http_hdr_clone(), isWriteable(), HdrHeapObjImpl::m_type, sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), and TS_SUCCESS.
Referenced by SDK_API_TSHttpHdr().
tsapi TSReturnCode TSHttpHdrCopy | ( | TSMBuffer | dest_bufp, | |
TSMLoc | dest_offset, | |||
TSMBuffer | src_bufp, | |||
TSMLoc | src_offset | |||
) |
Copies the contents of the HTTP header located at src_loc within src_bufp to the HTTP header located at dest_loc within dest_bufp.
TSHttpHdrCopy() works correctly even if src_bufp and dest_bufp point to different marshal buffers. Make sure that you create the destination HTTP header before copying into it.
Note: TSHttpHdrCopy() appends the port number to the domain of the URL portion of the header. For example, a copy of http://www.example.com appears as http://www.example.com:80 in the destination buffer.
dest_bufp | marshal buffer to contain the copied header. | |
dest_offset | location of the copied header. | |
src_bufp | marshal buffer containing the source header. | |
src_offset | location of the source header. |
Definition at line 3515 of file InkAPI.cc.
References HDR_HEAP_OBJ_HTTP_HEADER, http_hdr_copy_onto(), isWriteable(), HTTPHdrImpl::m_polarity, HdrHeapObjImpl::m_type, sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), TS_SUCCESS, and TSHttpHdrTypeSet().
Referenced by SDK_API_TSHttpHdr().
Definition at line 3461 of file InkAPI.cc.
References HTTPHdr::create(), HTTP_TYPE_UNKNOWN, HdrHeapSDKHandle::m_heap, HTTPHdr::m_http, sdk_assert, sdk_sanity_check_mbuffer(), and TS_SUCCESS.
Referenced by SDK_API_TSHttpHdr(), and SDK_API_TSHttpHdrParse().
Destroys the HTTP header located at hdr_loc within the marshal buffer bufp.
Do not forget to release the handle hdr_loc with a call to TSHandleMLocRelease().
Definition at line 3472 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), and TS_SUCCESS.
Referenced by SDK_API_TSHttpHdr().
Definition at line 3623 of file InkAPI.cc.
References HDR_HEAP_OBJ_HTTP_HEADER, ink_assert, HTTPHdr::length_get(), HTTPHdr::m_http, HdrHeapObjImpl::m_type, sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), SET_HTTP_HDR, and TS_SUCCESS.
Referenced by SDK_API_TSHttpHdr().
Definition at line 3724 of file InkAPI.cc.
References HTTPHdr::method_get(), sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_null_ptr(), SET_HTTP_HDR, and TS_SUCCESS.
Referenced by SDK_API_TSHttpHdr().
tsapi TSReturnCode TSHttpHdrMethodSet | ( | TSMBuffer | bufp, | |
TSMLoc | offset, | |||
const char * | value, | |||
int | length | |||
) |
Definition at line 3737 of file InkAPI.cc.
References isWriteable(), HTTPHdr::method_set(), sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_null_ptr(), SET_HTTP_HDR, and TS_SUCCESS.
Referenced by SDK_API_TSHttpHdr().
tsapi TSParseResult TSHttpHdrParseReq | ( | TSHttpParser | parser, | |
TSMBuffer | bufp, | |||
TSMLoc | offset, | |||
const char ** | start, | |||
const char * | end | |||
) |
Parses an HTTP request header.
The HTTP header must have already been created, and must reside inside the marshal buffer bufp. The start argument points to the current position of the string buffer being parsed. The end argument points to one byte after the end of the buffer to be parsed. On return, TSHttpHdrParseReq() modifies start to point past the last character parsed.
It is possible to parse an HTTP request header a single byte at a time using repeated calls to TSHttpHdrParseReq(). As long as an error does not occur, the TSHttpHdrParseReq() function will consume that single byte and ask for more.
parser | parses the HTTP header. | |
bufp | marshal buffer containing the HTTP header to be parsed. | |
offset | location of the HTTP header within bufp. | |
start | both an input and output. On input, it points to the current position of the string buffer being parsed. On return, start is modified to point past the last character parsed. | |
end | points to one byte after the end of the buffer to be parsed. |
Definition at line 3583 of file InkAPI.cc.
References HDR_HEAP_OBJ_HTTP_HEADER, ink_assert, isWriteable(), HTTPHdr::m_http, HdrHeapObjImpl::m_type, HTTPHdr::parse_req(), sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_null_ptr(), SET_HTTP_HDR, TS_HTTP_TYPE_REQUEST, TS_SUCCESS, and TSHttpHdrTypeSet().
Referenced by SDK_API_TSHttpHdrParse().
tsapi TSParseResult TSHttpHdrParseResp | ( | TSHttpParser | parser, | |
TSMBuffer | bufp, | |||
TSMLoc | offset, | |||
const char ** | start, | |||
const char * | end | |||
) |
Definition at line 3603 of file InkAPI.cc.
References HDR_HEAP_OBJ_HTTP_HEADER, ink_assert, isWriteable(), HTTPHdr::m_http, HdrHeapObjImpl::m_type, HTTPHdr::parse_resp(), sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_null_ptr(), SET_HTTP_HDR, TS_HTTP_TYPE_RESPONSE, TS_SUCCESS, and TSHttpHdrTypeSet().
Referenced by SDK_API_TSHttpHdrParse().
tsapi void TSHttpHdrPrint | ( | TSMBuffer | bufp, | |
TSMLoc | offset, | |||
TSIOBuffer | iobufp | |||
) |
Definition at line 3548 of file InkAPI.cc.
References MIOBuffer::add_block(), IOBufferBlock::end(), MIOBuffer::fill(), MIOBuffer::get_current_block(), HDR_HEAP_OBJ_HTTP_HEADER, ink_assert, HTTPHdr::m_http, HdrHeapObjImpl::m_type, HTTPHdr::print(), sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_iocore_structure(), sdk_sanity_check_mbuffer(), SET_HTTP_HDR, TS_SUCCESS, and IOBufferBlock::write_avail().
Referenced by convert_http_hdr_to_string(), and SDK_API_TSHttpHdr().
Definition at line 3834 of file InkAPI.cc.
References HTTPHdr::reason_get(), sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_null_ptr(), SET_HTTP_HDR, and TS_SUCCESS.
Referenced by SDK_API_TSHttpHdr(), and SpdyNV::SpdyNV().
tsapi const char* TSHttpHdrReasonLookup | ( | TSHttpStatus | status | ) |
Definition at line 3874 of file InkAPI.cc.
References http_hdr_reason_lookup().
Referenced by SDK_API_TSHttpHdr().
tsapi TSReturnCode TSHttpHdrReasonSet | ( | TSMBuffer | bufp, | |
TSMLoc | offset, | |||
const char * | value, | |||
int | length | |||
) |
Definition at line 3847 of file InkAPI.cc.
References isWriteable(), HTTPHdr::reason_set(), sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_null_ptr(), SET_HTTP_HDR, and TS_SUCCESS.
Referenced by SDK_API_TSHttpHdr().
tsapi TSHttpStatus TSHttpHdrStatusGet | ( | TSMBuffer | bufp, | |
TSMLoc | offset | |||
) |
Definition at line 3801 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), SET_HTTP_HDR, HTTPHdr::status_get(), and TS_SUCCESS.
Referenced by SDK_API_TSHttpHdr(), SpdyNV::SpdyNV(), and transformable().
tsapi TSReturnCode TSHttpHdrStatusSet | ( | TSMBuffer | bufp, | |
TSMLoc | offset, | |||
TSHttpStatus | status | |||
) |
Definition at line 3813 of file InkAPI.cc.
References HDR_HEAP_OBJ_HTTP_HEADER, ink_assert, isWriteable(), HTTPHdr::m_http, HdrHeapObjImpl::m_type, sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), SET_HTTP_HDR, HTTPHdr::status_set(), and TS_SUCCESS.
Referenced by SDK_API_TSHttpHdr().
tsapi TSHttpType TSHttpHdrTypeGet | ( | TSMBuffer | bufp, | |
TSMLoc | offset | |||
) |
Definition at line 3636 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), SET_HTTP_HDR, TS_SUCCESS, and HTTPHdr::type_get().
Referenced by SDK_API_TSHttpHdr().
tsapi TSReturnCode TSHttpHdrTypeSet | ( | TSMBuffer | bufp, | |
TSMLoc | offset, | |||
TSHttpType | type | |||
) |
Definition at line 3650 of file InkAPI.cc.
References HDR_HEAP_OBJ_HTTP_HEADER, HTTP_TYPE_REQUEST, HTTP_TYPE_UNKNOWN, ink_assert, isWriteable(), HdrHeapSDKHandle::m_heap, HTTPHdr::m_http, HTTPHdrImpl::m_polarity, HdrHeapObjImpl::m_type, HTTPHdrImpl::req, sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), SET_HTTP_HDR, TS_HTTP_TYPE_RESPONSE, TS_HTTP_TYPE_UNKNOWN, TS_SUCCESS, HTTPHdrImpl::u, and url_create().
Referenced by SDK_API_TSHttpHdr(), TSHttpHdrCopy(), TSHttpHdrParseReq(), and TSHttpHdrParseResp().
tsapi TSReturnCode TSHttpHdrUrlGet | ( | TSMBuffer | bufp, | |
TSMLoc | offset, | |||
TSMLoc * | locp | |||
) |
Definition at line 3761 of file InkAPI.cc.
References HTTP_TYPE_REQUEST, HTTPHdrImpl::m_polarity, HTTPHdrImpl::req, sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), TS_SUCCESS, and HTTPHdrImpl::u.
Referenced by SDK_API_TSHttpHdr().
tsapi TSReturnCode TSHttpHdrUrlSet | ( | TSMBuffer | bufp, | |
TSMLoc | offset, | |||
TSMLoc | url | |||
) |
Definition at line 3776 of file InkAPI.cc.
References HDR_HEAP_OBJ_HTTP_HEADER, http_hdr_url_set(), isWriteable(), HdrHeapObjImpl::m_type, sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_url_handle(), and TS_SUCCESS.
Referenced by SDK_API_TSHttpHdr().
Definition at line 3688 of file InkAPI.cc.
References HTTPVersion::m_version, sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), SET_HTTP_HDR, TS_SUCCESS, and HTTPHdr::version_get().
Referenced by SDK_API_TSHttpHdr(), and SpdyNV::SpdyNV().
tsapi TSReturnCode TSHttpHdrVersionSet | ( | TSMBuffer | bufp, | |
TSMLoc | offset, | |||
int | ver | |||
) |
Definition at line 3701 of file InkAPI.cc.
References HDR_HEAP_OBJ_HTTP_HEADER, ink_assert, isWriteable(), HTTPHdr::m_http, HdrHeapObjImpl::m_type, sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), SET_HTTP_HDR, TS_SUCCESS, and HTTPHdr::version_set().
Referenced by SDK_API_TSHttpHdr().
tsapi void TSHttpHookAdd | ( | TSHttpHookID | id, | |
TSCont | contp | |||
) |
Definition at line 4379 of file InkAPI.cc.
References FeatureAPIHooks< ID, N >::append(), sdk_assert, sdk_sanity_check_continuation(), sdk_sanity_check_hook_id(), and TS_SUCCESS.
Referenced by altinfo_hook_handler(), SDK_API_HttpAltInfo(), SDK_API_HttpHookAdd(), SDK_API_HttpSsn(), SDK_API_HttpTxnCache(), SDK_API_HttpTxnTransform(), SDK_API_TSHttpConnectIntercept(), SDK_API_TSHttpConnectServerIntercept(), and PrefetchProcessor::start().
tsapi const char* TSHttpHookNameLookup | ( | TSHttpHookID | hook | ) |
Return a string respresentation for a TSHttpHookID value.
This is useful for plugin debugging.
hook | the value of this TSHttpHookID |
Definition at line 8617 of file InkAPI.cc.
References HttpDebugNames::get_api_hook_name().
Referenced by SDK_API_DEBUG_NAME_LOOKUPS().
tsapi TSReturnCode TSHttpIsInternalRequest | ( | TSHttpTxn | txnp | ) |
Definition at line 7403 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_txn(), TS_SUCCESS, TSHttpIsInternalSession(), and TSHttpTxnSsnGet().
tsapi TSReturnCode TSHttpIsInternalSession | ( | TSHttpSsn | ssnp | ) |
Definition at line 7387 of file InkAPI.cc.
References NetVConnection::get_is_internal_request(), HttpClientSession::get_netvc(), and TS_SUCCESS.
Referenced by TSHttpIsInternalRequest().
tsapi void TSHttpParserClear | ( | TSHttpParser | parser | ) |
Definition at line 3441 of file InkAPI.cc.
References http_parser_clear(), sdk_assert, sdk_sanity_check_http_parser(), and TS_SUCCESS.
Referenced by SDK_API_TSHttpHdrParse().
tsapi TSHttpParser TSHttpParserCreate | ( | void | ) |
Definition at line 3432 of file InkAPI.cc.
References ats_malloc(), and http_parser_init().
Referenced by SDK_API_TSHttpHdrParse().
tsapi void TSHttpParserDestroy | ( | TSHttpParser | parser | ) |
Definition at line 3448 of file InkAPI.cc.
References ats_free(), http_parser_clear(), sdk_assert, sdk_sanity_check_http_parser(), and TS_SUCCESS.
Referenced by SDK_API_TSHttpHdrParse().
tsapi const char* TSHttpServerStateNameLookup | ( | TSServerState | state | ) |
Return a string respresentation for a TSServerState value.
This is useful for plugin debugging.
state | the value of this TSServerState |
Definition at line 8611 of file InkAPI.cc.
References HttpDebugNames::get_server_state_name().
Referenced by SDK_API_DEBUG_NAME_LOOKUPS().
tsapi void* TSHttpSsnArgGet | ( | TSHttpSsn | ssnp, | |
int | arg_idx | |||
) |
Definition at line 5627 of file InkAPI.cc.
References ProxyClientSession::get_user_arg(), HTTP_SSN_TXN_MAX_USER_ARG, sdk_assert, sdk_sanity_check_http_ssn(), and TS_SUCCESS.
tsapi void TSHttpSsnArgSet | ( | TSHttpSsn | ssnp, | |
int | arg_idx, | |||
void * | arg | |||
) |
Definition at line 5616 of file InkAPI.cc.
References HTTP_SSN_TXN_MAX_USER_ARG, sdk_assert, sdk_sanity_check_http_ssn(), ProxyClientSession::set_user_arg(), and TS_SUCCESS.
tsapi struct sockaddr const* TSHttpSsnClientAddrGet | ( | TSHttpSsn | ssnp | ) | [read] |
Definition at line 5191 of file InkAPI.cc.
References HttpClientSession::get_netvc(), and NetVConnection::get_remote_addr().
Referenced by TSHttpTxnClientAddrGet().
tsapi TSReturnCode TSHttpSsnClientFdGet | ( | TSHttpSsn | ssnp, | |
int * | fdp | |||
) |
Definition at line 6905 of file InkAPI.cc.
References HttpClientSession::get_netvc(), NetVConnection::get_socket(), sdk_assert, sdk_sanity_check_null_ptr(), and TS_SUCCESS.
Referenced by TSHttpTxnClientFdGet().
tsapi int TSHttpSsnDebugGet | ( | TSHttpSsn | ssnp, | |
int * | on | |||
) |
Returns the transaction specific debugging flag for this client session.
txnp | Client session to check. |
tsapi void TSHttpSsnDebugSet | ( | TSHttpSsn | ssnp, | |
int | on | |||
) |
Set the session specific debugging flag for this client session.
When turned on, internal debug messages related to this session and all transactions in the session will be written even if the debug tag isn't on.
ssnp | Client session to change. | |
on | set to 1 to turn on, 0 to turn off. |
Definition at line 5736 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_http_ssn(), and TS_SUCCESS.
tsapi void TSHttpSsnHookAdd | ( | TSHttpSsn | ssnp, | |
TSHttpHookID | id, | |||
TSCont | contp | |||
) |
Definition at line 4412 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_continuation(), sdk_sanity_check_hook_id(), sdk_sanity_check_http_ssn(), HttpClientSession::ssn_hook_append(), and TS_SUCCESS.
Referenced by ssn_handler().
tsapi struct sockaddr const* TSHttpSsnIncomingAddrGet | ( | TSHttpSsn | ssnp | ) | [read] |
Definition at line 5212 of file InkAPI.cc.
References NetVConnection::get_local_addr(), and HttpClientSession::get_netvc().
Referenced by TSHttpTxnIncomingAddrGet().
Definition at line 4454 of file InkAPI.cc.
References ET_NET, eventProcessor, Continuation::handleEvent(), Continuation::mutex, MUTEX_TRY_LOCK, REGULAR, EventProcessor::schedule_imm(), sdk_assert, sdk_sanity_check_http_ssn(), this_ethread(), TS_SUCCESS, and EThread::tt.
Referenced by ssn_handler().
tsapi void* TSHttpSsnSSLConnectionGet | ( | TSHttpSsn | ssnp | ) |
Get SSL object of this session.
Retrieves the SSL object of the SSL connection.
Definition at line 5173 of file InkAPI.cc.
References HttpClientSession::get_netvc(), sdk_assert, sdk_sanity_check_null_ptr(), SSLNetVConnection::ssl, and TS_SUCCESS.
tsapi int TSHttpSsnTransactionCount | ( | TSHttpSsn | ssnp | ) |
Definition at line 4423 of file InkAPI.cc.
References HttpClientSession::get_transact_count(), sdk_assert, sdk_sanity_check_http_ssn(), and TS_SUCCESS.
tsapi TSReturnCode TSHttpTxnAborted | ( | TSHttpTxn | txnp | ) |
Check if transaction was aborted (due client/server errors etc.
)
Definition at line 5074 of file InkAPI.cc.
References HttpTransact::ABORTED, HttpTransact::State::current, sdk_assert, sdk_sanity_check_txn(), HttpTransact::State::squid_codes, SQUID_LOG_ERR_CLIENT_ABORT, SQUID_LOG_TCP_SWAPFAIL, HttpSM::t_state, and TS_SUCCESS.
tsapi void TSHttpTxnActiveTimeoutSet | ( | TSHttpTxn | txnp, | |
int | timeout | |||
) |
timeout is in msec overrides as proxy.config.http.transaction_active_timeout_out
Definition at line 4978 of file InkAPI.cc.
References HttpTransact::State::api_txn_active_timeout_value, sdk_assert, sdk_sanity_check_txn(), and TS_SUCCESS.
tsapi void* TSHttpTxnArgGet | ( | TSHttpTxn | txnp, | |
int | arg_idx | |||
) |
Definition at line 5606 of file InkAPI.cc.
References HTTP_SSN_TXN_MAX_USER_ARG, sdk_assert, sdk_sanity_check_txn(), HttpSM::t_state, TS_SUCCESS, and HttpTransact::State::user_args.
tsapi void TSHttpTxnArgSet | ( | TSHttpTxn | txnp, | |
int | arg_idx, | |||
void * | arg | |||
) |
Definition at line 5596 of file InkAPI.cc.
References HTTP_SSN_TXN_MAX_USER_ARG, sdk_assert, sdk_sanity_check_txn(), HttpSM::t_state, TS_SUCCESS, and HttpTransact::State::user_args.
tsapi int TSHttpTxnBackgroundFillStarted | ( | TSHttpTxn | txnp | ) |
Definition at line 8574 of file InkAPI.cc.
References HttpSM::background_fill, BACKGROUND_FILL_STARTED, sdk_assert, sdk_sanity_check_txn(), and TS_SUCCESS.
tsapi TSReturnCode TSHttpTxnCachedReqGet | ( | TSHttpTxn | txnp, | |
TSMBuffer * | bufp, | |||
TSMLoc * | offset | |||
) |
Definition at line 4642 of file InkAPI.cc.
References Arena::alloc(), HttpTransact::State::arena, HttpTransact::State::cache_info, HttpTransact::State::cache_req_hdr_heap_handle, HdrHeapSDKHandle::m_heap, HTTPHdr::m_http, sdk_assert, sdk_sanity_check_mbuffer(), sdk_sanity_check_null_ptr(), sdk_sanity_check_txn(), HttpSM::t_state, TS_SUCCESS, HTTPHdr::valid(), and HTTPInfo::valid().
Referenced by cache_hook_handler().
tsapi TSReturnCode TSHttpTxnCachedRespGet | ( | TSHttpTxn | txnp, | |
TSMBuffer * | bufp, | |||
TSMLoc * | offset | |||
) |
Definition at line 4680 of file InkAPI.cc.
References Arena::alloc(), HttpTransact::State::arena, HttpTransact::State::cache_info, HttpTransact::State::cache_resp_hdr_heap_handle, HdrHeapSDKHandle::m_heap, HTTPHdr::m_http, sdk_assert, sdk_sanity_check_mbuffer(), sdk_sanity_check_null_ptr(), sdk_sanity_check_txn(), HttpSM::t_state, TS_SUCCESS, HTTPHdr::valid(), and HTTPInfo::valid().
Referenced by cache_hook_handler().
tsapi TSReturnCode TSHttpTxnCachedRespModifiableGet | ( | TSHttpTxn | txnp, | |
TSMBuffer * | bufp, | |||
TSMLoc * | offset | |||
) |
Definition at line 4719 of file InkAPI.cc.
References HttpTransact::State::api_modifiable_cached_resp, HttpTransact::State::cache_info, HTTPInfo::create(), ink_assert, HTTPHdr::m_http, HTTPInfo::response_get(), HTTPInfo::response_set(), sdk_assert, sdk_sanity_check_mbuffer(), sdk_sanity_check_null_ptr(), sdk_sanity_check_txn(), HttpSM::t_state, TS_SUCCESS, HTTPHdr::valid(), and HTTPInfo::valid().
tsapi TSReturnCode TSHttpTxnCacheLookupStatusGet | ( | TSHttpTxn | txnp, | |
int * | lookup_status | |||
) |
Definition at line 4752 of file InkAPI.cc.
References HttpTransact::CACHE_LOOKUP_DOC_BUSY, HttpTransact::CACHE_LOOKUP_HIT_FRESH, HttpTransact::CACHE_LOOKUP_HIT_STALE, HttpTransact::CACHE_LOOKUP_HIT_WARNING, HttpTransact::CACHE_LOOKUP_MISS, HttpTransact::CACHE_LOOKUP_NONE, HttpTransact::State::cache_lookup_result, HttpTransact::CACHE_LOOKUP_SKIPPED, sdk_assert, sdk_sanity_check_null_ptr(), sdk_sanity_check_txn(), HttpSM::t_state, and TS_SUCCESS.
Referenced by cache_hook_handler(), and PrefetchPlugin().
tsapi TSReturnCode TSHttpTxnCacheLookupStatusSet | ( | TSHttpTxn | txnp, | |
int | cachelookup | |||
) |
Definition at line 4798 of file InkAPI.cc.
References HttpTransact::State::api_cleanup_cache_read, HttpTransact::CACHE_LOOKUP_MISS, HttpTransact::State::cache_lookup_result, ink_assert, sdk_assert, sdk_sanity_check_txn(), HttpSM::t_state, HttpTransact::State::transact_return_point, TS_CACHE_LOOKUP_HIT_FRESH, TS_CACHE_LOOKUP_HIT_STALE, TS_CACHE_LOOKUP_MISS, and TS_SUCCESS.
tsapi TSReturnCode TSHttpTxnCacheLookupUrlGet | ( | TSHttpTxn | txnp, | |
TSMBuffer | bufp, | |||
TSMLoc | obj | |||
) |
Definition at line 4834 of file InkAPI.cc.
References HttpTransact::State::cache_info, URL::copy(), HdrHeapSDKHandle::m_heap, URL::m_url_impl, sdk_assert, sdk_sanity_check_mbuffer(), sdk_sanity_check_txn(), sdk_sanity_check_url_handle(), HttpSM::t_state, TS_ERROR, TS_SUCCESS, and URL::valid().
tsapi struct sockaddr const* TSHttpTxnClientAddrGet | ( | TSHttpTxn | txnp | ) | [read] |
Get client address for transaction txnp.
Retrieves the socket address of the remote client that has connected to Traffic Server for transaction txnp. The return structure is the generic socket address storage in order to be address-family agnostic. The user of this function can then go on to do the appropriate thing with the type specified in the ss_family field of the structure whether that be for IPv4, IPv6, or any other address family.
Definition at line 5203 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_txn(), TS_SUCCESS, TSHttpSsnClientAddrGet(), and TSHttpTxnSsnGet().
Referenced by checkHttpTxnClientAddrGet(), and checkHttpTxnClientIPGet().
tsapi TSReturnCode TSHttpTxnClientFdGet | ( | TSHttpTxn | txnp, | |
int * | fdp | |||
) |
Definition at line 6922 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_null_ptr(), sdk_sanity_check_txn(), TS_SUCCESS, TSHttpSsnClientFdGet(), and TSHttpTxnSsnGet().
tsapi void TSHttpTxnClientIncomingPortSet | ( | TSHttpTxn | txnp, | |
int | port | |||
) |
Definition at line 5258 of file InkAPI.cc.
References HttpTransact::State::client_info, sdk_assert, sdk_sanity_check_txn(), HttpSM::t_state, and TS_SUCCESS.
tsapi TSReturnCode TSHttpTxnClientPacketMarkSet | ( | TSHttpTxn | txnp, | |
int | mark | |||
) |
Change packet firewall mark for the client side connection.
Definition at line 5322 of file InkAPI.cc.
References NetVConnection::apply_options(), HttpClientSession::get_netvc(), NetVConnection::options, NetVCOptions::packet_mark, sdk_assert, sdk_sanity_check_txn(), TS_SUCCESS, and HttpSM::ua_session.
tsapi TSReturnCode TSHttpTxnClientPacketTosSet | ( | TSHttpTxn | txnp, | |
int | tos | |||
) |
Change packet TOS for the client side connection.
Definition at line 5364 of file InkAPI.cc.
References NetVConnection::apply_options(), HttpClientSession::get_netvc(), NetVConnection::options, NetVCOptions::packet_tos, sdk_assert, sdk_sanity_check_txn(), TS_SUCCESS, and HttpSM::ua_session.
tsapi int64_t TSHttpTxnClientReqBodyBytesGet | ( | TSHttpTxn | txnp | ) |
Definition at line 5759 of file InkAPI.cc.
References HttpSM::client_request_body_bytes, sdk_assert, sdk_sanity_check_txn(), and TS_SUCCESS.
tsapi TSReturnCode TSHttpTxnClientReqGet | ( | TSHttpTxn | txnp, | |
TSMBuffer * | bufp, | |||
TSMLoc * | offset | |||
) |
Definition at line 4528 of file InkAPI.cc.
References HttpTransact::State::hdr_info, HTTPHdr::m_http, HTTPHdr::mark_target_dirty(), sdk_assert, sdk_sanity_check_mbuffer(), sdk_sanity_check_null_ptr(), sdk_sanity_check_txn(), HttpSM::t_state, TS_SUCCESS, and HTTPHdr::valid().
Referenced by checkHttpTxnClientReqGet(), get_request_id(), and transform_hook_handler().
tsapi int TSHttpTxnClientReqHdrBytesGet | ( | TSHttpTxn | txnp | ) |
Definition at line 5750 of file InkAPI.cc.
References HttpSM::client_request_hdr_bytes, sdk_assert, sdk_sanity_check_txn(), and TS_SUCCESS.
tsapi int64_t TSHttpTxnClientRespBodyBytesGet | ( | TSHttpTxn | txnp | ) |
Definition at line 5813 of file InkAPI.cc.
References HttpSM::client_response_body_bytes, sdk_assert, sdk_sanity_check_txn(), and TS_SUCCESS.
tsapi TSReturnCode TSHttpTxnClientRespGet | ( | TSHttpTxn | txnp, | |
TSMBuffer * | bufp, | |||
TSMLoc * | offset | |||
) |
Definition at line 4581 of file InkAPI.cc.
References HttpTransact::State::hdr_info, HTTPHdr::m_http, sdk_assert, sdk_sanity_check_mbuffer(), sdk_sanity_check_null_ptr(), sdk_sanity_check_txn(), HttpSM::t_state, TS_SUCCESS, and HTTPHdr::valid().
Referenced by checkHttpTxnClientRespGet().
tsapi int TSHttpTxnClientRespHdrBytesGet | ( | TSHttpTxn | txnp | ) |
Definition at line 5804 of file InkAPI.cc.
References HttpSM::client_response_hdr_bytes, sdk_assert, sdk_sanity_check_txn(), and TS_SUCCESS.
tsapi TSReturnCode TSHttpTxnConfigFind | ( | const char * | name, | |
int | length, | |||
TSOverridableConfigKey * | conf, | |||
TSRecordDataType * | type | |||
) |
Definition at line 8041 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_null_ptr(), TS_CONFIG_NULL, TS_ERROR, and TS_SUCCESS.
Referenced by SDK_API_OVERRIDABLE_CONFIGS().
tsapi TSReturnCode TSHttpTxnConfigFloatGet | ( | TSHttpTxn | txnp, | |
TSOverridableConfigKey | conf, | |||
TSMgmtFloat * | value | |||
) |
Definition at line 7953 of file InkAPI.cc.
References _conf_to_memberp(), OVERRIDABLE_TYPE_FLOAT, sdk_assert, sdk_sanity_check_null_ptr(), sdk_sanity_check_txn(), and TS_SUCCESS.
Referenced by SDK_API_OVERRIDABLE_CONFIGS().
tsapi TSReturnCode TSHttpTxnConfigFloatSet | ( | TSHttpTxn | txnp, | |
TSOverridableConfigKey | conf, | |||
TSMgmtFloat | value | |||
) |
Definition at line 7930 of file InkAPI.cc.
References _conf_to_memberp(), OVERRIDABLE_TYPE_FLOAT, sdk_assert, sdk_sanity_check_txn(), HttpTransact::State::setup_per_txn_configs(), HttpSM::t_state, TS_SUCCESS, and HttpTransact::State::txn_conf.
Referenced by SDK_API_OVERRIDABLE_CONFIGS().
tsapi TSReturnCode TSHttpTxnConfigIntGet | ( | TSHttpTxn | txnp, | |
TSOverridableConfigKey | conf, | |||
TSMgmtInt * | value | |||
) |
Definition at line 7886 of file InkAPI.cc.
References _conf_to_memberp(), OVERRIDABLE_TYPE_BYTE, OVERRIDABLE_TYPE_INT, sdk_assert, sdk_sanity_check_null_ptr(), sdk_sanity_check_txn(), OverridableHttpConfigParams::server_session_sharing_match, OverridableHttpConfigParams::server_session_sharing_pool, HttpSM::t_state, TS_CONFIG_HTTP_SHARE_SERVER_SESSIONS, TS_SERVER_SESSION_SHARING_MATCH_BOTH, TS_SERVER_SESSION_SHARING_MATCH_NONE, TS_SERVER_SESSION_SHARING_POOL_GLOBAL, TS_SERVER_SESSION_SHARING_POOL_THREAD, TS_SUCCESS, and HttpTransact::State::txn_conf.
Referenced by SDK_API_OVERRIDABLE_CONFIGS().
tsapi TSReturnCode TSHttpTxnConfigIntSet | ( | TSHttpTxn | txnp, | |
TSOverridableConfigKey | conf, | |||
TSMgmtInt | value | |||
) |
Definition at line 7837 of file InkAPI.cc.
References _conf_to_memberp(), OVERRIDABLE_TYPE_BYTE, OVERRIDABLE_TYPE_INT, sdk_assert, sdk_sanity_check_txn(), OverridableHttpConfigParams::server_session_sharing_match, OverridableHttpConfigParams::server_session_sharing_pool, HttpTransact::State::setup_per_txn_configs(), HttpSM::t_state, TS_CONFIG_HTTP_SHARE_SERVER_SESSIONS, TS_SUCCESS, and HttpTransact::State::txn_conf.
Referenced by SDK_API_OVERRIDABLE_CONFIGS(), TSHttpTxnServerPacketMarkSet(), and TSHttpTxnServerPacketTosSet().
tsapi TSReturnCode TSHttpTxnConfigStringGet | ( | TSHttpTxn | txnp, | |
TSOverridableConfigKey | conf, | |||
const char ** | value, | |||
int * | length | |||
) |
Definition at line 8013 of file InkAPI.cc.
References OverridableHttpConfigParams::global_user_agent_header, OverridableHttpConfigParams::global_user_agent_header_size, OverridableHttpConfigParams::proxy_response_server_string, OverridableHttpConfigParams::proxy_response_server_string_len, sdk_assert, sdk_sanity_check_null_ptr(), sdk_sanity_check_txn(), HttpSM::t_state, TS_CONFIG_HTTP_GLOBAL_USER_AGENT_HEADER, TS_CONFIG_HTTP_RESPONSE_SERVER_STR, TS_SUCCESS, and HttpTransact::State::txn_conf.
Referenced by SDK_API_OVERRIDABLE_CONFIGS().
tsapi TSReturnCode TSHttpTxnConfigStringSet | ( | TSHttpTxn | txnp, | |
TSOverridableConfigKey | conf, | |||
const char * | value, | |||
int | length | |||
) |
Definition at line 7973 of file InkAPI.cc.
References OverridableHttpConfigParams::global_user_agent_header, OverridableHttpConfigParams::global_user_agent_header_size, OverridableHttpConfigParams::proxy_response_server_string, OverridableHttpConfigParams::proxy_response_server_string_len, sdk_assert, sdk_sanity_check_txn(), HttpTransact::State::setup_per_txn_configs(), HttpSM::t_state, TS_CONFIG_HTTP_GLOBAL_USER_AGENT_HEADER, TS_CONFIG_HTTP_RESPONSE_SERVER_STR, TS_SUCCESS, and HttpTransact::State::txn_conf.
Referenced by SDK_API_OVERRIDABLE_CONFIGS().
tsapi void TSHttpTxnConnectTimeoutSet | ( | TSHttpTxn | txnp, | |
int | timeout | |||
) |
timeout is in msec overrides as proxy.config.http.connect_attempts_timeout
Definition at line 4991 of file InkAPI.cc.
References HttpTransact::State::api_txn_connect_timeout_value, sdk_assert, sdk_sanity_check_txn(), and TS_SUCCESS.
tsapi int TSHttpTxnDebugGet | ( | TSHttpTxn | txnp | ) |
Returns the transaction specific debugging flag for this transaction.
txnp | transaction to check. |
Definition at line 5729 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_txn(), and TS_SUCCESS.
tsapi void TSHttpTxnDebugSet | ( | TSHttpTxn | txnp, | |
int | on | |||
) |
Set the transaction specific debugging flag for this transaction.
When turned on, internal debug messages related to this transaction will be written even if the debug tag isn't on.
txnp | transaction to change. | |
on | set to 1 to turn on, 0 to turn off. |
Definition at line 5722 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_txn(), and TS_SUCCESS.
tsapi void TSHttpTxnDNSTimeoutSet | ( | TSHttpTxn | txnp, | |
int | timeout | |||
) |
timeout is in msec overrides as proxy.config.dns.lookup_timeout
Definition at line 5004 of file InkAPI.cc.
References HttpTransact::State::api_txn_dns_timeout_value, sdk_assert, sdk_sanity_check_txn(), and TS_SUCCESS.
tsapi char* TSHttpTxnEffectiveUrlStringGet | ( | TSHttpTxn | txnp, | |
int * | length | |||
) |
Get the effective URL for the transaction.
The effective URL is the URL taking in to account both the explicit URL in the request and the HOST field.
A possibly non-null terminated string is returned.
TSfree
. length | String length return, may be NULL . |
Definition at line 4571 of file InkAPI.cc.
References HttpTransact::State::hdr_info, sdk_assert, sdk_sanity_check_null_ptr(), sdk_sanity_check_txn(), HttpSM::t_state, and TS_SUCCESS.
tsapi void TSHttpTxnErrorBodySet | ( | TSHttpTxn | txnp, | |
char * | buf, | |||
size_t | buflength, | |||
char * | mimetype | |||
) |
Sets an error type body to a transaction.
Note that both string arguments must be allocated with TSmalloc() or TSstrdup(). The mimetype argument is optional, if not provided it defaults to "text/html". Sending an emptry string would prevent setting a content type header (but that is not adviced).
txnp | HTTP transaction whose parent proxy to get. | |
buf | The body message (must be heap allocated). | |
buflength | Length of the body message. | |
mimetype | The MIME type to set the response to (can be NULL, but must be heap allocated if non-NULL). |
Definition at line 5407 of file InkAPI.cc.
References ats_free(), HttpTransact::State::free_internal_msg_buffer(), HttpTransact::State::internal_msg_buffer, HttpTransact::State::internal_msg_buffer_fast_allocator_size, HttpTransact::State::internal_msg_buffer_size, HttpTransact::State::internal_msg_buffer_type, sdk_assert, sdk_sanity_check_txn(), HttpSM::t_state, and TS_SUCCESS.
Referenced by ssn_handler().
tsapi TSReturnCode TSHttpTxnFollowRedirect | ( | TSHttpTxn | txnp, | |
int | on | |||
) |
This API informs the core to try to follow redirections (e.g.
301 responses. The new URL would be provided in the standard Location header.
txnp | the transaction pointer | |
on | turn this on or off (0 or 1) |
TS_SUCCESS
if it succeeded Definition at line 7137 of file InkAPI.cc.
References HttpSM::enable_redirection, sdk_assert, sdk_sanity_check_txn(), and TS_SUCCESS.
tsapi void TSHttpTxnHookAdd | ( | TSHttpTxn | txnp, | |
TSHttpHookID | id, | |||
TSCont | contp | |||
) |
Definition at line 4479 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_continuation(), sdk_sanity_check_hook_id(), sdk_sanity_check_txn(), TS_SUCCESS, and HttpSM::txn_hook_append().
Referenced by check_n_attach_prefetch_transform(), ssn_handler(), transform_add(), and transform_hook_handler().
tsapi struct sockaddr const* TSHttpTxnIncomingAddrGet | ( | TSHttpTxn | txnp | ) | [read] |
Get the incoming address.
Definition at line 5224 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_txn(), TS_SUCCESS, TSHttpSsnIncomingAddrGet(), and TSHttpTxnSsnGet().
Referenced by checkHttpTxnIncomingAddrGet().
Allows a plugin take over the servicing of the request as though it was the origin server.
contp will be sent TS_EVENT_NET_ACCEPT. The edata passed with TS_NET_EVENT_ACCEPT is an TSVConn just as it would be for a normal accept. The plugin must act as if it is an http server and read the http request and body off the TSVConn and send an http response header and body.
TSHttpTxnIntercept() must be called be called from only TS_HTTP_READ_REQUEST_HOOK. Using TSHttpTxnIntercept will bypass the Traffic Server cache. If response sent by the plugin should be cached, use TSHttpTxnServerIntercept() instead. TSHttpTxnIntercept() primary use is allow plugins to serve data about their functioning directly.
TSHttpTxnIntercept() must only be called once per transaction.
contp | continuation called to handle the interception. | |
txnp | transaction to be intercepted. |
Definition at line 6379 of file InkAPI.cc.
References PluginVCCore::alloc(), Continuation::mutex, HttpSM::plugin_tunnel, HttpSM::plugin_tunnel_type, sdk_assert, sdk_sanity_check_continuation(), sdk_sanity_check_null_ptr(), sdk_sanity_check_txn(), PluginVCCore::set_accept_cont(), and TS_SUCCESS.
Referenced by cont_test_handler().
Test whether a request / response header pair would be cacheable under the current configuration.
This would typically be used in TS_HTTP_READ_RESPONSE_HDR_HOOK, when you have both the client request and server response ready.
txnp | the transaction pointer | |
request | the client request header. If NULL, use the transactions client request. | |
response | the server response header. If NULL, use the transactions origin response. |
Definition at line 8583 of file InkAPI.cc.
References HttpTransact::State::hdr_info, HttpTransact::is_response_cacheable(), sdk_assert, sdk_sanity_check_mbuffer(), sdk_sanity_check_txn(), HttpSM::t_state, TS_SUCCESS, and HTTPHdr::valid().
tsapi TSReturnCode TSHttpTxnMilestoneGet | ( | TSHttpTxn | txnp, | |
TSMilestonesType | milestone, | |||
TSHRTime * | time | |||
) |
Return the particular milestone timer for the transaction.
If 0 is returned, it means the transaction has not yet reached that milestone. Asking for an "unknown" milestone is an error.
txnp | the transaction pointer | |
milestone | the requested milestone timer was created. | |
time | a pointer to a TSHRTime where we will store the timer |
TS_SUCCESS
if the milestone is supported, TS_ERROR otherwise tsapi struct sockaddr const* TSHttpTxnNextHopAddrGet | ( | TSHttpTxn | txnp | ) | [read] |
Get the next hop address.
Return zero if the server structure is not yet constructed.
Definition at line 5288 of file InkAPI.cc.
References HttpTransact::State::current, sdk_assert, sdk_sanity_check_txn(), HttpSM::t_state, and TS_SUCCESS.
Referenced by checkHttpTxnNextHopIPGet().
tsapi void TSHttpTxnNoActivityTimeoutSet | ( | TSHttpTxn | txnp, | |
int | timeout | |||
) |
timeout is in msec overrides as proxy.config.http.transaction_no_activity_timeout_out
Definition at line 5019 of file InkAPI.cc.
References HttpTransact::State::api_txn_no_activity_timeout_value, sdk_assert, sdk_sanity_check_txn(), and TS_SUCCESS.
tsapi TSReturnCode TSHttpTxnOutgoingAddrSet | ( | TSHttpTxn | txnp, | |
struct sockaddr const * | addr | |||
) |
Definition at line 5269 of file InkAPI.cc.
References IpAddr::assign(), ats_ip_port_host_order(), ats_is_ip4(), ats_is_ip6(), IpAddr::invalidate(), HttpClientSession::outbound_ip4, HttpClientSession::outbound_ip6, HttpClientSession::outbound_port, sdk_assert, sdk_sanity_check_txn(), TS_SUCCESS, and HttpSM::ua_session.
tsapi TSReturnCode TSHttpTxnOutgoingTransparencySet | ( | TSHttpTxn | txnp, | |
int | flag | |||
) |
Definition at line 5304 of file InkAPI.cc.
References HttpClientSession::f_outbound_transparent, sdk_sanity_check_txn(), TS_SUCCESS, and HttpSM::ua_session.
tsapi TSReturnCode TSHttpTxnParentProxyGet | ( | TSHttpTxn | txnp, | |
char ** | hostname, | |||
int * | port | |||
) |
Retrieves the parent proxy hostname and port, if parent proxying is enabled.
If parent proxying is not enabled, TSHttpTxnParentProxyGet() sets hostname to NULL and port to -1.
txnp | HTTP transaction whose parent proxy to get. | |
hostname | of the parent proxy. | |
port | parent proxy's port. |
Definition at line 5449 of file InkAPI.cc.
References HttpTransact::State::api_info, _HttpApiInfo::parent_proxy_name, _HttpApiInfo::parent_proxy_port, sdk_assert, sdk_sanity_check_txn(), HttpSM::t_state, and TS_SUCCESS.
Referenced by checkHttpTxnParentProxy().
tsapi void TSHttpTxnParentProxySet | ( | TSHttpTxn | txnp, | |
char * | hostname, | |||
int | port | |||
) |
Sets the parent proxy name and port.
The string hostname is copied into the TSHttpTxn; you can modify or delete the string after calling TSHttpTxnParentProxySet().
txnp | HTTP transaction whose parent proxy to set. | |
hostname | parent proxy host name string. | |
port | parent proxy port to set. |
Definition at line 5462 of file InkAPI.cc.
References HttpTransact::State::api_info, HttpTransact::State::arena, _HttpApiInfo::parent_proxy_name, _HttpApiInfo::parent_proxy_port, sdk_assert, sdk_sanity_check_null_ptr(), sdk_sanity_check_txn(), Arena::str_store(), HttpSM::t_state, and TS_SUCCESS.
Referenced by checkHttpTxnParentProxy().
tsapi TSReturnCode TSHttpTxnPristineUrlGet | ( | TSHttpTxn | txnp, | |
TSMBuffer * | bufp, | |||
TSMLoc * | url_loc | |||
) |
Definition at line 4550 of file InkAPI.cc.
References HttpTransact::State::hdr_info, URL::m_url_impl, HttpTransact::State::pristine_url, sdk_assert, sdk_sanity_check_mbuffer(), sdk_sanity_check_null_ptr(), sdk_sanity_check_txn(), HttpSM::t_state, TS_SUCCESS, and HTTPHdr::valid().
tsapi TSReturnCode TSHttpTxnPrivateSessionSet | ( | TSHttpTxn | txnp, | |
int | private_session | |||
) |
Definition at line 8465 of file InkAPI.cc.
References sdk_sanity_check_txn(), HttpSM::set_server_session_private(), and TS_SUCCESS.
tsapi int64_t TSHttpTxnPushedRespBodyBytesGet | ( | TSHttpTxn | txnp | ) |
Definition at line 5831 of file InkAPI.cc.
References HttpSM::pushed_response_body_bytes, sdk_assert, sdk_sanity_check_txn(), and TS_SUCCESS.
tsapi int TSHttpTxnPushedRespHdrBytesGet | ( | TSHttpTxn | txnp | ) |
Definition at line 5822 of file InkAPI.cc.
References HttpSM::pushed_response_hdr_bytes, sdk_assert, sdk_sanity_check_txn(), and TS_SUCCESS.
tsapi int TSHttpTxnRedirectRetries | ( | TSHttpTxn | txnp | ) |
Return the number of redirection retries we have done.
This starts off at zero, and can be used to select different URLs based on which attempt this is. This can be useful for example when providing a list of URLs to try, and do so in order until one succeeds.
txnp | the transaction pointer |
Definition at line 7213 of file InkAPI.cc.
References HttpSM::redirection_tries, sdk_assert, sdk_sanity_check_txn(), and TS_SUCCESS.
tsapi const char* TSHttpTxnRedirectUrlGet | ( | TSHttpTxn | txnp, | |
int * | url_len_ptr | |||
) |
Return the current (if set) redirection URL string.
This is still owned by the core, and must not be free'd.
txnp | the transaction pointer | |
url_len_ptr | a pointer to where the URL length is to be stored |
Definition at line 7195 of file InkAPI.cc.
References HttpSM::redirect_url, HttpSM::redirect_url_len, sdk_assert, sdk_sanity_check_txn(), and TS_SUCCESS.
Referenced by TSRedirectUrlGet().
tsapi void TSHttpTxnRedirectUrlSet | ( | TSHttpTxn | txnp, | |
const char * | url, | |||
const int | url_len | |||
) |
This is a generalization of the TSHttpTxnFollowRedirect(), but gives finer control over the behavior.
Instead of using the Location: header for the new destination, this API takes the new URL as a parameter. Calling this API transfers the ownership of the URL from the plugin to the core, so you must make sure it is heap allocated, and that you do not free it.
Calling this API implicitly also enables the "Follow Redirect" feature, so there is no rason to call TSHttpTxnFollowRedirect() as well.
txnp | the transaction pointer | |
url | a heap allocated string with the URL | |
url_len | the length of the URL |
Definition at line 7149 of file InkAPI.cc.
References ats_free(), HttpSM::enable_redirection, HttpSM::redirect_url, HttpSM::redirect_url_len, sdk_assert, sdk_sanity_check_null_ptr(), sdk_sanity_check_txn(), and TS_SUCCESS.
Notifies the HTTP transaction txnp that the plugin is finished processing the current hook.
The plugin tells the transaction to either continue (TS_EVENT_HTTP_CONTINUE) or stop (TS_EVENT_HTTP_ERROR).
You must always reenable the HTTP transaction after the processing of each transaction event. However, never reenable twice. Reenabling twice is a serious error.
txnp | transaction to be reenabled. | |
event | tells the transaction how to continue:
|
Definition at line 5517 of file InkAPI.cc.
References ET_NET, eventProcessor, Continuation::mutex, MUTEX_TRY_LOCK, REGULAR, EventProcessor::schedule_imm(), sdk_assert, sdk_sanity_check_txn(), HttpSM::state_api_callback(), this_ethread(), TS_SUCCESS, and EThread::tt.
Referenced by altinfo_hook_handler(), cache_hook_handler(), cont_test_handler(), mytest_handler(), PrefetchPlugin(), ssn_handler(), and transform_hook_handler().
tsapi void TSHttpTxnReqCacheableSet | ( | TSHttpTxn | txnp, | |
int | flag | |||
) |
Definition at line 5097 of file InkAPI.cc.
References HttpTransact::State::api_req_cacheable, sdk_assert, sdk_sanity_check_txn(), HttpSM::t_state, and TS_SUCCESS.
tsapi void TSHttpTxnRespCacheableSet | ( | TSHttpTxn | txnp, | |
int | flag | |||
) |
Definition at line 5106 of file InkAPI.cc.
References HttpTransact::State::api_resp_cacheable, sdk_assert, sdk_sanity_check_txn(), HttpSM::t_state, and TS_SUCCESS.
tsapi struct sockaddr const* TSHttpTxnServerAddrGet | ( | TSHttpTxn | txnp | ) | [read] |
Get the origin server address.
Definition at line 5233 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_txn(), HttpTransact::State::server_info, HttpSM::t_state, and TS_SUCCESS.
Referenced by checkHttpTxnServerIPGet().
tsapi TSReturnCode TSHttpTxnServerAddrSet | ( | TSHttpTxn | txnp, | |
struct sockaddr const * | addr | |||
) |
Set the origin server address.
This must be invoked before the origin server address is looked up. If called no lookup is done, the address addr is used instead.
TS_SUCCESS
if the origin server address is set, TS_ERROR
otherwise. addr | Address for origin server. |
Definition at line 5242 of file InkAPI.cc.
References HttpTransact::State::api_server_addr_set, ats_ip_copy(), ats_ip_port_cast(), sdk_assert, sdk_sanity_check_txn(), HttpTransact::State::server_info, HttpSM::t_state, and TS_SUCCESS.
Allows a plugin take over the servicing of the request as though it was the origin server.
In the event a request needs to be made to the server for transaction txnp, contp will be sent TS_EVENT_NET_ACCEPT. The edata passed with TS_NET_EVENT_ACCEPT is an TSVConn just as it would be for a normal accept. The plugin must act as if it is an http server and read the http request and body off the TSVConn and send an http response header and body.
TSHttpTxnInterceptServer() must be not be called after the connection to the server has taken place. The last hook last hook in that TSHttpTxnIntercept() can be called from is TS_HTTP_READ_CACHE_HDR_HOOK. If a connection to the server is not necessary, contp is not called.
The response from the plugin is cached subject to standard and configured http caching rules. Should the plugin wish the response not be cached, the plugin must use appropriate http response headers to prevent caching. The primary purpose of TSHttpTxnInterceptServer() is allow plugins to provide gateways to other protocols or to allow to plugin to it's own transport for the next hop to the server. TSHttpTxnInterceptServer() overrides parent cache configuration.
TSHttpTxnInterceptServer() must only be called once per transaction.
contp | continuation called to handle the interception | |
txnp | transaction to be intercepted. |
Definition at line 6362 of file InkAPI.cc.
References PluginVCCore::alloc(), Continuation::mutex, HttpSM::plugin_tunnel, HttpSM::plugin_tunnel_type, sdk_assert, sdk_sanity_check_continuation(), sdk_sanity_check_null_ptr(), sdk_sanity_check_txn(), PluginVCCore::set_accept_cont(), and TS_SUCCESS.
Referenced by cont_test_handler().
tsapi TSReturnCode TSHttpTxnServerPacketMarkSet | ( | TSHttpTxn | txnp, | |
int | mark | |||
) |
Change packet firewall mark for the server side connection.
Definition at line 5341 of file InkAPI.cc.
References NetVConnection::apply_options(), HttpServerSession::get_netvc(), HttpClientSession::get_server_session(), NetVConnection::options, NetVCOptions::packet_mark, sdk_assert, sdk_sanity_check_txn(), TS_CONFIG_NET_SOCK_PACKET_MARK_OUT, TS_SUCCESS, TSHttpTxnConfigIntSet(), and HttpSM::ua_session.
tsapi TSReturnCode TSHttpTxnServerPacketTosSet | ( | TSHttpTxn | txnp, | |
int | tos | |||
) |
Change packet TOS for the server side connection.
Definition at line 5383 of file InkAPI.cc.
References NetVConnection::apply_options(), HttpServerSession::get_netvc(), HttpClientSession::get_server_session(), NetVConnection::options, NetVCOptions::packet_tos, sdk_assert, sdk_sanity_check_txn(), TS_CONFIG_NET_SOCK_PACKET_TOS_OUT, TS_SUCCESS, TSHttpTxnConfigIntSet(), and HttpSM::ua_session.
tsapi int64_t TSHttpTxnServerReqBodyBytesGet | ( | TSHttpTxn | txnp | ) |
Definition at line 5777 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_txn(), HttpSM::server_request_body_bytes, and TS_SUCCESS.
tsapi TSReturnCode TSHttpTxnServerReqGet | ( | TSHttpTxn | txnp, | |
TSMBuffer * | bufp, | |||
TSMLoc * | offset | |||
) |
Definition at line 4602 of file InkAPI.cc.
References HttpTransact::State::hdr_info, HTTPHdr::m_http, sdk_assert, sdk_sanity_check_mbuffer(), sdk_sanity_check_null_ptr(), sdk_sanity_check_txn(), HttpSM::t_state, TS_SUCCESS, and HTTPHdr::valid().
Referenced by checkHttpTxnServerReqGet().
tsapi int TSHttpTxnServerReqHdrBytesGet | ( | TSHttpTxn | txnp | ) |
Definition at line 5768 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_txn(), HttpSM::server_request_hdr_bytes, and TS_SUCCESS.
tsapi int64_t TSHttpTxnServerRespBodyBytesGet | ( | TSHttpTxn | txnp | ) |
Definition at line 5795 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_txn(), HttpSM::server_response_body_bytes, and TS_SUCCESS.
tsapi TSReturnCode TSHttpTxnServerRespGet | ( | TSHttpTxn | txnp, | |
TSMBuffer * | bufp, | |||
TSMLoc * | offset | |||
) |
Definition at line 4622 of file InkAPI.cc.
References HttpTransact::State::hdr_info, HTTPHdr::m_http, sdk_assert, sdk_sanity_check_mbuffer(), sdk_sanity_check_null_ptr(), sdk_sanity_check_txn(), HttpSM::t_state, TS_SUCCESS, and HTTPHdr::valid().
Referenced by checkHttpTxnServerRespGet(), and transformable().
tsapi int TSHttpTxnServerRespHdrBytesGet | ( | TSHttpTxn | txnp | ) |
Definition at line 5786 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_txn(), HttpSM::server_response_hdr_bytes, and TS_SUCCESS.
tsapi TSReturnCode TSHttpTxnServerRespNoStoreSet | ( | TSHttpTxn | txnp, | |
int | flag | |||
) |
Set flag indicating whether or not to cache the server response for given TSHttpTxn.
txnp | The transaction whose server response you do not want to store. | |
flag | Set 0 to allow storing and 1 to disable storing. |
Definition at line 5028 of file InkAPI.cc.
References HttpTransact::State::api_server_response_no_store, sdk_assert, sdk_sanity_check_txn(), and TS_SUCCESS.
tsapi TSServerState TSHttpTxnServerStateGet | ( | TSHttpTxn | txnp | ) |
Definition at line 5713 of file InkAPI.cc.
References HttpTransact::State::current, sdk_assert, sdk_sanity_check_txn(), and TS_SUCCESS.
tsapi void TSHttpTxnSetHttpRetStatus | ( | TSHttpTxn | txnp, | |
TSHttpStatus | http_retstatus | |||
) |
Definition at line 5637 of file InkAPI.cc.
References HttpTransact::State::http_return_code, sdk_assert, sdk_sanity_check_txn(), HttpSM::t_state, and TS_SUCCESS.
Definition at line 4509 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_txn(), TS_SUCCESS, and HttpSM::ua_session.
Referenced by ssn_handler(), TSHttpIsInternalRequest(), TSHttpTxnClientAddrGet(), TSHttpTxnClientFdGet(), and TSHttpTxnIncomingAddrGet().
tsapi void TSHttpTxnTransformedRespCache | ( | TSHttpTxn | txnp, | |
int | on | |||
) |
Definition at line 5484 of file InkAPI.cc.
References HttpTransact::State::api_info, _HttpApiInfo::cache_transformed, sdk_assert, sdk_sanity_check_txn(), HttpSM::t_state, and TS_SUCCESS.
Referenced by transform_hook_handler().
tsapi TSReturnCode TSHttpTxnTransformRespGet | ( | TSHttpTxn | txnp, | |
TSMBuffer * | bufp, | |||
TSMLoc * | offset | |||
) |
Definition at line 5156 of file InkAPI.cc.
References HttpTransact::State::hdr_info, HTTPHdr::m_http, sdk_assert, sdk_sanity_check_mbuffer(), sdk_sanity_check_txn(), HttpSM::t_state, TS_SUCCESS, and HTTPHdr::valid().
Referenced by transform_hook_handler().
tsapi void TSHttpTxnUntransformedRespCache | ( | TSHttpTxn | txnp, | |
int | on | |||
) |
Definition at line 5475 of file InkAPI.cc.
References HttpTransact::State::api_info, _HttpApiInfo::cache_untransformed, sdk_assert, sdk_sanity_check_txn(), HttpSM::t_state, and TS_SUCCESS.
Referenced by transform_hook_handler().
tsapi const char* TSInstallDirGet | ( | void | ) |
Gets the path of the directory in which Traffic Server is installed.
Use this function to specify the location of files that the plugin uses.
Definition at line 1715 of file InkAPI.cc.
References Layout::get(), and Layout::prefix.
Referenced by SDK_API_TSfopen(), and SDK_API_TSPluginDirGet().
tsapi TSIOBufferBlock TSIOBufferBlockNext | ( | TSIOBufferBlock | blockp | ) |
Definition at line 588 of file InkIOCoreAPI.cc.
References IOBufferBlock::next, sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by FetchSM::ext_read_data(), SDK_API_TSIOBufferBlockNext(), spdy_recv_callback(), synclient_txn_read_response(), and synserver_txn_read_request().
tsapi int64_t TSIOBufferBlockReadAvail | ( | TSIOBufferBlock | blockp, | |
TSIOBufferReader | readerp | |||
) |
Definition at line 634 of file InkIOCoreAPI.cc.
References IOBufferReader::block, IOBufferBlock::read_avail(), sdk_assert, sdk_sanity_check_iocore_structure(), IOBufferReader::start_offset, and TS_SUCCESS.
Referenced by SDK_API_TSIOBufferBlockReadAvail().
tsapi const char* TSIOBufferBlockReadStart | ( | TSIOBufferBlock | blockp, | |
TSIOBufferReader | readerp, | |||
int64_t * | avail | |||
) |
Definition at line 607 of file InkIOCoreAPI.cc.
References IOBufferReader::block, IOBufferBlock::read_avail(), sdk_assert, sdk_sanity_check_iocore_structure(), IOBufferBlock::start(), IOBufferReader::start_offset, and TS_SUCCESS.
Referenced by convert_http_hdr_to_string(), convert_mime_hdr_to_string(), FetchSM::ext_read_data(), handle_callbacks(), SDK_API_TSHttpHdr(), SDK_API_TSIOBufferBlockReadAvail(), spdy_recv_callback(), synclient_txn_read_response(), synserver_txn_read_request(), test_url_print(), and UDPClient_handle_callbacks().
tsapi int64_t TSIOBufferBlockWriteAvail | ( | TSIOBufferBlock | blockp | ) |
Definition at line 668 of file InkIOCoreAPI.cc.
References sdk_assert, sdk_sanity_check_iocore_structure(), TS_SUCCESS, and IOBufferBlock::write_avail().
Referenced by SDK_API_TSIOBufferBlockReadAvail().
tsapi char* TSIOBufferBlockWriteStart | ( | TSIOBufferBlock | blockp, | |
int64_t * | avail | |||
) |
Definition at line 656 of file InkIOCoreAPI.cc.
References IOBufferBlock::end(), sdk_assert, sdk_sanity_check_iocore_structure(), TS_SUCCESS, and IOBufferBlock::write_avail().
Referenced by cache_handler(), load(), SDK_API_TSIOBufferBlockReadAvail(), synclient_txn_write_request(), and synserver_txn_write_response().
tsapi int64_t TSIOBufferCopy | ( | TSIOBuffer | bufp, | |
TSIOBufferReader | readerp, | |||
int64_t | length, | |||
int64_t | offset | |||
) |
Definition at line 536 of file InkIOCoreAPI.cc.
References sdk_assert, sdk_sanity_check_iocore_structure(), TS_SUCCESS, and MIOBuffer::write().
Referenced by handle_transform(), and SDK_API_TSIOBufferCopy().
tsapi TSIOBuffer TSIOBufferCreate | ( | void | ) |
Definition at line 489 of file InkIOCoreAPI.cc.
References new_empty_MIOBuffer, sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by PrefetchBlaster::blastObject(), cache_handler(), convert_http_hdr_to_string(), convert_mime_hdr_to_string(), handle_callbacks(), handle_transform(), load(), SDK_API_TSHttpHdr(), SDK_API_TSIOBufferBlockNext(), SDK_API_TSIOBufferBlockReadAvail(), SDK_API_TSIOBufferCreate(), server_handler(), spdy_cs_create(), synclient_txn_connect_handler(), synserver_accept_handler(), test_url_print(), and UDPClient_handle_callbacks().
tsapi void TSIOBufferDestroy | ( | TSIOBuffer | bufp | ) |
Definition at line 511 of file InkIOCoreAPI.cc.
References free_MIOBuffer(), sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by cache_handler(), SpdyClientSession::clear(), convert_http_hdr_to_string(), convert_mime_hdr_to_string(), handle_callbacks(), my_data_destroy(), SDK_API_TSHttpHdr(), SDK_API_TSIOBufferCreate(), synclient_txn_close(), synserver_txn_close(), test_url_print(), UDPClient_handle_callbacks(), and SDK_NetVConn_Params::~SDK_NetVConn_Params().
tsapi void TSIOBufferProduce | ( | TSIOBuffer | bufp, | |
int64_t | nbytes | |||
) |
Definition at line 568 of file InkIOCoreAPI.cc.
References MIOBuffer::fill(), sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by cache_handler(), load(), SDK_API_TSIOBufferProduce(), SDK_API_TSIOBufferReaderClone(), SDK_API_TSIOBufferReaderConsume(), synclient_txn_write_request(), and synserver_txn_write_response().
tsapi TSIOBufferReader TSIOBufferReaderAlloc | ( | TSIOBuffer | bufp | ) |
Definition at line 696 of file InkIOCoreAPI.cc.
References MIOBuffer::alloc_reader(), sdk_assert, sdk_sanity_check_iocore_structure(), sdk_sanity_check_null_ptr(), and TS_SUCCESS.
Referenced by PrefetchBlaster::blastObject(), cache_handler(), convert_http_hdr_to_string(), convert_mime_hdr_to_string(), handle_callbacks(), handle_transform(), load(), SDK_API_TSHttpHdr(), SDK_API_TSIOBufferBlockNext(), SDK_API_TSIOBufferBlockReadAvail(), SDK_API_TSIOBufferCopy(), SDK_API_TSIOBufferProduce(), SDK_API_TSIOBufferReaderClone(), SDK_API_TSIOBufferReaderConsume(), SDK_API_TSIOBufferStart(), spdy_cs_create(), synclient_txn_connect_handler(), synserver_accept_handler(), test_url_print(), and UDPClient_handle_callbacks().
tsapi int64_t TSIOBufferReaderAvail | ( | TSIOBufferReader | readerp | ) |
Definition at line 749 of file InkIOCoreAPI.cc.
References IOBufferReader::read_avail(), sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by cache_handler(), convert_http_hdr_to_string(), convert_mime_hdr_to_string(), handle_transform(), load(), SDK_API_TSHttpHdr(), SDK_API_TSIOBufferProduce(), SDK_API_TSIOBufferReaderClone(), SDK_API_TSIOBufferReaderConsume(), spdy_process_write(), synclient_txn_read_response_handler(), synserver_txn_read_request_handler(), and test_url_print().
tsapi TSIOBufferReader TSIOBufferReaderClone | ( | TSIOBufferReader | readerp | ) |
Definition at line 709 of file InkIOCoreAPI.cc.
References IOBufferReader::clone(), sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by SDK_API_TSIOBufferReaderClone().
tsapi void TSIOBufferReaderConsume | ( | TSIOBufferReader | readerp, | |
int64_t | nbytes | |||
) |
Definition at line 739 of file InkIOCoreAPI.cc.
References IOBufferReader::consume(), sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by cache_handler(), convert_http_hdr_to_string(), convert_mime_hdr_to_string(), FetchSM::ext_read_data(), handle_callbacks(), handle_transform(), SDK_API_TSHttpHdr(), SDK_API_TSIOBufferReaderClone(), SDK_API_TSIOBufferReaderConsume(), spdy_recv_callback(), synclient_txn_read_response_handler(), synserver_txn_read_request_handler(), test_url_print(), and UDPClient_handle_callbacks().
tsapi void TSIOBufferReaderFree | ( | TSIOBufferReader | readerp | ) |
Definition at line 718 of file InkIOCoreAPI.cc.
References MIOBuffer::dealloc_reader(), IOBufferReader::mbuf, sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by SpdyClientSession::clear(), convert_http_hdr_to_string(), convert_mime_hdr_to_string(), handle_callbacks(), SDK_API_TSHttpHdr(), test_url_print(), and UDPClient_handle_callbacks().
tsapi TSIOBufferBlock TSIOBufferReaderStart | ( | TSIOBufferReader | readerp | ) |
Definition at line 727 of file InkIOCoreAPI.cc.
References IOBufferReader::block, IOBufferReader::get_current_block(), sdk_assert, sdk_sanity_check_iocore_structure(), IOBufferReader::skip_empty_blocks(), and TS_SUCCESS.
Referenced by convert_http_hdr_to_string(), convert_mime_hdr_to_string(), FetchSM::ext_read_data(), SDK_API_TSHttpHdr(), SDK_API_TSIOBufferBlockNext(), SDK_API_TSIOBufferStart(), spdy_recv_callback(), synclient_txn_read_response(), synserver_txn_read_request(), and test_url_print().
tsapi TSIOBuffer TSIOBufferSizedCreate | ( | TSIOBufferSizeIndex | index | ) |
Creates a new TSIOBuffer of the specified size.
With this function, you can create smaller buffers than the 32K buffer created by TSIOBufferCreate(). In some situations using smaller buffers can improve performance.
index | size of the new TSIOBuffer to be created. | |
new | TSIOBuffer of the specified size. |
Definition at line 499 of file InkIOCoreAPI.cc.
References new_MIOBuffer, sdk_assert, sdk_sanity_check_iocore_structure(), TS_IOBUFFER_SIZE_INDEX_128, TS_IOBUFFER_SIZE_INDEX_32K, and TS_SUCCESS.
Referenced by SDK_API_TSIOBufferCopy(), SDK_API_TSIOBufferProduce(), SDK_API_TSIOBufferReaderClone(), SDK_API_TSIOBufferReaderConsume(), and SDK_API_TSIOBufferStart().
tsapi TSIOBufferBlock TSIOBufferStart | ( | TSIOBuffer | bufp | ) |
Definition at line 518 of file InkIOCoreAPI.cc.
References MIOBuffer::add_block(), MIOBuffer::get_current_block(), sdk_assert, sdk_sanity_check_iocore_structure(), sdk_sanity_check_null_ptr(), TS_SUCCESS, and IOBufferBlock::write_avail().
Referenced by cache_handler(), load(), SDK_API_TSIOBufferBlockReadAvail(), SDK_API_TSIOBufferStart(), synclient_txn_write_request(), and synserver_txn_write_response().
tsapi int64_t TSIOBufferWaterMarkGet | ( | TSIOBuffer | bufp | ) |
The watermark of an TSIOBuffer is the minimum number of bytes of data that have to be in the buffer before calling back any continuation that has initiated a read operation on this buffer.
TSIOBufferWaterMarkGet() will provide the size of the watermark, in bytes, for a specified TSIOBuffer.
bufp | buffer whose watermark the function gets. |
Definition at line 677 of file InkIOCoreAPI.cc.
References sdk_assert, sdk_sanity_check_iocore_structure(), TS_SUCCESS, and MIOBuffer::water_mark.
Referenced by SDK_API_TSIOBufferCreate().
tsapi void TSIOBufferWaterMarkSet | ( | TSIOBuffer | bufp, | |
int64_t | water_mark | |||
) |
The watermark of an TSIOBuffer is the minimum number of bytes of data that have to be in the buffer before calling back any continuation that has initiated a read operation on this buffer.
As a writer feeds data into the TSIOBuffer, no readers are called back until the amount of data reaches the watermark. Setting a watermark can improve performance because it avoids frequent callbacks to read small amounts of data. TSIOBufferWaterMarkSet() assigns a watermark to a particular TSIOBuffer.
bufp | buffer whose water mark the function sets. | |
water_mark | watermark setting, as a number of bytes. |
Definition at line 686 of file InkIOCoreAPI.cc.
References sdk_assert, sdk_sanity_check_iocore_structure(), TS_SUCCESS, and MIOBuffer::water_mark.
Referenced by SDK_API_TSIOBufferCreate().
tsapi int64_t TSIOBufferWrite | ( | TSIOBuffer | bufp, | |
const void * | buf, | |||
int64_t | length | |||
) |
Writes length bytes of data contained in the string buf to the TSIOBuffer bufp.
Returns the number of bytes of data successfully written to the TSIOBuffer.
bufp | is the TSIOBuffer to write into. | |
buf | string to write into the TSIOBuffer. | |
length | of the string buf. |
Definition at line 549 of file InkIOCoreAPI.cc.
References sdk_assert, sdk_sanity_check_iocore_structure(), sdk_sanity_check_null_ptr(), TS_SUCCESS, and MIOBuffer::write().
Referenced by SDK_API_TSIOBufferBlockNext(), SDK_API_TSIOBufferBlockReadAvail(), SDK_API_TSIOBufferCopy(), and spdy_send_callback().
tsapi int TSIsDebugTagSet | ( | const char * | t | ) |
Definition at line 6749 of file InkAPI.cc.
References diags, DiagsTagType_Debug, and Diags::on().
tsapi void TSLifecycleHookAdd | ( | TSLifecycleHookID | id, | |
TSCont | contp | |||
) |
Definition at line 4388 of file InkAPI.cc.
References FeatureAPIHooks< ID, N >::append(), sdk_assert, sdk_sanity_check_continuation(), sdk_sanity_check_lifecycle_hook_id(), and TS_SUCCESS.
tsapi TSMBuffer TSMBufferCreate | ( | void | ) |
Creates a new marshal buffer and initializes the reference count to 1.
Definition at line 1893 of file InkAPI.cc.
References HdrHeapSDKHandle::m_heap, new_HdrHeap(), sdk_assert, sdk_sanity_check_mbuffer(), and TS_SUCCESS.
Referenced by SDK_API_TSHttpHdr(), SDK_API_TSHttpHdrParse(), SDK_API_TSMimeHdrField(), SDK_API_TSMimeHdrParse(), SDK_API_TSUrl(), and SDK_API_TSUrlParse().
tsapi TSReturnCode TSMBufferDestroy | ( | TSMBuffer | bufp | ) |
Ignores the reference count and destroys the marshal buffer bufp.
The internal data buffer associated with the marshal buffer is also destroyed if the marshal buffer allocated it.
bufp | marshal buffer to be destroyed. |
Definition at line 1906 of file InkAPI.cc.
References HdrHeap::destroy(), isWriteable(), HdrHeapSDKHandle::m_heap, sdk_assert, sdk_sanity_check_mbuffer(), and TS_SUCCESS.
Referenced by SDK_API_TSHttpHdr(), SDK_API_TSHttpHdrParse(), SDK_API_TSMimeHdrField(), SDK_API_TSMimeHdrParse(), SDK_API_TSUrl(), and SDK_API_TSUrlParse().
tsapi TSReturnCode TSMgmtCounterGet | ( | const char * | var_name, | |
TSMgmtCounter * | result | |||
) |
Definition at line 4168 of file InkAPI.cc.
References REC_ERR_OKAY, RecGetRecordCounter(), and TS_SUCCESS.
Referenced by SDK_API_TSMgmtGet().
tsapi TSReturnCode TSMgmtFloatGet | ( | const char * | var_name, | |
TSMgmtFloat * | result | |||
) |
Definition at line 4174 of file InkAPI.cc.
References REC_ERR_OKAY, RecGetRecordFloat(), and TS_SUCCESS.
Referenced by SDK_API_TSMgmtGet().
tsapi TSReturnCode TSMgmtIntCreate | ( | TSRecordType | rec_type, | |
const char * | name, | |||
TSMgmtInt | data_default, | |||
TSRecordUpdateType | update_type, | |||
TSRecordCheckType | check_type, | |||
const char * | check_regex, | |||
TSRecordAccessType | access_type | |||
) |
Definition at line 8493 of file InkAPI.cc.
References REC_ERR_OKAY, RecRegisterConfigInt(), and TS_RECORDCHECK_NULL.
tsapi TSReturnCode TSMgmtIntGet | ( | const char * | var_name, | |
TSMgmtInt * | result | |||
) |
Definition at line 4162 of file InkAPI.cc.
References REC_ERR_OKAY, RecGetRecordInt(), and TS_SUCCESS.
Referenced by SDK_API_TSMgmtGet(), and TSMgmtConfigIntSet().
tsapi TSReturnCode TSMgmtStringCreate | ( | TSRecordType | rec_type, | |
const char * | name, | |||
const TSMgmtString | data_default, | |||
TSRecordUpdateType | update_type, | |||
TSRecordCheckType | check_type, | |||
const char * | check_regex, | |||
TSRecordAccessType | access_type | |||
) |
Definition at line 8479 of file InkAPI.cc.
References REC_ERR_OKAY, RecRegisterConfigString(), and TS_RECORDCHECK_NULL.
tsapi TSReturnCode TSMgmtStringGet | ( | const char * | var_name, | |
TSMgmtString * | result | |||
) |
Definition at line 4180 of file InkAPI.cc.
References RecGetRecordString_Xmalloc().
Referenced by SDK_API_TSMgmtGet().
tsapi void TSMgmtUpdateRegister | ( | TSCont | contp, | |
const char * | plugin_name | |||
) |
Definition at line 4153 of file InkAPI.cc.
References ConfigUpdateCbTable::insert(), sdk_assert, sdk_sanity_check_iocore_structure(), sdk_sanity_check_null_ptr(), and TS_SUCCESS.
tsapi TSReturnCode TSMimeHdrClone | ( | TSMBuffer | dest_bufp, | |
TSMBuffer | src_bufp, | |||
TSMLoc | src_hdr, | |||
TSMLoc * | locp | |||
) |
Copies a specified MIME header to a specified marshal buffer, and returns the location of the copied MIME header within the destination marshal buffer.
Unlike TSMimeHdrCopy(), you do not have to create the destination MIME header before cloning. Release the returned TSMLoc handle with a call to TSHandleMLocRelease().
dest_bufp | destination marshal buffer. | |
src_bufp | source marshal buffer. | |
src_hdr | location of the source MIME header. | |
locp | where to store the location of the copied MIME header. |
Definition at line 2428 of file InkAPI.cc.
References _hdr_mloc_to_mime_hdr_impl(), isWriteable(), mime_hdr_clone(), sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), sdk_sanity_check_null_ptr(), and TS_SUCCESS.
tsapi TSReturnCode TSMimeHdrCopy | ( | TSMBuffer | dest_bufp, | |
TSMLoc | dest_offset, | |||
TSMBuffer | src_bufp, | |||
TSMLoc | src_offset | |||
) |
Copies the contents of the MIME header located at src_loc within src_bufp to the MIME header located at dest_loc within dest_bufp.
TSMimeHdrCopy() works correctly even if src_bufp and dest_bufp point to different marshal buffers. Important: you must create the destination MIME header before copying into it--use TSMimeHdrCreate().
dest_bufp | is the destination marshal buffer. | |
dest_offset | ||
src_bufp | is the source marshal buffer. | |
src_offset |
Definition at line 2456 of file InkAPI.cc.
References _hdr_mloc_to_mime_hdr_impl(), isWriteable(), mime_hdr_copy_onto(), mime_hdr_fields_clear(), sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), and TS_SUCCESS.
Referenced by SDK_API_TSMimeHdrParse().
tsapi TSReturnCode TSMimeHdrCreate | ( | TSMBuffer | bufp, | |
TSMLoc * | locp | |||
) |
Creates a new MIME header within bufp.
Release with a call to TSHandleMLocRelease().
bufp | marshal buffer to contain the new MIME header. | |
locp | buffer pointer to contain the MLoc |
Definition at line 2392 of file InkAPI.cc.
References isWriteable(), mime_hdr_create(), sdk_assert, sdk_sanity_check_mbuffer(), sdk_sanity_check_null_ptr(), and TS_SUCCESS.
Referenced by SDK_API_TSMimeHdrField(), and SDK_API_TSMimeHdrParse().
tsapi TSReturnCode TSMimeHdrDestroy | ( | TSMBuffer | bufp, | |
TSMLoc | offset | |||
) |
Destroys the MIME header located at hdr_loc within bufp.
bufp | marshal buffer containing the MIME header to destroy. | |
offset | location of the MIME header. |
Definition at line 2408 of file InkAPI.cc.
References _hdr_mloc_to_mime_hdr_impl(), isWriteable(), mime_hdr_destroy(), sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), and TS_SUCCESS.
Referenced by SDK_API_TSHttpHdrParse(), SDK_API_TSMimeHdrField(), and SDK_API_TSMimeHdrParse().
tsapi TSReturnCode TSMimeHdrFieldAppend | ( | TSMBuffer | bufp, | |
TSMLoc | hdr, | |||
TSMLoc | field | |||
) |
Returns the TSMLoc location of a specified MIME field from within the MIME header located at hdr.
The retrieved_str parameter specifies which field to retrieve. For each MIME field in the MIME header, a pointer comparison is done between the field name and retrieved_str. This is a much quicker retrieval function than TSMimeHdrFieldFind() since it obviates the need for a string comparison. However, retrieved_str must be one of the predefined field names of the form TS_MIME_FIELD_XXX for the call to succeed. Release the returned TSMLoc handle with a call to TSHandleMLocRelease().
bufp | marshal buffer containing the MIME field. | |
hdr | location of the MIME header containing the field. | |
retrieved_str | specifies the field to retrieve. Must be one of the predefined field names of the form TS_MIME_FIELD_XXX. |
Definition at line 2685 of file InkAPI.cc.
References _hdr_mloc_to_mime_hdr_impl(), MIMEFieldSDKHandle::field_ptr, ink_assert, isWriteable(), MIMEField::m_ptr_name, memcpy, MIMEFieldSDKHandle::mh, mime_field_create(), mime_hdr_field_attach(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), and TS_SUCCESS.
Referenced by SDK_API_TSMimeHdrField(), and SDK_API_TSMimeHdrParse().
tsapi TSReturnCode TSMimeHdrFieldClone | ( | TSMBuffer | dest_bufp, | |
TSMLoc | dest_hdr, | |||
TSMBuffer | src_bufp, | |||
TSMLoc | src_hdr, | |||
TSMLoc | src_field, | |||
TSMLoc * | locp | |||
) |
Definition at line 2888 of file InkAPI.cc.
References isWriteable(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), sdk_sanity_check_null_ptr(), TS_SUCCESS, TSMimeHdrFieldCopy(), and TSMimeHdrFieldCreate().
Referenced by SDK_API_TSMimeHdrParse().
tsapi TSReturnCode TSMimeHdrFieldCopy | ( | TSMBuffer | dest_bufp, | |
TSMLoc | dest_hdr, | |||
TSMLoc | dest_field, | |||
TSMBuffer | src_bufp, | |||
TSMLoc | src_hdr, | |||
TSMLoc | src_field | |||
) |
Definition at line 2842 of file InkAPI.cc.
References MIMEFieldSDKHandle::field_ptr, MIMEField::is_live(), isWriteable(), MIMEField::m_len_name, MIMEField::m_len_value, MIMEField::m_ptr_name, MIMEField::m_ptr_value, MIMEField::m_wks_idx, MIMEFieldSDKHandle::mh, mime_field_name_value_set(), mime_hdr_field_attach(), mime_hdr_field_detach(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), and TS_SUCCESS.
Referenced by SDK_API_TSMimeHdrParse(), and TSMimeHdrFieldClone().
tsapi TSReturnCode TSMimeHdrFieldCopyValues | ( | TSMBuffer | dest_bufp, | |
TSMLoc | dest_hdr, | |||
TSMLoc | dest_field, | |||
TSMBuffer | src_bufp, | |||
TSMLoc | src_hdr, | |||
TSMLoc | src_field | |||
) |
Definition at line 2915 of file InkAPI.cc.
References MIMEFieldSDKHandle::field_ptr, isWriteable(), MIMEField::m_len_value, MIMEField::m_ptr_value, MIMEFieldSDKHandle::mh, mime_field_value_set(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), and TS_SUCCESS.
Referenced by SDK_API_TSMimeHdrParse().
tsapi TSReturnCode TSMimeHdrFieldCreate | ( | TSMBuffer | bufp, | |
TSMLoc | hdr, | |||
TSMLoc * | locp | |||
) |
Definition at line 2796 of file InkAPI.cc.
References _hdr_mloc_to_mime_hdr_impl(), MIMEFieldSDKHandle::field_ptr, isWriteable(), mime_field_create(), sdk_alloc_field_handle(), sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), sdk_sanity_check_null_ptr(), and TS_SUCCESS.
Referenced by SDK_API_TSMimeHdrField(), SDK_API_TSMimeHdrParse(), and TSMimeHdrFieldClone().
tsapi TSReturnCode TSMimeHdrFieldCreateNamed | ( | TSMBuffer | bufp, | |
TSMLoc | mh_mloc, | |||
const char * | name, | |||
int | name_len, | |||
TSMLoc * | locp | |||
) |
Definition at line 2819 of file InkAPI.cc.
References _hdr_mloc_to_mime_hdr_impl(), MIMEFieldSDKHandle::field_ptr, isWriteable(), mime_field_create_named(), sdk_alloc_field_handle(), sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), sdk_sanity_check_null_ptr(), and TS_SUCCESS.
tsapi TSReturnCode TSMimeHdrFieldDestroy | ( | TSMBuffer | bufp, | |
TSMLoc | hdr, | |||
TSMLoc | field | |||
) |
Destroys the MIME field located at field within bufp.
You must release the TSMLoc field with a call to TSHandleMLocRelease().
bufp | contains the MIME field to be destroyed. | |
hdr | location of the parent header containing the field to be destroyed. This could be the location of a MIME header or HTTP header. | |
field | location of the field to be destroyed. |
Definition at line 2761 of file InkAPI.cc.
References _hdr_mloc_to_mime_hdr_impl(), MIMEFieldSDKHandle::field_ptr, ink_assert, ink_release_assert, isWriteable(), MIMEFieldSDKHandle::mh, mime_hdr_field_delete(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), and TS_SUCCESS.
Referenced by SDK_API_TSMimeHdrField().
Retrieves the TSMLoc location of a specified MIME field from within the MIME header located at hdr.
The name and length parameters specify which field to retrieve. For each MIME field in the MIME header, a case insensitive string comparison is done between the field name and name. If TSMimeHdrFieldFind() cannot find the requested field, it returns TS_NULL_MLOC. Release the returned TSMLoc handle with a call to TSHandleMLocRelease().
bufp | marshal buffer containing the MIME header field to find. | |
hdr | location of the MIME header containing the field. | |
name | of the field to retrieve. | |
length | string length of the string name. If length is -1, then name is assumed to be null-terminated. |
Definition at line 2662 of file InkAPI.cc.
References _hdr_mloc_to_mime_hdr_impl(), MIMEFieldSDKHandle::field_ptr, mime_hdr_field_find(), sdk_alloc_field_handle(), sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), sdk_sanity_check_null_ptr(), TS_NULL_MLOC, and TS_SUCCESS.
Referenced by get_request_id(), SDK_API_TSMimeHdrField(), SDK_API_TSMimeHdrParse(), and transform_hook_handler().
Retrieves the location of a specified MIME field within the MIME header located at hdr_loc within bufp.
The idx parameter specifies which field to retrieve. The fields are numbered from 0 to TSMimeHdrFieldsCount(bufp, hdr_loc) - 1. If idx does not lie within that range then TSMimeHdrFieldGet returns 0. Release the returned handle with a call to TSHandleMLocRelease.
bufp | marshal buffer containing the MIME header. | |
hdr | location of the MIME header. | |
idx | index of the field to get with base at 0. |
Definition at line 2642 of file InkAPI.cc.
References _hdr_mloc_to_mime_hdr_impl(), MIMEFieldSDKHandle::field_ptr, mime_hdr_field_get(), sdk_alloc_field_handle(), sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), TS_NULL_MLOC, and TS_SUCCESS.
Referenced by SDK_API_TSMimeHdrField(), SDK_API_TSMimeHdrParse(), and SpdyNV::SpdyNV().
Definition at line 3002 of file InkAPI.cc.
References MIMEFieldSDKHandle::field_ptr, mime_field_length_get(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), and TS_SUCCESS.
Referenced by SDK_API_TSMimeHdrField().
Definition at line 3014 of file InkAPI.cc.
References MIMEFieldSDKHandle::field_ptr, mime_field_name_get(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), sdk_sanity_check_null_ptr(), and TS_SUCCESS.
Referenced by compare_field_names(), SDK_API_TSMimeHdrField(), SDK_API_TSMimeHdrParse(), and SpdyNV::SpdyNV().
tsapi TSReturnCode TSMimeHdrFieldNameSet | ( | TSMBuffer | bufp, | |
TSMLoc | hdr, | |||
TSMLoc | field, | |||
const char * | name, | |||
int | length | |||
) |
Definition at line 3027 of file InkAPI.cc.
References MIMEFieldSDKHandle::field_ptr, MIMEField::is_live(), isWriteable(), MIMEFieldSDKHandle::mh, mime_hdr_field_attach(), mime_hdr_field_detach(), MIMEField::name_set(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), sdk_sanity_check_null_ptr(), and TS_SUCCESS.
Referenced by SDK_API_TSMimeHdrField().
Definition at line 2950 of file InkAPI.cc.
References MIMEFieldSDKHandle::field_ptr, MIMEField::is_live(), MIMEFieldSDKHandle::mh, mime_hdr_field_get_slotnum(), mime_hdr_field_slotnum(), sdk_alloc_field_handle(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), TS_NULL_MLOC, and TS_SUCCESS.
Referenced by SDK_API_TSMimeHdrField(), and SpdyNV::SpdyNV().
Definition at line 2983 of file InkAPI.cc.
References _hdr_mloc_to_mime_hdr_impl(), MIMEFieldSDKHandle::field_ptr, MIMEField::m_next_dup, sdk_alloc_field_handle(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), TS_NULL_MLOC, and TS_SUCCESS.
Referenced by SDK_API_TSMimeHdrParse().
tsapi TSReturnCode TSMimeHdrFieldRemove | ( | TSMBuffer | bufp, | |
TSMLoc | hdr, | |||
TSMLoc | field | |||
) |
Removes the MIME field located at field within bufp from the header located at hdr within bufp.
If the specified field cannot be found in the list of fields associated with the header then nothing is done.
Note: removing the field does not destroy the field, it only detaches the field, hiding it from the printed output. The field can be reattached with a call to TSMimeHdrFieldAppend(). If you do not use the detached field you should destroy it with a call to TSMimeHdrFieldDestroy() and release the handle field with a call to TSHandleMLocRelease().
bufp | contains the MIME field to remove. | |
hdr | location of the header containing the MIME field to be removed. This header could be an HTTP header or MIME header. | |
field | is the location of the field to remove. |
Definition at line 2735 of file InkAPI.cc.
References _hdr_mloc_to_mime_hdr_impl(), MIMEFieldSDKHandle::field_ptr, ink_assert, isWriteable(), MIMEFieldSDKHandle::mh, mime_hdr_field_detach(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), and TS_SUCCESS.
Referenced by SDK_API_TSMimeHdrParse().
tsapi TSReturnCode TSMimeHdrFieldsClear | ( | TSMBuffer | bufp, | |
TSMLoc | offset | |||
) |
Removes and destroys all the MIME fields within the MIME header located at hdr_loc within the marshal buffer bufp.
bufp | marshal buffer containing the MIME header. | |
offset | location of the MIME header. |
Definition at line 2548 of file InkAPI.cc.
References _hdr_mloc_to_mime_hdr_impl(), isWriteable(), mime_hdr_fields_clear(), sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), and TS_SUCCESS.
Referenced by SDK_API_TSMimeHdrField().
Returns a count of the number of MIME fields within the MIME header located at hdr_loc within the marshal buffer bufp.
bufp | marshal buffer containing the MIME header. | |
offset | location of the MIME header within bufp. |
Definition at line 2564 of file InkAPI.cc.
References _hdr_mloc_to_mime_hdr_impl(), mime_hdr_fields_count(), sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), and TS_SUCCESS.
Referenced by SDK_API_TSMimeHdrField(), and SpdyNV::SpdyNV().
tsapi TSReturnCode TSMimeHdrFieldValueAppend | ( | TSMBuffer | bufp, | |
TSMLoc | hdr, | |||
TSMLoc | field, | |||
int | idx, | |||
const char * | value, | |||
int | length | |||
) |
Definition at line 3292 of file InkAPI.cc.
References MIMEFieldSDKHandle::field_ptr, isWriteable(), MIMEFieldSDKHandle::mh, mime_field_value_extend_comma_val(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), sdk_sanity_check_null_ptr(), and TS_SUCCESS.
Referenced by SDK_API_TSMimeHdrField().
Definition at line 3111 of file InkAPI.cc.
References mime_parse_date(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), TS_SUCCESS, and TSMimeFieldValueGet().
Referenced by SDK_API_TSMimeHdrField().
tsapi TSReturnCode TSMimeHdrFieldValueDateInsert | ( | TSMBuffer | bufp, | |
TSMLoc | hdr, | |||
TSMLoc | field, | |||
time_t | value | |||
) |
Definition at line 3381 of file InkAPI.cc.
References isWriteable(), mime_format_date(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), TS_ERROR, TS_SUCCESS, TSMimeFieldValueSet(), and TSMimeHdrFieldValuesClear().
Referenced by SDK_API_TSMimeHdrField().
tsapi TSReturnCode TSMimeHdrFieldValueDateSet | ( | TSMBuffer | bufp, | |
TSMLoc | hdr, | |||
TSMLoc | field, | |||
time_t | value | |||
) |
Definition at line 3202 of file InkAPI.cc.
References isWriteable(), mime_format_date(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), TS_SUCCESS, and TSMimeFieldValueSet().
Referenced by SDK_API_TSMimeHdrField().
tsapi TSReturnCode TSMimeHdrFieldValueDelete | ( | TSMBuffer | bufp, | |
TSMLoc | hdr, | |||
TSMLoc | field, | |||
int | idx | |||
) |
Definition at line 3406 of file InkAPI.cc.
References MIMEFieldSDKHandle::field_ptr, isWriteable(), MIMEFieldSDKHandle::mh, mime_field_value_delete_comma_val(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), and TS_SUCCESS.
Referenced by SDK_API_TSMimeHdrField().
Definition at line 3145 of file InkAPI.cc.
References mime_parse_int64(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), TS_SUCCESS, and TSMimeFieldValueGet().
tsapi TSReturnCode TSMimeHdrFieldValueInt64Set | ( | TSMBuffer | bufp, | |
TSMLoc | hdr, | |||
TSMLoc | field, | |||
int | idx, | |||
int64_t | value | |||
) |
Definition at line 3248 of file InkAPI.cc.
References isWriteable(), mime_format_int64(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), TS_SUCCESS, and TSMimeFieldValueSet().
Definition at line 3128 of file InkAPI.cc.
References mime_parse_int(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), TS_SUCCESS, and TSMimeFieldValueGet().
Referenced by get_request_id(), SDK_API_TSMimeHdrField(), and transform_hook_handler().
tsapi TSReturnCode TSMimeHdrFieldValueIntInsert | ( | TSMBuffer | bufp, | |
TSMLoc | hdr, | |||
TSMLoc | field, | |||
int | idx, | |||
int | value | |||
) |
Definition at line 3339 of file InkAPI.cc.
References isWriteable(), mime_format_int(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), TS_SUCCESS, and TSMimeFieldValueInsert().
Referenced by SDK_API_TSMimeHdrField().
tsapi TSReturnCode TSMimeHdrFieldValueIntSet | ( | TSMBuffer | bufp, | |
TSMLoc | hdr, | |||
TSMLoc | field, | |||
int | idx, | |||
int | value | |||
) |
Definition at line 3226 of file InkAPI.cc.
References isWriteable(), mime_format_int(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), TS_SUCCESS, and TSMimeFieldValueSet().
Referenced by SDK_API_TSMimeHdrField().
tsapi TSReturnCode TSMimeHdrFieldValuesClear | ( | TSMBuffer | bufp, | |
TSMLoc | hdr, | |||
TSMLoc | field | |||
) |
Modified the string value passed from an empty string ("") to NULL. An empty string is also considered to be a token. The correct value of the field after this function should be NULL.
Definition at line 3061 of file InkAPI.cc.
References MIMEFieldSDKHandle::field_ptr, isWriteable(), MIMEFieldSDKHandle::mh, mime_field_value_set(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), and TS_SUCCESS.
Referenced by SDK_API_TSMimeHdrField(), and TSMimeHdrFieldValueDateInsert().
Definition at line 3088 of file InkAPI.cc.
References MIMEFieldSDKHandle::field_ptr, mime_field_value_get_comma_val_count(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), and TS_SUCCESS.
Referenced by compare_field_values(), and SDK_API_TSMimeHdrField().
tsapi const char* TSMimeHdrFieldValueStringGet | ( | TSMBuffer | bufp, | |
TSMLoc | hdr, | |||
TSMLoc | field, | |||
int | idx, | |||
int * | value_len_ptr | |||
) |
Definition at line 3100 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), sdk_sanity_check_null_ptr(), TS_SUCCESS, and TSMimeFieldValueGet().
Referenced by compare_field_values(), SDK_API_TSMimeHdrField(), and SpdyNV::SpdyNV().
tsapi TSReturnCode TSMimeHdrFieldValueStringInsert | ( | TSMBuffer | bufp, | |
TSMLoc | hdr, | |||
TSMLoc | field, | |||
int | idx, | |||
const char * | value, | |||
int | length | |||
) |
Definition at line 3318 of file InkAPI.cc.
References isWriteable(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), sdk_sanity_check_null_ptr(), TS_SUCCESS, and TSMimeFieldValueInsert().
Referenced by SDK_API_TSMimeHdrField().
tsapi TSReturnCode TSMimeHdrFieldValueStringSet | ( | TSMBuffer | bufp, | |
TSMLoc | hdr, | |||
TSMLoc | field, | |||
int | idx, | |||
const char * | value, | |||
int | length | |||
) |
Definition at line 3179 of file InkAPI.cc.
References isWriteable(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), sdk_sanity_check_null_ptr(), TS_SUCCESS, and TSMimeFieldValueSet().
Referenced by SDK_API_TSMimeHdrField().
Definition at line 3162 of file InkAPI.cc.
References mime_parse_uint(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), TS_SUCCESS, and TSMimeFieldValueGet().
Referenced by SDK_API_TSMimeHdrField().
tsapi TSReturnCode TSMimeHdrFieldValueUintInsert | ( | TSMBuffer | bufp, | |
TSMLoc | hdr, | |||
TSMLoc | field, | |||
int | idx, | |||
unsigned int | value | |||
) |
Definition at line 3360 of file InkAPI.cc.
References isWriteable(), mime_format_uint(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), TS_SUCCESS, and TSMimeFieldValueInsert().
Referenced by SDK_API_TSMimeHdrField().
tsapi TSReturnCode TSMimeHdrFieldValueUintSet | ( | TSMBuffer | bufp, | |
TSMLoc | hdr, | |||
TSMLoc | field, | |||
int | idx, | |||
unsigned int | value | |||
) |
Definition at line 3270 of file InkAPI.cc.
References isWriteable(), mime_format_uint(), sdk_assert, sdk_sanity_check_field_handle(), sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), TS_SUCCESS, and TSMimeFieldValueSet().
Referenced by SDK_API_TSMimeHdrField().
Calculates the length of the MIME header located at hdr_loc if it were returned as a string.
This the length of the MIME header in its unparsed form.
bufp | marshal buffer containing the MIME header. | |
offset | location of the MIME header. |
Definition at line 2537 of file InkAPI.cc.
References _hdr_mloc_to_mime_hdr_impl(), mime_hdr_length_get(), sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), and TS_SUCCESS.
Referenced by SDK_API_TSMimeHdrParse(), and SpdyNV::SpdyNV().
tsapi TSParseResult TSMimeHdrParse | ( | TSMimeParser | parser, | |
TSMBuffer | bufp, | |||
TSMLoc | offset, | |||
const char ** | start, | |||
const char * | end | |||
) |
Parses a MIME header.
The MIME header must have already been allocated and both bufp and hdr_loc must point within that header. It is possible to parse a MIME header a single byte at a time using repeated calls to TSMimeHdrParse(). As long as an error does not occur, TSMimeHdrParse() consumes each single byte and asks for more.
parser | parses the specified MIME header. | |
bufp | marshal buffer containing the MIME header to be parsed. | |
offset | ||
start | both an input and output. On input, the start argument points to the current position of the buffer being parsed. On return, start is modified to point past the last character parsed. | |
end | points to one byte after the end of the buffer. |
Definition at line 2518 of file InkAPI.cc.
References _hdr_mloc_to_mime_hdr_impl(), isWriteable(), mime_parser_parse(), sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), sdk_sanity_check_null_ptr(), and TS_SUCCESS.
Referenced by SDK_API_TSMimeHdrParse().
tsapi void TSMimeHdrPrint | ( | TSMBuffer | bufp, | |
TSMLoc | offset, | |||
TSIOBuffer | iobufp | |||
) |
Formats the MIME header located at hdr_loc within bufp into the TSIOBuffer iobufp.
bufp | marshal buffer containing the header to be copied to an TSIOBuffer. | |
offset | ||
iobufp | target TSIOBuffer. |
Definition at line 2486 of file InkAPI.cc.
References _hdr_mloc_to_mime_hdr_impl(), MIOBuffer::add_block(), IOBufferBlock::end(), MIOBuffer::fill(), MIOBuffer::get_current_block(), mime_hdr_print(), sdk_assert, sdk_sanity_check_http_hdr_handle(), sdk_sanity_check_iocore_structure(), sdk_sanity_check_mbuffer(), sdk_sanity_check_mime_hdr_handle(), TS_SUCCESS, and IOBufferBlock::write_avail().
Referenced by convert_mime_hdr_to_string().
tsapi void TSMimeParserClear | ( | TSMimeParser | parser | ) |
Clears the specified MIME parser so that it can be used again.
parser | to be cleared. |
Definition at line 2368 of file InkAPI.cc.
References mime_parser_clear(), sdk_assert, sdk_sanity_check_mime_parser(), and TS_SUCCESS.
Referenced by SDK_API_TSMimeHdrParse().
tsapi TSMimeParser TSMimeParserCreate | ( | void | ) |
Creates a MIME parser.
The parser's data structure contains information about the header being parsed. A single MIME parser can be used multiple times, though not simultaneously. Before being used again, the parser must be cleared by calling TSMimeParserClear().
Definition at line 2359 of file InkAPI.cc.
References ats_malloc(), and mime_parser_init().
Referenced by SDK_API_TSMimeHdrParse().
tsapi void TSMimeParserDestroy | ( | TSMimeParser | parser | ) |
Destroys the specified MIME parser and frees the associated memory.
parser | to destroy. |
Definition at line 2376 of file InkAPI.cc.
References ats_free(), mime_parser_clear(), sdk_assert, sdk_sanity_check_mime_parser(), and TS_SUCCESS.
Referenced by SDK_API_TSMimeHdrParse().
tsapi TSMutex TSMutexCreate | ( | void | ) |
Definition at line 182 of file InkIOCoreAPI.cc.
References new_ProxyMutex(), sdk_assert, sdk_sanity_check_mutex(), and TS_SUCCESS.
Referenced by SDK_API_HttpAltInfo(), SDK_API_HttpHookAdd(), SDK_API_HttpSsn(), SDK_API_HttpTxnCache(), SDK_API_HttpTxnTransform(), SDK_API_TSActionCancel(), SDK_API_TSCache(), SDK_API_TSContCreate(), SDK_API_TSContDataGet(), SDK_API_TSContMutexGet(), SDK_API_TSContSchedule(), SDK_API_TSHttpConnectIntercept(), SDK_API_TSHttpConnectServerIntercept(), SDK_API_TSMutexCreate(), SDK_API_TSNetVConn(), SDK_API_TSPortDescriptor(), SDK_API_TSTextLog(), synclient_txn_send_request(), synclient_txn_send_request_to_vc(), synserver_accept_handler(), synserver_create(), UDPClientTestInit(), and UDPTestInit().
tsapi void TSMutexLock | ( | TSMutex | mutexp | ) |
Definition at line 221 of file InkIOCoreAPI.cc.
References MUTEX_TAKE_LOCK, sdk_assert, sdk_sanity_check_mutex(), this_ethread(), and TS_SUCCESS.
Referenced by SDK_API_TSActionCancel(), and SDK_API_TSMutexCreate().
tsapi TSReturnCode TSMutexLockTry | ( | TSMutex | mutexp | ) |
Definition at line 229 of file InkIOCoreAPI.cc.
References MUTEX_TAKE_TRY_LOCK, sdk_assert, sdk_sanity_check_mutex(), this_ethread(), TS_ERROR, and TS_SUCCESS.
Referenced by SDK_API_TSContCreate(), and SDK_API_TSMutexCreate().
tsapi void TSMutexUnlock | ( | TSMutex | mutexp | ) |
Definition at line 236 of file InkIOCoreAPI.cc.
References MUTEX_UNTAKE_LOCK, sdk_assert, sdk_sanity_check_mutex(), this_ethread(), and TS_SUCCESS.
Referenced by SDK_API_TSActionCancel(), SDK_API_TSContCreate(), and SDK_API_TSMutexCreate().
Definition at line 6480 of file InkAPI.cc.
References NetProcessor::accept(), NetProcessor::AcceptOptions::accept_threads, FORCE_PLUGIN_MUTEX, NetProcessor::AcceptOptions::frequent_accept, NetProcessor::AcceptOptions::ip_family, NetProcessor::AcceptOptions::local_port, netProcessor, sdk_assert, sdk_sanity_check_continuation(), and TS_SUCCESS.
Referenced by SDK_API_TSNetVConn(), and synserver_start().
tsapi TSReturnCode TSNetAcceptNamedProtocol | ( | TSCont | contp, | |
const char * | protocol | |||
) |
Listen on all SSL ports for connections for the specified protocol name.
TSNetAcceptNamedProtocol registers the specified protocol for all statically configured TLS ports. When a client using the TLS Next Protocol Negotiation extension negotiates the requested protocol, TrafficServer will route the request to the given handler. Note that the protocol is not registered on ports opened by other plugins.
The event and data provided to the handler are the same as for TSNetAccept(). If a connection is successfully accepted, the event code will be TS_EVENT_NET_ACCEPT and the event data will be a valid TSVConn bound to the accepted connection.
Neither contp nor protocol are copied. They must remain valid for the lifetime of the plugin.
TSNetAcceptNamedProtocol fails if the requested protocol cannot be registered on all of the configured TLS ports. If it fails, the protocol will not be registered on any ports (ie.. no partial failure).
Opens a network connection to the host specified by ip on the port specified by port.
If the connection is successfully opened, contp is called back with the event TS_EVENT_NET_CONNECT and the new network vconnection will be passed in the event data parameter. If the connection is not successful, contp is called back with the event TS_EVENT_NET_CONNECT_FAILED.
Note: on Solaris, it is possible to receive TS_EVENT_NET_CONNECT even if the connection failed, because of the implementation of network sockets in the underlying operating system. There is an exception: if a plugin tries to open a connection to a port on its own host machine, then TS_EVENT_NET_CONNECT is sent only if the connection is successfully opened. In general, however, your plugin needs to look for an TS_EVENT_VCONN_WRITE_READY to be sure that the connection is successfully opened.
contp | continuation that is called back when the attempted net connection either succeeds or fails. | |
to | Address to which to connect. |
Referenced by SDK_API_TSNetVConn(), SDK_API_TSPortDescriptor(), and synclient_txn_send_request().
tsapi struct sockaddr const* TSNetVConnLocalAddrGet | ( | TSVConn | vc | ) | [read] |
Definition at line 6433 of file InkAPI.cc.
References NetVConnection::get_local_addr(), sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
tsapi struct sockaddr const* TSNetVConnRemoteAddrGet | ( | TSVConn | vc | ) | [read] |
Definition at line 6441 of file InkAPI.cc.
References NetVConnection::get_remote_addr(), sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by client_handler(), and spdy_fetcher_launch().
tsapi const char* TSPluginDirGet | ( | void | ) |
Gets the path of the plugin directory relative to the Traffic Server install directory.
For example, to open the file "config_ui.txt" in the plugin directory:
TSfopen("TSPluginInstallDirGet()/TSPluginDirGet()/config_ui.txt");
Definition at line 1737 of file InkAPI.cc.
References ats_free(), ink_strlcpy(), PATH_NAME_MAX, plugin_dir, and RecConfigReadPrefixPath().
Referenced by plugin_init(), remap_load_plugin(), and SDK_API_TSPluginDirGet().
tsapi TSReturnCode TSPluginRegister | ( | TSSDKVersion | sdk_version, | |
TSPluginRegistrationInfo * | plugin_info | |||
) |
This function registers your plugin with a particular version of Traffic Server SDK.
Use this function to make sure that the Traffic Server version currently running also supports your plugin. See the SDK sample code for usage.
sdk_version | earliest version of the Traffic Server SDK that supports your plugin. | |
plugin_info | contains registration information about your plugin. See TSPluginRegistrationInfo. |
Definition at line 1757 of file InkAPI.cc.
References ats_strdup, PluginRegInfo::plugin_name, plugin_reg_current, PluginRegInfo::plugin_registered, PLUGIN_SDK_VERSION_3_0, PLUGIN_SDK_VERSION_4_0, sdk_assert, sdk_sanity_check_null_ptr(), PluginRegInfo::sdk_version, PluginRegInfo::support_email, TS_SUCCESS, and PluginRegInfo::vendor_name.
tsapi TSReturnCode TSPortDescriptorAccept | ( | TSPortDescriptor | , | |
TSCont | ||||
) |
Start listening on the given port descriptor.
If a connection is successfully accepted, the TS_EVENT_NET_ACCEPT is delivered to the continuation. The event data will be a valid TSVConn bound to the accepted connection.
Definition at line 8541 of file InkAPI.cc.
References HttpProxyPort::isSSL(), HttpProxyPort::m_fd, NetProcessor::main_accept(), make_net_accept_options(), netProcessor, sslNetProcessor, and TS_SUCCESS.
Referenced by SDK_API_TSPortDescriptor().
tsapi TSPortDescriptor TSPortDescriptorParse | ( | const char * | descriptor | ) |
Create a new port from the string specification used by the proxy.config.http.server_ports configuration value.
Definition at line 8528 of file InkAPI.cc.
References HttpProxyPort::processOptions().
Referenced by SDK_API_TSPortDescriptor().
tsapi void TSRecordDump | ( | int | rec_type, | |
TSRecordDumpCb | callback, | |||
void * | edata | |||
) |
Definition at line 7489 of file InkAPI.cc.
References RecDumpRecords().
tsapi TS_DEPRECATED const char* TSRedirectUrlGet | ( | TSHttpTxn | txnp, | |
int * | url_len_ptr | |||
) |
Definition at line 7207 of file InkAPI.cc.
References TSHttpTxnRedirectUrlGet().
tsapi TS_DEPRECATED void TSRedirectUrlSet | ( | TSHttpTxn | txnp, | |
const char * | url, | |||
const int | url_len | |||
) |
Definition at line 7169 of file InkAPI.cc.
References ats_free(), ats_malloc(), HttpSM::enable_redirection, ink_strlcpy(), HttpConfig::m_master, HttpConfigParams::number_of_redirections, HttpSM::redirect_url, HttpSM::redirect_url_len, HttpSM::redirection_tries, sdk_assert, sdk_sanity_check_null_ptr(), sdk_sanity_check_txn(), and TS_SUCCESS.
tsapi void TSSkipRemappingSet | ( | TSHttpTxn | txnp, | |
int | flag | |||
) |
Definition at line 7498 of file InkAPI.cc.
References HttpTransact::State::api_skip_all_remapping, sdk_assert, sdk_sanity_check_txn(), HttpSM::t_state, and TS_SUCCESS.
Referenced by altinfo_hook_handler(), cache_hook_handler(), mytest_handler(), ssn_handler(), and transform_hook_handler().
tsapi int TSStatCreate | ( | const char * | the_name, | |
TSRecordDataType | the_type, | |||
TSStatPersistence | persist, | |||
TSStatSync | sync | |||
) |
Definition at line 6652 of file InkAPI.cc.
References api_rsb_index, RECP_NON_PERSISTENT, RECP_PERSISTENT, RecRegisterRawStat, RECT_PLUGIN, sdk_sanity_check_null_ptr(), TS_STAT_NON_PERSISTENT, TS_STAT_PERSISTENT, TS_STAT_SYNC_AVG, TS_STAT_SYNC_SUM, TS_STAT_SYNC_TIMEAVG, and TS_SUCCESS.
tsapi TSReturnCode TSStatFindName | ( | const char * | name, | |
int * | idp | |||
) |
Definition at line 6722 of file InkAPI.cc.
References REC_ERR_OKAY, RecGetRecordOrderAndId(), sdk_assert, sdk_sanity_check_null_ptr(), and TS_SUCCESS.
tsapi void TSStatIntDecrement | ( | int | the_stat, | |
TSMgmtInt | amount | |||
) |
Definition at line 6701 of file InkAPI.cc.
References RecDecrRawStat().
tsapi TSMgmtInt TSStatIntGet | ( | int | the_stat | ) |
Definition at line 6707 of file InkAPI.cc.
References RecGetGlobalRawStatSum().
tsapi void TSStatIntIncrement | ( | int | the_stat, | |
TSMgmtInt | amount | |||
) |
Definition at line 6695 of file InkAPI.cc.
References RecIncrRawStat().
tsapi void TSStatIntSet | ( | int | the_stat, | |
TSMgmtInt | value | |||
) |
Definition at line 6716 of file InkAPI.cc.
References RecSetGlobalRawStatSum().
tsapi TSReturnCode TSStringPercentDecode | ( | const char * | str, | |
size_t | str_len, | |||
char * | dst, | |||
size_t | dst_size, | |||
size_t * | length | |||
) |
Perform percent-decoding of the string in the buffer, writing to the output buffer.
The source and destination can be the same, in which case they overwrite. The decoded string is always guaranteed to be no longer than the source string.
str | the string to decode (and possibly write to). | |
str_len | length of the input string (or 0). | |
dst | output buffer (can be the same as src). | |
dst_len | size of the output buffer. | |
length | amount of data written to the destination buffer. |
Definition at line 2306 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_null_ptr(), TS_SUCCESS, and unescape_str().
Referenced by SDK_API_ENCODING().
tsapi TSReturnCode TSStringPercentEncode | ( | const char * | str, | |
int | str_len, | |||
char * | dst, | |||
size_t | dst_size, | |||
size_t * | length, | |||
const unsigned char * | map | |||
) |
Perform percent-encoding of the string in the buffer, storing the new string in the destination buffer.
The length parameter will be set to the new (encoded) string length, or 0 if the encoding failed.
str | the string buffer to encode. | |
str_len | length of the string buffer. | |
dst | destination buffer. | |
dst_size | size of the destination buffer. | |
length | amount of data written to the destination buffer. | |
map | optional (can be NULL) map of characters to encode. |
Definition at line 2280 of file InkAPI.cc.
References LogUtils::escapify_url(), sdk_assert, sdk_sanity_check_null_ptr(), and TS_SUCCESS.
Referenced by SDK_API_ENCODING(), and TSUrlPercentEncode().
tsapi TSReturnCode TSTextLogObjectCreate | ( | const char * | filename, | |
int | mode, | |||
TSTextLogObject * | new_log_obj | |||
) |
Creates a new custom log file that your plugin can write to.
You can design the fields and inputs to the log file using the TSTextLogObjectWrite() function. The logs you create are treated like ordinary logs; they are rolled if log rolling is enabled. (Log collation is not supported though).
filename | new log file being created. The new log file is created in the logs directory. You can specify a path to a subdirectory within the log directory, e.g. subdir/filename, but make sure you create the subdirectory first. If you do not specify a file name extension, the extension ".log" is automatically added. | |
mode | is one (or both) of the following:
| |
new_log_obj | new custom log file. |
Definition at line 6783 of file InkAPI.cc.
References Log::config, LogConfig::log_object_manager, LogObjectManager::manage_api_object(), LogObjectManager::NO_FILENAME_CONFLICTS, sdk_assert, sdk_sanity_check_null_ptr(), TS_LOG_MODE_ADD_TIMESTAMP, TS_LOG_MODE_DO_NOT_RENAME, TS_LOG_MODE_INVALID_FLAG, and TS_SUCCESS.
Referenced by SDK_API_TSTextLog().
tsapi TSReturnCode TSTextLogObjectDestroy | ( | TSTextLogObject | the_object | ) |
Destroys a log object and releases the memory allocated to it.
Use this call if you are done with the log.
the_object | custom log to be destroyed. |
Definition at line 6857 of file InkAPI.cc.
References Log::config, sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by log_test_handler().
tsapi TSReturnCode tsapi void TSTextLogObjectFlush | ( | TSTextLogObject | the_object | ) |
This immediately flushes the contents of the log write buffer for the_object to disk.
Use this call only if you want to make sure that log entries are flushed immediately. This call has a performance cost. Traffic Server flushes the log buffer automatically about every 1 second.
the_object | custom log file whose write buffer is to be flushed. |
Definition at line 6849 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by SDK_API_TSTextLog().
tsapi void TSTextLogObjectHeaderSet | ( | TSTextLogObject | the_object, | |
const char * | header | |||
) |
Set log header.
Definition at line 6868 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
tsapi TSReturnCode TSTextLogObjectRollingEnabledSet | ( | TSTextLogObject | the_object, | |
int | rolling_enabled | |||
) |
Enable/disable rolling.
rolling_enabled | a valid proxy.config.log.rolling_enabled value. |
Definition at line 6876 of file InkAPI.cc.
References LogRollingEnabledIsValid(), sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
tsapi void TSTextLogObjectRollingIntervalSecSet | ( | TSTextLogObject | the_object, | |
int | rolling_interval_sec | |||
) |
Set the rolling interval.
Definition at line 6889 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
tsapi void TSTextLogObjectRollingOffsetHrSet | ( | TSTextLogObject | the_object, | |
int | rolling_offset_hr | |||
) |
Set the rolling offset.
rolling_offset_hr specifies the hour (between 0 and 23) when log rolling should take place.
Definition at line 6897 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
tsapi TSReturnCode TSTextLogObjectWrite | ( | TSTextLogObject | the_object, | |
const char * | format, | |||
... | ||||
) |
Writes a printf-style formatted statement to an TSTextLogObject (a plugin custom log).
the_object | log object to write to. You must first create this object with TSTextLogObjectCreate(). | |
format | printf-style formatted statement to be printed. | |
... | parameters in the formatted statement. A newline is automatically added to the end. |
Referenced by SDK_API_TSTextLog().
tsapi TSThread TSThreadCreate | ( | TSThreadFunc | func, | |
void * | data | |||
) |
Definition at line 124 of file InkIOCoreAPI.cc.
References INKThreadInternal::data, EThread::event_types, INKThreadInternal::func, ink_assert, ink_thread_create(), and ink_thread_trampoline().
Referenced by SDK_API_TSThread().
tsapi void TSThreadDestroy | ( | TSThread | thread | ) |
Definition at line 160 of file InkIOCoreAPI.cc.
References sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by pthread_start_func().
tsapi TSThread TSThreadInit | ( | void | ) |
Definition at line 143 of file InkIOCoreAPI.cc.
References Thread::set_specific().
Referenced by pthread_start_func().
tsapi TSThread TSThreadSelf | ( | void | ) |
Definition at line 169 of file InkIOCoreAPI.cc.
References this_ethread().
Referenced by SDK_API_TSThread(), and thread_create_handler().
tsapi const char* TSTrafficServerVersionGet | ( | void | ) |
Gets the version of Traffic Server currently running.
Use this function to make sure that the plugin version and Traffic Server version are compatible. See the SDK sample code for usage.
Definition at line 1727 of file InkAPI.cc.
References traffic_server_version.
Referenced by SDK_API_TSTrafficServerVersionGet().
int TSTrafficServerVersionGetMajor | ( | void | ) |
Get the major version of Traffic Server currently running.
This is the same as the first element of the string returned by TSTrafficServerVersionGet
Definition at line 1732 of file InkAPI.cc.
References ts_major_version.
int TSTrafficServerVersionGetMinor | ( | void | ) |
Get the minor version of Traffic Server currently running.
This is the same as the second element of the string returned by TSTrafficServerVersionGet
Definition at line 1733 of file InkAPI.cc.
References ts_minor_version.
int TSTrafficServerVersionGetPatch | ( | void | ) |
Get the patch version of Traffic Server currently running.
This is the same as the third element of the string returned by TSTrafficServerVersionGet
Definition at line 1734 of file InkAPI.cc.
References ts_patch_version.
tsapi TSVConn TSTransformCreate | ( | TSEventFunc | event_funcp, | |
TSHttpTxn | txnp | |||
) |
Definition at line 6341 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_txn(), TS_SUCCESS, TSContMutexGet(), and TSVConnCreate().
Referenced by transform_add().
Definition at line 6350 of file InkAPI.cc.
References VConnection::get_data(), sdk_assert, sdk_sanity_check_iocore_structure(), TS_API_DATA_OUTPUT_VC, and TS_SUCCESS.
Referenced by handle_transform(), and transformtest_transform().
tsapi TSReturnCode TSUrlClone | ( | TSMBuffer | dest_bufp, | |
TSMBuffer | src_bufp, | |||
TSMLoc | src_url, | |||
TSMLoc * | locp | |||
) |
Copies the URL located at src_url within src_bufp to a URL location within the marshal buffer dest_bufp, and returns the TSMLoc location of the copied URL.
Unlike TSUrlCopy(), you do not have to create the destination URL before cloning. Release the returned TSMLoc handle with a call to TSHandleMLocRelease().
dest_bufp | marshal buffer containing the cloned URL. | |
src_bufp | marshal buffer containing the URL to be cloned. | |
src_url | location of the URL to be cloned, within the marshal buffer src_bufp. | |
locp | pointer to a TSMLoc to store the MLoc into. |
Definition at line 1951 of file InkAPI.cc.
References isWriteable(), sdk_assert, sdk_sanity_check_mbuffer(), sdk_sanity_check_null_ptr(), sdk_sanity_check_url_handle(), TS_SUCCESS, and url_copy().
Referenced by SDK_API_TSUrl().
tsapi TSReturnCode TSUrlCopy | ( | TSMBuffer | dest_bufp, | |
TSMLoc | dest_offset, | |||
TSMBuffer | src_bufp, | |||
TSMLoc | src_offset | |||
) |
Copies the contents of the URL at location src_loc within the marshal buffer src_bufp to the location dest_loc within the marshal buffer dest_bufp.
TSUrlCopy() works correctly even if src_bufp and dest_bufp point to different marshal buffers. Important: create the destination URL before copying into it. Use TSUrlCreate().
dest_bufp | marshal buffer to contain the copied URL. | |
dest_offset | location of the URL to be copied. | |
src_bufp | marshal buffer containing the source URL. | |
src_offset | location of the source URL within src_bufp. |
Definition at line 1974 of file InkAPI.cc.
References isWriteable(), sdk_assert, sdk_sanity_check_mbuffer(), sdk_sanity_check_url_handle(), TS_SUCCESS, and url_copy_onto().
Referenced by SDK_API_TSUrl().
tsapi TSReturnCode TSUrlCreate | ( | TSMBuffer | bufp, | |
TSMLoc * | locp | |||
) |
Creates a new URL within the marshal buffer bufp.
Returns a location for the URL within the marshal buffer.
bufp | marshal buffer containing the new URL. | |
locp | pointer to a TSMLoc to store the MLoc into. |
Definition at line 1931 of file InkAPI.cc.
References isWriteable(), sdk_assert, sdk_sanity_check_mbuffer(), sdk_sanity_check_null_ptr(), TS_SUCCESS, and url_create().
Referenced by SDK_API_TSHttpHdr(), SDK_API_TSUrl(), and SDK_API_TSUrlParse().
tsapi TS_DEPRECATED TSReturnCode TSUrlDestroy | ( | TSMBuffer | bufp, | |
TSMLoc | offset | |||
) |
Destroys the URL located at url_loc within the marshal buffer bufp.
Do not forget to release the TSMLoc url_loc with a call to TSHandleMLocRelease().
bufp | marshal buffer containing the URL to be destroyed. | |
offset | location of the URL to be destroyed. |
Should be removed for v5.0.0
Retrieves the FTP type of the URL located at url_loc within bufp.
Definition at line 2208 of file InkAPI.cc.
References HdrHeapSDKHandle::m_heap, URL::m_url_impl, sdk_assert, sdk_sanity_check_mbuffer(), sdk_sanity_check_url_handle(), TS_SUCCESS, and URL::type_get().
Referenced by SDK_API_TSUrl().
tsapi TSReturnCode TSUrlFtpTypeSet | ( | TSMBuffer | bufp, | |
TSMLoc | offset, | |||
int | type | |||
) |
Sets the FTP type portion of the URL located at url_loc within bufp to the value type.
bufp | marshal buffer containing the URL. | |
offset | location of the URL to modify. | |
type | new FTP type for the URL. |
Definition at line 2220 of file InkAPI.cc.
References isWriteable(), HdrHeapSDKHandle::m_heap, URL::m_url_impl, sdk_assert, sdk_sanity_check_mbuffer(), sdk_sanity_check_url_handle(), TS_SUCCESS, and URL::type_set().
Referenced by SDK_API_TSUrl().
Retrieves the host portion of the URL located at url_loc within bufp.
Note: the returned string is not guaranteed to be null-terminated.
bufp | marshal buffer containing the URL. | |
offset | location of the URL. | |
length | of the returned string. |
Definition at line 2150 of file InkAPI.cc.
References URL::host_get(), and URLPartGet().
Referenced by SDK_API_TSHttpHdr(), and SDK_API_TSUrl().
tsapi TSReturnCode TSUrlHostSet | ( | TSMBuffer | bufp, | |
TSMLoc | offset, | |||
const char * | value, | |||
int | length | |||
) |
Sets the host portion of the URL at url_loc to the string value.
If length is -1 then TSUrlHostSet() assumes that value is null-terminated. Otherwise, the length of the string value is taken to be length. The string is copied to within bufp, so you can modify or delete value after calling TSUrlHostSet().
bufp | marshal buffer containing the URL to modify. | |
offset | location of the URL. | |
value | new host name for the URL. | |
length | string length of the new host name of the URL. |
Definition at line 2156 of file InkAPI.cc.
References URL::host_set(), and URLPartSet().
Referenced by SDK_API_TSHttpHdr(), and SDK_API_TSUrl().
Retrieves the HTTP fragment portion of the URL located at url_loc within bufp.
The length of the returned string is in the length argument. Note: the returned string is not guaranteed to be null-terminated.
bufp | marshal buffer containing the URL. | |
offset | location of the URL. | |
length | of the returned string. |
Definition at line 2267 of file InkAPI.cc.
References URL::fragment_get(), and URLPartGet().
Referenced by SDK_API_TSUrl().
tsapi TSReturnCode TSUrlHttpFragmentSet | ( | TSMBuffer | bufp, | |
TSMLoc | offset, | |||
const char * | value, | |||
int | length | |||
) |
Sets the HTTP fragment portion of the URL located at url_loc within bufp to value.
If length is -1, the string value is assumed to be null-terminated; otherwise, the length of value is taken to be length. TSUrlHttpFragmentSet() copies the string to within bufp, so you can modify or delete value after calling TSUrlHttpFragmentSet().
bufp | marshal buffer containing the URL. | |
offset | location of the URL within bufp. | |
value | new HTTP fragment string for the URL. | |
length | of the new HTTP query string. |
Definition at line 2273 of file InkAPI.cc.
References URL::fragment_set(), and URLPartSet().
Referenced by SDK_API_TSUrl().
Retrieves the HTTP params portion of the URL located at url_loc within bufp.
The length of the returned string is in the length argument. Note: the returned string is not guaranteed to be null-terminated.
bufp | marshal buffer containing the URL. | |
offset | location of the URL. | |
length | of the returned string. |
Definition at line 2243 of file InkAPI.cc.
References URL::params_get(), and URLPartGet().
Referenced by SDK_API_TSUrl().
tsapi TSReturnCode TSUrlHttpParamsSet | ( | TSMBuffer | bufp, | |
TSMLoc | offset, | |||
const char * | value, | |||
int | length | |||
) |
Sets the HTTP params portion of the URL located at url_loc within bufp to the string value.
If length is -1 that TSUrlHttpParamsSet() assumes that value is null-terminated. Otherwise, the length of the string value is taken to be length. TSUrlHttpParamsSet() copies the string to within bufp, so you can modify or delete value after calling TSUrlHttpParamsSet().
bufp | marshal buffer containing the URL. | |
offset | location of the URL. | |
value | HTTP params string to set in the URL. | |
length | string length of the new HTTP params value. |
Definition at line 2249 of file InkAPI.cc.
References URL::params_set(), and URLPartSet().
Referenced by SDK_API_TSUrl().
Retrieves the HTTP query portion of the URL located at url_loc within bufp.
The length of the returned string is in the length argument. Note: the returned string is not guaranteed to be null-terminated.
bufp | marshal buffer containing the URL. | |
offset | location of the URL. | |
length | of the returned string. |
Definition at line 2255 of file InkAPI.cc.
References URL::query_get(), and URLPartGet().
Referenced by SDK_API_TSUrl().
tsapi TSReturnCode TSUrlHttpQuerySet | ( | TSMBuffer | bufp, | |
TSMLoc | offset, | |||
const char * | value, | |||
int | length | |||
) |
Sets the HTTP query portion of the URL located at url_loc within bufp to value.
If length is -1, the string value is assumed to be null-terminated; otherwise, the length of value is taken to be length. TSUrlHttpQuerySet() copies the string to within bufp, so you can modify or delete value after calling TSUrlHttpQuerySet().
bufp | marshal buffer containing the URL. | |
offset | location of the URL within bufp. | |
value | new HTTP query string for the URL. | |
length | of the new HTTP query string. |
Definition at line 2261 of file InkAPI.cc.
References URL::query_set(), and URLPartSet().
Referenced by SDK_API_TSUrl().
Calculates the length of the URL located at url_loc within the marshal buffer bufp if it were returned as a string.
This length is the same as the length returned by TSUrlStringGet().
bufp | marshal buffer containing the URL whose length you want. | |
offset | location of the URL within the marshal buffer bufp. |
Definition at line 2051 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_mbuffer(), sdk_sanity_check_url_handle(), TS_SUCCESS, and url_length_get().
Referenced by SDK_API_TSUrl().
tsapi TSParseResult TSUrlParse | ( | TSMBuffer | bufp, | |
TSMLoc | offset, | |||
const char ** | start, | |||
const char * | end | |||
) |
Parses a URL.
The start pointer is both an input and an output parameter and marks the start of the URL to be parsed. After a successful parse, the start pointer equals the end pointer. The end pointer must be one byte after the last character you want to parse. The URL parsing routine assumes that everything between start and end is part of the URL. It is up to higher level parsing routines, such as TSHttpHdrParseReq(), to determine the actual end of the URL. Returns TS_PARSE_ERROR if an error occurs, otherwise TS_PARSE_DONE is returned to indicate success.
bufp | marshal buffer containing the URL to be parsed. | |
offset | location of the URL to be parsed. | |
start | points to the start of the URL to be parsed AND at the end of a successful parse it will equal the end pointer. | |
end | must be one byte after the last character. |
Definition at line 2032 of file InkAPI.cc.
References isWriteable(), HdrHeapSDKHandle::m_heap, URL::m_url_impl, URL::parse(), sdk_assert, sdk_sanity_check_mbuffer(), sdk_sanity_check_null_ptr(), sdk_sanity_check_url_handle(), TS_SUCCESS, and url_clear().
Referenced by SDK_API_TSUrlParse().
Retrieves the password portion of the URL located at url_loc within bufp.
TSUrlPasswordGet() places the length of the returned string in the length argument. Note: the returned string is not guaranteed to be null-terminated.
bufp | marshal buffer containing the URL. | |
offset | ||
length | of the returned password string. |
Definition at line 2138 of file InkAPI.cc.
References URL::password_get(), and URLPartGet().
Referenced by SDK_API_TSUrl().
tsapi TSReturnCode TSUrlPasswordSet | ( | TSMBuffer | bufp, | |
TSMLoc | offset, | |||
const char * | value, | |||
int | length | |||
) |
Sets the password portion of the URL located at url_loc within bufp to the string value.
If length is -1 then TSUrlPasswordSet() assumes that value is null-terminated. Otherwise, the length of value is taken to be length. TSUrlPasswordSet() copies the string to within bufp, so it is okay to modify or delete value after calling TSUrlPasswordSet().
bufp | marshal buffer containing the URL. | |
offset | ||
value | new password. | |
length | of the new password. |
Definition at line 2144 of file InkAPI.cc.
References URL::password_set(), and URLPartSet().
Referenced by SDK_API_TSUrl().
Retrieves the path portion of the URL located at url_loc within bufp.
TSUrlPathGet() places the length of the returned string in the length argument. Note: the returned string is not guaranteed to be null-terminated.
bufp | marshal buffer containing the URL. | |
offset | location of the URL. | |
length | of the returned string. |
Definition at line 2194 of file InkAPI.cc.
References URL::path_get(), and URLPartGet().
Referenced by SDK_API_TSHttpHdr(), and SDK_API_TSUrl().
tsapi TSReturnCode TSUrlPathSet | ( | TSMBuffer | bufp, | |
TSMLoc | offset, | |||
const char * | value, | |||
int | length | |||
) |
Sets the path portion of the URL located at url_loc within bufp to the string value.
If length is -1 then TSUrlPathSet() assumes that value is null-terminated. Otherwise, the length of the value is taken to be length. TSUrlPathSet() copies the string into bufp, so you can modify or delete value after calling TSUrlPathSet().
bufp | marshal buffer containing the URL. | |
offset | location of the URL. | |
value | new path string for the URL. | |
length | of the new path string. |
Definition at line 2200 of file InkAPI.cc.
References URL::path_set(), and URLPartSet().
Referenced by SDK_API_TSHttpHdr(), and SDK_API_TSUrl().
tsapi TSReturnCode TSUrlPercentEncode | ( | TSMBuffer | bufp, | |
TSMLoc | offset, | |||
char * | dst, | |||
size_t | dst_size, | |||
size_t * | length, | |||
const unsigned char * | map | |||
) |
Similar to TSStringPercentEncode(), but works on a URL object.
bufp | marshal buffer containing the URL. | |
offset | location of the URL within bufp. | |
dst | destination buffer. | |
dst_size | size of the destination buffer. | |
length | amount of data written to the destination buffer. | |
map | optional (can be NULL) map of characters to encode. |
Definition at line 2329 of file InkAPI.cc.
References ats_free(), sdk_assert, sdk_sanity_check_mbuffer(), sdk_sanity_check_url_handle(), TS_SUCCESS, TSStringPercentEncode(), and url_string_get().
Retrieves the port portion of the URL located at url_loc.
Definition at line 2162 of file InkAPI.cc.
References HdrHeapSDKHandle::m_heap, URL::m_url_impl, URL::port_get(), sdk_assert, sdk_sanity_check_mbuffer(), sdk_sanity_check_url_handle(), and TS_SUCCESS.
Referenced by SDK_API_TSHttpHdr(), and SDK_API_TSUrl().
tsapi TSReturnCode TSUrlPortSet | ( | TSMBuffer | bufp, | |
TSMLoc | offset, | |||
int | port | |||
) |
Sets the port portion of the URL located at url_loc.
bufp | marshal buffer containing the URL. | |
offset | location of the URL. | |
port | new port setting for the URL. |
Definition at line 2175 of file InkAPI.cc.
References isWriteable(), HdrHeapSDKHandle::m_heap, URL::m_url_impl, URL::port_set(), sdk_assert, sdk_sanity_check_mbuffer(), sdk_sanity_check_url_handle(), and TS_SUCCESS.
Referenced by SDK_API_TSHttpHdr(), and SDK_API_TSUrl().
tsapi void TSUrlPrint | ( | TSMBuffer | bufp, | |
TSMLoc | offset, | |||
TSIOBuffer | iobufp | |||
) |
Formats a URL stored in an TSMBuffer into an TSIOBuffer.
bufp | marshal buffer contain the URL to be printed. | |
offset | location of the URL within bufp. | |
iobufp | destination TSIOBuffer for the URL. |
Definition at line 1997 of file InkAPI.cc.
References MIOBuffer::add_block(), IOBufferBlock::end(), MIOBuffer::fill(), MIOBuffer::get_current_block(), HdrHeapSDKHandle::m_heap, URL::m_url_impl, URL::print(), sdk_assert, sdk_sanity_check_iocore_structure(), sdk_sanity_check_mbuffer(), sdk_sanity_check_url_handle(), TS_SUCCESS, and IOBufferBlock::write_avail().
Referenced by test_url_print().
Retrieves the scheme portion of the URL located at url_loc within the marshal buffer bufp.
TSUrlSchemeGet() places the length of the string in the length argument. If the length is NULL then no attempt is made to dereference it.
bufp | marshal buffer storing the URL. | |
offset | location of the URL within bufp. | |
length | length of the returned string. |
Definition at line 2112 of file InkAPI.cc.
References URL::scheme_get(), and URLPartGet().
Referenced by SDK_API_TSHttpHdr(), and SDK_API_TSUrl().
tsapi TSReturnCode TSUrlSchemeSet | ( | TSMBuffer | bufp, | |
TSMLoc | offset, | |||
const char * | value, | |||
int | length | |||
) |
Sets the scheme portion of the URL located at url_loc within the marshal buffer bufp to the string value.
If length is -1 then TSUrlSchemeSet() assumes that value is null-terminated. Otherwise, the length of the string value is taken to be length. TSUrlSchemeSet() copies the string to within bufp, so it is OK to modify or delete value after calling TSUrlSchemeSet().
bufp | marshal buffer containing the URL. | |
offset | location of the URL. | |
value | value to set the URL's scheme to. | |
length | string stored in value. |
Definition at line 2118 of file InkAPI.cc.
References URL::scheme_set(), and URLPartSet().
Referenced by SDK_API_TSHttpHdr(), and SDK_API_TSUrl().
Constructs a string representation of the URL located at url_loc within bufp.
TSUrlStringGet() stores the length of the allocated string in the parameter length. This is the same length that TSUrlLengthGet() returns. The returned string is allocated by a call to TSmalloc(). It should be freed by a call to TSfree(). The length parameter must present, providing storage for the URL string length value. Note: To get the effective URL from a request, use the alternative TSHttpTxnEffectiveUrlStringGet API.
bufp | marshal buffer containing the URL you want to get. | |
offset | location of the URL within bufp. | |
length | string length of the URL. |
Definition at line 2061 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_mbuffer(), sdk_sanity_check_null_ptr(), sdk_sanity_check_url_handle(), TS_SUCCESS, and url_string_get().
Referenced by SDK_API_TSUrl(), and SDK_API_TSUrlParse().
Retrieves the user portion of the URL located at url_loc within bufp.
Note: the returned string is not guaranteed to be null-terminated.
bufp | marshal buffer containing the URL. | |
offset | location of the URL. | |
length | length of the returned string. |
Definition at line 2126 of file InkAPI.cc.
References URLPartGet(), and URL::user_get().
Referenced by SDK_API_TSUrl().
tsapi TSReturnCode TSUrlUserSet | ( | TSMBuffer | bufp, | |
TSMLoc | offset, | |||
const char * | value, | |||
int | length | |||
) |
Sets the user portion of the URL located at url_loc within bufp to the string value.
If length is -1 then TSUrlUserSet() assumes that value is null-terminated. Otherwise, the length of the string value is taken to be length. TSUrlUserSet() copies the string to within bufp, so it is OK to modify or delete value after calling TSUrlUserSet().
bufp | marshal buffer containing the URL. | |
offset | location of the URL whose user is to be set. | |
value | holds the new user name. | |
length | string length of value. |
Definition at line 2132 of file InkAPI.cc.
References URLPartSet(), and URL::user_set().
Referenced by SDK_API_TSUrl().
tsapi void TSVConnAbort | ( | TSVConn | connp, | |
int | error | |||
) |
Definition at line 6295 of file InkAPI.cc.
References VConnection::do_io_close(), sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
tsapi void TSVConnActiveTimeoutCancel | ( | TSVConn | connp | ) |
Definition at line 6424 of file InkAPI.cc.
References NetVConnection::cancel_active_timeout(), sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Definition at line 6415 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_iocore_structure(), NetVConnection::set_active_timeout(), and TS_SUCCESS.
tsapi int64_t TSVConnCacheObjectSizeGet | ( | TSVConn | connp | ) |
Definition at line 6320 of file InkAPI.cc.
References CacheVC::get_object_size(), sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by cache_handler().
tsapi void TSVConnClose | ( | TSVConn | connp | ) |
Definition at line 6286 of file InkAPI.cc.
References VConnection::do_io_close(), sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by cache_handler(), SpdyClientSession::clear(), client_handler(), synclient_txn_close(), and synserver_txn_close().
tsapi int TSVConnClosedGet | ( | TSVConn | connp | ) |
Definition at line 6246 of file InkAPI.cc.
References VConnection::get_data(), sdk_assert, sdk_sanity_check_iocore_structure(), TS_API_DATA_CLOSED, and TS_SUCCESS.
Referenced by transformtest_transform().
tsapi TSVConn TSVConnCreate | ( | TSEventFunc | event_funcp, | |
TSMutex | mutexp | |||
) |
Definition at line 6149 of file InkAPI.cc.
References INKVConnAllocator, new_ProxyMutex(), sdk_assert, sdk_sanity_check_mutex(), sdk_sanity_check_null_ptr(), and TS_SUCCESS.
Referenced by TSTransformCreate().
tsapi TSVConn TSVConnFdCreate | ( | int | fd | ) |
Definition at line 6182 of file InkAPI.cc.
References UnixNetVConnection::action_, NetProcessor::allocate_vc(), UnixNetVConnection::connectUp(), UnixNetVConnection::free(), UnixNetVConnection::id, ink_get_hrtime(), Continuation::mutex, net_connections_currently_open_stat, net_next_connection_number(), NET_SUM_GLOBAL_DYN_STAT, netProcessor, new_ProxyMutex(), NO_FD, NetVConnection::set_is_transparent(), UnixNetVConnection::submit_time, this_ethread(), and unlikely.
tsapi void TSVConnInactivityTimeoutCancel | ( | TSVConn | connp | ) |
Definition at line 6406 of file InkAPI.cc.
References NetVConnection::cancel_inactivity_timeout(), sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Definition at line 6397 of file InkAPI.cc.
References sdk_assert, sdk_sanity_check_iocore_structure(), NetVConnection::set_inactivity_timeout(), and TS_SUCCESS.
tsapi TSVIO TSVConnRead | ( | TSVConn | connp, | |
TSCont | contp, | |||
TSIOBuffer | bufp, | |||
int64_t | nbytes | |||
) |
Definition at line 6258 of file InkAPI.cc.
References VConnection::do_io(), FORCE_PLUGIN_MUTEX, VIO::READ, sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by cache_handler(), server_handler(), synclient_txn_write_request_handler(), and synserver_accept_handler().
Definition at line 6216 of file InkAPI.cc.
References VConnection::get_data(), sdk_assert, sdk_sanity_check_iocore_structure(), TS_API_DATA_READ_VIO, and TS_SUCCESS.
tsapi void TSVConnShutdown | ( | TSVConn | connp, | |
int | read, | |||
int | write | |||
) |
Definition at line 6304 of file InkAPI.cc.
References VConnection::do_io_shutdown(), IO_SHUTDOWN_READ, IO_SHUTDOWN_READWRITE, IO_SHUTDOWN_WRITE, sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by synserver_txn_read_request_handler(), synserver_txn_write_response_handler(), and transformtest_transform().
tsapi TSVIO TSVConnWrite | ( | TSVConn | connp, | |
TSCont | contp, | |||
TSIOBufferReader | readerp, | |||
int64_t | nbytes | |||
) |
Definition at line 6272 of file InkAPI.cc.
References VConnection::do_io_write(), FORCE_PLUGIN_MUTEX, sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by cache_handler(), handle_transform(), synclient_txn_write_request(), and synserver_txn_write_response().
Definition at line 6231 of file InkAPI.cc.
References VConnection::get_data(), sdk_assert, sdk_sanity_check_iocore_structure(), TS_API_DATA_WRITE_VIO, and TS_SUCCESS.
Referenced by handle_transform(), and transformtest_transform().
tsapi TSIOBuffer TSVIOBufferGet | ( | TSVIO | viop | ) |
Definition at line 254 of file InkIOCoreAPI.cc.
References VIO::get_writer(), sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by cache_handler(), and handle_transform().
Definition at line 319 of file InkIOCoreAPI.cc.
References VIO::_cont, sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by cache_handler(), handle_transform(), and transformtest_transform().
Definition at line 337 of file InkIOCoreAPI.cc.
References VIO::mutex, sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by cache_handler().
tsapi int64_t TSVIONBytesGet | ( | TSVIO | viop | ) |
Definition at line 272 of file InkIOCoreAPI.cc.
References VIO::nbytes, sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by cache_handler(), and handle_transform().
tsapi void TSVIONBytesSet | ( | TSVIO | viop, | |
int64_t | nbytes | |||
) |
Definition at line 281 of file InkIOCoreAPI.cc.
References VIO::nbytes, sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by cache_handler(), and handle_transform().
tsapi int64_t TSVIONDoneGet | ( | TSVIO | viop | ) |
Definition at line 291 of file InkIOCoreAPI.cc.
References VIO::ndone, sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by cache_handler(), handle_transform(), and spdy_process_write().
tsapi void TSVIONDoneSet | ( | TSVIO | viop, | |
int64_t | ndone | |||
) |
Definition at line 300 of file InkIOCoreAPI.cc.
References VIO::ndone, sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by cache_handler(), and handle_transform().
tsapi int64_t TSVIONTodoGet | ( | TSVIO | viop | ) |
Definition at line 310 of file InkIOCoreAPI.cc.
References VIO::ntodo(), sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by cache_handler(), and handle_transform().
tsapi TSIOBufferReader TSVIOReaderGet | ( | TSVIO | viop | ) |
Definition at line 263 of file InkIOCoreAPI.cc.
References VIO::get_reader(), sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by cache_handler(), and handle_transform().
tsapi void TSVIOReenable | ( | TSVIO | viop | ) |
Definition at line 245 of file InkIOCoreAPI.cc.
References VIO::reenable(), sdk_assert, sdk_sanity_check_iocore_structure(), and TS_SUCCESS.
Referenced by cache_handler(), handle_transform(), spdy_on_ctrl_recv_callback(), spdy_on_data_recv_callback(), spdy_on_data_send_callback(), spdy_prepare_status_response_and_clean_request(), spdy_process_fetch_body(), spdy_process_fetch_header(), spdy_process_write(), spdy_read_fetch_body_callback(), spdy_recv_callback(), synclient_txn_read_response_handler(), synclient_txn_write_request_handler(), synserver_txn_read_request_handler(), and synserver_txn_write_response_handler().
Definition at line 328 of file InkIOCoreAPI.cc.
References sdk_assert, sdk_sanity_check_iocore_structure(), TS_SUCCESS, and VIO::vc_server.
Referenced by cache_handler().
tsapi void tsapi void int diags_on_for_plugins |
Definition at line 48 of file Diags.cc.
Referenced by Diags::Diags().