OK, I've nailed it down to a difference in the way Xalan handles extension function parameter passing between 2.3.1 and recent builds. In the following stylesheet, the variable named StatConfig is passed to an extension function. The extension function is expecting a NodeList object/interface. In 2.3.1 and earlier, this would work fine, whereas later builds threw the iterator/caching exception. Just for a goof, I added a wrapper call to the "xalan:nodeset()" when passing the StatConfig variable to the extension function, and voila, it worked. It appears that prior versions of Xalan automatically "massaged" variables containing a document fragment into a nodelist, but the latest build does not. My workaround is to call xalan:nodeset, but I wonder if this should be necessary.
<?xml version="1.0"?> <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0" xmlns:java="http://xml.apache.org/xslt/java" xmlns:xalan="http://xml.apache.org/xalan" exclude-result-prefixes="xalan java"> <xsl:output method="xml" media-type="text/xml"/> <xsl:template match="/"> <xsl:variable name="StatConfig"> <STATISTICSCONFIGURATION> <SUBGROUPSIZE>1</SUBGROUPSIZE> </STATISTICSCONFIGURATION> </xsl:variable> <STUFF> <xsl:copy-of select="java:LHSPC.ExecuteDummySPCRequest(xalan:nodeset($StatConfig))"/> </STUFF> </xsl:template> </xsl:stylesheet> Rick Bullotta CTO Lighthammer Software (www.lighthammer.com) Voice: 610-903-8000 x14 -----Original Message----- From: Joseph Kesselman/CAM/Lotus [mailto:[EMAIL PROTECTED]] Sent: Wednesday, April 10, 2002 2:08 PM To: [EMAIL PROTECTED] Subject: Re: Critical Xalan 2.3.X Error in testing... First thought: Hard to diagnose without seeing a sample of the problem. Can you come up with a minimal set of sample files that provokes this error, and post a bugzilla report?
