Statistics
| Branch: | Tag: | Revision:

root / Ganeti / OpCodes.hs @ 4bc33d60

History | View | Annotate | Download (4.9 kB)

# Date Author Comment
6bc39970 12/30/2010 03:41 pm Iustin Pop

Add 'Read' instances for most objects

This allows a cluster structure to be easily serialized via "read";
together with the already existing instances of Show, this gives a
poor man's serialization/deserialization implementation.

The patch also exports the compDetailedCV function from Cluster.hs, so...

88f25dd0 05/28/2010 12:25 am Iustin Pop

Introduce OpCode unittests

f36a8028 05/28/2010 12:00 am Iustin Pop

Introduce suport for optional keys in JObjects

Some keys are optional in the Ganeti opcodes (e.g. ‘node’ in the
OpReplaceDisks), and as such we need to transform them in a Maybe value,
instead of failing.

The patch reworks a bit fromObj and adds maybeFromObj which parses such...

0903280b 02/25/2010 02:34 pm Iustin Pop

Fix unused imports for ghc 6.12

GHC 6.12 has become more picky about unused imports, so we need to
remove/tighten some of them.

262f3e6c 11/06/2009 07:23 pm Iustin Pop

Change the Utils.fromObj signature

Currently the fromObj function takes a JSON object which is then
converted into a list of (String, JSValue) in which we make a lookup.
However, most of the callers of this function call it repeatedly on the
same object, which means we do the object→list conversion repeatedly....

702a4ee0 10/02/2009 06:35 pm Iustin Pop

Add a small implementation of OpCodes

These are just a few opcodes we need for executing instance moves.