From cbf08de13d1636e21248697560c203821c172bef Mon Sep 17 00:00:00 2001 From: Marius Date: Sun, 17 Jan 2016 15:34:27 +0100 Subject: [PATCH] Add documentation for FinisherDataStore --- datastore.go | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/datastore.go b/datastore.go index bdec145..92b27d1 100644 --- a/datastore.go +++ b/datastore.go @@ -64,9 +64,16 @@ type TerminaterDataStore interface { Terminate(id string) error } +// FinisherDataStore is the interface which can be implemented by DataStores +// which need to do additional operations once an entire upload has been +// completed. These tasks may include but are not limited to freeing unused +// resources or notifying other services. For example, S3Store uses this +// interface for removing a temporary object. type FinisherDataStore interface { DataStore + // FinishUpload executes additional operations for the finished upload which + // is specified by its ID. FinishUpload(id string) error }