IDEMPIERE-2163 Hazelcast: Context class loader. Set context class loader for hazelcast instance.
This commit is contained in:
parent
f2b32d505a
commit
8b06047bb9
|
@ -110,11 +110,14 @@ public class Activator implements BundleActivator {
|
||||||
if (file != null && file.exists()) {
|
if (file != null && file.exists()) {
|
||||||
try {
|
try {
|
||||||
Config config = new FileSystemXmlConfig(file);
|
Config config = new FileSystemXmlConfig(file);
|
||||||
|
config.setClassLoader(getClass().getClassLoader());
|
||||||
hazelcastInstance = Hazelcast.newHazelcastInstance(config);
|
hazelcastInstance = Hazelcast.newHazelcastInstance(config);
|
||||||
return;
|
return;
|
||||||
} catch (FileNotFoundException e) {}
|
} catch (FileNotFoundException e) {}
|
||||||
}
|
}
|
||||||
hazelcastInstance = Hazelcast.newHazelcastInstance(null);
|
Config config = new Config();
|
||||||
|
config.setClassLoader(getClass().getClassLoader());
|
||||||
|
hazelcastInstance = Hazelcast.newHazelcastInstance(config);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue