auxFac.setName( auxName );
ccMgr.registryFacPut( auxFac );
}
// GET ATTRIBUTES
IAuxiliaryCacheAttributes auxAttr = ccMgr.registryAttrGet( auxName );
String attrName = AUXILIARY_PREFIX + auxName + ATTRIBUTE_PREFIX;
if ( auxAttr == null )
{
// auxFactory was not previously initialized.
String prefix = AUXILIARY_PREFIX + auxName + ATTRIBUTE_PREFIX;
auxAttr = ( IAuxiliaryCacheAttributes ) OptionConverter.instantiateByKey( props, prefix,
org.apache.stratum.jcs.auxiliary.behavior.IAuxiliaryCacheAttributes.class,
null );
if ( auxFac == null )
{
log.error( "Could not instantiate auxAttr named '" + attrName + "'" );
return null;
}
auxAttr.setName( auxName );
ccMgr.registryAttrPut( auxAttr );
}
auxAttr = auxAttr.copy();
log.debug( "Parsing options for '" + attrName + "'" );
PropertySetter.setProperties( auxAttr, props, attrName + "." );
auxAttr.setCacheName( regName );
log.debug( "End of parsing for '" + attrName + "'" );
// GET CACHE FROM FACTORY WITH ATTRIBUTES
auxAttr.setCacheName( regName );
auxCache = auxFac.createCache( auxAttr );
return auxCache;
}