Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re: Multithreaded (or similar) access to a complex data structure

by Sigil (Novice)
on Nov 07, 2011 at 02:09 UTC ( #936382=note: print w/ replies, xml ) Need Help??


in reply to Multithreaded (or similar) access to a complex data structure

That sounds cool

What about storing the tree in a Berkeley DB? Serialize each object with Storable, then load a DB wrapper into each thread and use Berkeley DB concurrent data store feature. Maybe a materialized path, like SNMP, for the data store keys each representing a device? Maybe a record to record the path to a change as events come in? Or a thread queue for each event?

Just a thought.


Comment on Re: Multithreaded (or similar) access to a complex data structure
Replies are listed 'Best First'.
Re^2: Multithreaded (or similar) access to a complex data structure
by FloydATC (Chaplain) on Nov 07, 2011 at 06:10 UTC
    I'll have to look into this feature of Berkeley DB, I've never heard about it before. If this allows me to keep a "central database" in memory accessible by "child threads" who's purpose is to access and invoke object methods in the data structure, it might just be a way to go. Sending back changes can be done in any number of ways ofcourse.

    -- Time flies when you don't know what you're doing

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://936382]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others scrutinizing the Monastery: (10)
As of 2015-07-30 19:22 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (273 votes), past polls