defer SETSTATE and GETSTATE for now

TAHOE-LAFS may use these eventually, but that's TBD and none of git-annex's
own special remotes need that, except for the web special remote's urls.
This commit is contained in:
Joey Hess 2013-12-27 13:07:56 -04:00
parent a7f3724e21
commit 9125a25738
3 changed files with 0 additions and 17 deletions

View file

@ -211,8 +211,6 @@ handleRequest' lck external req mp responsehandler = do
value <- fromMaybe "" . M.lookup setting value <- fromMaybe "" . M.lookup setting
<$> liftIO (atomically $ readTMVar $ externalConfig external) <$> liftIO (atomically $ readTMVar $ externalConfig external)
sendMessage lck external (VALUE value) sendMessage lck external (VALUE value)
handleRemoteRequest (SETSTATE k value) = error "TODO"
handleRemoteRequest (GETSTATE k) = error "TODO"
handleRemoteRequest (VERSION _) = handleRemoteRequest (VERSION _) =
sendMessage lck external (ERROR "too late to send VERSION") sendMessage lck external (ERROR "too late to send VERSION")

View file

@ -157,8 +157,6 @@ data RemoteRequest
| DIRHASH Key | DIRHASH Key
| SETCONFIG Setting String | SETCONFIG Setting String
| GETCONFIG Setting | GETCONFIG Setting
| SETSTATE Key String
| GETSTATE Key
deriving (Show) deriving (Show)
instance Receivable RemoteRequest where instance Receivable RemoteRequest where
@ -167,8 +165,6 @@ instance Receivable RemoteRequest where
parseCommand "DIRHASH" = parse1 DIRHASH parseCommand "DIRHASH" = parse1 DIRHASH
parseCommand "SETCONFIG" = parse2 SETCONFIG parseCommand "SETCONFIG" = parse2 SETCONFIG
parseCommand "GETCONFIG" = parse1 GETCONFIG parseCommand "GETCONFIG" = parse1 GETCONFIG
parseCommand "SETSTATE" = parse2 SETSTATE
parseCommand "GETSTATE" = parse1 GETSTATE
parseCommand _ = parseFail parseCommand _ = parseFail
-- Responses to RemoteRequest. -- Responses to RemoteRequest.

View file

@ -188,17 +188,6 @@ in control.
can have been set by a previous SETCONFIG. Can be run at any time. can have been set by a previous SETCONFIG. Can be run at any time.
(git-annex replies with VALUE followed by the value. If the setting is (git-annex replies with VALUE followed by the value. If the setting is
not set, the value will be empty.) not set, the value will be empty.)
* `SETSTATE Key Value`
git-annex can store state in the git-annex branch on a
per-special-remote, per-key basis. This sets that state.
(git-annex replies with VALUE followed by the value stored.)
* `GETSTATE Key`
Gets any state previously stored for the key from the git-annex branch.
Note that some special remotes may be accessed from multiple
repositories, and the state is only eventually consistently synced
between them. If two repositories set different values in the state
for a key, the one that sets it last wins.
(git-annex replies with VALUE followed by the value.)
## general messages ## general messages