use of com.hazelcast.spi.NodeAware in project hazelcast by hazelcast.
the class HazelcastManagedContext method initialize.
@Override
public Object initialize(Object obj) {
if (obj instanceof HazelcastInstanceAware) {
HazelcastInstanceAware hazelcastInstanceAware = (HazelcastInstanceAware) obj;
hazelcastInstanceAware.setHazelcastInstance(instance);
}
if (obj instanceof NodeAware) {
NodeAware nodeAware = (NodeAware) obj;
nodeAware.setNode(instance.node);
}
if (hasExternalContext) {
return externalContext.initialize(obj);
}
return obj;
}
Aggregations