Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Co-authored-by: XiguoHu <huxiguo@baidu.com>
  • Loading branch information
Huixxi and XiguoHu authored Aug 1, 2022
1 parent fe48cd3 commit 65b5fcd
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/bvar/detail/sampler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@

// Date: Tue Jul 28 18:14:40 CST 2015

#include <gflags/gflags.h>
#include "butil/time.h"
#include "butil/memory/singleton_on_pthread_once.h"
#include "bvar/reducer.h"
Expand Down Expand Up @@ -127,7 +128,11 @@ static PassiveStatus<double>* s_cumulated_time_bvar = NULL;
static bvar::PerSecond<bvar::PassiveStatus<double> >* s_sampling_thread_usage_bvar = NULL;
#endif

DEFINE_int32(bvar_sampler_thread_start_delay_us, 10000, "bvar sampler thread start delay us");

void SamplerCollector::run() {
::usleep(FLAGS_bvar_sampler_thread_start_delay_us);

#ifndef UNIT_TEST
// NOTE:
// * Following vars can't be created on thread's stack since this thread
Expand Down

0 comments on commit 65b5fcd

Please sign in to comment.