Github user robertkowalski commented on the pull request:
https://github.com/apache/couchdb-couch/pull/70#issuecomment-120774518
sorry for nit-picking, but obtaining the current time is not the
performance problem here -- formatting it according to rfc1123 takes so much
time.
open
http://robert-kowalski.de/assets/data/erlang-perf/chttpd-flame-server-header.svg
and click on `mochiweb_request:server_headers/0` for an example. it even eats
more time (percent-wise) on the backdoor ports: [here is a version that uses
httpd_util:rfc1123 on the backdoor
port](http://robert-kowalski.de/assets/data/2015-05-29-erlang-perf/flame--unpatched.svg)
i think 2% is OK, given that it adds up with the other performance
improvements I already landed or that are in the work. I measured a 8%
improvement for
https://github.com/apache/couchdb-couch/commit/e19b262d4e5bd5ff1765b22589b8d3eeaac88749
yesterday on the cluster ports, so CouchDB is getting faster and faster by
taking baby steps. I still hope for lager3 is released soon as I also reported
some performance problems in lager to the lager team -- the fix for it should
also bring ~5% better performance (btw the issue is also related to formatting
of lists). taking all these three improvements we already have 15% which is a
nice figure for relatively simple optimizations in the http layer.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---