#1019 Clearing the schema cache

v9.2
closed
Michael Kay
5
2012-10-08
2009-12-10
Michael Kay
No

Saxon provides no mechanism to clear the schema cache maintained by the Configuration (or s9api Processor). Sometimes it is necessary to load schema components that are incompatible with those already held in the cache. This can currently be done only by creating a new Configuration, which uses a new NamePool and therefore invalidates existing documents built using the old NamePool. It is possible for two Configurations to share a NamePool but this is awkward and error-prone.

A new feature is being introduced by patch on the 9.2 branch: the class EnterpriseConfiguration acquires a method clearSchemaCache() whose effect is to delete all schema components held in the Configuration. Note that this must only be used when there are no active processes (e.g. stylesheet compilation or execution) running against the Configuration.

This feature will appear in the next maintenance release.

Discussion

  • Michael Kay
    Michael Kay
    2010-01-27

    Fixed in 9.2.0.5