Commons JCS
  1. Commons JCS
  2. JCS-55

Custom serializaer is not always used

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: Indexed Disk Cache
    • Labels:
      None

      Description

      I'm trying to use indexed disk cache with custom serializer feature. I added the following line to my cache.ccf:

      jcs.auxiliary.DC.serializer=mypackage.MySerializer

      I see that my serializer is used for serializing only, deSerialize method is never called.

        Activity

        Hide
        Aaron Smuts added a comment -

        I think it has to do with the initialization order. The factory calls the manager, the manager creates the IndexedDiskCache and then sets the serializer. But it's too late. The IndexedDiskCache creates the IndexedDisk object, which uses the serilizer, in its constructor.

        Show
        Aaron Smuts added a comment - I think it has to do with the initialization order. The factory calls the manager, the manager creates the IndexedDiskCache and then sets the serializer. But it's too late. The IndexedDiskCache creates the IndexedDisk object, which uses the serilizer, in its constructor.

          People

          • Assignee:
            Aaron Smuts
            Reporter:
            Alexander Sofronov
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development