Last time I checked it did have a performance impact, especially for
things like the tech empower benchmark where you are dealing with
hundreds of thousands of requests per second (when you are doing
enough requests a second everything has a cost, no matter how fast it
supposedly is). In general most apps won't notice any difference, but
we still turn it off by default as there is not really any need to use
it unless you want to measure request time.
Stuart
On Fri, Mar 10, 2017 at 3:43 AM, Matt Solnit <msolnit(a)soasta.com> wrote:
Hi everyone. I'd like to add request duration to our HTTP access
log, and
found the "record-request-start-time" setting in the documentation.
The documentation says "This has a small but measurable performance impact."
But is that really true? From what I can see in the code, all it's doing is
calling System.nanoTime().
Chasing this led me to a lot of Google searching on nanoTime() itself, and
its performance. There's a lot of out-dated information out there,
especially with regard to Linux. From what I can see in the Java source,
it's using clock_gettime(CLOCK_MONOTONIC), and various sources say this is
plenty fast:
https://upvoid.com/devblog/2014/05/linux-timers/ (note: this site has an
expired certificate as of 2/20, so you'll get a browser complaint)
http://stackoverflow.com/questions/38779763/linux-times-or-clock-gettimec...
Has anyone measured this at the Undertow level, to see whether
"record-request-start-time" really affects performance?
-- Matt
_______________________________________________
undertow-dev mailing list
undertow-dev(a)lists.jboss.org
https://lists.jboss.org/mailman/listinfo/undertow-dev