Some Catalog decorators like AdvertisedCatalog, and other beans like DefaultResourceAccessManager use
org.geotools.filter.expression.InternalVolatileFunction functions in the Filter passed to Catalog query methods. These functions are inherently non-translatable to SQL, and can do anything with the CatalogInfo they evaluate.
The PgsqlCatalogFacade resolves CatalogInfo relationships (ResolvingProxy) and other properties like the Catalog itself in its "outbound" function, but delegates the evaluation of Filters to the
PgsqlCatalogInfoRepository for each CatalogInfo concrete type.
This in turn splits the provided Filter into supported (SQL translatable) and unsupported (evaluated in-process) parts.
Hence, at the time an InternalVolatileFunction is evaluated, either the ResolvingProxy relations or the Catalog property of a CatalogInfo may not yet be resolved, producing the NullPointerException.
A number of refactorings in this patch favor composition over inheritance to better use inbound/outbound resolvers, and moves the resolving bit from PgsqlCatalogFacade down to the PgsqlCatalogInfoRepository itself.
Some
Catalog
decorators likeAdvertisedCatalog
, and other beans likeDefaultResourceAccessManager
useorg.geotools.filter.expression.InternalVolatileFunction
functions in theFilter
passed toCatalog
query methods. These functions are inherently non-translatable to SQL, and can do anything with theCatalogInfo
they evaluate.The
PgsqlCatalogFacade
resolves CatalogInfo relationships (ResolvingProxy
) and other properties like theCatalog
itself in its "outbound" function, but delegates the evaluation ofFilter
s to thePgsqlCatalogInfoRepository
for eachCatalogInfo
concrete type.This in turn splits the provided
Filter
into supported (SQL translatable) and unsupported (evaluated in-process) parts.Hence, at the time an
InternalVolatileFunction
is evaluated, either theResolvingProxy
relations or theCatalog
property of aCatalogInfo
may not yet be resolved, producing theNullPointerException
.A number of refactorings in this patch favor composition over inheritance to better use inbound/outbound resolvers, and moves the resolving bit from
PgsqlCatalogFacade
down to thePgsqlCatalogInfoRepository
itself.