Skip to content

Commit 11cf2c4

Browse files
committed
pebble: deflake move compaction datadriven test
Reduce the number of expected compactions in l0_to_lbase_compaction from 17 to 3. This still exercises the conditions we'd like to test by having more than 1 file in L0. Fixes: #4981
1 parent fe43e7b commit 11cf2c4

File tree

2 files changed

+23
-47
lines changed

2 files changed

+23
-47
lines changed

compaction_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1283,7 +1283,7 @@ func TestCompaction(t *testing.T) {
12831283
lower := 1
12841284
upper := 1
12851285
td.MaybeScanArgs(t, "max", &upper)
1286-
td.MaybeScanArgs(t, "range", &lower, upper)
1286+
td.MaybeScanArgs(t, "range", &lower, &upper)
12871287
d.opts.CompactionConcurrencyRange = func() (int, int) {
12881288
return lower, upper
12891289
}

testdata/compaction/l0_to_lbase_compaction

Lines changed: 22 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -5,82 +5,58 @@ define l0-compaction-threshold=1 auto-compactions=off
55
----
66

77

8-
populate keylen=4 timestamps=(1) vallen=64
8+
set-concurrent-compactions range=(3,3)
9+
----
10+
11+
12+
populate keylen=4 timestamps=(1) vallen=1
913
----
1014
wrote 475254 keys
1115

1216

1317
flush
1418
----
1519
L0.0:
16-
000005:[a@1#10,SET-boao@1#28148,SET]
17-
000006:[boap@1#28149,SET-dcbc@1#56285,SET]
18-
000007:[dcbd@1#56286,SET-eqbu@1#84424,SET]
19-
000008:[eqbv@1#84425,SET-gecj@1#112562,SET]
20-
000009:[geck@1#112563,SET-hsda@1#140701,SET]
21-
000010:[hsdb@1#140702,SET-jgdq@1#168839,SET]
22-
000011:[jgdr@1#168840,SET-kueg@1#196977,SET]
23-
000012:[kueh@1#196978,SET-miev@1#225114,SET]
24-
000013:[miew@1#225115,SET-nwfl@1#253252,SET]
25-
000014:[nwfm@1#253253,SET-pkga@1#281390,SET]
26-
000015:[pkgb@1#281391,SET-qygs@1#309529,SET]
27-
000016:[qygt@1#309530,SET-smhh@1#337667,SET]
28-
000017:[smhi@1#337668,SET-uahw@1#365804,SET]
29-
000018:[uahx@1#365805,SET-voim@1#393942,SET]
30-
000019:[voin@1#393943,SET-xcjb@1#422080,SET]
31-
000020:[xcjc@1#422081,SET-yqjt@1#450219,SET]
32-
000021:[yqju@1#450220,SET-zzzz@1#475263,SET]
20+
000005:[a@1#10,SET-itbq@1#159645,SET]
21+
000006:[itbr@1#159646,SET-rmbh@1#319226,SET]
22+
000007:[rmbi@1#319227,SET-zzzz@1#475263,SET]
3323

3424

35-
auto-compact count=17
25+
auto-compact count=3
3626
----
3727
L6:
38-
000005:[a@1#10,SET-boao@1#28148,SET]
39-
000006:[boap@1#28149,SET-dcbc@1#56285,SET]
40-
000007:[dcbd@1#56286,SET-eqbu@1#84424,SET]
41-
000008:[eqbv@1#84425,SET-gecj@1#112562,SET]
42-
000009:[geck@1#112563,SET-hsda@1#140701,SET]
43-
000010:[hsdb@1#140702,SET-jgdq@1#168839,SET]
44-
000011:[jgdr@1#168840,SET-kueg@1#196977,SET]
45-
000012:[kueh@1#196978,SET-miev@1#225114,SET]
46-
000013:[miew@1#225115,SET-nwfl@1#253252,SET]
47-
000014:[nwfm@1#253253,SET-pkga@1#281390,SET]
48-
000015:[pkgb@1#281391,SET-qygs@1#309529,SET]
49-
000016:[qygt@1#309530,SET-smhh@1#337667,SET]
50-
000017:[smhi@1#337668,SET-uahw@1#365804,SET]
51-
000018:[uahx@1#365805,SET-voim@1#393942,SET]
52-
000019:[voin@1#393943,SET-xcjb@1#422080,SET]
53-
000020:[xcjc@1#422081,SET-yqjt@1#450219,SET]
54-
000021:[yqju@1#450220,SET-zzzz@1#475263,SET]
28+
000005:[a@1#10,SET-itbq@1#159645,SET]
29+
000006:[itbr@1#159646,SET-rmbh@1#319226,SET]
30+
000007:[rmbi@1#319227,SET-zzzz@1#475263,SET]
5531

5632

5733
metrics
5834
----
5935
| | | | ingested | moved | written | | amp
6036
level | tables size val-bl vtables | score ff cff | in | tables size | tables size | tables size | read | r w
6137
------+-----------------------------+----------------+-------+--------------+--------------+--------------+-------+---------
62-
0 | 0 0B 0B 0 | - 0 0 | 33MB | 0 0B | 0 0B | 17 34MB | 0B | 0 1.02
38+
0 | 0 0B 0B 0 | - 0 0 | 4.5MB | 0 0B | 0 0B | 3 6.0MB | 0B | 0 1.32
6339
1 | 0 0B 0B 0 | - 0 0 | 0B | 0 0B | 0 0B | 0 0B | 0B | 0 0
6440
2 | 0 0B 0B 0 | - 0 0 | 0B | 0 0B | 0 0B | 0 0B | 0B | 0 0
6541
3 | 0 0B 0B 0 | - 0 0 | 0B | 0 0B | 0 0B | 0 0B | 0B | 0 0
6642
4 | 0 0B 0B 0 | - 0 0 | 0B | 0 0B | 0 0B | 0 0B | 0B | 0 0
6743
5 | 0 0B 0B 0 | - 0 0 | 0B | 0 0B | 0 0B | 0 0B | 0B | 0 0
68-
6 | 17 34MB 0B 0 | - 0.53 0.53 | 0B | 0 0B | 17 34MB | 0 0B | 0B | 1 0
69-
total | 17 34MB 0B 0 | - - - | 33MB | 0 0B | 17 34MB | 17 67MB | 0B | 1 2.02
44+
6 | 3 6.0MB 0B 0 | - 0.09 0.09 | 0B | 0 0B | 3 6.0MB | 0 0B | 0B | 1 0
45+
total | 3 6.0MB 0B 0 | - - - | 4.5MB | 0 0B | 3 6.0MB | 3 10MB | 0B | 1 2.32
7046
----------------------------------------------------------------------------------------------------------------------------
71-
WAL: 1 files (0B) in: 33MB written: 33MB (0% overhead)
47+
WAL: 1 files (0B) in: 4.5MB written: 4.5MB (0% overhead)
7248
Flushes: 2
73-
Compactions: 17 estimated debt: 0B in progress: 0 (0B) canceled: 0 (0B) failed: 0 problem spans: 0
74-
default: 0 delete: 0 elision: 0 move: 17 read: 0 tombstone-density: 0 rewrite: 0 copy: 0 multi-level: 0 blob-file-rewrite: 0
49+
Compactions: 3 estimated debt: 0B in progress: 0 (0B) canceled: 0 (0B) failed: 0 problem spans: 0
50+
default: 0 delete: 0 elision: 0 move: 3 read: 0 tombstone-density: 0 rewrite: 0 copy: 0 multi-level: 0 blob-file-rewrite: 0
7551
MemTables: 1 (512KB) zombie: 1 (512KB)
7652
Zombie tables: 0 (0B, local: 0B)
7753
Backing tables: 0 (0B)
7854
Virtual tables: 0 (0B)
79-
Local tables size: 34MB
80-
Compression types: snappy: 17
55+
Local tables size: 6.0MB
56+
Compression types: snappy: 3
8157
Table stats: all loaded
82-
Block cache: 3.3K entries (7.0MB) hit rate: 0.1%
83-
File cache: 17 tables, 0 blobfiles (4.6KB) hit rate: 97.4%
58+
Block cache: 1.5K entries (6.4MB) hit rate: 60.0%
59+
File cache: 3 tables, 0 blobfiles (840B) hit rate: 90.0%
8460
Range key sets: 0 Tombstones: 0 Total missized tombstones encountered: 0
8561
Snapshots: 0 earliest seq num: 0
8662
Table iters: 0

0 commit comments

Comments
 (0)