ganeti-htoolsSource codeContentsIndex
Ganeti.Confd
Description
Implementation of the Ganeti confd types.
Synopsis
data ConfdRequestType
= ReqPing
| ReqNodeRoleByName
| ReqNodePipList
| ReqNodePipByInstPip
| ReqClusterMaster
| ReqMcPipList
| ReqInstIpsList
| ReqNodeDrbd
confdRequestTypeFromRaw :: forall m[aRbw]. Monad m[aRbw] => Int -> m[aRbw] ConfdRequestType
confdRequestTypeToRaw :: ConfdRequestType -> Int
data ConfdReqField
= ReqFieldName
| ReqFieldIp
| ReqFieldMNodePip
confdReqFieldFromRaw :: forall m[aRik]. Monad m[aRik] => String -> m[aRik] ConfdReqField
confdReqFieldToRaw :: ConfdReqField -> String
data ConfdReqQ = ConfdReqQ {
confdReqQIp :: Maybe String
confdReqQIpList :: [String]
confdReqQLink :: Maybe String
confdReqQFields :: [ConfdReqField]
}
loadConfdReqQ :: JSValue -> Result ConfdReqQ
saveConfdReqQ :: ConfdReqQ -> JSValue
toDictConfdReqQ :: ConfdReqQ -> [(String, JSValue)]
data ConfdQuery
= EmptyQuery
| PlainQuery String
| DictQuery ConfdReqQ
data ConfdReplyStatus
= ReplyStatusOk
| ReplyStatusError
| ReplyStatusNotImpl
confdReplyStatusFromRaw :: forall m[aRBB]. Monad m[aRBB] => Int -> m[aRBB] ConfdReplyStatus
confdReplyStatusToRaw :: ConfdReplyStatus -> Int
data ConfdNodeRole
= NodeRoleMaster
| NodeRoleCandidate
| NodeRoleOffline
| NodeRoleDrained
| NodeRoleRegular
confdNodeRoleFromRaw :: forall m[aRI2]. Monad m[aRI2] => Int -> m[aRI2] ConfdNodeRole
confdNodeRoleToRaw :: ConfdNodeRole -> Int
data ConfdErrorType
= ConfdErrorUnknownEntry
| ConfdErrorInternal
| ConfdErrorArgument
confdErrorTypeFromRaw :: forall m[aROj]. Monad m[aROj] => Int -> m[aROj] ConfdErrorType
confdErrorTypeToRaw :: ConfdErrorType -> Int
data ConfdRequest = ConfdRequest {
confdRqProtocol :: Int
confdRqType :: ConfdRequestType
confdRqQuery :: ConfdQuery
confdRqRsalt :: String
}
loadConfdRequest :: JSValue -> Result ConfdRequest
saveConfdRequest :: ConfdRequest -> JSValue
toDictConfdRequest :: ConfdRequest -> [(String, JSValue)]
data ConfdReply = ConfdReply {
confdReplyProtocol :: Int
confdReplyStatus :: ConfdReplyStatus
confdReplyAnswer :: JSValue
confdReplySerial :: Int
}
loadConfdReply :: JSValue -> Result ConfdReply
saveConfdReply :: ConfdReply -> JSValue
toDictConfdReply :: ConfdReply -> [(String, JSValue)]
data SignedMessage = SignedMessage {
signedMsgHmac :: String
signedMsgMsg :: String
signedMsgSalt :: String
}
loadSignedMessage :: JSValue -> Result SignedMessage
saveSignedMessage :: SignedMessage -> JSValue
toDictSignedMessage :: SignedMessage -> [(String, JSValue)]
Documentation
data ConfdRequestType Source
Constructors
ReqPing
ReqNodeRoleByName
ReqNodePipList
ReqNodePipByInstPip
ReqClusterMaster
ReqMcPipList
ReqInstIpsList
ReqNodeDrbd
confdRequestTypeFromRaw :: forall m[aRbw]. Monad m[aRbw] => Int -> m[aRbw] ConfdRequestTypeSource
confdRequestTypeToRaw :: ConfdRequestType -> IntSource
data ConfdReqField Source
Constructors
ReqFieldName
ReqFieldIp
ReqFieldMNodePip
confdReqFieldFromRaw :: forall m[aRik]. Monad m[aRik] => String -> m[aRik] ConfdReqFieldSource
confdReqFieldToRaw :: ConfdReqField -> StringSource
data ConfdReqQ Source
Constructors
ConfdReqQ
confdReqQIp :: Maybe String
confdReqQIpList :: [String]
confdReqQLink :: Maybe String
confdReqQFields :: [ConfdReqField]
loadConfdReqQ :: JSValue -> Result ConfdReqQSource
saveConfdReqQ :: ConfdReqQ -> JSValueSource
toDictConfdReqQ :: ConfdReqQ -> [(String, JSValue)]Source
data ConfdQuery Source
Confd query type. This is complex enough that we can't automatically derive it via THH.
Constructors
EmptyQuery
PlainQuery String
DictQuery ConfdReqQ
data ConfdReplyStatus Source
Constructors
ReplyStatusOk
ReplyStatusError
ReplyStatusNotImpl
confdReplyStatusFromRaw :: forall m[aRBB]. Monad m[aRBB] => Int -> m[aRBB] ConfdReplyStatusSource
confdReplyStatusToRaw :: ConfdReplyStatus -> IntSource
data ConfdNodeRole Source
Constructors
NodeRoleMaster
NodeRoleCandidate
NodeRoleOffline
NodeRoleDrained
NodeRoleRegular
confdNodeRoleFromRaw :: forall m[aRI2]. Monad m[aRI2] => Int -> m[aRI2] ConfdNodeRoleSource
confdNodeRoleToRaw :: ConfdNodeRole -> IntSource
data ConfdErrorType Source
Constructors
ConfdErrorUnknownEntry
ConfdErrorInternal
ConfdErrorArgument
confdErrorTypeFromRaw :: forall m[aROj]. Monad m[aROj] => Int -> m[aROj] ConfdErrorTypeSource
confdErrorTypeToRaw :: ConfdErrorType -> IntSource
data ConfdRequest Source
Constructors
ConfdRequest
confdRqProtocol :: Int
confdRqType :: ConfdRequestType
confdRqQuery :: ConfdQuery
confdRqRsalt :: String
loadConfdRequest :: JSValue -> Result ConfdRequestSource
saveConfdRequest :: ConfdRequest -> JSValueSource
toDictConfdRequest :: ConfdRequest -> [(String, JSValue)]Source
data ConfdReply Source
Constructors
ConfdReply
confdReplyProtocol :: Int
confdReplyStatus :: ConfdReplyStatus
confdReplyAnswer :: JSValue
confdReplySerial :: Int
loadConfdReply :: JSValue -> Result ConfdReplySource
saveConfdReply :: ConfdReply -> JSValueSource
toDictConfdReply :: ConfdReply -> [(String, JSValue)]Source
data SignedMessage Source
Constructors
SignedMessage
signedMsgHmac :: String
signedMsgMsg :: String
signedMsgSalt :: String
loadSignedMessage :: JSValue -> Result SignedMessageSource
saveSignedMessage :: SignedMessage -> JSValueSource
toDictSignedMessage :: SignedMessage -> [(String, JSValue)]Source
Produced by Haddock version 2.6.0