Statistics
| Branch: | Tag: | Revision:

root / test @ fce5efd1

# Date Author Comment
f863d7aa 01/05/2012 05:30 pm Michael Hanselmann

rpc._RpcProcessor: Make read timeout a non-keyword argument

It is always used and can be set to “None” if intended.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

fce5efd1 01/05/2012 05:30 pm Michael Hanselmann

rpc: Pass resolver options to actual resolver

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

aa66c183 12/22/2011 07:16 pm Michael Hanselmann

Merge branch 'devel-2.5'

  • devel-2.5:
    jqueue: Factorize checking job processor's result
    jqueue unittest: Rename simple fake-job class
    jqueue: Fix epylint errors introduced in 37d76f1e4
    jqueue: Fix deadlock between job queue and dependency manager...
4f44e311 12/22/2011 06:41 pm Michael Hanselmann

Merge branch 'stable-2.5' into devel-2.5

  • stable-2.5:
    jqueue: Fix epylint errors introduced in 37d76f1e4
    jqueue: Fix deadlock between job queue and dependency manager

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

fc4498e9 12/22/2011 05:04 pm Michael Hanselmann

test/lockperf: Use a list of integers, not booleans

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

e4d452b4 12/22/2011 03:25 pm Michael Hanselmann

Add lock performance utility

I had an idea for improving locking performance. To see if it worked I
wrote this tool. Unfortunately the idea didn't quite work (broke
unittests left and right), but the tool is still handy for evaluating
future changes to the “SharedLock” class....

df5a5730 12/22/2011 03:19 pm Michael Hanselmann

jqueue: Factorize checking job processor's result

This allows for more unittesting.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

1b5150ab 12/22/2011 03:19 pm Michael Hanselmann

jqueue unittest: Rename simple fake-job class

Also add a parameter for priority, to be used in an upcoming
patch.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

fd6eaa09 12/22/2011 03:12 pm Bernardo Dal Seno

unit tests: Add tests for file mode handling in utils.WriteFile

Signed-off-by: Bernardo Dal Seno <>
Reviewed-by: Michael Hanselmann <>

0d20cc42 12/22/2011 03:12 pm Bernardo Dal Seno

unit tests: Add tests for uid and gid handling in utils.WriteFile

These tests need fakeroot. If it's not present, they are not run (they
don't fail).

Signed-off-by: Bernardo Dal Seno <>
Reviewed-by: Michael Hanselmann <>

eea3b572 12/22/2011 03:12 pm Bernardo Dal Seno

noded: Fix /etc/hosts group ownership

When Ganeti was compiled with the option of running as a different
user/group, the group ownership of /etc/hosts was set to gnt-daemons. Now
permissions for /etc/hosts are preserved (or set correctly).

Signed-off-by: Bernardo Dal Seno <>...

d9de612c 12/21/2011 06:02 pm Iustin Pop

Change internal RPC client body values

Currently, all RPC payloads sent by the client to the remote node
daemons must be identical, due to how the data is passed
internally. This is deficient in both use (from the programmer's point
of view) and from the network traffic (cluster verify/disk data...

51129a7f 12/21/2011 05:25 pm Michael Hanselmann

test/hv_kvm: Code style, additional tests

Change code style to match rest of Ganeti code and add
two tests checking for single-line messages.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

a182a3ed 12/21/2011 04:55 pm Michael Hanselmann

serializer: Remove JSON indentation and dict key sorting

Serializing to JSON using “simplejson” is significantly slower when
indentation and/or sorting of dictionary keys is used. In simplejson 1.x
the difference isn't that big, but with simplejson 2.x the difference...

37d76f1e 12/21/2011 04:35 pm Michael Hanselmann

jqueue: Fix deadlock between job queue and dependency manager

When an opcode is about to be processed its dependencies are
evaluated using “_JobDependencyManager.CheckAndRegister”. Due
to its nature that function requires a lock on the manager's
internal structures. All of this happens while the job queue...

0f63f1f9 12/21/2011 12:04 pm Iustin Pop

Fix unittests for daemon_util with disabled confd

Signed-off-by: Iustin Pop <>
Reviewed-by: Michael Hanselmann <>

6396dc04 12/13/2011 02:00 pm Michael Hanselmann

RAPI client: Export feature constants

Users of the RAPI client may want to use feature strings too, therefore
they should be explicitely public.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

edd49f9b 12/08/2011 07:24 pm Agata Murawska

Group query now calculates ipolicy

Signed-off-by: Agata Murawska <>
Reviewed-by: Iustin Pop <>

b6522276 12/08/2011 06:21 pm Michael Hanselmann

utils.io.WritePidFile: Improve error reporting

If the PID file is already locked by another process, try to read
the content and report it as part of the error message.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

2dbc6857 12/08/2011 12:42 pm Michael Hanselmann

utils.ListVisibleFiles: Hide “lost+found” directories

If a “lost+found” directory is found at a filesystem's root path it is
ignored. In all other cases directory entries named “lost+found” are
treated normally. Unittests are included. Fixes issue 153.

Signed-off-by: Michael Hanselmann <>...

42a769f9 12/08/2011 11:53 am Bernardo Dal Seno

Add tests for parameter "always_failover"

Signed-off-by: Bernardo Dal Seno <>
Signed-off-by: Iustin Pop <>
Reviewed-by: Iustin Pop <>

0ba177e2 12/08/2011 10:48 am René Nussbaumer

cmdlib: Adding hv/disk state dict helper functions

Signed-off-by: René Nussbaumer <>
Reviewed-by: Michael Hanselmann <>

784cd737 12/08/2011 10:48 am René Nussbaumer

cmdlib: Adding _UpdateAndVerifySubDict helper

This helps with 2 dimensional dicts.
For example the hv_state and the disk_state dicts.

Signed-off-by: René Nussbaumer <>
Reviewed-by: Michael Hanselmann <>

8a69b3a8 12/06/2011 06:34 pm Andrea Spadaccini

Add DRBD barriers disk parameters

Add the disk-barriers and meta-barriers parameters described in the
design doc.

constants.py:
  • add the needed LD and DT-level parameters, use the defaults provided
    at ./configure time;
  • add constants representing which barriers should be disabled and the...
0fbedb7a 12/02/2011 06:55 pm Michael Hanselmann

objects.Cluster: Add property for primary hypervisor

This is useful for working with a node's hypervisor state, where only
the primary hypervisor will be authoritative.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

bc5d0215 12/01/2011 01:03 pm Andrea Spadaccini

Add basic support for disk parameters

objects.py: * add disk parameters to Disk, Cluster, NodeGroup.

constants.py: * add dictionaries that will hold types and default values for disk
parameters (for now, empty).

test/ganeti.constants_unittest.py:...

fbd55434 11/30/2011 03:18 pm Michael Hanselmann

Fix race condition in test for *FileID functions

In this test the “file ID” of a temporary file is compared against the
file ID gathered via an open file descriptor to the same file. For
reasons unknown to me utime(2) is called in-between to update the
inode's a- and mtime. Depending on the file system's timestamp...

5f06ce5e 11/30/2011 01:57 pm Michael Hanselmann

Add objects for disk/hv state

- Data objects
- Serialization/deserialization
- Unittests

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>
Reviewed-by: René Nussbaumer <>

c6a622cf 11/30/2011 12:16 pm Michael Hanselmann

locking: Allow checking if lock is owned in certain mode

With this patch the “LockSet” and “GanetiLockManager” classes have a new
function to check if a single or a group of locks (at a certain level)
have been acquired in a specific mode. This will be used for additional...

75191077 11/24/2011 12:31 pm Michael Hanselmann

Merge branch 'devel-2.5'

  • devel-2.5:
    LUGroupAssignNodes: Fix node membership corruption
    LUGroupAssignNodes: Fix node membership corruption
    Fix pylint warning on unreachable code
    LUNodeEvacuate: Disallow migrating all instances at once
    Separate OpNodeEvacuate.mode from iallocator...
2b9245ff 11/24/2011 11:04 am Michael Hanselmann

Merge branch 'stable-2.5' into devel-2.5

  • stable-2.5:
    LUGroupAssignNodes: Fix node membership corruption
    Fix pylint warning on unreachable code
    LUNodeEvacuate: Disallow migrating all instances at once
    LUNodeEvacuate: Locking fixes
    Fix error when removing node...
54c31fd3 11/24/2011 10:39 am Michael Hanselmann

LUGroupAssignNodes: Fix node membership corruption

Note: This bug only manifests itself in Ganeti 2.5, but since the
problematic code also exists in 2.4, I decided to fix it there.

If a node was assigned to a new group using “gnt-group assign-nodes” the...

cb92e7a1 11/23/2011 03:03 pm Michael Hanselmann

Separate OpNodeEvacuate.mode from iallocator

Until now the iallocator constants for node evacuation
(IALLOCATOR_NEVAC_*) were also used for the opcode. However, it turned
out this was due to a misunderstanding and is incorrect. This patch adds
new constants (with the same values) and changes the affected places....

861610e9 11/22/2011 07:55 pm Guido Trotter

unittests: use max/min memory

Signed-off-by: Guido Trotter <>
Reviewed-by: Iustin Pop <>

0e82dcf9 11/18/2011 01:48 pm Andrea Spadaccini

Merge branch 'devel-2.5'

  • devel-2.5: (24 commits)
    LUInstanceCreate: Release unused node locks
    htools: rework message display construction
    hbal: handle empty node groups
    Document OpNodeMigrate's result for RAPI
    Ensure unused ports return to the free port pool...
0c1441eb 11/18/2011 12:41 pm Michael Hanselmann

Merge branch 'stable-2.5' into devel-2.5

  • stable-2.5:
    htools: rework message display construction
    hbal: handle empty node groups
    Document OpNodeMigrate's result for RAPI
    Fail if node/group evacuation can't evacuate instances
    LUInstanceRename: Compare name with name...
27caa993 11/17/2011 03:39 pm Michael Hanselmann

workerpool: Allow processing of new tasks to be stopped

This is different from “Quiesce” in the sense that this function just
changes an internal flag and doesn't wait for the queue to be empty.
Tasks already being processed continue normally, but no new tasks will...

2e04d454 11/16/2011 03:15 pm Agata Murawska

Introduce admin_state as 3-values data type

Signed-off-by: Agata Murawska <>
Reviewed-by: Iustin Pop <>

9ca8a7c5 11/16/2011 03:15 pm Agata Murawska

Rename admin_up to admin_state

Signed-off-by: Agata Murawska <>
Reviewed-by: Iustin Pop <>

9c709b31 11/16/2011 10:41 am René Nussbaumer

algo: Make a dict from an flat list

This is in preparation to take deeper dict constructs from the command
line. You can feed the optionslist directly constructed of type
"identkeyval" to it and it returns a fully deflated dict.

This is mainly needed for the resource model changes where we have to...

ee2b99e3 11/15/2011 03:50 pm Michael Hanselmann

locking: Make some aliased methods public

Some methods, such as “_is_owned” and “list_owned”, have been aliased to
make them public for a while now. This patch makes the actual
implementation public.

SharedLock's “is_owned” needs to be aliased to “_is_owned” to remain...

db859c7d 11/14/2011 08:23 am Michael Hanselmann

check-python-code: Detect old-style pylint disable-msg lines

Commit b459a848d was supposed to replace all, but one was missed. Add a
check to autotools/check-python-code.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Andrea Spadaccini <>

d755483c 11/08/2011 04:06 pm Michael Hanselmann

Fail if node/group evacuation can't evacuate instances

If an instance can't be evacuated, only a message would be printed. With
this change the operation always aborts. Newly added unittests check for
this behaviour.

Signed-off-by: Michael Hanselmann <>...

320e34df 11/07/2011 07:01 pm Michael Hanselmann

query: Use new SequenceToDict utility

Signed-off-by: Michael Hanselmann <>
Reviewed-by: René Nussbaumer <>

6d0accae 11/04/2011 08:09 am Michael Hanselmann

utils.algo: Add utility to convert sequence to dictionary

Useful for converting list of query fields to a dictionary and to
convert RPC definitions. Includes duplicate detection.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

d60946d9 11/02/2011 05:28 pm René Nussbaumer

utils.algo: Add a function to insert a list into a list

Signed-off-by: René Nussbaumer <>
Reviewed-by: Michael Hanselmann <>

da124e89 11/01/2011 09:07 pm Andrea Spadaccini

Generalize HooksMaster

- remove any dependence on Logical Units from the HooksMaster;
- add a new function parameter to the constructor, a function that is
expected to convert the results of the hooks execution in a format
understood by the HooksMaster;...

949dcb1d 11/01/2011 08:37 pm Andrea Spadaccini

Generalize HooksMaster

- remove any dependence on Logical Units from the HooksMaster;
- add a new function parameter to the constructor, a function that is
expected to convert the results of the hooks execution in a format
understood by the HooksMaster;...

0f03d8d4 11/01/2011 03:19 pm Michael Hanselmann

Clean up incorrect merge 7dcf333d

The unittests weren't corrected for the master branch.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: René Nussbaumer <>

7dcf333d 10/31/2011 05:54 pm Michael Hanselmann

Merge branch 'devel-2.5'

  • devel-2.5:
    Fix wrong headers and licences
    Update NEWS and increase to 2.4.5
    Fix parameters of RpcResult in hooks unit tests
    Fix a too long line.
    Move RenameFile to the new functions
    ensure_dirs: Move some useful functions into utils....
fd7b69c0 10/31/2011 04:36 pm Michael Hanselmann

Fix wrong headers and licences

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Stephen Shirley <>

3fc210de 10/27/2011 12:31 pm Andrea Spadaccini

Fix parameters of RpcResult in hooks unit tests

In FakeHooksRpcSuccess, the data parameter of the RpcResult constructor
was not enclosed in a tuple. While this does not make the test fail, it
must be fixed.

Signed-off-by: Andrea Spadaccini <>...

5c3ee7b2 10/26/2011 06:13 pm Michael Hanselmann

Fix RPC unittest

Add missing “read_timeout” value.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

b355affb 10/26/2011 12:06 pm René Nussbaumer

Fix a too long line.

That's what you get for not running make lint :(

Signed-off-by: René Nussbaumer <>
Reviewed-by: Iustin Pop <>

db04ce5d 10/26/2011 11:53 am Michael Hanselmann

Move bootstrap-related RPC to generated wrappers

With this patch, only 6 RPC are left as old-style code.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

83e7af18 10/26/2011 11:51 am Michael Hanselmann

rpc: Disable timeout check

This is in preparation for the definition-based RPC model, where
the timeout will be stored within the definition.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

9c2b3a70 10/26/2011 11:42 am René Nussbaumer

Move RenameFile to the new functions

Signed-off-by: René Nussbaumer <>
Reviewed-by: Michael Hanselmann <>

b81b3c96 10/26/2011 11:42 am René Nussbaumer

ensure_dirs: Move some useful functions into utils.

With this change we can easily reuse this functionality where it makes
sense on other parts of Ganeti.

Signed-off-by: René Nussbaumer <>
Reviewed-by: Michael Hanselmann <>

cdf71b12 10/25/2011 05:05 pm Andrea Spadaccini

Add the JoinDisjointDicts function to utils.algo

Add a function that joins two dictionaries, enforcing the constraint
that the two key sets should be disjoint. Also, add unit tests for this
function.

Signed-off-by: Andrea Spadaccini <>...

dce20078 10/24/2011 03:49 pm Michael Hanselmann

utils.ShellWriter: Don't indent empty lines

Empty lines shouldn't get indented. Unittest included.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

97298dc9 10/21/2011 04:16 pm René Nussbaumer

Merge branch 'stable-2.5' into devel-2.5

Signed-off-by: René Nussbaumer <>
Reviewed-by: Michael Hanselmann <>

bac6ea51 10/21/2011 01:58 pm Michael Hanselmann

http.client: Remove use of PycURL's “reset” function

We don't re-use cURL objects anymore, so there's no need to reset them.
PycURL 7.19.0 has a reference counting bug leading to a crash after
a certain number of performed requests.

Since a unittest depended on this function for a test, it is replaced...

4fd2660d 10/21/2011 01:58 pm Michael Hanselmann

Add unittest for PycURL 7.19.0's reset issue

While we won't use this function in Ganeti (yet), users should be aware
of the potential crashes caused by this functioni (discussed offline).
If the installed version of PycURL is not affected, this test is a...

73ebb9ff 10/20/2011 04:30 pm Guido Trotter

Merge branch 'devel-2.5'

  • devel-2.5:
    Allow per-hypervisor optional files
    Add hypervisors ancillary files list
    xen: abstract a few hardcoded strings as constants

Conflicts:
lib/cmdlib.py
- trivial

Signed-off-by: Guido Trotter <>...

0ad1ea40 10/20/2011 03:04 pm Guido Trotter

Allow per-hypervisor optional files

Rather than just allowing files for all nodes to be optional, we allow
optional files to be per-category. The way this works is that they must
be included in both lists (the new code checks for this).

The code also removes a duplicate assert (present both in verify and...

8dc76d54 10/20/2011 12:22 pm Guido Trotter

Revert "Rename utils.mlock to utils.cfunc"

The rename is not needed either, since we're not adding more code as of
now.
This reverts commit 57ca011e1cd2681948969724e2646edaac22da28.

Signed-off-by: Guido Trotter <>
Reviewed-by: Michael Hanselmann <>

142c1ad0 10/20/2011 12:22 pm Guido Trotter

Revert "utils.cfunc: Cleanup, more flexibility"

We discussed that this is not needed right now, and it breaks existing
functionality and unittests.

This reverts commit 6915fe26da8dce41fc967d761f005390aa956161.

Signed-off-by: Guido Trotter <>...

0b58db81 10/18/2011 06:29 pm Michael Hanselmann

RAPI: Make node evacuation actually work

Commit e1f23243 changed te LU and opcode for node evacuation to receive
a “mode” parameter (among other things). Commit de40437a changed the
RAPI code accordingly, but did so for an earlier version of the first
patch. Obviously this couldn't work, so here's the fix....

682878d9 10/18/2011 04:00 pm Guido Trotter

Merge branch 'devel-2.5'

  • devel-2.5:
    rapi.client.ModifyNode should PUT rather than POST
    Fix RAPI node modify client and server calls
    xen: changes to facilitate "xl" support (xen 4.1)
    xen: abstract instance config file naming
    Abstract xen's 'xm' command as a constant...
6915fe26 10/17/2011 06:05 pm Michael Hanselmann

utils.cfunc: Cleanup, more flexibility

- Split code using ctypes directly into a helper class
- Don't load “libc.so.6”, but use handle for main program instead (see
comment in code)
- Clarify comment on errno with older ctypes versions
- Rename unittest since it can't be used for other functions (modifies...

57ca011e 10/17/2011 06:05 pm Michael Hanselmann

Rename utils.mlock to utils.cfunc

Renaming so that more code using ctypes could be added to the same file.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

539d65ba 10/17/2011 04:58 pm Michael Hanselmann

RAPI: Fix resource for replacing disks

Commit d1c172deb4f inadvertently changes the
“/2/instances/[instance_name]/replace-disks” resource to use body
parameters. There were no QA tests and the issue wasn't noticed.

This patch re-introduces support for query parameters and adds a QA...

94497dd1 10/13/2011 05:40 pm Michael Hanselmann

rapi: Add resource for modifying node

A separate patch will add “auto-promote” through
“/2/nodes/[node_name]/role”.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

b8d51bb2 10/13/2011 05:40 pm Michael Hanselmann

constants: Verify exported names

The “constants” module is a bit special in the sense that we don't want
to export random stuff from it. This unittest checks the naming
convention and removes imported modules from the module's namespace.

Signed-off-by: Michael Hanselmann <>...

abbf2cd9 10/13/2011 03:22 pm Michael Hanselmann

http.client: Remove HTTP client pool code

This patch removes all remains of the HTTP client pool. Newly added unittests
provide 96% coverage on http.client.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

2e5c33db 10/12/2011 02:01 pm Iustin Pop

Rename filter and filter_ to qfilter

We currently use 'filter' as the OpCode, QueryRequest and RAPI field
name for representing a query filter. However, since 'filter' is a
built-in function, we actually have to use filter_ throughout the code
in order to not override the built-in function....

fa337742 10/05/2011 06:30 pm Agata Murawska

Fixes for ovfconverter + vmware

Signed-off-by: Agata Murawska <>
Reviewed-by: Iustin Pop <>

eedf99b5 10/05/2011 03:17 pm Andrea Spadaccini

Move cluster verify error codes to constants

- move the cluster verify error codes from cmdlib._VerifyErrors to
constants;
- add to each of them the CV (Cluster Verify) prefix;
- add the CV_ALL_ECODES and CV_ALL_ECODES_STRINGS constants;
- wrap the lines that exceed 80 characters after changing the error...

7df2c4f0 10/05/2011 12:05 pm Andrea Spadaccini

Add ValidateNetmask and GetClass IPAddress methods

Add the following methods to netutils.IPAddress:
  • ValidateNetmask
  • GetClassFromIpVersion
  • GetClassFromIpFamily

Also, add related tests to the test suite.

Signed-off-by: Andrea Spadaccini <>...

ea9c753d 10/04/2011 09:34 pm Andrea Spadaccini

Merge branch 'devel-2.5'

  • devel-2.5:
    cluster-merge: log an info message at node readd
    Bump version to 2.5.0~rc1
    Fix issue when verifying cluster files
    Revert "utils.log: Write error messages to stderr"
    Fix adding nodes after commit 64c7b3831dc...
a080bab8 10/04/2011 09:32 pm Andrea Spadaccini

Merge branch 'stable-2.5' into devel-2.5

Signed-off-by: Andrea Spadaccini <>
Reviewed-by: René Nussbaumer <>

170b02b7 10/04/2011 11:33 am Michael Hanselmann

Fix issue when verifying cluster files

If a cluster has any non-master-candidate nodes, those don't contain all
files (e.g. config.data). With commit aef59ae764dc (March 31st, 2011)
the logic was changed and subsequently verifying a cluster with non-mc
nodes would complain....

64c7b383 09/30/2011 07:04 pm Michael Hanselmann

LUClusterVerifyGroup: Spread SSH checks over more nodes

When verifying a group the code would always check SSH to all nodes in
the same group, as well as the first node for every other group. On big
clusters this can cause issues since many nodes will try to connect to...

fb926117 09/30/2011 02:06 pm Andrea Spadaccini

Add gnt-cluster commands to toggle the master IP

lib/client/gnt_cluster.py:
  • Add activate-master-ip and deactivate-master-ip commands
man/gnt-cluster.rst:
  • Document the new commands
lib/opcodes.py lib/cmdlib.py
  • Add two opcodes and the LU that call the relevant RPCs...
f8326fca 09/29/2011 12:41 pm Andrea Spadaccini

Move _TimeoutExpired to utils

Signed-off-by: Andrea Spadaccini <>
Reviewed-by: Michael Hanselmann <>

aea5caef 09/28/2011 01:15 pm Michael Hanselmann

rpc/http: Show pending RPC requests in lock monitor

Not all requests use an instance of RpcRunner yet and therefore won't
show up (only instances have access to the global Ganeti context).
Currently only the IP address is accessible. Another patch will add a...

00267bfe 09/27/2011 02:47 pm Michael Hanselmann

rpc: Overhaul client structure

- Clearly separate node name to IP address resolution into separate
functions
- Simplified code structure (one code path instead of several)
- Fully unittested
- Preparation for more RPC improvements

Signed-off-by: Michael Hanselmann <>...

d92518d3 09/26/2011 05:10 pm Agata Murawska

Export: unittests

Signed-off-by: Agata Murawska <>
Reviewed-by: Michael Hanselmann <>

1e6fab60 09/26/2011 05:10 pm Agata Murawska

Import: unittests

Signed-off-by: Agata Murawska <>
Reviewed-by: Michael Hanselmann <>

cdeda3b6 09/26/2011 12:35 pm Michael Hanselmann

Revert "Fail if dictionary uses invalid keys" and "Support newer “json” module"

This reverts commit fd0351aef246f5d36e641209429e2ec093d325f8 and
9869e771704ada62bab001e729c52a36525ef081. The built-in module is a lot
slower in Python 2.6.

Signed-off-by: Michael Hanselmann <>...

fd0351ae 09/23/2011 05:39 pm Michael Hanselmann

serializer: Fail if dictionary uses invalid keys

JSON only supports a very restricted set of types for dictionary keys,
among them strings, booleans and “null”. Integers and floats are
converted to strings. Since this can cause a lot of confusion in Python,...

42d4d8b9 09/20/2011 06:17 pm Michael Hanselmann

RAPI: Add resource to powercycle node

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

a52978c7 09/16/2011 10:44 am Michael Hanselmann

RAPI: Add resource to recreate instance's disks

This was still missing from RAPI.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

e4f4896b 09/15/2011 04:40 pm Guido Trotter

Merge branch 'devel-2.5'

  • devel-2.5: (33 commits)
    htools: remove dead code
    hail: don't select the primary as new secondary
    hail: add an extra safety check in relocate
    Fix RAPI documentation for gnt-instance console
    Add SPICE compression and streaming options...
8497c267 09/14/2011 06:29 pm Michael Hanselmann

docs unittest: Add verification of opcodes covered by RAPI

All opcodes which are not yet covered or can't with the current design
(e.g. cluster initialization) are excluded. This test is added to the
docs unittest since here the code already has access to a list of all...

1315b792 09/14/2011 06:29 pm Michael Hanselmann

docs unittest: Split into two separate test cases

The RAPI and hooks documentation aren't related at all.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

bf317058 09/14/2011 06:29 pm Michael Hanselmann

docs unittest: Make _ReadDocFile a global function

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

f6ce0ba2 09/14/2011 06:29 pm Michael Hanselmann

rlib2: Declare all opcodes and equivalents

By declaring all used opcodes or opcodes equivalent to the operations
executed in a resource we will be able to ensure all opcodes are covered
by RAPI (with some exceptions).

Signed-off-by: Michael Hanselmann <>...

4d2cdb5a 09/13/2011 03:29 pm Andrea Spadaccini

Add SPICE support to gnt-instance console

Also update related unit tests.

Signed-off-by: Andrea Spadaccini <>
Reviewed-by: Michael Hanselmann <>

04b2332b 09/13/2011 03:27 pm Michael Hanselmann

Fix unittest breakage from commit 132cdb87159e

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>