You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficserver.apache.org by ja...@apache.org on 2016/04/14 22:43:17 UTC
[trafficserver] branch master updated: Clang format for TS-4341
This is an automated email from the ASF dual-hosted git repository.
jacksontj pushed a commit to branch master
in repository https://git-dual.apache.org/repos/asf/trafficserver.git
The following commit(s) were added to refs/heads/master by this push:
new 1b65f76 Clang format for TS-4341
1b65f76 is described below
commit 1b65f76a903472a1b6b3dfcb713321ff6628d8b7
Author: Thomas Jackson <ja...@gmail.com>
AuthorDate: Thu Apr 14 13:43:02 2016 -0700
Clang format for TS-4341
---
plugins/experimental/ts_lua/ts_lua_http_config.c | 3 +--
proxy/http/HttpConfig.h | 14 ++++++-------
proxy/http/HttpConnectionCount.h | 5 +++--
proxy/http/HttpSM.cc | 13 +++++++-----
proxy/http/HttpTransact.h | 26 ++++++++++++------------
5 files changed, 32 insertions(+), 29 deletions(-)
diff --git a/plugins/experimental/ts_lua/ts_lua_http_config.c b/plugins/experimental/ts_lua/ts_lua_http_config.c
index 2b89d30..ea1dc18 100644
--- a/plugins/experimental/ts_lua/ts_lua_http_config.c
+++ b/plugins/experimental/ts_lua/ts_lua_http_config.c
@@ -200,8 +200,7 @@ ts_lua_var_item ts_lua_http_config_vars[] = {
TS_LUA_MAKE_VAR_ITEM(TS_LUA_CONFIG_HTTP_CACHE_MAX_OPEN_WRITE_RETRIES),
TS_LUA_MAKE_VAR_ITEM(TS_LUA_CONFIG_HTTP_REDIRECT_USE_ORIG_CACHE_KEY),
TS_LUA_MAKE_VAR_ITEM(TS_LUA_CONFIG_HTTP_ATTACH_SERVER_SESSION_TO_CLIENT),
- TS_LUA_MAKE_VAR_ITEM(TS_LUA_CONFIG_HTTP_ORIGIN_MAX_CONNECTIONS_QUEUE),
- TS_LUA_MAKE_VAR_ITEM(TS_LUA_CONFIG_LAST_ENTRY),
+ TS_LUA_MAKE_VAR_ITEM(TS_LUA_CONFIG_HTTP_ORIGIN_MAX_CONNECTIONS_QUEUE), TS_LUA_MAKE_VAR_ITEM(TS_LUA_CONFIG_LAST_ENTRY),
};
// Needed to make sure we have the latest list of overridable http config vars when compiling
diff --git a/proxy/http/HttpConfig.h b/proxy/http/HttpConfig.h
index 92ec3db..1f1f487 100644
--- a/proxy/http/HttpConfig.h
+++ b/proxy/http/HttpConfig.h
@@ -378,13 +378,13 @@ struct OverridableHttpConfigParams {
cache_heuristic_min_lifetime(3600), cache_heuristic_max_lifetime(86400), cache_guaranteed_min_lifetime(0),
cache_guaranteed_max_lifetime(31536000), cache_max_stale_age(604800), keep_alive_no_activity_timeout_in(115),
keep_alive_no_activity_timeout_out(120), transaction_no_activity_timeout_in(30), transaction_no_activity_timeout_out(30),
- transaction_active_timeout_out(0), origin_max_connections(0), origin_max_connections_queue(0), attach_server_session_to_client(0),
- connect_attempts_max_retries(0), connect_attempts_max_retries_dead_server(3), connect_attempts_rr_retries(3),
- connect_attempts_timeout(30), post_connect_attempts_timeout(1800), down_server_timeout(300), client_abort_threshold(10),
- freshness_fuzz_time(240), freshness_fuzz_min_time(0), max_cache_open_read_retries(-1), cache_open_read_retry_time(10),
- cache_generation_number(-1), max_cache_open_write_retries(1), background_fill_active_timeout(60), http_chunking_size(4096),
- flow_high_water_mark(0), flow_low_water_mark(0), default_buffer_size_index(8), default_buffer_water_mark(32768),
- slow_log_threshold(0),
+ transaction_active_timeout_out(0), origin_max_connections(0), origin_max_connections_queue(0),
+ attach_server_session_to_client(0), connect_attempts_max_retries(0), connect_attempts_max_retries_dead_server(3),
+ connect_attempts_rr_retries(3), connect_attempts_timeout(30), post_connect_attempts_timeout(1800), down_server_timeout(300),
+ client_abort_threshold(10), freshness_fuzz_time(240), freshness_fuzz_min_time(0), max_cache_open_read_retries(-1),
+ cache_open_read_retry_time(10), cache_generation_number(-1), max_cache_open_write_retries(1),
+ background_fill_active_timeout(60), http_chunking_size(4096), flow_high_water_mark(0), flow_low_water_mark(0),
+ default_buffer_size_index(8), default_buffer_water_mark(32768), slow_log_threshold(0),
// Strings / floats must come last
body_factory_template_base(NULL), body_factory_template_base_len(0), proxy_response_server_string(NULL),
diff --git a/proxy/http/HttpConnectionCount.h b/proxy/http/HttpConnectionCount.h
index d1f3656..b025e8f 100644
--- a/proxy/http/HttpConnectionCount.h
+++ b/proxy/http/HttpConnectionCount.h
@@ -193,7 +193,8 @@ protected:
ink_mutex _mutex;
};
-class ConnectionCountQueue: public ConnectionCount {
+class ConnectionCountQueue : public ConnectionCount
+{
public:
/**
* Static method to get the instance of the class
@@ -204,10 +205,10 @@ public:
{
return &_connectionCount;
}
+
private:
static ConnectionCountQueue _connectionCount;
};
-
#endif
diff --git a/proxy/http/HttpSM.cc b/proxy/http/HttpSM.cc
index f084c63..2272053 100644
--- a/proxy/http/HttpSM.cc
+++ b/proxy/http/HttpSM.cc
@@ -4766,17 +4766,19 @@ HttpSM::do_http_server_open(bool raw)
if (t_state.origin_request_queued || t_state.txn_conf->origin_max_connections_queue < 0) {
pending_action = eventProcessor.schedule_in(this, HRTIME_MSECONDS(100));
return;
- } else if (t_state.txn_conf->origin_max_connections_queue > 0) { // If we have a queue, lets see if there is a slot
+ } else if (t_state.txn_conf->origin_max_connections_queue > 0) { // If we have a queue, lets see if there is a slot
ConnectionCountQueue *waiting_connections = ConnectionCountQueue::getInstance();
// if there is space in the queue
if (waiting_connections->getCount(t_state.current.server->dst_addr, hostname_hash,
- (TSServerSessionSharingMatchType)t_state.txn_conf->server_session_sharing_match) < t_state.txn_conf->origin_max_connections_queue) {
+ (TSServerSessionSharingMatchType)t_state.txn_conf->server_session_sharing_match) <
+ t_state.txn_conf->origin_max_connections_queue) {
t_state.origin_request_queued = true;
Debug("http", "[%" PRId64 "] queued for this host: %s", sm_id,
ats_ip_ntop(&t_state.current.server->dst_addr.sa, addrbuf, sizeof(addrbuf)));
- waiting_connections->incrementCount(t_state.current.server->dst_addr, hostname_hash, (TSServerSessionSharingMatchType)t_state.txn_conf->server_session_sharing_match, 1);
+ waiting_connections->incrementCount(t_state.current.server->dst_addr, hostname_hash,
+ (TSServerSessionSharingMatchType)t_state.txn_conf->server_session_sharing_match, 1);
pending_action = eventProcessor.schedule_in(this, HRTIME_MSECONDS(100));
- } else { // the queue is full
+ } else { // the queue is full
t_state.current.state = HttpTransact::CONNECTION_ERROR;
call_transact_and_set_next_state(HttpTransact::HandleResponse);
}
@@ -5206,7 +5208,8 @@ HttpSM::handle_http_server_open()
strlen(t_state.current.server->name));
ConnectionCountQueue *waiting_connections = ConnectionCountQueue::getInstance();
- waiting_connections->incrementCount(t_state.current.server->dst_addr, hostname_hash, (TSServerSessionSharingMatchType)t_state.txn_conf->server_session_sharing_match, -1);
+ waiting_connections->incrementCount(t_state.current.server->dst_addr, hostname_hash,
+ (TSServerSessionSharingMatchType)t_state.txn_conf->server_session_sharing_match, -1);
// The request is now not queued. This is important if the request will ever retry, the t_state is re-used
t_state.origin_request_queued = false;
}
diff --git a/proxy/http/HttpTransact.h b/proxy/http/HttpTransact.h
index 00046ca..8e4faef 100644
--- a/proxy/http/HttpTransact.h
+++ b/proxy/http/HttpTransact.h
@@ -962,19 +962,19 @@ public:
first_dns_lookup(true), backdoor_request(false), cop_test_page(false), parent_params(NULL),
cache_lookup_result(CACHE_LOOKUP_NONE), next_action(SM_ACTION_UNDEFINED), api_next_action(SM_ACTION_UNDEFINED),
transact_return_point(NULL), post_remap_upgrade_return_point(NULL), upgrade_token_wks(NULL), is_upgrade_request(false),
- is_websocket(false), did_upgrade_succeed(false), origin_request_queued(false), internal_msg_buffer(NULL), internal_msg_buffer_type(NULL),
- internal_msg_buffer_size(0), internal_msg_buffer_fast_allocator_size(-1), icp_lookup_success(false), scheme(-1),
- next_hop_scheme(scheme), orig_scheme(scheme), method(0), cause_of_death_errno(-UNKNOWN_INTERNAL_ERROR),
- client_request_time(UNDEFINED_TIME), request_sent_time(UNDEFINED_TIME), response_received_time(UNDEFINED_TIME),
- plugin_set_expire_time(UNDEFINED_TIME), state_machine_id(0), client_connection_enabled(true),
- acl_filtering_performed(false), negative_caching(false), srv_lookup(false), www_auth_content(CACHE_AUTH_NONE),
- remap_plugin_instance(0), fp_tsremap_os_response(NULL), http_return_code(HTTP_STATUS_NONE),
- api_txn_active_timeout_value(-1), api_txn_connect_timeout_value(-1), api_txn_dns_timeout_value(-1),
- api_txn_no_activity_timeout_value(-1), cache_req_hdr_heap_handle(NULL), cache_resp_hdr_heap_handle(NULL),
- api_cleanup_cache_read(false), api_server_response_no_store(false), api_server_response_ignore(false),
- api_http_sm_shutdown(false), api_modifiable_cached_resp(false), api_server_request_body_set(false),
- api_req_cacheable(false), api_resp_cacheable(false), api_server_addr_set(false), stale_icp_lookup(false),
- api_update_cached_object(UPDATE_CACHED_OBJECT_NONE), api_lock_url(LOCK_URL_FIRST),
+ is_websocket(false), did_upgrade_succeed(false), origin_request_queued(false), internal_msg_buffer(NULL),
+ internal_msg_buffer_type(NULL), internal_msg_buffer_size(0), internal_msg_buffer_fast_allocator_size(-1),
+ icp_lookup_success(false), scheme(-1), next_hop_scheme(scheme), orig_scheme(scheme), method(0),
+ cause_of_death_errno(-UNKNOWN_INTERNAL_ERROR), client_request_time(UNDEFINED_TIME), request_sent_time(UNDEFINED_TIME),
+ response_received_time(UNDEFINED_TIME), plugin_set_expire_time(UNDEFINED_TIME), state_machine_id(0),
+ client_connection_enabled(true), acl_filtering_performed(false), negative_caching(false), srv_lookup(false),
+ www_auth_content(CACHE_AUTH_NONE), remap_plugin_instance(0), fp_tsremap_os_response(NULL),
+ http_return_code(HTTP_STATUS_NONE), api_txn_active_timeout_value(-1), api_txn_connect_timeout_value(-1),
+ api_txn_dns_timeout_value(-1), api_txn_no_activity_timeout_value(-1), cache_req_hdr_heap_handle(NULL),
+ cache_resp_hdr_heap_handle(NULL), api_cleanup_cache_read(false), api_server_response_no_store(false),
+ api_server_response_ignore(false), api_http_sm_shutdown(false), api_modifiable_cached_resp(false),
+ api_server_request_body_set(false), api_req_cacheable(false), api_resp_cacheable(false), api_server_addr_set(false),
+ stale_icp_lookup(false), api_update_cached_object(UPDATE_CACHED_OBJECT_NONE), api_lock_url(LOCK_URL_FIRST),
saved_update_next_action(SM_ACTION_UNDEFINED), saved_update_cache_action(CACHE_DO_UNDEFINED), url_map(),
pCongestionEntry(NULL), congest_saved_next_action(SM_ACTION_UNDEFINED), congestion_control_crat(0),
congestion_congested_or_failed(0), congestion_connection_opened(0), filter_mask(0), remap_redirect(NULL),
--
To stop receiving notification emails like this one, please contact
['"commits@trafficserver.apache.org" <co...@trafficserver.apache.org>'].