[controller] refresh manifest API
Feature: client can submit manifest text and get back new manifest text with updated block signatures.
Valid local signatures are updated with fresh signatures.
Controller instructs keepstore to pull each block with +R signature and rewrites the manifest with local signatures.Because pulling remote blocks could take a while and/or the controller could fall over while it is processing the collection, requires one or more of:
- do the update incrementally
- prevent timeouts (eg responding 102 Processing)
- get a cookie that can be used to poll for progress
#3 Updated by Tom Clegg over 2 years ago
Rather than require the client to detect different types of signatures and do an extra step, we could make the "create/update collection" APIs do all the necessary copying when given remote signatures.
(A "refresh local signatures" API would be "create expiring collection" under the hood anyway. The typical use case is "ensure all signatures are local; save manifest to a collection" so we might as well skip the temporary collection and go straight to saving the real one.)
Whatever "operation in progress" mechanism we use should be done such that any API can use it, and client libraries can implement it generically. E.g., send an "I understand 202" header, and follow up transparently, so the application doesn't need to care which operations involve multiple HTTP requests.