swh:1:snp:5115096b921df712aeb2a08114fede57fb3331fb
Revision c1bb32e1ba9da94d9e40af692f60c2c0420685cd authored by Dhruba Borthakur on 27 September 2012, 08:05:38 UTC, committed by Dhruba Borthakur on 28 September 2012, 18:10:52 UTC
Summary:
In the current code, a Get() call can trigger compaction if it has to look at more than one file. This causes unnecessary compaction because looking at more than one file is a penalty only if the file is not yet in the cache. Also, th current code counts these files before the bloom filter check is applied.

This patch counts a 'seek' only if the file fails the bloom filter
check and has to read in data block(s) from the storage.

This patch also counts a 'seek' if a file is not present in the file-cache, because opening a file means that its index blocks need to be read into cache.

Test Plan: unit test attached. I will probably add one more unti tests.

Reviewers: heyongqiang

Reviewed By: heyongqiang

CC: MarkCallaghan

Differential Revision: https://reviews.facebook.net/D5709
1 parent 92368ab
History
Tip revision: 19076c95aa2bcee55c26fcf0960cc844ad86ee9c authored by Levi Tamasi on 21 January 2021, 22:18:25 UTC
Update HISTORY.md for PR 7888 (#7890)
Tip revision: 19076c9
File Mode Size
db
doc
hdfs
helpers
include
port
scribe
snappy
table
thrift
tools
util
.arcconfig -rw-r--r-- 110 bytes
.gitignore -rw-r--r-- 61 bytes
AUTHORS -rw-r--r-- 193 bytes
LICENSE -rw-r--r-- 1.4 KB
Makefile -rw-r--r-- 8.9 KB
NEWS -rw-r--r-- 509 bytes
README -rw-r--r-- 1.7 KB
README.fb -rw-r--r-- 281 bytes
TODO -rw-r--r-- 494 bytes
build_detect_platform -rwxr-xr-x 7.6 KB
build_detect_version -rwxr-xr-x 1.1 KB
fbcode.gcc471.sh -rw-r--r-- 2.2 KB
fbcode.sh -rw-r--r-- 2.1 KB

README

back to top