diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2015-12-22 18:56:16 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2016-01-08 18:26:00 +0200 |
commit | eb16296f88ce0fdb4a98a08950b58a346a6e2bd9 (patch) | |
tree | 007cd0c925705a488a053b756fc9b3f41e464118 /web/apache/service | |
parent | 1d2117596f23b8606a17f74946a229944558d3a4 (diff) |
Log brep and libs version on web server startup
Diffstat (limited to 'web/apache/service')
-rw-r--r-- | web/apache/service | 20 |
1 files changed, 15 insertions, 5 deletions
diff --git a/web/apache/service b/web/apache/service index 32ca98d..9641a6b 100644 --- a/web/apache/service +++ b/web/apache/service @@ -84,18 +84,27 @@ namespace web template <typename M> static int - config_finalizer (apr_pool_t*, apr_pool_t*, apr_pool_t*, server_rec*) + config_finalizer (apr_pool_t*, apr_pool_t*, apr_pool_t*, server_rec* s) noexcept { - instance<M> ()->options_parsed_ = true; + auto srv (instance<M> ()); + bool& parsed (srv->options_parsed_); + + if (!parsed) + { + log l (s); + srv->exemplar_.version (l); + parsed = true; + } + return OK; } template <typename M> static void - worker_initializer (apr_pool_t*, server_rec* server) noexcept + worker_initializer (apr_pool_t*, server_rec* s) noexcept { - log l (server); + log l (s); instance<M> ()->init_worker (l); } @@ -125,7 +134,8 @@ namespace web add_option (const char* name, optional<std::string> value); template <typename M> - int handle (request& r, log& l) noexcept; + int + handle (request& r, log& l) noexcept; private: std::string name_; |