Skip to content

Memoized Value refactor proposal

andyberry88 edited this page Oct 14, 2014 · 2 revisions

Memoized Value refactor proposal

The Memoized value and file modification service architecture needs a rethink to simplify it. Below is the proposed interface for the new approach.

UML Image 1

Overview:

  • FileModificationRegistry will now control access to last modified information
  • MemoizedValue doesn't change much at all
  • The memoization logic will be removed from FileInfo. This class will be renamed to MemoizedFile, extend java.io.File and cache the reponses from the superclass by using MemoizedValue
  • We will remove the need for FileModificationServices. This will be replaced by a single (optional) thread that will detect changes on disk and updateLastModified values in the FileModificationRegistry

Clone this wiki locally