This week's book giveaway is in the Clojure forum.
We're giving away four copies of Clojure in Action and have Amit Rathore and Francis Avila on-line!
See this thread for details.
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Pool of threads

 
Isaac Ferguson
Ranch Hand
Posts: 831
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi

sorry for the "basic" question

I am in a real hurry. I have been asked to create a "queue the dao operations to a pool of 10 threads. Those background threads will actually store the user details in the database."

I have not use this approach before. I know I shouldn`t ask for code here. But could somebody post a piece of code for this functionality and explain it please

Thanks

Regards

 
Jayesh A Lalwani
Rancher
Pie
Posts: 2756
32
Eclipse IDE Spring Tomcat Server
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
look at java.util.concurrent.Executor. It contains what you need to run a queue of tasks in a thread pool
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic