Commit 3ff890a1 authored by Michele Tartara's avatar Michele Tartara
Browse files

Add the reason trail type definition in Haskell



It will be added to the haskell definition of opcodes, to keep it aligned to
the python one, and it will be used for fetching the reason trail by the
instance status data collector.
Signed-off-by: default avatarMichele Tartara <mtartara@google.com>
Reviewed-by: default avatarHelga Velroyen <helgav@google.com>
parent 2bd9ec7c
......@@ -92,6 +92,8 @@ module Ganeti.Types
, opStatusToRaw
, opStatusFromRaw
, ELogType(..)
, ReasonElem
, ReasonTrail
) where
import Control.Monad (liftM)
......@@ -485,3 +487,9 @@ $(THH.declareSADT "ELogType"
, ("ELogJqueueTest", 'C.elogJqueueTest)
])
$(THH.makeJSONInstance ''ELogType)
-- | Type of one element of a reason trail.
type ReasonElem = (String, String, Integer)
-- | Type representing a reason trail.
type ReasonTrail = [ReasonElem]
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment