Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
indiff7643
Terarkdb
提交
aca403d2
T
Terarkdb
项目概览
indiff7643
/
Terarkdb
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
T
Terarkdb
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
aca403d2
编写于
12月 11, 2015
作者:
D
Dmitri Smirnov
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Fix another rebase problems.
上级
a6fbdd64
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
12 addition
and
10 deletion
+12
-10
db/db_bench.cc
db/db_bench.cc
+0
-1
db/version_set.cc
db/version_set.cc
+11
-8
util/rate_limiter.h
util/rate_limiter.h
+1
-1
未找到文件。
db/db_bench.cc
浏览文件 @
aca403d2
...
...
@@ -3214,7 +3214,6 @@ class Benchmark {
if
(
thread
->
tid
>
0
)
{
ReadRandom
(
thread
);
}
else
{
BGWriter
(
thread
,
kPut
);
BGWriter
(
thread
,
kWrite
);
}
}
...
...
db/version_set.cc
浏览文件 @
aca403d2
...
...
@@ -757,7 +757,7 @@ uint64_t VersionStorageInfo::GetEstimatedActiveKeys() const {
// casting to avoid overflowing
return
static_cast
<
uint64_t
>
(
(
est
*
static_cast
<
double
>
(
file_count
)
/
current_num_samples_
)
;
(
est
*
static_cast
<
double
>
(
file_count
)
/
current_num_samples_
)
);
}
else
{
return
est
;
...
...
@@ -871,21 +871,24 @@ Version::Version(ColumnFamilyData* column_family_data, VersionSet* vset,
refs_
(
0
),
version_number_
(
version_number
)
{}
void
Version
::
Get
(
const
ReadOptions
&
read_options
,
const
LookupKey
&
k
,
std
::
string
*
value
,
Status
*
status
,
MergeContext
*
merge_context
,
bool
*
value_found
)
{
void
Version
::
Get
(
const
ReadOptions
&
read_options
,
const
LookupKey
&
k
,
std
::
string
*
value
,
Status
*
status
,
MergeContext
*
merge_context
,
bool
*
value_found
,
bool
*
key_exists
,
SequenceNumber
*
seq
)
{
Slice
ikey
=
k
.
internal_key
();
Slice
user_key
=
k
.
user_key
();
assert
(
status
->
ok
()
||
status
->
IsMergeInProgress
());
if
(
key_exists
!=
nullptr
)
{
// will falsify below if not found
*
key_exists
=
true
;
}
GetContext
get_context
(
user_comparator
(),
merge_operator_
,
info_log_
,
db_statistics_
,
status
->
ok
()
?
GetContext
::
kNotFound
:
GetContext
::
kMerge
,
user_key
,
value
,
value_found
,
merge_context
,
this
->
env_
);
value
,
value_found
,
merge_context
,
this
->
env_
,
seq
);
FilePicker
fp
(
storage_info_
.
files_
,
user_key
,
ikey
,
&
storage_info_
.
level_files_brief_
,
...
...
util/rate_limiter.h
浏览文件 @
aca403d2
...
...
@@ -60,7 +60,7 @@ class GenericRateLimiter : public RateLimiter {
private:
void
Refill
();
int64_t
CalculateRefillBytesPerPeriod
(
int64_t
rate_bytes_per_sec
)
{
return
static_cast
<
int64_t
>
(
rate_bytes_per_sec
*
refill_period_us_
/
1000000.0
)
;
return
rate_bytes_per_sec
*
refill_period_us_
/
1000000
;
}
// This mutex guard all internal states
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录