Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 8 additions & 7 deletions proxy/http/HttpSM.cc
Original file line number Diff line number Diff line change
Expand Up @@ -4992,6 +4992,14 @@ HttpSM::do_http_server_open(bool raw)
SMDebug("http", "[%" PRId64 "] open connection to %s: %s", sm_id, t_state.current.server->name,
ats_ip_nptop(&t_state.current.server->dst_addr.sa, addrbuf, sizeof(addrbuf)));

SMDebug("http_seq", "[HttpSM::do_http_server_open] Sending request to server");

// set the server first connect milestone here in case we return in the plugin_tunnel case that follows
milestones[TS_MILESTONE_SERVER_CONNECT] = Thread::get_hrtime();
if (milestones[TS_MILESTONE_SERVER_FIRST_CONNECT] == 0) {
milestones[TS_MILESTONE_SERVER_FIRST_CONNECT] = milestones[TS_MILESTONE_SERVER_CONNECT];
}

if (plugin_tunnel) {
PluginVCCore *t = plugin_tunnel;
plugin_tunnel = nullptr;
Expand All @@ -5002,13 +5010,6 @@ HttpSM::do_http_server_open(bool raw)
return;
}

SMDebug("http_seq", "[HttpSM::do_http_server_open] Sending request to server");

milestones[TS_MILESTONE_SERVER_CONNECT] = Thread::get_hrtime();
if (milestones[TS_MILESTONE_SERVER_FIRST_CONNECT] == 0) {
milestones[TS_MILESTONE_SERVER_FIRST_CONNECT] = milestones[TS_MILESTONE_SERVER_CONNECT];
}

// Check for remap rule. If so, only apply ip_allow filter if it is activated (ip_allow_check_enabled_p set).
// Otherwise, if no remap rule is defined, apply the ip_allow filter.
if (!t_state.url_remap_success || t_state.url_map.getMapping()->ip_allow_check_enabled_p) {
Expand Down