[CLJ-1125] Clojure can leak memory when used in a servlet container Created: 11/Dec/12 Updated: 13/May/13 |
|
| Status: | Open |
| Project: | Clojure |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | Release 1.6 |
| Type: | Defect | Priority: | Major |
| Reporter: | Toby Crawley | Assignee: | Unassigned |
| Resolution: | Unresolved | Votes: | 8 |
| Labels: | None | ||
| Attachments: |
|
| Patch: | Code |
| Approval: | Vetted |
| Description |
|
When used within a servlet container The issue comes from threads living beyond the lifetime of a I've attached a patch that does the following:
There is still the opportunity for memory leaks if agents or futures This patch has a small performance impact: its use of a try/finally Providing an automated test for this patch is difficult - I've tested The above is a condensation of: I'm happy to provide whatever feedback/work is needed to get this |
| Comments |
| Comment by Colin Jones [ 13/May/13 7:30 PM ] |
|
This patch works great for me to avoid OOM/PermGen crashes from classloaders being retained [mine is a non-servlet use case]. |