@Override
public void createBackingStore(String persistenceType, String storeName, Class<T> metadataClass, Map<String, Object> vendorMap) {
if (_logger.isLoggable(Level.FINE)) {
_logger.fine("Create backing store invoked with persistence type " + persistenceType + " and store name " + storeName);
}
BackingStoreFactory factory = services.getService(BackingStoreFactory.class, persistenceType);
BackingStoreConfiguration<String, T> conf = new BackingStoreConfiguration<String, T>();
if(gmsAdapterService.isGmsEnabled()) {
clusterName = gmsAdapterService.getGMSAdapter().getClusterName();
instanceName = gmsAdapterService.getGMSAdapter().getModule().getInstanceName();
}
conf.setStoreName(storeName)
.setClusterName(clusterName)
.setInstanceName(instanceName)
.setStoreType(persistenceType)
.setKeyClazz(String.class).setValueClazz(metadataClass)
.setClassLoader(this.getClass().getClassLoader());
if (vendorMap != null) {
conf.getVendorSpecificSettings().putAll(vendorMap);
}
try {
if (_logger.isLoggable(Level.FINE)) {
_logger.fine("About to create backing store " + conf);
}
this.backingStore = factory.createBackingStore(conf);
} catch (BackingStoreException e) {
_logger.log(Level.WARNING, "Could not create backing store", e);
}
Object obj = conf.getVendorSpecificSettings().get("key.mapper");
if (obj != null && obj instanceof GlassFishHAReplicaPredictor) {