- Dec 18, 2012
-
-
Bernardo Dal Seno authored
Some fixes, added more information in a few points, removed a stale (5+ year old) TODO comment. Signed-off-by:
Bernardo Dal Seno <bdalseno@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Iustin Pop authored
This can be more useful than the "make" version. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Michael Hanselmann authored
Commit 141d1489 was a bit too enthusiastic. The three parameters added to the list of parameters to be checked default to a value not evaluating to false, leading to a failure on cluster initialization. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Dimitris Aragiorgis authored
LEVEL_NODE_ALLOC should be aquired too if LEVEL_NODE is ALL_SET. Signed-off-by:
Dimitris Aragiorgis <dimara@grnet.gr> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Helga Velroyen authored
This patch contains the HUnit test that checks the compatibility of Haskell-generated networks with the python code. For that the generation of test instances of networks was enhanced to meet the validation steps of the python implementation. Also, so far networks were generated at two different places in the code; this is now consolidated. Signed-off-by:
Helga Velroyen <helgav@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
- Dec 17, 2012
-
-
Michael Hanselmann authored
“_SPICE_ADDITIONAL_PARAMS” is supposed to be the full list of SPICE-related KVM hypervisor parameters with the exception of “HV_KVM_SPICE_BIND”. The new test checks if all parameters starting with “HV_KVM_SPICE_*” are included. Three previously missing parameters are added to the list. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Michael Hanselmann authored
This list is static at runtime and doesn't need to be recreated every time. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Michael Hanselmann authored
When non-DRBD disks are used for an instance, “lu.needed_locks[locking.LEVEL_NODE]” is set to “locking.ALL_SET” (which is None). The assertion will then fail as None evaluates to False. Reported by Constantinos Venetsanopoulos. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Michael Hanselmann authored
Doing so avoids triggering an assertion in mcpu which cross-checks the node lock and node allocation lock acquisition mode. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Iustin Pop authored
Commit f0f8d060 (“Show old primary/secondary node on disk replacement”) added two wrong uses of feedback_fn, which results in log entries such like these: "log": [ [ 7, [1351258326, 466214], "message", "Replacing disk(s) 0 for instance 'instance1.example.com'" ], [ 8, [1351258326, 749391], "Current primary node: %s", "node1" ], [ 9, [1351258326, 774829], "Current seconary node: %s", "node4" ], [ 10, [1351258329, 620410], "message", "STEP 1/6 Check device existence" ], (the first and fourth are OK, the 2nd and 3rd are broken). The API of jqueue._OpExecCallbacks.Feedback should probably be changed to prevent such an occurrence in the future. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michele Tartara <mtartara@google.com>
-
Iustin Pop authored
Some confd types were not tested for serialisation, so let's move these (type-related) tests to their own module and extend them. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Helga Velroyen <helgav@google.com>
-
Iustin Pop authored
Commit e821050d (“Switch the Luxi interface from Strings to ByteStrings”) was designed to optimise the receive interface, but has an unfortunate side-effect: when sending non-trivial messages, it means that both the entire String and the ByteString versions must be in memory at the same time, leading to much increased memory usage. By changing the "hPut" from strict to lazy ByteStrings, it means that both the String and the ByteString values can be evaluated lazily, with significant effects: for a test query answer, instead of having a peak from ~600MB to 1.4G during the entire Luxi send operation, memory consumption actually decreased during the send operation, as the ByteString chunks are released individually and even the backing storage of the items that create the JSON string serialisation is released lazily as well. So instead of slow growth 10→550MB then quick peak to 1.4GB during Luxi send, we now have an even slower growth to ~580MB and then decrease of memory as the Luxi send progresses. The only downside is of a small increase in CPU time of a few percents for the above case; for our use cases, I think this is much desirable. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Helga Velroyen <helgav@google.com>
-
Iustin Pop authored
This allows us to ensure that query results are strict as we build them, instead of being lazy and only evaluated when the reply is sent over the Luxi interface. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Helga Velroyen <helgav@google.com>
-
Iustin Pop authored
The JSValue/JSObject types don't come with a NFData instance, so let's add one ourselves, so that we can force evaluation of JSValues (either when building or when reading them). Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Helga Velroyen <helgav@google.com>
-
Iustin Pop authored
It seems that Python code generates (sometimes) absolute job dependencies which are strings, instead of integers, so we should be able to parse these as well. We simply change from explicit int-based parsing (makeJobId) to the generic one (parseJobId). Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Helga Velroyen <helgav@google.com>
-
Iustin Pop authored
This changes deps and comment fields to always be shown, to match the Python behaviour for (at least) job listing/ops field. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Helga Velroyen <helgav@google.com>
-
Iustin Pop authored
This is not a required field, but rather an optional one; we add a new parameter and use it instead. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Helga Velroyen <helgav@google.com>
-
Iustin Pop authored
Python code sometimes sends this, so let's support it even though it's non-standard. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Helga Velroyen <helgav@google.com>
-
Iustin Pop authored
Having makeJobIdS as a separate function will allow us to use it outside of json encoding. The patch also exports one more function from the Types module. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michele Tartara <mtartara@google.com>
-
Iustin Pop authored
The 'temporary' library add support for create temporary directories/files beyond what is offered in the base library (which is somewhat limited, and hard to use in tests). Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michele Tartara <mtartara@google.com>
-
Iustin Pop authored
This allows tests to execute IO actions which have logging as a side effect, without polluting the stderr too much. A better solution would be that we have fine-grained control over loggers, so that tests can run with their own logging, etc. etc.. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Iustin Pop authored
This single constant could be as well moved to constants.py. For now I choose to just export the module as well. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Iustin Pop authored
Instead of always using "arbitrary", make it require a generator (that can then use more complex rules for building the list elements), and also convert it to use a temporary set instead of list membership. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Iustin Pop authored
Also adds a small helper for building the paths. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michele Tartara <mtartara@google.com>
-
Iustin Pop authored
Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Helga Velroyen <helgav@google.com>
-
Iustin Pop authored
This implements in the Haskell codebase the opcode summary. As opposed to Python, we always use custom code for formatting, since we don't want to use dynamic attribute lookup. To test this properly, we need to change MetaOpCode to record-syntax, so that we get accessor functions. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Helga Velroyen <helgav@google.com>
-
Iustin Pop authored
For some opcodes, the output is not "stable", and depends on the exact input values; this makes it harder to check consistency against Haskell code. To compensate for this, we add a way to override the formatting of the OP_DSC_FIELD; by default, this is always "%s", but if the OP_DSC_FORMATTER is defined (must be a callable), it is used to format the actual value. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Iustin Pop authored
Also fixes indentation for OP_STATUS. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Iustin Pop authored
The extra space results in inaccessible names; currently GHC doesn't flag this as an error, but I've filled an upstream bug for that (http://hackage.haskell.org/trac/ghc/ticket/7484 ). Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
- Dec 14, 2012
-
-
Iustin Pop authored
Two constants which we use as Integer are defined as Int in Constants.hs (coming from constants.py), so we do the conversion every time we use it. Let's move them to top-level names, so that the conversion is only done once. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Iustin Pop authored
Introduced in commit d4752785. Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
-
Guido Trotter authored
Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Guido Trotter authored
this (a) allows us to test renaming in burnin even if we don't have an extra instance name and (b) is a valid operation, as it allows to "fix" an instance who went name-astray Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Guido Trotter authored
This is a "better than nothing" support, just for kvm and just joining the machine to the opevswitch bridge with the right command. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com> Reviewed-by:
René Nussbaumer <rn@google.com>
-
Guido Trotter authored
Return type is changed from Property to Bool, and the ==? True at the end is dropped. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Guido Trotter authored
Also update the docstring of a function. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Guido Trotter authored
As discussed on the list, these are needed to do a make hs-prof. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- Dec 13, 2012
-
-
Iustin Pop authored
Currently, we log the entire response (at debug level) in the Luxi replies. This is not a good idea; the logging library operates on strings, and as such it will use huge amounts of memory: without debug logging, a certain gnt-job list invocation uses 295MB (+RTS -s) and 2m35s time, when in debug mode, it's 1525MB and 48m! So we make two changes: - first, we switch from "show (pp_value a)" to "encode a", which generates a non-formatted string rather than a indented one - second we log only the first 2000 characters; this should be enough to understand the first part of the response We could go for higher, or for logging in batches (that would be faster, as well). Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Helga Velroyen <helgav@google.com>
-
Constantinos Venetsanopoulos authored
This should be done because in the case of --no-name-check there is no 'hostname.ip' attribute, causing an execution error. 'check_ip' is always set (in CheckArguments) even if --no-name-check is passed in the command line. Signed-off-by:
Constantinos Venetsanopoulos <cven@grnet.gr> Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
Michael Hanselmann authored
This is similar to README or “doc/security.rst”. Having a comment that needs updating for a new version is more likely going to trigger a check of the lists of design drafts. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-