feat: export SetBackgroundThreads(n, Env::BOTTOM); (#7191)
Summary: - https://github.com/rust-rocksdb/rust-rocksdb/pull/448 Pull Request resolved: https://github.com/facebook/rocksdb/pull/7191 Reviewed By: riversand963 Differential Revision: D22809066 Pulled By: ajkr fbshipit-source-id: 036939f9a28cacc3f677c318d1aed97fe5f4f85e
This commit is contained in:
parent
a38f04ac26
commit
50f206ad84
10
db/c.cc
10
db/c.cc
@ -3831,10 +3831,20 @@ void rocksdb_env_set_background_threads(rocksdb_env_t* env, int n) {
|
||||
env->rep->SetBackgroundThreads(n);
|
||||
}
|
||||
|
||||
void rocksdb_env_set_bottom_priority_background_threads(rocksdb_env_t* env,
|
||||
int n) {
|
||||
env->rep->SetBackgroundThreads(n, Env::BOTTOM);
|
||||
}
|
||||
|
||||
void rocksdb_env_set_high_priority_background_threads(rocksdb_env_t* env, int n) {
|
||||
env->rep->SetBackgroundThreads(n, Env::HIGH);
|
||||
}
|
||||
|
||||
void rocksdb_env_set_low_priority_background_threads(rocksdb_env_t* env,
|
||||
int n) {
|
||||
env->rep->SetBackgroundThreads(n, Env::LOW);
|
||||
}
|
||||
|
||||
void rocksdb_env_join_all_threads(rocksdb_env_t* env) {
|
||||
env->rep->WaitForJoin();
|
||||
}
|
||||
|
@ -1555,6 +1555,10 @@ extern ROCKSDB_LIBRARY_API void rocksdb_env_set_background_threads(
|
||||
rocksdb_env_t* env, int n);
|
||||
extern ROCKSDB_LIBRARY_API void
|
||||
rocksdb_env_set_high_priority_background_threads(rocksdb_env_t* env, int n);
|
||||
extern ROCKSDB_LIBRARY_API void rocksdb_env_set_low_priority_background_threads(
|
||||
rocksdb_env_t* env, int n);
|
||||
extern ROCKSDB_LIBRARY_API void
|
||||
rocksdb_env_set_bottom_priority_background_threads(rocksdb_env_t* env, int n);
|
||||
extern ROCKSDB_LIBRARY_API void rocksdb_env_join_all_threads(
|
||||
rocksdb_env_t* env);
|
||||
extern ROCKSDB_LIBRARY_API void rocksdb_env_lower_thread_pool_io_priority(rocksdb_env_t* env);
|
||||
|
Loading…
Reference in New Issue
Block a user