Details
-
Type:
Improvement
-
Status:
Closed
-
Priority:
Minor
-
Resolution: Fixed
-
Affects Version/s: 1.2
-
Fix Version/s: 1.4.0
-
Component/s: Core: Containers
-
Labels:None
-
Similar Issues:None
Description
I was sending a Mule Message to an http connector. The message was created from a url which had different parameters for each message. For example:
http://127.0.0.1:80/mysite/gateway.cfm?site=icm6100&action=UPDATE&itemtype=Article&itemid=5397
http://127.0.0.1:80/mysite/gateway.cfm?site=icm6100&action=UPDATE&itemtype=Article&itemid=5398
http://127.0.0.1:80/mysite/gateway.cfm?site=icm6100&action=UPDATE&itemtype=Article&itemid=5399
Mule looks at the endpoint and creates a thread pool for each unique url. My url's are different every time so a new thread pool was being created for each message.
The system created more and more threads until it ran out of heap memory.
See the mailing list archive:
http://www.nabble.com/Heap-Memory-Usage%2C-Out-Of-Memory-Error-t961635.html
Ross suggests an option to define a maximum number of threads for all receivers.
I think a single pool will be a abtter solution because endpoints that are not being accessed just linger around anyway. Creating too many threads (numCPUs * 4..8) and/or pools usually does not increase performance or responsiveness any more.