Changes between Initial Version and Version 1 of Ticket #17008, comment 13


Ignore:
Timestamp:
09/19/14 19:40:38 (6 years ago)
Author:
nbruin
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #17008, comment 13

    initial v1  
    1 I'd expect that caching strategies need amending if schemes move over to `UniqueRepresentations`. As we know, if one has an object `A` from which another object `b=B(A,...)` is constructed then if b is `UniqueRepresentation`, it should NOT be cached on A. That's because the global `UniqueRepresentation` cache bounds holds a strong reference to A for the lifetime of b (i.e., A will not die before b).
     1I'd expect that caching strategies need amending if schemes move over to `UniqueRepresentations`. As we know, if one has an object `A` from which another object `b=B(A,...)` is constructed then if b is `UniqueRepresentation`, it should NOT be cached on A. That's because the global `UniqueRepresentation` cache holds a strong reference to A for the lifetime of b (i.e., A will not die before b).
    22
    33If A also holds a strong reference to b (in its local cache) then b will also not die before A: they're immortal! The garbage collector does not recognize this, because the reference to A is truly global, so it's not a cycle (it's key in a `WeakValueDict`, so the reference is artificially removed should `b` be deallocated).