Measured in the test phase of the Dockerfile as make test runs it, with -v added locally for per-test times.
Before, internal/vaultik took 31.9s, 23.6s of it in 36 tests that ran one at a time; 24 of those were serial only because they call log.Initialize. The slowest serial tests were TestListSnapshots_JSONReportsTruncation (3.9s), the two tests in changed_file_restore_test.go (about 2s each) and TestRestoreCleansTempDirOnInterrupt (1.7s). internal/database took 9.8s, 8.4s of it in TestLargeDatasets, which committed each of its 1,500 inserts on its own.
The 24 tests call log.Initialize before t.Parallel(), as the package's other tests do, so the logger is replaced before any parallel test runs. The 12 still serial change the umask, TMPDIR, os.Stderr or time.Local.
TestLargeDatasets makes its inserts in one transaction and still creates 1,000 files.
TestDedupOnlySnapshotRestores names its second backup second instead of sleeping 1.1s for a new snapshot ID, as changed_file_restore_test.go does.
After, over four runs: internal/vaultik 13.3s to 14.1s, internal/database 5.2s to 6.0s.
Partially verified: the before figures are one run at a host load average near 60, the after runs were at lower load, so part of the drop in parallel test times is the host. The serial time (23.6s before, 5.8s after) depends little on load.
Not changed: TestRestoreSweeperEvictsBlobs (about 6.5s, 30 MB of random data) is now the longest test; the serial truncation test needs 1,001 manifests to pass the listing cap.
Model: opus-5-5
Closes https://git.eeqj.de/sneak/vaultik/issues/235.
Measured in the `test` phase of the `Dockerfile` as `make test` runs it, with `-v` added locally for per-test times.
Before, `internal/vaultik` took 31.9s, 23.6s of it in 36 tests that ran one at a time; 24 of those were serial only because they call `log.Initialize`. The slowest serial tests were `TestListSnapshots_JSONReportsTruncation` (3.9s), the two tests in `changed_file_restore_test.go` (about 2s each) and `TestRestoreCleansTempDirOnInterrupt` (1.7s). `internal/database` took 9.8s, 8.4s of it in `TestLargeDatasets`, which committed each of its 1,500 inserts on its own.
- The 24 tests call `log.Initialize` before `t.Parallel()`, as the package's other tests do, so the logger is replaced before any parallel test runs. The 12 still serial change the umask, `TMPDIR`, `os.Stderr` or `time.Local`.
- `TestLargeDatasets` makes its inserts in one transaction and still creates 1,000 files.
- `TestDedupOnlySnapshotRestores` names its second backup `second` instead of sleeping 1.1s for a new snapshot ID, as `changed_file_restore_test.go` does.
After, over four runs: `internal/vaultik` 13.3s to 14.1s, `internal/database` 5.2s to 6.0s.
- Partially verified: the before figures are one run at a host load average near 60, the after runs were at lower load, so part of the drop in parallel test times is the host. The serial time (23.6s before, 5.8s after) depends little on load.
- Not changed: `TestRestoreSweeperEvictsBlobs` (about 6.5s, 30 MB of random data) is now the longest test; the serial truncation test needs 1,001 manifests to pass the listing cap.
Model: opus-5-5
In the Dockerfile test phase, internal/vaultik spent 23.6s of 31.9s in
36 tests run one at a time. 24 of them were serial only because they
call log.Initialize; they now call it before t.Parallel(), so the
logger is replaced before any parallel test runs. The 12 still serial
change the umask, TMPDIR, os.Stderr or time.Local.
TestLargeDatasets took 8.4s of the 9.8s internal/database run by
committing each of its 1,500 inserts on its own; it now makes them in
one transaction. TestDedupOnlySnapshotRestores gives its second backup
its own snapshot name instead of sleeping 1.1s for a new snapshot ID.
Model: opus-5-5
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Closes #235.
Measured in the
testphase of theDockerfileasmake testruns it, with-vadded locally for per-test times.Before,
internal/vaultiktook 31.9s, 23.6s of it in 36 tests that ran one at a time; 24 of those were serial only because they calllog.Initialize. The slowest serial tests wereTestListSnapshots_JSONReportsTruncation(3.9s), the two tests inchanged_file_restore_test.go(about 2s each) andTestRestoreCleansTempDirOnInterrupt(1.7s).internal/databasetook 9.8s, 8.4s of it inTestLargeDatasets, which committed each of its 1,500 inserts on its own.log.Initializebeforet.Parallel(), as the package's other tests do, so the logger is replaced before any parallel test runs. The 12 still serial change the umask,TMPDIR,os.Stderrortime.Local.TestLargeDatasetsmakes its inserts in one transaction and still creates 1,000 files.TestDedupOnlySnapshotRestoresnames its second backupsecondinstead of sleeping 1.1s for a new snapshot ID, aschanged_file_restore_test.godoes.After, over four runs:
internal/vaultik13.3s to 14.1s,internal/database5.2s to 6.0s.TestRestoreSweeperEvictsBlobs(about 6.5s, 30 MB of random data) is now the longest test; the serial truncation test needs 1,001 manifests to pass the listing cap.Model: opus-5-5
Review passed.
Model: opus-5-5