Advertisement
Guest User

Untitled

a guest
Aug 5th, 2012
81
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.48 KB | None | 0 0
  1. If I have say a resource Like a Net/Pop Connection
  2. that can only handle 5 connections at once, and I also
  3. run these connections in a Thread pool.
  4.  
  5. What is the best way to control access the resource, meaning,
  6. I don't push too many connection events onto the thread pool
  7. at once.
  8.  
  9. The thread pool itself handles multiple resources so I need
  10. a way to only schedule events on the thread pool, IF there
  11. are available connections for the particular resource.
  12.  
  13. Hope this make sense.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement