commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jörg Schaible <>
Subject Re: [proxy] InvocationRecorder?
Date Sat, 05 Apr 2008 20:28:54 GMT
Hi James,

James Carman wrote:

> What do you folks think about a new addition to Proxy which basically
> allows you to record invocations made on proxy objects, similar to how
> EasyMock does it.  Here's the idea...
> public class InvocationRecorder
> {
>   public List<RecordedInvocation> getRecordedInvocations();
>   public <T> proxy(Class<T> type);
> }
> public class RecordedInvocation
> {
>   public Method getInvokedMethod();
>   public Object[] getArguments();
> }
> The Wicket folks are doing something similar to build up their
> bindings for form components
> (
> SafePropertyModel<Person> p = new SafePropertyModel<Person>(new Person());
> TextField field = new TextField("name",
> p.bind(;
> With this addition to Proxy, we can handle all the "recording" for
> them.  They just have to figure out what to do with the recorded
> invocations.

Pico folks do this for years in their web layer. More or less done in
ProxyToys technology. They use it also to assemble the components available
for each incoming request. However, the interesting part is the replay
action. That way the expensive part with all the reflection magic to search
the matching components is replaced the second time simply with the
recordings of the proxy.

- Jörg

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message