ra = connector.getResourceAdapter(0);
} else {
ra = new ResourceAdapter();
connector.setResourceAdapter(new ResourceAdapter[]{ra});
}
ResourceAdapterInstance raInstance = new ResourceAdapterInstance();
ra.setResourceAdapterInstance(raInstance);
raInstance.setResourceAdapterName(data.instanceName);
for (Iterator it = data.instanceProps.entrySet().iterator(); it.hasNext();) {
Map.Entry entry = (Map.Entry) it.next();
String name = getPropertyName((String)entry.getKey(), provider.getInstanceConfigProperties());
for(int i=0; i<raInstance.getConfigPropertySetting().length; i++) {
if(raInstance.getConfigPropertySetting(i).getName().equals(name)) {
raInstance.getConfigPropertySetting(i).setValue((String)entry.getValue());
break;
}
}
}
GBeanLocator workManager = new GBeanLocator();
raInstance.setWorkManager(workManager);
workManager.setGBeanLink(data.workManager); //todo
// Connection Factories
if(data.getConnectionFactoryCount() > 0) {
ConnectionDefinition[] defs = new ConnectionDefinition[data.getConnectionFactoryCount()];
for (int i = 0; i < defs.length; i++) {