Statistics
| Branch: | Tag: | Revision:

root / src / Ganeti / WConfd @ 1e0d1a19

# Date Author Comment
1e0d1a19 03/07/2014 05:22 pm Petr Pudlak

Add a helper to ConfigWriter for creating async. workers

In particular, stateful workers that can fail with an error, in which
case the error is logged and the state remains unchanged.

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

f3010b75 03/07/2014 10:57 am Klaus Aehlig

Also clean up stale livelock files

Upon detection of a stale livelock, make WConfD also
try to clean it up. We can safely ignore any failures,
as the Ganeti resources are already freed, and the worst
thing that can happen is an empty file left over in the...

db0d2ee9 03/06/2014 05:35 pm Klaus Aehlig

In WConfD run a cleanup task

Add the cleanup task for locks of died owners to WConfD,
as a separate thread.

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

b57c50de 03/06/2014 05:35 pm Klaus Aehlig

Provide a periodic lock cleanup task

Provide a task that periodically checks for all locks
owners whether they are still alive. If not, it cleans
up their locks.

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

bacb44fe 03/06/2014 05:35 pm Klaus Aehlig

Add a function to detect death of a job

With jobs running in processes different from the lock management soon,
we need to detect if a job holding locks dies, in order to release the
resources.

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

1d4febbd 03/04/2014 05:03 pm Klaus Aehlig

Write lock state to disk after updates

Make use of asynchronous worker to save to log status after every
update. The answer to the query is only returned, once the state
is saved on disk. Note that replication of the lock status is not
necessary, as all jobs will be gone if the master node goes away....

5d7ac40f 03/03/2014 06:05 pm Klaus Aehlig

Export opportunistic lock union through WConfd

Make WConfD provide a function to opportunistically allocate
locks.

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

66927d09 03/03/2014 06:05 pm Klaus Aehlig

Export lock intersection through WConfD

Export the functionality to restrict the owned locks to a given set.

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

b4d1b49f 03/03/2014 06:05 pm Klaus Aehlig

Export freeLocks through WConfD

Export the functionality to free all locks of a given
owner.

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

032befbd 03/03/2014 06:05 pm Klaus Aehlig

Add lock modification without result to WConfdMonad

Enrich the structure of WConfdMonad by a convenience
wrapper around modifyLockAllocation for the case that
the modification always succeeds and does not produce
any result.

Signed-off-by: Klaus Aehlig <>...

f919184d 03/03/2014 06:05 pm Klaus Aehlig

Export updateLocks through WConfD

Export the functionality to update the locks of a given
owner through WConfD.

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

62f1e053 03/03/2014 06:05 pm Klaus Aehlig

Add serialization for LockRequest GanetiLocks

Add a module describing how abstract requests, like lock requests are
passed over the wire to WConfD.

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

84640a93 03/03/2014 06:05 pm Klaus Aehlig

Export listing of locks

Make WconfD answer requests about the locks of a specific
owner.

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

3e80d1b7 03/03/2014 06:05 pm Klaus Aehlig

Support reading the lock allocation in WConfdMonad

As opposed to the atomic modify-and-read provided my modifyLockAllocation,
no storing is necessary here.

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

b28f715a 02/27/2014 04:33 pm Klaus Aehlig

Remove the client state from WConfD monad

As we decided to keep our protocols stateless, the client
state is no longer needed.

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

bc820a01 02/27/2014 12:27 pm Petr Pudlak

Add the --force-node option to WConfd

.. and fix the superfluous options list in ganeti-wconfd.hs

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

5ca6adf5 02/26/2014 07:17 pm Klaus Aehlig

Prefer unless over when (not...)

...and by doing so, please lint.

Signed-off-by: Klaus Aehlig <>
Reviewed-by: Hrvoje Ribicic <>

5e26a86e 02/26/2014 06:23 pm Klaus Aehlig

At startup, make WConfD read the lock allocation from disk

On startup, make wconfd read a the state of the lock allocation from disk,
instead of starting from an empty allocation.

Note that, as opposed to the configuration, no finding a saved
log configuration is not an error; e.g., the node might be master...

59651d52 02/26/2014 02:07 pm Petr Pudlak

Export reading and writing the configuration using RPC

Note that currently these functions lack any kind of locking and
concurrent calls to 'writeConfig' will result in lost changes in the
configuration.

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

833c32b3 02/26/2014 02:07 pm Petr Pudlak

Add a module for functions specific to config. management

.. and include ConfigData in WConfd's ConfigState.

Currently it includes functions for asynchronous saving the
configuration and reading and (over)writing it in the daemon state.

Load the configuration from the file at daemon startup and configure an...

13d26b66 02/26/2014 02:06 pm Petr Pudlak

Add more general conf. handling functions to WConfd's Monad

Add functions for reading and writing the configuration. Writing
triggers the asynchronous worker which saves the configuration into the
master file. The actual action that saves the configuration is passed as...

a317d77a 02/17/2014 03:40 pm Klaus Aehlig

Make the lock allocation part of WConfD's state

As WConfD is supposed to be the authoritative source for
configuration and locks, it needs to have access to the lock
state as well.

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

59881a0b 02/14/2014 11:47 am Petr Pudlak

Add the WConfD daemon itself

The daemon exposes the declared functions in Ganeti.WConfd.Core to RPC
clients (currently just 'echo').

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

13f59e11 02/14/2014 11:47 am Petr Pudlak

Add a module for WConfd core functions

There are no exported functions yet, except for `echo`, which just
returns its argument back to a client.

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

9515a7d2 02/14/2014 11:46 am Petr Pudlak

Add a monad for running all WConfD functions

This monad encapsulates working with the daemon and client state, as
well as failures and IO operations.

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