string marker;
list<rgw_bi_log_entry> *result;
+ std::optional<PerfGuard> timer;
public:
RGWListBucketIndexLogCR(RGWDataSyncEnv *_sync_env, const rgw_bucket_shard& bs,
int operate() override {
reenter(this) {
+ if (sync_env->counters) {
+ timer.emplace(sync_env->counters, sync_counters::l_poll);
+ }
yield {
rgw_http_param_pair pairs[] = { { "bucket-instance", instance_key.c_str() },
{ "format" , "json" },
call(new RGWReadRESTResourceCR<list<rgw_bi_log_entry> >(sync_env->cct, sync_env->conn, sync_env->http_manager, "/admin/log", pairs, result));
}
+ timer.reset();
if (retcode < 0) {
+ if (sync_env->counters) {
+ sync_env->counters->inc(sync_counters::l_poll_err);
+ }
return set_cr_error(retcode);
}
return set_cr_done();