Skip to content

Commit

Permalink
Merge 207ac5d into e79bb10
Browse files Browse the repository at this point in the history
  • Loading branch information
straybirdzls committed Aug 28, 2018
2 parents e79bb10 + 207ac5d commit f58964b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@
import java.io.ByteArrayInputStream;
import java.io.ByteArrayOutputStream;
import java.io.IOException;
import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;
import java.util.Collection;

Expand Down Expand Up @@ -167,6 +168,8 @@ protected Object doInvoke(MethodInvocation invocation) throws Throwable {
Object retVal = transformMethod.invoke(targetService, arguments);

return hessianTransport(retVal, getClientClassloader());
} catch (InvocationTargetException ex) {
throw ex.getTargetException();
} finally {
setClientClassloader(null);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ private Object createServiceProxy(Contract contract, JvmBinding binding,
factory.setProxyTargetClass(true);
}
factory.addAdvice(handler);
return factory.getProxy();
return factory.getProxy(newClassLoader);
} finally {
Thread.currentThread().setContextClassLoader(oldClassLoader);
}
Expand Down

0 comments on commit f58964b

Please sign in to comment.