이 콘텐츠는 선택한 언어로 제공되지 않습니다.
22.5.2. NotifyingFutures Example
The following is an example depicting how to use
NotifyingFutures in JBoss Data Grid:
FutureListener futureListener = new FutureListener() {
public void futureDone(Future future) {
try {
future.get();
} catch (Exception e) {
// Future did not complete successfully
System.out.println("Help!");
}
}
};
cache.putAsync("key", "value").attachListener(futureListener);