This week's book giveaway is in the OO, Patterns, UML and Refactoring forum.
We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line!
See this thread for details.
The moose likes JSP and the fly likes many instances of one tag giving problem Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

JavaRanch » Java Forums » Java » JSP
Reply locked New topic

many instances of one tag giving problem

ankur rathi
Ranch Hand

Joined: Oct 11, 2004
Posts: 3830
In my application, some tags are being used many times (after all that's the purpose of tag) and every time a new instance of that tag class is created in memory and that is not garbadge collected as I mentioned in other post.

So if I start my application and click here and there, I see, around 50-60 live tag objects are present in the memory (and they will increase with the time and action).

I was thinking if there is a way, I can make tag a *singleton kind* of object so only one object is present in the memory at any point of time but couldn't find (I know, I can't provide private constructor and all...).

Please comments, what to do in this situation.


Bear Bibeault
Author and ninkuma

Joined: Jan 10, 2002
Posts: 63208

This is the same issue as your other post, please continue any discussion there.

[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link:
subject: many instances of one tag giving problem
It's not a secret anymore!