[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-devel
Subject:    Re: Threadsafe access to a KConfig object
From:       Michael Pyne <michael.pyne () kdemail ! net>
Date:       2007-05-31 22:28:48
Message-ID: 200705311828.51534.michael.pyne () kdemail ! net
[Download RAW message or body]

[Attachment #2 (multipart/signed)]


On Thursday 31 May 2007, Andreas Pakulat wrote:
> So we'd like to get some ideas as to how we can make the access to the
> project configuration threadsafe, without letting each plugin know what
> the config files are that are used to create the KConfig object (the
> setup code should stay internal to the project class).

Does anyone know a reason why KConfig (or KSharedConfig::Ptr) should not be 
thread-safe?  Is it just too hard to implement?  It should be fixed in 
kdelibs if possible I think because I'm sure that KDevelop won't be the only 
project with this problem.

Beyond that, assuming kdelibs isn't fixed then you could create a struct or 
something, read out the appropriate data from KSharedConfig into the struct 
when necessary, make the struct threadsafe and then share the struct between 
the threads.  But that's a lot of extra work. :(

Regards,
 - Michael Pyne

["signature.asc" (application/pgp-signature)]

>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic