https://bz.apache.org/bugzilla/show_bug.cgi?id=65159

--- Comment #27 from Michael Kaufmann <[email protected]> ---
Created attachment 37987
  --> https://bz.apache.org/bugzilla/attachment.cgi?id=37987&action=edit
Performance improvement for mod_unique_id

The root cause of the problem is that the winnt MPM creates multiple APR thread
objects for a single OS thread, since r1374874. Reverting that commit fixes the
issues with non-unique IDs on Windows. But just reverting the commit is
probably not good enough.

While debugging the problem, I have created a patch that improves the
performance: With the patch, apr_thread_data_set() gets called only when
necessary. So maybe this patch could be applied after the problem with the
winnt MPM has been fixed.

If you want to replace the implementation of mod_unique_id, a simple approach
would be to generate the whole ID with pseudo-random bytes, like other web
servers do. Unfortunately there is no fast APR function available to generate
pseudo-random bytes (e.g. reading from /dev/urandom on Linux), just like there
is no APR function available for real thread local storage.

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to