ProxyObjectReference creates a new ProxyFactory for each deserialization which disables proxy caching
Description
Environment
None
Attachments
1
- 20 Jun 2011, 04:33 AM
Activity
Show:
Fabio Maulo July 30, 2011 at 2:11 PM
Closed after final release of NH3.2.0GA
cremor June 21, 2011 at 7:29 AM
Just tried to test that but I could only reach a ProxyFactoryFactory (and not the ProxyFactory itself) via the BytecodeProvider. But it seems like you have fixed it differently now?
Fabio Maulo June 21, 2011 at 6:14 AM
The test fail even with static ProxyFactory.
The DefaultProxyFactory is part of the BytecodeProvider (static in Environment)
cremor June 20, 2011 at 7:19 AM
I just saw that in Beta2 the ProxyFactory field of the DefaultProxyFactory isn't static any more. I don't know if the DefaultProxyFactory itself is cached anywhere but if not my test will of course fail even after the fix (and I'd then also wonder how the proxy caching works at all).
Fixed
Details
Details
Assignee
Unassigned
UnassignedReporter
cremor
cremorComponents
Fix versions
Affects versions
Priority
Who's Looking?
Open Who's Looking?
Created June 20, 2011 at 4:32 AM
Updated July 30, 2011 at 2:11 PM
Resolved June 21, 2011 at 7:22 AM
Who's Looking?
If you deserialize a session which contains references to proxies a new ProxyFactory (and thus ProxyCache) is created for each reference which results in a new proxy assembly and module for each reference.
I think this class should also use the static ProxyFactory field of the DefaultProxyFactory so the cache is correctly used. A test for this assumption is attached.