Implements unit test for SDK APIs. More...
#include "Regression.h"
#include "api/ts/ts.h"
#include <arpa/inet.h>
#include "P_Net.h"
#include <records/I_RecHttp.h>
Go to the source code of this file.
Implements unit test for SDK APIs.
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.
Definition in file InkAPITestTool.cc.
#define CDBG_TAG "SockClient" |
Definition at line 32 of file InkAPITestTool.cc.
Referenced by synclient_txn_close(), synclient_txn_connect_handler(), synclient_txn_create(), synclient_txn_read_response(), synclient_txn_read_response_handler(), synclient_txn_write_request(), and synclient_txn_write_request_handler().
#define ERROR_BODY "TESTING ERROR PAGE" |
Definition at line 55 of file InkAPITestTool.cc.
Referenced by ssn_handler().
#define HTTP_REQUEST_DEFAULT_FORMAT |
"GET http://127.0.0.1:%d/default.html HTTP/1.0\r\n" \ "X-Request-ID: %d\r\n" \ "\r\n"
Referenced by generate_request().
#define HTTP_REQUEST_END "\r\n\r\n" |
Definition at line 49 of file InkAPITestTool.cc.
Referenced by synserver_txn_read_request().
#define HTTP_REQUEST_FORMAT1 |
"GET http://127.0.0.1:%d/format1.html HTTP/1.0\r\n" \ "X-Request-ID: %d\r\n" \ "\r\n"
Referenced by generate_request().
#define HTTP_REQUEST_FORMAT10 |
"GET http://trafficserver.apache.org/format10.html HTTP/1.0\r\n" \ "X-Request-ID: %d\r\n" \ "\r\n"
Referenced by generate_request().
#define HTTP_REQUEST_FORMAT2 |
"GET http://127.0.0.1:%d/format2.html HTTP/1.0\r\n" \ "X-Request-ID: %d\r\n" \ "Content-Type: text/html\r\n" \ "\r\n"
Referenced by generate_request().
#define HTTP_REQUEST_FORMAT3 |
"GET http://127.0.0.1:%d/format3.html HTTP/1.0\r\n" \ "X-Request-ID: %d\r\n" \ "Response: Error\r\n" \ "\r\n"
Referenced by generate_request().
#define HTTP_REQUEST_FORMAT4 |
"GET http://127.0.0.1:%d/format4.html HTTP/1.0\r\n" \ "X-Request-ID: %d\r\n" \ "Request:%d\r\n" \ "\r\n"
Referenced by generate_request().
#define HTTP_REQUEST_FORMAT5 |
"GET http://127.0.0.1:%d/format5.html HTTP/1.0\r\n" \ "X-Request-ID: %d\r\n" \ "Request:%d\r\n" \ "\r\n"
Referenced by generate_request().
#define HTTP_REQUEST_FORMAT6 |
"GET http://127.0.0.1:%d/format.html HTTP/1.0\r\n" \ "X-Request-ID: %d\r\n" \ "Accept-Language: English\r\n" \ "\r\n"
Referenced by generate_request().
#define HTTP_REQUEST_FORMAT7 |
"GET http://127.0.0.1:%d/format.html HTTP/1.0\r\n" \ "X-Request-ID: %d\r\n" \ "Accept-Language: French\r\n" \ "\r\n"
Referenced by generate_request().
#define HTTP_REQUEST_FORMAT8 |
"GET http://127.0.0.1:%d/format.html HTTP/1.0\r\n" \ "X-Request-ID: %d\r\n" \ "Accept-Language: English,French\r\n" \ "\r\n"
Referenced by generate_request().
#define HTTP_REQUEST_FORMAT9 |
"GET http://trafficserver.apache.org/format9.html HTTP/1.0\r\n" \ "X-Request-ID: %d\r\n" \ "\r\n"
Referenced by generate_request().
#define HTTP_REQUEST_TESTCASE_FORMAT |
"GET %1024s HTTP/1.%d\r\n" \ "X-Request-ID: %d\r\n"
Referenced by generate_response().
#define HTTP_RESPONSE_DEFAULT_FORMAT |
"HTTP/1.0 200 OK\r\n" \ "X-Response-ID: %d\r\n" \ "Cache-Control: max-age=86400\r\n" \ "Content-Type: text/html\r\n" \ "\r\n" \ "Default body"
Referenced by generate_response().
#define HTTP_RESPONSE_FORMAT1 |
"HTTP/1.0 200 OK\r\n" \ "X-Response-ID: %d\r\n" \ "Content-Type: text/html\r\n" \ "Cache-Control: no-cache\r\n" \ "\r\n" \ "Body for response 1"
Referenced by generate_response().
#define HTTP_RESPONSE_FORMAT10 |
"HTTP/1.0 200 OK\r\n" \ "Cache-Control: max-age=86400\r\n" \ "X-Response-ID: %d\r\n" \ "\r\n" \ "Body for response 10"
Referenced by generate_response().
#define HTTP_RESPONSE_FORMAT2 |
"HTTP/1.0 200 OK\r\n" \ "X-Response-ID: %d\r\n" \ "Cache-Control: max-age=86400\r\n" \ "Content-Type: text/html\r\n" \ "\r\n" \ "Body for response 2"
Referenced by generate_response().
#define HTTP_RESPONSE_FORMAT4 |
"HTTP/1.0 200 OK\r\n" \ "X-Response-ID: %d\r\n" \ "Cache-Control: max-age=86400\r\n" \ "Content-Type: text/html\r\n" \ "\r\n" \ "Body for response 4"
Referenced by generate_response().
#define HTTP_RESPONSE_FORMAT5 |
"HTTP/1.0 200 OK\r\n" \ "X-Response-ID: %d\r\n" \ "Content-Type: text/html\r\n" \ "\r\n" \ "Body for response 5"
Referenced by generate_response().
#define HTTP_RESPONSE_FORMAT6 |
"HTTP/1.0 200 OK\r\n" \ "X-Response-ID: %d\r\n" \ "Cache-Control: max-age=86400\r\n" \ "Content-Language: English\r\n" \ "\r\n" \ "Body for response 6"
Referenced by generate_response().
#define HTTP_RESPONSE_FORMAT7 |
"HTTP/1.0 200 OK\r\n" \ "X-Response-ID: %d\r\n" \ "Cache-Control: max-age=86400\r\n" \ "Content-Language: French\r\n" \ "\r\n" \ "Body for response 7"
Referenced by generate_response().
#define HTTP_RESPONSE_FORMAT8 |
"HTTP/1.0 200 OK\r\n" \ "X-Response-ID: %d\r\n" \ "Cache-Control: max-age=86400\r\n" \ "Content-Language: French, English\r\n" \ "\r\n" \ "Body for response 8"
Referenced by generate_response().
#define HTTP_RESPONSE_FORMAT9 |
"HTTP/1.0 200 OK\r\n" \ "Cache-Control: max-age=86400\r\n" \ "X-Response-ID: %d\r\n" \ "\r\n" \ "Body for response 9"
Referenced by generate_response().
Definition at line 34 of file InkAPITestTool.cc.
Referenced by synclient_txn_create().
#define MAGIC_ALIVE 0xfeedbaba |
Definition at line 38 of file InkAPITestTool.cc.
Referenced by cont_test_handler(), log_test_handler(), mytest_handler(), 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 MAGIC_DEAD 0xdeadbeef |
Definition at line 39 of file InkAPITestTool.cc.
#define PROXY_CONFIG_NAME_HTTP_PORT "proxy.config.http.server_port" |
Definition at line 43 of file InkAPITestTool.cc.
#define PROXY_HTTP_DEFAULT_PORT 8080 |
Definition at line 44 of file InkAPITestTool.cc.
Referenced by synclient_txn_create().
#define REQUEST_MAX_SIZE 4095 |
Definition at line 46 of file InkAPITestTool.cc.
Referenced by generate_request(), and synserver_txn_read_request().
#define RESPONSE_MAX_SIZE 4095 |
Definition at line 47 of file InkAPITestTool.cc.
Referenced by generate_response(), and synclient_txn_read_response().
#define SDBG_TAG "SockServer" |
Definition at line 31 of file InkAPITestTool.cc.
Referenced by synserver_accept_handler(), synserver_delete(), synserver_stop(), synserver_txn_close(), synserver_txn_read_request(), synserver_txn_read_request_handler(), synserver_txn_write_response(), and synserver_txn_write_response_handler().
#define SET_TEST_HANDLER | ( | _d, | ||
_s | ||||
) | {_d = _s;} |
Definition at line 36 of file InkAPITestTool.cc.
Referenced by synclient_txn_connect_handler(), synclient_txn_send_request(), synclient_txn_send_request_to_vc(), synclient_txn_write_request_handler(), synserver_accept_handler(), and synserver_txn_write_response().
#define SYNSERVER_LISTEN_PORT 3300 |
Definition at line 41 of file InkAPITestTool.cc.
Referenced by generate_request(), SDK_API_HttpAltInfo(), SDK_API_HttpHookAdd(), SDK_API_HttpTxnCache(), and SDK_API_HttpTxnTransform().
#define TRANSFORM_APPEND_STRING "This is a transformed response" |
Definition at line 56 of file InkAPITestTool.cc.
Referenced by SDK_API_HttpTxnTransform(), and transform_hook_handler().
#define X_REQUEST_ID "X-Request-ID" |
Definition at line 52 of file InkAPITestTool.cc.
Referenced by get_request_id().
#define X_RESPONSE_ID "X-Response-ID" |
Definition at line 53 of file InkAPITestTool.cc.
typedef int(* TxnHandler)(TSCont contp, TSEvent event, void *data) |
Definition at line 62 of file InkAPITestTool.cc.
enum RequestStatus |
Definition at line 93 of file InkAPITestTool.cc.
static char * generate_request | ( | int | test_case | ) | [static] |
Definition at line 181 of file InkAPITestTool.cc.
References HTTP_REQUEST_DEFAULT_FORMAT, HTTP_REQUEST_FORMAT1, HTTP_REQUEST_FORMAT10, HTTP_REQUEST_FORMAT2, HTTP_REQUEST_FORMAT3, HTTP_REQUEST_FORMAT4, HTTP_REQUEST_FORMAT5, HTTP_REQUEST_FORMAT6, HTTP_REQUEST_FORMAT7, HTTP_REQUEST_FORMAT8, HTTP_REQUEST_FORMAT9, REQUEST_MAX_SIZE, SYNSERVER_LISTEN_PORT, and TSmalloc.
Referenced by SDK_API_HttpAltInfo(), SDK_API_HttpHookAdd(), SDK_API_HttpSsn(), SDK_API_HttpTxnCache(), SDK_API_HttpTxnTransform(), SDK_API_TSHttpConnectIntercept(), and SDK_API_TSHttpConnectServerIntercept().
static char * generate_response | ( | const char * | request | ) | [static] |
Definition at line 273 of file InkAPITestTool.cc.
References HTTP_REQUEST_TESTCASE_FORMAT, HTTP_RESPONSE_DEFAULT_FORMAT, HTTP_RESPONSE_FORMAT1, HTTP_RESPONSE_FORMAT10, HTTP_RESPONSE_FORMAT2, HTTP_RESPONSE_FORMAT4, HTTP_RESPONSE_FORMAT5, HTTP_RESPONSE_FORMAT6, HTTP_RESPONSE_FORMAT7, HTTP_RESPONSE_FORMAT8, HTTP_RESPONSE_FORMAT9, RESPONSE_MAX_SIZE, and TSmalloc.
Referenced by synserver_txn_write_response().
static char * get_body_ptr | ( | const char * | request | ) | [static] |
Definition at line 172 of file InkAPITestTool.cc.
Referenced by cont_test_handler().
static int get_request_id | ( | TSHttpTxn | txnp | ) | [static] |
Definition at line 397 of file InkAPITestTool.cc.
References TS_NULL_MLOC, TS_SUCCESS, TSHandleMLocRelease(), TSHttpTxnClientReqGet(), TSMimeHdrFieldFind(), TSMimeHdrFieldValueIntGet(), and X_REQUEST_ID.
Referenced by cont_test_handler().
static int synclient_txn_close | ( | TSCont | contp | ) | [static] |
Definition at line 469 of file InkAPITestTool.cc.
References CDBG_TAG, ClientTxn::magic, MAGIC_ALIVE, ClientTxn::req_buffer, ClientTxn::resp_buffer, TSAssert, TSContDataGet(), TSContDestroy(), TSIOBufferDestroy(), TSVConnClose(), and ClientTxn::vconn.
Referenced by synclient_txn_connect_handler(), synclient_txn_read_response_handler(), and synclient_txn_write_request_handler().
Definition at line 675 of file InkAPITestTool.cc.
References CDBG_TAG, ClientTxn::current_handler, ClientTxn::local_port, ClientTxn::magic, MAGIC_ALIVE, ClientTxn::read_vio, ClientTxn::req_buffer, ClientTxn::req_reader, ClientTxn::resp_buffer, ClientTxn::resp_reader, ClientTxn::response, ClientTxn::response_len, SET_TEST_HANDLER, ClientTxn::status, synclient_txn_close(), synclient_txn_write_request(), synclient_txn_write_request_handler(), TS_EVENT_NET_CONNECT, TS_EVENT_NET_CONNECT_FAILED, TSAssert, TSContDataGet(), TSIOBufferCreate(), TSIOBufferReaderAlloc(), ClientTxn::vconn, and ClientTxn::write_vio.
Referenced by synclient_txn_send_request(), and synclient_txn_send_request_to_vc().
static ClientTxn * synclient_txn_create | ( | void | ) | [static] |
Definition at line 427 of file InkAPITestTool.cc.
References CDBG_TAG, ClientTxn::connect_action, ClientTxn::connect_ip, ClientTxn::connect_port, HttpProxyPort::findHttp(), IP, ClientTxn::local_port, HttpProxyPort::m_port, ClientTxn::magic, PROXY_HTTP_DEFAULT_PORT, ClientTxn::req_buffer, ClientTxn::req_reader, ClientTxn::request, ClientTxn::resp_buffer, ClientTxn::resp_reader, ClientTxn::status, TSmalloc, and ClientTxn::vconn.
Referenced by SDK_API_HttpAltInfo(), SDK_API_HttpHookAdd(), SDK_API_HttpSsn(), SDK_API_HttpTxnCache(), SDK_API_HttpTxnTransform(), SDK_API_TSHttpConnectIntercept(), and SDK_API_TSHttpConnectServerIntercept().
static int synclient_txn_delete | ( | ClientTxn * | txn | ) | [static] |
Definition at line 454 of file InkAPITestTool.cc.
References ats_free(), ClientTxn::connect_action, ClientTxn::magic, MAGIC_ALIVE, ClientTxn::request, TSActionCancel(), TSActionDone(), TSAssert, and TSfree.
Referenced by altinfo_hook_handler(), cache_hook_handler(), cont_test_handler(), mytest_handler(), ssn_handler(), and transform_hook_handler().
Definition at line 715 of file InkAPITestTool.cc.
References ClientTxn::current_handler, ClientTxn::magic, MAGIC_ALIVE, TSAssert, and TSContDataGet().
Referenced by synclient_txn_send_request(), and synclient_txn_send_request_to_vc().
static int synclient_txn_read_response | ( | TSCont | contp | ) | [static] |
Definition at line 526 of file InkAPITestTool.cc.
References CDBG_TAG, ClientTxn::magic, MAGIC_ALIVE, memcpy, ClientTxn::resp_reader, ClientTxn::response, ClientTxn::response_len, RESPONSE_MAX_SIZE, TSAssert, TSContDataGet(), TSIOBufferBlockNext(), TSIOBufferBlockReadStart(), and TSIOBufferReaderStart().
Referenced by synclient_txn_read_response_handler().
static int synclient_txn_read_response_handler | ( | TSCont | contp, | |
TSEvent | event, | |||
void * | data | |||
) | [static] |
Definition at line 553 of file InkAPITestTool.cc.
References CDBG_TAG, ClientTxn::magic, MAGIC_ALIVE, ClientTxn::read_vio, ClientTxn::resp_reader, ClientTxn::status, synclient_txn_close(), synclient_txn_read_response(), TS_EVENT_ERROR, TS_EVENT_VCONN_EOS, TS_EVENT_VCONN_READ_COMPLETE, TS_EVENT_VCONN_READ_READY, TSAssert, TSContDataGet(), TSIOBufferReaderAvail(), TSIOBufferReaderConsume(), and TSVIOReenable().
Referenced by synclient_txn_write_request_handler().
static int synclient_txn_send_request | ( | ClientTxn * | txn, | |
char * | request | |||
) | [static] |
Definition at line 491 of file InkAPITestTool.cc.
References ats_ip4_set(), ats_ip_sa_cast(), ats_strdup, ClientTxn::connect_ip, ClientTxn::connect_port, ClientTxn::current_handler, ClientTxn::magic, MAGIC_ALIVE, ClientTxn::request, SET_TEST_HANDLER, synclient_txn_connect_handler(), synclient_txn_main_handler(), TSAssert, TSContCreate(), TSContDataSet(), TSMutexCreate(), and TSNetConnect().
Referenced by altinfo_hook_handler(), cache_hook_handler(), SDK_API_HttpAltInfo(), SDK_API_HttpHookAdd(), SDK_API_HttpSsn(), SDK_API_HttpTxnCache(), SDK_API_HttpTxnTransform(), and transform_hook_handler().
static int synclient_txn_send_request_to_vc | ( | ClientTxn * | txn, | |
char * | request, | |||
TSVConn | vc | |||
) | [static] |
Definition at line 510 of file InkAPITestTool.cc.
References ats_strdup, ClientTxn::current_handler, ClientTxn::magic, MAGIC_ALIVE, ClientTxn::request, SET_TEST_HANDLER, synclient_txn_connect_handler(), synclient_txn_main_handler(), TS_EVENT_NET_CONNECT, TSAssert, TSContCall(), TSContCreate(), TSContDataSet(), and TSMutexCreate().
Referenced by SDK_API_TSHttpConnectIntercept(), and SDK_API_TSHttpConnectServerIntercept().
static int synclient_txn_write_request | ( | TSCont | contp | ) | [static] |
Definition at line 602 of file InkAPITestTool.cc.
References CDBG_TAG, ClientTxn::magic, MAGIC_ALIVE, memcpy, MIN, ClientTxn::req_buffer, ClientTxn::req_reader, ClientTxn::request, TSAssert, TSContDataGet(), TSIOBufferBlockWriteStart(), TSIOBufferProduce(), TSIOBufferStart(), TSVConnWrite(), ClientTxn::vconn, and ClientTxn::write_vio.
Referenced by synclient_txn_connect_handler().
static int synclient_txn_write_request_handler | ( | TSCont | contp, | |
TSEvent | event, | |||
void * | data | |||
) | [static] |
Definition at line 633 of file InkAPITestTool.cc.
References CDBG_TAG, ClientTxn::current_handler, INT64_MAX, ClientTxn::magic, MAGIC_ALIVE, ClientTxn::read_vio, ClientTxn::resp_buffer, SET_TEST_HANDLER, ClientTxn::status, synclient_txn_close(), synclient_txn_read_response_handler(), TS_EVENT_ERROR, TS_EVENT_VCONN_EOS, TS_EVENT_VCONN_WRITE_COMPLETE, TS_EVENT_VCONN_WRITE_READY, TSAssert, TSContDataGet(), TSVConnRead(), TSVIOReenable(), ClientTxn::vconn, and ClientTxn::write_vio.
Referenced by synclient_txn_connect_handler().
Definition at line 780 of file InkAPITestTool.cc.
References SocketServer::accept_port, ServerTxn::current_handler, ink_release_assert, INT64_MAX, ServerTxn::magic, SocketServer::magic, MAGIC_ALIVE, ServerTxn::read_vio, ServerTxn::req_buffer, ServerTxn::req_reader, ServerTxn::request, ServerTxn::request_len, ServerTxn::resp_buffer, ServerTxn::resp_reader, SDBG_TAG, SET_TEST_HANDLER, synserver_txn_main_handler(), synserver_txn_read_request_handler(), TS_EVENT_NET_ACCEPT, TS_EVENT_NET_ACCEPT_FAILED, TSAssert, TSContCreate(), TSContDataGet(), TSContDataSet(), TSIOBufferCreate(), TSIOBufferReaderAlloc(), TSmalloc, TSMutexCreate(), TSVConnRead(), ServerTxn::vconn, Warning, and ServerTxn::write_vio.
Referenced by synserver_create().
SocketServer * synserver_create | ( | int | port | ) |
Definition at line 730 of file InkAPITestTool.cc.
References SocketServer::accept_action, SocketServer::accept_cont, SocketServer::accept_port, SocketServer::magic, synserver_accept_handler(), TSContCreate(), TSContDataSet(), TSmalloc, and TSMutexCreate().
Referenced by SDK_API_HttpAltInfo(), SDK_API_HttpHookAdd(), SDK_API_HttpTxnCache(), SDK_API_HttpTxnTransform(), SDK_API_TSHttpConnectIntercept(), and SDK_API_TSHttpConnectServerIntercept().
static int synserver_delete | ( | SocketServer * | s | ) | [static] |
Definition at line 763 of file InkAPITestTool.cc.
References SocketServer::accept_cont, SocketServer::magic, MAGIC_ALIVE, SDBG_TAG, synserver_stop(), TSAssert, TSContDestroy(), and TSfree.
Referenced by altinfo_hook_handler(), cache_hook_handler(), cont_test_handler(), mytest_handler(), and transform_hook_handler().
static int synserver_start | ( | SocketServer * | s | ) | [static] |
Definition at line 742 of file InkAPITestTool.cc.
References SocketServer::accept_action, SocketServer::accept_cont, SocketServer::accept_port, SocketServer::magic, MAGIC_ALIVE, TSAssert, and TSNetAccept().
Referenced by SDK_API_HttpAltInfo(), SDK_API_HttpHookAdd(), SDK_API_HttpTxnCache(), and SDK_API_HttpTxnTransform().
static int synserver_stop | ( | SocketServer * | s | ) | [static] |
Definition at line 750 of file InkAPITestTool.cc.
References SocketServer::accept_action, SocketServer::magic, MAGIC_ALIVE, SDBG_TAG, TSActionCancel(), TSActionDone(), and TSAssert.
Referenced by synserver_delete().
static int synserver_txn_close | ( | TSCont | contp | ) | [static] |
Definition at line 826 of file InkAPITestTool.cc.
References ServerTxn::magic, MAGIC_ALIVE, ServerTxn::req_buffer, ServerTxn::resp_buffer, SDBG_TAG, TSAssert, TSContDataGet(), TSContDestroy(), TSfree, TSIOBufferDestroy(), TSVConnClose(), and ServerTxn::vconn.
Referenced by synserver_txn_read_request_handler(), and synserver_txn_write_response_handler().
Definition at line 1005 of file InkAPITestTool.cc.
References ServerTxn::current_handler, ServerTxn::magic, MAGIC_ALIVE, TSAssert, and TSContDataGet().
Referenced by synserver_accept_handler().
static int synserver_txn_read_request | ( | TSCont | contp | ) | [static] |
Definition at line 926 of file InkAPITestTool.cc.
References HTTP_REQUEST_END, ServerTxn::magic, MAGIC_ALIVE, memcpy, ServerTxn::req_reader, ServerTxn::request, ServerTxn::request_len, REQUEST_MAX_SIZE, SDBG_TAG, TSAssert, TSContDataGet(), TSIOBufferBlockNext(), TSIOBufferBlockReadStart(), and TSIOBufferReaderStart().
Referenced by synserver_txn_read_request_handler().
Definition at line 958 of file InkAPITestTool.cc.
References ServerTxn::magic, MAGIC_ALIVE, ServerTxn::read_vio, ServerTxn::req_reader, SDBG_TAG, synserver_txn_close(), synserver_txn_read_request(), synserver_txn_write_response(), TS_EVENT_ERROR, TS_EVENT_VCONN_EOS, TS_EVENT_VCONN_READ_COMPLETE, TS_EVENT_VCONN_READ_READY, TSAssert, TSContDataGet(), TSIOBufferReaderAvail(), TSIOBufferReaderConsume(), TSVConnShutdown(), TSVIOReenable(), and ServerTxn::vconn.
Referenced by synserver_accept_handler().
static int synserver_txn_write_response | ( | TSCont | contp | ) | [static] |
Definition at line 851 of file InkAPITestTool.cc.
References ServerTxn::current_handler, generate_response(), ServerTxn::magic, MAGIC_ALIVE, memcpy, MIN, ServerTxn::request, ServerTxn::resp_buffer, ServerTxn::resp_reader, SDBG_TAG, SET_TEST_HANDLER, synserver_txn_write_response_handler(), TSAssert, TSContDataGet(), TSfree, TSIOBufferBlockWriteStart(), TSIOBufferProduce(), TSIOBufferStart(), TSVConnWrite(), ServerTxn::vconn, and ServerTxn::write_vio.
Referenced by synserver_txn_read_request_handler().
static int synserver_txn_write_response_handler | ( | TSCont | contp, | |
TSEvent | event, | |||
void * | data | |||
) | [static] |
Definition at line 890 of file InkAPITestTool.cc.
References ServerTxn::magic, MAGIC_ALIVE, SDBG_TAG, synserver_txn_close(), TS_EVENT_ERROR, TS_EVENT_VCONN_EOS, TS_EVENT_VCONN_WRITE_COMPLETE, TS_EVENT_VCONN_WRITE_READY, TSAssert, TSContDataGet(), TSVConnShutdown(), TSVIOReenable(), ServerTxn::vconn, and ServerTxn::write_vio.
Referenced by synserver_txn_write_response().