hydra/t
Rick van Schijndel ef619eca99
t: increase timeouts for slow commands with high load
We've seen many fails on ofborg, at lot of them ultimately appear to come down to
a timeout being hit, resulting in something like this:

Failure executing slapadd -F /<path>/slap.d -b dc=example -l /<path>/load.ldif.

Hopefully this resolves it for most cases.
I've done some endurance testing and this helps a lot.
some other commands also regularly time-out with high load:

- hydra-init
- hydra-create-user
- nix-store --delete

This should address most issues with tests randomly failing.

Used the following script for endurance testing:

```

import os
import subprocess

run_counter = 0
fail_counter = 0

while True:
    try:
        run_counter += 1
        print(f"Starting run {run_counter}")
        env = os.environ
        env["YATH_JOB_COUNT"] = "20"
        result = subprocess.run(["perl", "t/test.pl"], env=env)
        if (result.returncode != 0):
            fail_counter += 1
        print(f"Finish run {run_counter}, total fail count: {fail_counter}")
    except KeyboardInterrupt:
        print(f"Finished {run_counter} runs with {fail_counter} fails")
        break
```

In case someone else wants to do it on their system :).
Note that YATH_JOB_COUNT may need to be changed loosely based on your
cores.
I only have 4 cores (8 threads), so for others higher numbers might
yield better results in hashing out unstable tests.
2024-08-11 16:08:09 +02:00
..
content-addressed Minimal CA support 2024-01-26 00:34:58 -05:00
evaluator treewide: start removing tests related to constituents 2024-07-17 08:31:19 +02:00
Helper/AddBuilds AddBuilds: fix declarative jobsets with dynamic runcommand enabled 2022-06-30 01:49:30 +02:00
Hydra jobset-eval: fix actions not showing up sometimes for new jobs 2024-07-20 13:09:39 +02:00
input-types perlcritic: use strict, use warnings 2021-09-06 22:13:33 -04:00
jobs hydra-eval-jobset: use nix-eval-jobs instead of hydra-eval-jobs 2024-07-17 08:31:19 +02:00
lib t: increase timeouts for slow commands with high load 2024-08-11 16:08:09 +02:00
queue-runner t: increase timeouts for slow commands with high load 2024-08-11 16:08:09 +02:00
scripts t: increase timeouts for slow commands with high load 2024-08-11 16:08:09 +02:00
api-test.t api-test.t: don't print request content 2022-01-10 11:02:01 -05:00
build-products.t build-products: switch to makeAndEvaluateJobset 2021-12-14 20:32:13 -05:00
meson.build autotools -> meson 2024-07-22 22:30:41 +02:00
perlcritic.pl Start checking PRs with perlcritic 2021-08-20 11:06:43 -04:00
s3-backup-test.config tests: move to t, allow yath test from root 2021-03-05 09:49:06 -08:00
s3-backup-test.pl perlcritic: explicitly assign the result of readdir/file reads 2021-09-07 21:55:55 -04:00
setup-notifications-jobset.pl JSON -> JSON::MaybeXS 2021-12-13 15:37:56 -05:00
test.pl Update t/test.pl: fixup the list of env vars yath looks at for job count 2022-02-10 11:53:10 -05:00