Task #2695
Updated by Peter Amstutz over 10 years ago
This is a very large code review. Here are some hints that may make it easier to understand what's going on here:
A _Volume_ interface has been added to provide an abstraction layer for implementing any kind of storage device. The only Volume that has been implemented so far is a _UnixVolume_ (a volume mounted as a local POSIX filesystem).
When Keep receives a @GET@ or @PUT@ request from a remote user, it invokes a Get or Put method on the appropriate Volume. The Volume is responsible for serializing any I/O requests if necessary.
Suggestions for review:
# First review @volume.go@, which describes the Volume interface and implements a _MockVolume_ used for testing the front end.
# It may help then to review @keep_test.go@, to see how the Volume interface is used in unit tests.
# At that point, the changes in @keep.go@ should be easier to understand: they chiefly change the Keep front-end to interact with the Volume interface rather than reading and writing files directly to disk.
# The underlying UnixVolume type is implemented in volume_unix.go, including the code for managing any serialized I/O requests. volume_unix_test.go supplies unit tests.
Or, you know, review in whatever order makes sense to you. :-P