XStream
  1. XStream
  2. XSTR-636

FieldDictionary's use of WeakHashMap should be a strategy.

    Details

    • Type: Improvement Improvement
    • Status: Closed Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.3.1
    • Fix Version/s: 1.4
    • Component/s: Core
    • Labels:
      None

      Description

      FieldDictionary helps GC by allowing fieldName:Field pairs to be purged when the GC thinks it wants to. That would be some vague low memory situation of course, and is machine, impl, and air temperature dependent.

      A client of mine want them to never be purged. Other WeakRefs in the system should be purged first, or the VM should crash, but there is no situation where they want them to be eligible for purging. Now, they have cloned FieldDictionary into a subclass to effect that, but given we all love plugability, could we not have an optional constructor injected HashMapFactory ?

        People

        • Assignee:
          Jörg Schaible
          Reporter:
          Paul Hammant
        • Votes:
          0 Vote for this issue
          Watchers:
          0 Start watching this issue

          Dates

          • Created:
            Updated:
            Resolved: