We have started to get a NamePoolLimitException in our java web application. I have read the posts from about a year ago and think that I understand what is happening with the NamePool reaching its 1024 limit. I cannot however seem to find a solution which is not a bit of a hack…


Our application is very large and revolves completely around XML and transformation. We currently have a static TransformerFactory which is used to create Templates that are cached in an LRU(last recently used) queue which stores up to 50 Templates. There are, at present, 700 different XSLT’s in the system but this is growing. The 50 size is going to be ‘tweeked’ to optimize performance later.


These XSLT’s deal with a mixture of soap, xhtml, fo and lhs (our own namespace). The main problems I am facing are:


1) the XSLT’s are very mixed in the content that they deal with and I cannot seem to find a way to divide them into groups, each having their own NamePool.

2) the system auto-generates new elements in the lhs namespace and is not, therefore, finite in size.

3) catching the NamePoolLimitException and setting a new NamePool means that I have to flush the Transformer cache (I am assuming this as the Templates would referee to the old NamePool), which will then have to be recreated which will slow things down.


Re-writing the application to use <param name=”key”>value</param> instead of <key>value</key> would get rid of the infinite names, but would be a MAJOR task and live customer data would have to be updates. I’m not sure this is an option.



Do you have any suggestions?



Best regards,

Mark G

Mark Gabriel

Limehouse Software Ltd

DDI: (020) 7566 3336
Main: (020) 7566 3320
Fax: (020) 7566 3321

Limehouse Software Ltd
4th Floor
1 London Bridge

www.limehousesoftware.co.uk - Unifying Information                

The information contained in this e-mail or in any attachments is confidential and is intended solely for the named addressee only. Access to this e-mail by anyone else is unauthorised. If you are not the intended recipient, please notify Limehouse Software Ltd immediately by returning this e-mail to sender or calling 020 7566 3320 and do not read, use or disseminate the information. Opinions expressed in this e-mail are those of the sender and not necessarily the company. Although an active anti-virus policy is operated, the company accepts no liability for any damage caused by any virus transmitted by this e-mail, including any attachments.


No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.5.488 / Virus Database: 269.15.6/1086 - Release Date: 22/10/2007 19:57