Skip to content

feat: add ability to specify log level for access logger#3157

Closed
tglman wants to merge 4 commits intoactix:masterfrom
tglman:WIP_log_set_level
Closed

feat: add ability to specify log level for access logger#3157
tglman wants to merge 4 commits intoactix:masterfrom
tglman:WIP_log_set_level

Conversation

@tglman
Copy link
Copy Markdown
Contributor

@tglman tglman commented Oct 3, 2023

Hi,

This add a new feature to the Logger middleware to set the level of the log.

Example

Logger::default().level(Level::Debug);

This would ideally go together with #3086

PR Checklist

  • Tests for the changes have been added / updated.
  • Documentation comments have been added / updated.
  • A changelog entry has been made for the appropriate packages.
  • Format code with the latest stable rustfmt.
  • (Team) Label with affected crates and semver status.

@tglman tglman force-pushed the WIP_log_set_level branch from e93e3f7 to 7c80804 Compare October 12, 2023 20:11
@tglman
Copy link
Copy Markdown
Contributor Author

tglman commented Oct 12, 2023

Hi,

This is complete also, it may conflict with the pr: #3086 because it add the same deps for test the logs, I may rebase the one of the two pr based on the one that is merged before.

Regards

@robjtede robjtede added B-semver-minor A-web project: actix-web labels Jun 10, 2024
@robjtede
Copy link
Copy Markdown
Member

robjtede commented Jun 10, 2024

Thanks for the work you've put into this.

I'm planning on migrating all the actix/* codebases over to tracing gradually, but dynamic logging levels is not something that's well supported by that ecosystem. The benefits definitely outweigh that but it means this PR is probably never going to land as-is.

We can revisit this idea after the tracing migration.

@robjtede robjtede closed this Jun 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-web project: actix-web B-semver-minor

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants