Skip to content

Commit ed17281

Browse files
committed
Accissibility fix when invoking callback method
1 parent 3435ee0 commit ed17281

2 files changed

Lines changed: 3 additions & 1 deletion

File tree

framework/ipc/src/org/apache/cloudstack/framework/async/AsyncCallFuture.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
import java.util.concurrent.TimeUnit;
2323
import java.util.concurrent.TimeoutException;
2424

25-
public class AsyncCallFuture<T> implements Future<T> {
25+
public class AsyncCallFuture<T> implements Future<T>, AsyncCompletionCallback<T> {
2626

2727
Object _completed = new Object();
2828
boolean _done = false;
@@ -72,6 +72,7 @@ public boolean isDone() {
7272
return _done;
7373
}
7474

75+
@Override
7576
public void complete(T resultObject) {
7677
_resultObject = resultObject;
7778
synchronized(_completed) {

framework/ipc/src/org/apache/cloudstack/framework/async/AsyncCallbackDispatcher.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,7 @@ public T getTarget() {
6161
public Object intercept(Object arg0, Method arg1, Object[] arg2,
6262
MethodProxy arg3) throws Throwable {
6363
_callbackMethod = arg1;
64+
_callbackMethod.setAccessible(true);
6465
return null;
6566
}
6667
},

0 commit comments

Comments
 (0)