mirror of
https://github.com/apache/httpd.git
synced 2025-07-25 17:01:22 +00:00
Use the "recent time" cache to optimize timestamp generation for
the httpd error log Background: According to some profile data that we collected on Solaris, half the run time of ap_log_rerror() was spent in localtime(3). With this change, the recent-time cache ensures that the error logger won't cause more than one localtime() call per second, no matter how high the error rate is. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@93977 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
@ -102,6 +102,13 @@ AP_DECLARE(apr_status_t) ap_explode_recent_gmt(apr_time_exp_t *tm,
|
||||
apr_time_t t);
|
||||
|
||||
|
||||
/**
|
||||
* format a recent timestamp in the ctime() format.
|
||||
* @param date_str String to write to.
|
||||
* @param t the time to convert
|
||||
*/
|
||||
AP_DECLARE(apr_status_t) ap_recent_ctime(char *date_str, apr_time_t t);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user