Project

Profile

Help

Issue #2315

closed

Better logging at INFO level

Added by mhrivnak over 7 years ago. Updated almost 5 years ago.

Status:
CLOSED - CURRENTRELEASE
Priority:
Normal
Assignee:
Start date:
Due date:
Estimated time:
Severity:
2. Medium
Version - Nectar:
Platform Release:
2.13.1
Target Release - Nectar:
1.5.4
OS:
Triaged:
Yes
Groomed:
No
Sprint Candidate:
Yes
Tags:
Pulp 2
Sprint:
Sprint 13
Quarter:

Description

Downloads are currently logged at the DEBUG level, but a number of users have requested that they be logged at INFO.

The streamer already logs them at INFO, and a good discussion was had about that behavior where those involved came to consensus. A similar example that comes to mind is MTAs, where each email coming and going normally gets logged at INFO.

This would be done in two modules. HTTPThreadedDownloader and LocalFileDownloader. For example, here are some links to these where DEBUG logging currently takes place:

https://github.com/pulp/nectar/blob/4fe7327c4ad1bb2f8c040b75d80306ee047de615/nectar/downloaders/threaded.py#L267
https://github.com/pulp/nectar/blob/4fe7327c4ad1bb2f8c040b75d80306ee047de615/nectar/downloaders/local.py#L161

Implementation Details

It might make more sense to log right before calling the success and failure handlers, but that might miss the download_one workflow. That detail aside, I would imagine something like:

log.info('Download succeeded: {url}')

or

log.info('Download failed: {url}')

Related issues

Related to Pulp - Issue #2836: Pulp makes a wall of logs during syncCLOSED - WONTFIXActions

Also available in: Atom PDF