Commit a280e3a4 authored by Pranav Batra's avatar Pranav Batra Committed by Chromium LUCI CQ

cups_proxy/proxy_manager.cc: Always log rate limit exceeded warnings

If packets are rate limited by CUPS proxy, the print request will
probably fail. We want this information to always be logged so that we
can determine whether or not rate limiting is the cause of the print
failure by looking through the log.

Bug: 1157699
Change-Id: If1cb5689ca8f645a63ea93a0b4e368d83319e88e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2586756Reviewed-by: default avatarSean Kau <skau@chromium.org>
Commit-Queue: Sean Kau <skau@chromium.org>
Cr-Commit-Position: refs/heads/master@{#836211}
parent 6ccf20f5
......@@ -158,8 +158,8 @@ void ProxyManagerImpl::ProxyRequest(
time - timestamp_.ReadBuffer(0) < base::TimeDelta::FromSeconds(1);
timestamp_.SaveToBuffer(time);
if (block_request) {
DVLOG(1) << "CupsPrintService Error: Rate limit (" << kRateLimit
<< ") exceeded";
LOG(WARNING) << "CupsPrintService: Rate limit (" << kRateLimit
<< ") exceeded";
std::move(cb).Run({}, {}, 429); // HTTP_STATUS_TOO_MANY_REQUESTS
return;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment