Dynamic catalogs allow end-users to override the catalog mappings by dropping specific catalog files into a folder and have these files automatically loaded into the system. Dynamic catalogs can be updated with a dedicated API, and can be used with LinkManager or through publication pipelines.
The default name for such catalogs is catalog.xml
. This name can be changed through the
componize.catalog.autoload.filename system property, for example in
alfresco-global.properties
).
# file name for the auto-loading catalogs componize.catalog.autoload.filename=catalog.xml
By defaut, in any directory, when some URI gets resolved (e.g. to resolve a link, or in a pipeline execution), extra catalogs will be loaded and take precedence over the default (static) catalogs. "Take precedence" here means that if there are duplicate entries in dynamic and static catalogs, the one from the dynamic catalog will be the one that gets applied. But dynamic catalog are provided in addition to the static ones. This means that if there is no mapping for a given URI in any dynamic catalog, the static catalogs still apply.
alfresco:/path/to/folder/file.xml
, when
resolving an href attribute from this file.xml
, Componize will try and apply these catalogs
(if they exist) in addition to the static ones that were loaded during startup: alfresco:/path/to/folder/catalog.xml
alfresco:/path/to/catalog.xml
alfresco:/path/catalog.xml
alfresco:/catalog.xml
uri/
> catalog entry at the specified base
URI:boolean addUriEntry(URI baseUri, URI name, URI uri);
uri/
> catalog
entry:boolean removeUriEntry(URI baseUri, URI name);
catalog.xml
is stored. Add a
final /
for the base URI.