On 13.10.2007, at 00:06, Vlad Seryakov wrote:

> In it will not hurt performance when constantly asking for config
> parameter with locking i am fine with it.

Locking is of course necessary. But it is limited to locking
one mutex and, more importantly, the locking contention is
only between one reading and one or more writing threads.
Locking a mutex is per-se not problematic, speedwise. It is
the contention on the mutex that can slow you down.
Assuming that writing (changing config) is far less to expect
tnat reading, I'm sure there will be no speed penalty.
I can also make the thing read-only per-config parameter so
to avoid locking altogether if any concerns arise in future.

It is good to peek in the code so you can see why I think
this approach will not hurt.

Cheers
Zoran


-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
naviserver-devel mailing list
naviserver-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/naviserver-devel

Reply via email to