View Single Post
  #1 (permalink)  
Old 07-20-2005
mohamedriyaz mohamedriyaz is offline
Registered User
 
 
Join Date: Jul 2005
Location: United Arab Emirates
Posts: 1
Send a message via Yahoo to mohamedriyaz
-->
How do I implment ThreadPool in web-based applications?

In my web application,I want to implment java Thread to improve the portal system performance.

Multiple clients processing a same request(executing business methods with usage of Thread),for each request,It's creating a new Thread and does not get destroyed when user is logged out.I want to implement this by utilizing ThreadPool or something similar technique to manage the threads.

Scenario :

cl1 - CustomerInfo.jsp --> ListData() object
cl2 - CustomerInfo.jsp -->

ListData ld = new ListData();
Thread t = new Thread(ld);
t.start()



class ListData implments Runnable {


//business methods...

}


How to handle this with usage of ThreadPool.
-------------------------------------------

1. Where do I run the ThreadPool either in Server or client?
2. How do I access threads in ThreadPool for each client request?


Plz suggest best way to implement this technique in jdk1.4.
Reply With Quote