Revision 08f7d24d src/Ganeti/Rpc.hs
b/src/Ganeti/Rpc.hs | ||
---|---|---|
379 | 379 |
|
380 | 380 |
-- ** Version |
381 | 381 |
|
382 |
-- | Version |
|
383 |
-- Query node version. |
|
384 |
-- Note: We can't use THH as it does not know what to do with empty dict |
|
385 |
data RpcCallVersion = RpcCallVersion {} |
|
386 |
deriving (Show, Eq) |
|
387 |
|
|
388 |
instance J.JSON RpcCallVersion where |
|
389 |
showJSON _ = J.JSNull |
|
390 |
readJSON J.JSNull = return RpcCallVersion |
|
391 |
readJSON _ = fail "Unable to read RpcCallVersion" |
|
382 |
-- | Query node version. |
|
383 |
$(buildObject "RpcCallVersion" "rpcCallVersion" []) |
|
392 | 384 |
|
385 |
-- | Query node reply. |
|
393 | 386 |
$(buildObject "RpcResultVersion" "rpcResultVersion" |
394 | 387 |
[ simpleField "version" [t| Int |] |
395 | 388 |
]) |
Also available in: Unified diff