-
Aug 8th, 2006, 09:03 AM
#1
RmiProxyFactoryBean interception [SOLVED]
Hi,
I have an RMI service that I'm looking up via the RmiProxyFactoryBean. However whenever a remote method is called on the proxied bean I'd like an interceptor to be run.
I've tried to do this by wrapping the RmiProxyFactoryBean with a ProxyFactoryBean, but I get an error, since it's not possible to proxy a proxy:
java.lang.IllegalArgumentException: Cannot subclass final class class $Proxy12
at net.sf.cglib.proxy.Enhancer.generateClass(Enhancer .java:446)
Anyone have any ideas how I can achieve this?
Thanks
jv
Last edited by jv; Aug 9th, 2006 at 12:59 AM.
-
Aug 9th, 2006, 12:58 AM
#2
I seemed to have got this working by explicitly stating the interface of the proxied object via setting the proxyInterfaces on the ProxyFactoryBean definition. This seems to allow the use of JDK proxies :-)
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules