Overview
Updateable Subspace Keys (or USKs) are an updating mechanism provided in
Freenet 0.7. They look like this:
USK@60I8H8HinpgZSOuTSD66AVlIFAy-xsppFr0YCzCar7c,NzdivUGCGOdlgngOGRbbKDNfSCnjI0FXjHLzJM4xkJ4,AQABAAE/index/1/
This is simply an
SSK with a revision number. So, edition 4 is:
SSK@60I8H8HinpgZSOuTSD66AVlIFAy-xsppFr0YCzCar7c,NzdivUGCGOdlgngOGRbbKDNfSCnjI0FXjHLzJM4xkJ4,AQABAAE/index-4/
(Note the slash becoming a dash).
Why is this useful? The node knows about USKs and can automatically find the latest one. If you actually access the above USK in Fproxy, and it knows about version 3, it will redirect you to version 3 (updating the URL in the browser bar via a permanent HTTP redirect so if you then copy the URL it stays at the new version). If you ask it for version 3 and then for version 1, it will know about version 3, and redirect your request for version 1 to version 3.
Even better, if you request version 1 it will automatically start a background fetch for later versions. So there's a good chance that if you reload it 30 seconds or so afterwards, it will have found version 3.
You can also tell it to find the absolute latest version:
USK@60I8H8HinpgZSOuTSD66AVlIFAy-xsppFr0YCzCar7c,NzdivUGCGOdlgngOGRbbKDNfSCnjI0FXjHLzJM4xkJ4,AQABAAE/index/-1/
This tells the node to do a reasonably thorough search and after it has found 3 consecutive empty slots, to redirect you to the last edition it found (with a positive index so it loads immediately).
Another cool thing about USKs is that since the node has control of them, we can add alternate updating mechanisms in future. One such planned mechanism is "Hierarchical DBR's". This means that there might be separate DBRs for year, month, week, day, hour. Each is updated, on insert, only if the others are filled, and on a thorough request the node will ask for all of them and use the latest edition found - then it will search the next few slots, as above. That should improve performance and reliability on sites with very many updates when you have an old link to the site, but USKs are still pretty useful as they are.
Bookmarks to sites which are USKs will be automatically updated by the node.
FCP has a command to subscribe to a USK, so that a client can subscribe to a USK, and either be notified of the latest version every time a new one is found, or (when implemented) have the node automatically fetch the content and return it.
We may also provide a command to subscribe to a USK and have the node automatically return all data posted on that USK under any key.
See Also
Signed Subspace Keys (SSKs)