Seeking an example on using Queue to update variable while threading

Discussion in 'Python' started by Danny Wong (dannwong), Jul 28, 2011.

  1. Hi Python experts,
    I'm trying to use a dict structure to store and update information from X number of threads. How do I share this dict structure between threads? I heard of using a queue, but I'm not familiar with how it works. Does anyone have an example of using a queue to store variables/dicts between threads?

    Thanks
     
    Danny Wong (dannwong), Jul 28, 2011
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Paul L. Du Bois

    Queue.Queue-like class without the busy-wait

    Paul L. Du Bois, Mar 24, 2005, in forum: Python
    Replies:
    29
    Views:
    1,064
    Antoon Pardon
    Apr 4, 2005
  2. Russell Warren

    Is Queue.Queue.queue.clear() thread-safe?

    Russell Warren, Jun 22, 2006, in forum: Python
    Replies:
    4
    Views:
    691
    Russell Warren
    Jun 27, 2006
  3. Kceiw
    Replies:
    3
    Views:
    1,006
    Jim Langston
    Mar 14, 2006
  4. Replies:
    1
    Views:
    266
  5. Kris
    Replies:
    0
    Views:
    494
Loading...

Share This Page