I agree with Gary's comments: you'd definitely want to cache Templates, not Transformers.
Also, when you create a Transformer (or Template) from stylesheet1.xsl that includes stylesheet2.xsl, both files are read and parsed and fully computed into the Templates object. There's no easy way to separately cache the two stylesheets, and it's probably not worth the effort to figure out how to do this with the internals of Xalan. Also re: user.dir problem: make sure you call setSystemId() on any Source objects you use to create transformers or transform XML documents. IF this isn't set, then things like xsl:include and document() calls are resolved w/r/t the user.dir, since we don't know where they came from. If you setSystemID, then we should properly resolve includes/imports/document() w/r/t the systemID itself. (Reminders: if you create StreamSource("file.ext") then you don't need to set the systemId; and systemIds must be legal URIs *not* local file paths) ===== - Shane <eof aka="mailto:[EMAIL PROTECTED]" .sig="Du sublime au ridicule il n'y a qu'un pas." /> __________________________________________________ Do You Yahoo!? Yahoo! Sports - live college hoops coverage http://sports.yahoo.com/