// factor an empty XMLPipelineConfiguration instance. This is the
// configuration that is required to run the pipeline.
XMLPipelineConfiguration pipelineConfig =
pipelineFactory.createPipelineConfiguration();
PipelineConfiguration configFileInfo =
marinerConfiguration.getPipelineConfiguration();
// Create the caches
final CacheProcessConfiguration cacheProcessConfiguration;
final CacheOperationConfiguration cacheOperationConfiguration =
configFileInfo.getCacheOperationConfiguration();
if (cacheOperationConfiguration != null) {
// @todo this seems a bit inefficient, iterating over the same
// collection twice. But the collection is expected to be small.
// Leaving for now.
int cacheSize = calculateTotalMaxEntries(
cacheOperationConfiguration.getCacheConfigurations());
cacheProcessConfiguration = new CacheProcessConfiguration();
createCaches(cacheProcessConfiguration,
cacheOperationConfiguration.getCacheConfigurations());
cacheProcessConfiguration.setFixedExpiryMode(
cacheOperationConfiguration.isFixedExpiryMode());
} else {
cacheProcessConfiguration = new CacheProcessConfiguration();
}
pipelineConfig.storeConfiguration(CacheProcessConfiguration.class,
cacheProcessConfiguration);
// Store the web services driver configuration in the pipeline
// configurations class so that registration of web services
// process' may occur.
WSDriverConfiguration wsDriverConfiguration =
(configFileInfo.getWsDriverConfiguration() != null)
? configFileInfo.getWsDriverConfiguration()
: new WSDriverConfiguration();
pipelineConfig.storeConfiguration(WSDriverConfiguration.class,
wsDriverConfiguration);
WebDriverConfiguration webDriverConfiguration =
(configFileInfo.getWebDriverConfiguration() != null)
? configFileInfo.getWebDriverConfiguration()
: WebDriverFactory.getDefaultInstance().createConfiguration();
pipelineConfig.storeConfiguration(WebDriverConfiguration.class,
webDriverConfiguration);
// Store the transformation configuration in the pipeline
// configurations class so that registration of transformation
// process may occur. The transformation configuration determines
// whether xslt or xsltc is used by default.
TransformConfiguration transformConfiguration =
(configFileInfo.getTransformConfiguration() != null)
? configFileInfo.getTransformConfiguration()
: PipelineOperationFactory.getDefaultInstance().
createTransformConfiguration();
if(LOGGER.isInfoEnabled()){
if(transformConfiguration.isTemplateCacheRequired()){
LOGGER.info("transformation-cache-enabled");
} else {
LOGGER.info("transformation-cache-disabled");
}
}
// store away the configuration for transforms
pipelineConfig.storeConfiguration(TransformConfiguration.class,
transformConfiguration);
// Store the connection configuration away in the pipeline
// configuration. This may be null if no configuration is specified
ConnectionConfigurationImpl connectionConfiguration =
(ConnectionConfigurationImpl)
configFileInfo.getConnectionConfiguration();
pipelineConfig.storeConfiguration(
ConnectionConfiguration.class,
connectionConfiguration);
// Store the URLContentCache configuration if we have a connection