Statistics
| Branch: | Tag: | Revision:

root / src @ 129bde01

Name Size
  Ganeti
AutoConf.hs.in 4.5 kB
OLD-NEWS 19 kB
README 4.5 kB
ganeti-kvmd.hs 1.2 kB
ganeti-metad.hs 1.3 kB
ganeti-mond.hs 1.2 kB
ganeti-wconfd.hs 1.1 kB
haddock-prologue 251 Bytes
hconfd.hs 1.2 kB
hluxid.hs 1.2 kB
hs2py.hs 1.5 kB
htools.hs 824 Bytes
lint-hints.hs 1 kB
mon-collector.hs 1 kB
rpc-test.hs 8.6 kB

Latest revisions

# Date Author Comment
129bde01 03/07/2014 05:22 pm Petr Pudlak

Add reverse mappings to RuntimeEnts from UIDs to names

.. and GIDs to names. Also create a proper data type for it.

The reverse mapping to names is needed for properly translating local
IDs to names for RPC calls.

Use 'ResultT' for 'getEnts' and handle all exceptions, not just when a...

d6f05205 03/07/2014 05:22 pm Petr Pudlak

Create a data type for representing RPC compressed data

It is serialized as a JSON pair. The first element is a number
describing the compression type, the second element the actual data
(in this case Base64+Zlib encoded).

On the Python side it is decompressed by backend._Decompress....

8c337f87 03/07/2014 05:22 pm Petr Pudlak

Add a module for handling compression

Since the Haskell 'zlib' library by default uses exceptions for
signalling errors, we need to use its internals to implement a proper,
pure decompressing function.

Signed-off-by: Petr Pudlak <>
Reviewed-by: Klaus Aehlig <>

8e527d04 03/07/2014 05:22 pm Petr Pudlak

Enhance logRpcResults to also return the list of errors

It is common to log all RPC errors and then check if there were any.
Since 'logRpcResults' needs to filter the errors anyway, let it return
it.

Factor out the part that filters out errors into a separate function....

e45eeb79 03/07/2014 05:22 pm Petr Pudlak

Use lenses for modifying DaemonState in WConfd

This removes the verbose code for record updating and leads to more
point-free code.

Signed-off-by: Petr Pudlak <>
Reviewed-by: Klaus Aehlig <>

0d1d2d22 03/07/2014 05:22 pm Petr Pudlak

Write the configuration only if it changed

.. to avoid expensive operation when they're not actually needed.
Comparing the two objects in memory is much less costly that
distributing the configuration.

Signed-off-by: Petr Pudlak <>
Reviewed-by: Klaus Aehlig <>

227c0ef3 03/07/2014 05:22 pm Petr Pudlak

Add a module for generated lenses for Ganeti.Objects

The module also adds type classes for lenses for common fields (serial,
mTime, uuid and tags).

Splitting the lenses into a separate module avoids problems with unused
functions.

Signed-off-by: Petr Pudlak <>...

ba40281b 03/07/2014 05:22 pm Petr Pudlak

Add a module for custom generic Lens functions

The module currently re-exports Control.Lens and adds a function that
creates lenses from data types by appending 'L' to its field names.

All Ganeti modules should import this module instead of Control.Lens...

6696f1f9 03/07/2014 05:22 pm Petr Pudlak

Add a helper for creating 'FileMode' fields

.. which will be used for RPC objects.

Signed-off-by: Petr Pudlak <>
Reviewed-by: Klaus Aehlig <>

72375ff8 03/07/2014 05:22 pm Petr Pudlak

Move helpers for specific fields into a separate module

These helpers aren't needed by other code in Ganeti.THH and since the
module is already large, it'll be better to separate them into their
own.

No functionality is changed by this patch, just functions moved....

View revisions

Also available in: Atom