Skip to content

Commit 0209031

Browse files
authored
Bug 2064758 - Only log remote settings downloads on error (#7592)
We got reports that there were generating lots of log lines on iOS (breadcrumbs are also logged as warnings to the console). I changed the code to only report the breadcrumbs for error downloads, which should allow us to track down bad URLs without overloading the log files. Another option was to only report the breadcrumb, but not log. I didn't like this one, since I think the same issue could spam the breadcrumb list and make them less useful.
1 parent 308018f commit 0209031

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

components/remote_settings/src/client.rs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -647,7 +647,11 @@ impl ViaductApiClient {
647647
}
648648

649649
fn make_request(&mut self, url: Url) -> Result<Response> {
650-
breadcrumb!("make_request: {url}");
650+
self._make_request(url.clone())
651+
.inspect_err(|e| breadcrumb!("Request error: {e} ({url})"))
652+
}
653+
654+
fn _make_request(&mut self, url: Url) -> Result<Response> {
651655
self.remote_state.ensure_no_backoff()?;
652656

653657
let req = Request::get(url);

0 commit comments

Comments
 (0)