MCPcopy Create free account
hub / github.com/apache/trafficserver / initRequestProcessing

Function initRequestProcessing

plugins/esi/combo_handler.cc:824–846  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

822}
823
824static bool
825initRequestProcessing(InterceptData &int_data, void *edata, bool &write_response)
826{
827 TSAssert(int_data.initialized == false);
828 if (!int_data.init(static_cast<TSVConn>(edata))) {
829 LOG_ERROR("Could not initialize intercept data!");
830 return false;
831 }
832
833 if (int_data.creq.status == TS_HTTP_STATUS_OK) {
834 for (StringList::iterator iter = int_data.creq.file_urls.begin(); iter != int_data.creq.file_urls.end(); ++iter) {
835 if (!int_data.fetcher->addFetchRequest(*iter)) {
836 LOG_ERROR("Couldn't add fetch request for URL [%s]", iter->c_str());
837 } else {
838 LOG_DEBUG("Added fetch request for URL [%s]", iter->c_str());
839 }
840 }
841 } else {
842 LOG_DEBUG("Client request status [%d] not ok; Not fetching URLs", int_data.creq.status);
843 write_response = true;
844 }
845 return true;
846}
847
848static bool
849readInterceptRequest(InterceptData &int_data)

Callers 1

handleServerEventFunction · 0.85

Calls 5

initMethod · 0.45
beginMethod · 0.45
endMethod · 0.45
addFetchRequestMethod · 0.45
c_strMethod · 0.45

Tested by

no test coverage detected