ceilometer-common-0.2.3: Common Haskell types and encoding for OpenStack Ceilometer

Safe HaskellNone
LanguageHaskell2010

Ceilometer.Types

Contents

Synopsis

Payload Raws

newtype PRSimple Source

Payload Raw Simple

Constructors

PRSimple Word64 

data PRCompoundEvent Source

Payload Raw Compound Event

prCompoundEvent :: Iso' Word64 PRCompoundEvent Source

An "improper" iso to convert between a Word64 and the raw compound.

It is improper because the reserved 8 bytes are ignored on parsing/printing. So it doesn't satisfy a "roundtrip" between the serialised Word64 and the decoded Compound raw. This is fine since we don't care about the reserved bytes.

prCompoundPollster :: Iso' Word64 PRCompoundPollster Source

An "improper" iso to convert between a Word64 and the raw compound.

It is improper because we only preserve the value and status in a "roundtrip". This is fine for pollster since that's all we care about.

Payload Decoded Fields

Payload Decoded Points

Values

class Valued a where Source

A family of lens that allows viewing/updating the payload value of decoded Ceilometer points.

note: this is a Lens and not just a Getter since we wish to reuse the logic for collector (making the points) and user (reading the points).

Associated Types

type PFValue a Source

Methods

value :: Lens' a (PFValue a) Source

data Timed value Source

Values with a TimeStamp.

Constructors

Timed !Word64 value 

Instances

Functor Timed 
Foldable Timed 
Traversable Timed 
Show value => Show (Timed value) 
Valued a => Valued (Timed a) 
type PFValue (Timed a) = PFValue a 

time :: forall value. Lens' (Timed value) Word64 Source

Interface

data Env Source

Information needed to parse/fold Ceilometer types, supplied by users.