- Nov 30, 2012
-
-
Michael Hanselmann authored
The order of the calls to “ctx.use_privatekey” and “ctx.use_certificate” was wrong, leading to an exception being thrown. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Michael Hanselmann authored
This code will also be used by the node daemon setup utility. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Helga Velroyen <helgav@google.com>
-
Dimitris Aragiorgis authored
TValueNone checks if a value is "none" and TMaybeValueNone is a wrapper of TOr(TValueNone, x). This is used by OpNetworkSetParam in order to reset a network value (e.g. mac_prefix, gateway, etc.) Signed-off-by:
Dimitris Aragiorgis <dimara@grnet.gr> Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Michael Hanselmann authored
Also remove a superfluous empty line in test file. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
- Nov 29, 2012
-
-
Michael Hanselmann authored
This patch adds descriptors to the “_CheckCIDR*” functions in opcodes and improves the descriptions generated by “ht.TInstanceOf”, thereby indirectly fixing bad type descriptions in the RAPI documentation. Before this patch: - (String and (<function _CheckCIDRAddrNotation at 0x2f…>)) - (Instance of (<class 'ganeti.opcodes.OpInstanceCreate'>)) After this patch: - (String and (IPv4 address)) - (Instance of (ganeti.opcodes.OpInstanceCreate)) Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Helga Velroyen <helgav@google.com>
-
Helga Velroyen authored
This bug was introduced by my commit "Check ispecs against ipolicy on instance modify", because I did not filter for the 'add' action. Thus it would try to read the size parameter also when removing disks. Signed-off-by:
Helga Velroyen <helgav@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Michael Hanselmann authored
Some opcodes, for example LUInstanceFailover and LUInstanceMigrate, can't know whether they need to acquire all nodes until they have a lock on the instance. In turn they would have to acquire the node allocation lock “just in case” and could only release it once the instance had been acquired. Since there is no good reason for the node allocation lock to be before instances in the locking order, this patch changes the order so that instances are locked first. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Helga Velroyen <helgav@google.com>
-
Michele Tartara authored
The hpc tool, on squeeze, does not handle utf8 encoded files correctly. The Attoparsec test is just needed to verify whether the parser handles uft8 correctly, so the solution is to exclude it from coverage checks. Signed-off-by:
Michele Tartara <mtartara@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Michael Hanselmann authored
A new utility for configuring the node daemon will have to write the node certificate as well. To not split information about the certificate file even more, the constant is added to “pathutils”. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
- Nov 28, 2012
-
-
Michael Hanselmann authored
A new tool for configuring the node daemon will also have to verify the cluster name, so it's better to have this function in a central place. In the process of moving it to ssconf it is also changed to use “SimpleStore” instead of reading the ssconf directly. Tests are updated. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Helga Velroyen <helgav@google.com>
-
Michael Hanselmann authored
Until now ssconf would limit the amount read from files to 128 KiB and silently ignored files larger than that. With this patch a check is added by using fstat(2) on the file descriptor while it's being read. There were no tests file ssconf at all, so some are added. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Michael Hanselmann authored
Missing spaces around operator. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Michele Tartara <mtartara@google.com>
-
Michael Hanselmann authored
There is no good reason why these two constants should be inside the class. This patch moves them to the module so they can be used without “self”. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Michael Hanselmann authored
Commit b0dcdc10 removed the last user of this class. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Michael Hanselmann authored
- Include filename in error message - s/ip/IP/ - Stop using superfluous variable Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
- Nov 27, 2012
-
-
Helga Velroyen authored
Extend _GetNetworkStatsField() to accept 4 arguments. This fixes Issue 323. Signed-off-by:
Dimitris Aragiorgis <dimara@grnet.gr> Reviewed-by:
Helga Velroyen <helgav@google.com>
-
Dimitris Aragiorgis authored
Add uuid and serial_no to _NETWORK_SIMPLE_FIELDS in order to export them in network queries. Modify gnt-network to list them too. Signed-off-by:
Dimitris Aragiorgis <dimara@grnet.gr> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Michael Hanselmann authored
RE_VALID_SSCONF_NAME is not used anywhere. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Michele Tartara <mtartara@google.com>
-
Michael Hanselmann authored
Commit 9b7e05a6 didn't quite work as expected: glm.is_owned expects a locking level, not a lock name. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Helga Velroyen <helgav@google.com>
-
Michael Hanselmann authored
A new tool to configure the node daemon will also have to load and verify JSON data. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Michael Hanselmann authored
Most tools had their own “SetupLogging” function, but they were all essentially the same. This patch adds a generic version to “utils.log” and provides unit tests. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Michele Tartara authored
* Now the parser completely consumes the input, up to the end of the text. * Name of the test suite module changed to adhere to naming conventions. * Some reformatting of the source code. Signed-off-by:
Michele Tartara <mtartara@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Michael Hanselmann authored
Block instance allocations when all node locks will be acquired. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Michele Tartara <mtartara@google.com>
-
Michael Hanselmann authored
The execution context ID can be passed right away. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Helga Velroyen <helgav@google.com>
-
Michael Hanselmann authored
Check whether the BGL is actually held instead of just testing “REQ_BGL”. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Helga Velroyen <helgav@google.com>
-
Michael Hanselmann authored
The Log* functions are re-exported through the LU. Inline use of string formatting (“%”) was converted to additional arguments to Log* (unlike “feedback_fn”, these functions support it). Some punctuation has been removed from messages, as well as some small re-wordings. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Helga Velroyen <helgav@google.com>
-
Michael Hanselmann authored
Don't use inline versions of CommaJoin. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Helga Velroyen <helgav@google.com>
-
Michael Hanselmann authored
… instead of constructing an object, only to fill it separately. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Michele Tartara <mtartara@google.com>
-
- Nov 26, 2012
-
-
Michael Hanselmann authored
A new method is added to check whether the LockSet-internal lock is held. This is the case after LockSet.acquire was called with locking.ALL_SET. Unit tests are updated, including one where the list of names must be empty. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Michael Hanselmann authored
Commit 8716b1db added a new lock level, LEVEL_NODE_ALLOC. It is ahead of LEVEL_INSTANCE. The latter was hardcoded in mcpu to be locked right after the BGL, effectively ignoring LEVEL_NODE_ALLOC. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
- Nov 23, 2012
-
-
Michele Tartara authored
The bug was in the test itself, not in the tested code. Also, fixed a line longer than 80 characters in the same file. Signed-off-by:
Michele Tartara <mtartara@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Michael Hanselmann authored
The new lock is similar to the BGL in the sense that it has its own level and there is only one. It is called “node allocation lock”. Logical units will use it to synchronize with instance creations, which in turn will start using opportunistic locks on nodes. Additionally, an assertion in GanetiLockManager gained a message. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Michele Tartara authored
These new tests substitute the HTests, as by the suggestion received after submitting the previous patch. Signed-off-by:
Michele Tartara <mtartara@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Michael Hanselmann authored
Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Helga Velroyen authored
This patch fixes some inconsistencies betwen the network design doc and the actual user interface. Adding reserved ips works with option --add-reserved-ips and removing them with --remove-reserved-ips. There is no toggling of the reservation status of ips. Signed-off-by:
Helga Velroyen <helgav@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Iustin Pop authored
Commit 32e3d8b1 (“opcodes: Network parameter improvements and fixes”) changed a few parameters in the network add, connect and set params opcodes, but some of the changes are buggy. The patch changed the type to TMaybe(), whereas the default should have been changed from None to NoDefault - the network, mode and link are required. It also wrongly unified all types as _CheckCIDRNetNotation, whereas some are AddrNotation. The patch fixes these (correctly, I hope) and also add some new aliases for readability. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Iustin Pop authored
We have many cases in the code where we write TOr(TNone, a), so let's introduce a combinator that simplifies this case. Beside replacing the above with TMaybe(a), I did a few other parameter fixes: - noop change TOr(TNone, TDict) to TMaybeDict - noop change TOr(TNone, TNonEmptyString) to TMaybeString - OpClusterSetParams, change master netmask from any integer to a non-negative integer (I can move the last one to a separate patch if desired) Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Iustin Pop authored
The network patches and an existing test added function-call based dict construction as opposed to literal sintax. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michele Tartara <mtartara@google.com>
-
Dimitris Aragiorgis authored
Signed-off-by:
Dimitris Aragiorgis <dimara@grnet.gr> Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Dimitris Aragiorgis authored
Signed-off-by:
Dimitris Aragiorgis <dimara@grnet.gr> Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-