updates
This commit is contained in:
parent
19c4f3af6f
commit
b5674ff7f4
@ -1322,7 +1322,7 @@ TEST_F(CompactionJobTest, ResultSerialization) {
|
||||
}
|
||||
}
|
||||
|
||||
TEST_F(CompactionJobTest, GetRateLimiterPriority) {
|
||||
TEST_F(CompactionJobTest, GetRateLimiterPriorityForWrite) {
|
||||
NewDB();
|
||||
|
||||
auto expected_results = CreateTwoFiles(false);
|
||||
|
@ -94,7 +94,7 @@ class FlushJob {
|
||||
#endif // !ROCKSDB_LITE
|
||||
|
||||
private:
|
||||
friend class FlushJobTest_GetRateLimiterPriority_Test;
|
||||
friend class FlushJobTest_GetRateLimiterPriorityForWrite_Test;
|
||||
|
||||
void ReportStartedFlush();
|
||||
void ReportFlushInputSize(const autovector<MemTable*>& mems);
|
||||
|
@ -528,7 +528,7 @@ TEST_F(FlushJobTest, Snapshots) {
|
||||
job_context.Clean();
|
||||
}
|
||||
|
||||
TEST_F(FlushJobTest, GetRateLimiterPriorityWrite) {
|
||||
TEST_F(FlushJobTest, GetRateLimiterPriorityForWrite) {
|
||||
// Prepare a FlushJob that flush MemTables of Single Column Family.
|
||||
const size_t num_mems = 2;
|
||||
const size_t num_mems_to_flush = 1;
|
||||
@ -574,7 +574,7 @@ TEST_F(FlushJobTest, GetRateLimiterPriorityWrite) {
|
||||
Env::Priority::USER, nullptr /*IOTracer*/);
|
||||
|
||||
// When the state from WriteController is normal.
|
||||
ASSERT_EQ(flush_job.GetRateLimiterPriorityWrite(), Env::IO_HIGH);
|
||||
ASSERT_EQ(flush_job.GetRateLimiterPriorityForWrite(), Env::IO_HIGH);
|
||||
|
||||
WriteController* write_controller =
|
||||
flush_job.versions_->GetColumnFamilySet()->write_controller();
|
||||
@ -583,14 +583,14 @@ TEST_F(FlushJobTest, GetRateLimiterPriorityWrite) {
|
||||
// When the state from WriteController is Delayed.
|
||||
std::unique_ptr<WriteControllerToken> delay_token =
|
||||
write_controller->GetDelayToken(1000000);
|
||||
ASSERT_EQ(flush_job.GetRateLimiterPriorityWrite(), Env::IO_USER);
|
||||
ASSERT_EQ(flush_job.GetRateLimiterPriorityForWrite(), Env::IO_USER);
|
||||
}
|
||||
|
||||
{
|
||||
// When the state from WriteController is Stopped.
|
||||
std::unique_ptr<WriteControllerToken> stop_token =
|
||||
write_controller->GetStopToken();
|
||||
ASSERT_EQ(flush_job.GetRateLimiterPriorityWrite(), Env::IO_USER);
|
||||
ASSERT_EQ(flush_job.GetRateLimiterPriorityForWrite(), Env::IO_USER);
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user