diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/couchdb/couch_httpd.erl | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/couchdb/couch_httpd.erl b/src/couchdb/couch_httpd.erl index 4acc3d44..aa78ebb2 100644 --- a/src/couchdb/couch_httpd.erl +++ b/src/couchdb/couch_httpd.erl @@ -109,7 +109,7 @@ stop() -> handle_request(MochiReq, UrlHandlers, DbUrlHandlers, DesignUrlHandlers) -> - statistics(runtime), % prepare request_time counter, see end of function + Begin = now(), AuthenticationFun = make_arity_1_fun( couch_config:get("httpd", "authentication_handler")), % for the path, use the raw path with the query string and fragment @@ -180,7 +180,7 @@ handle_request(MochiReq, UrlHandlers, DbUrlHandlers, DesignUrlHandlers) -> RawUri, Resp:get(code) ]), - {_TotalRuntime, RequestTime} = statistics(runtime), + RequestTime = round(timer:now_diff(now(), Begin)/1000), couch_stats_collector:record({couchdb, request_time}, RequestTime), couch_stats_collector:increment({httpd, requests}), {ok, Resp}. |