Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

[HttpClient] Adjust logger messages and levels#30873

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
nicolas-grekas merged 1 commit intosymfony:masterfromlyrixx:http-client
Apr 5, 2019

Conversation

@lyrixx
Copy link
Member

QA
Branch?master
Bug fix?no
New feature?no
BC breaks?no
Deprecations?no
Tests pass?yes
Fixed tickets
LicenseMIT
Doc PR

@joelwurtz
Copy link
Contributor

joelwurtz commentedApr 5, 2019
edited
Loading

What about adding url / method / and other variables as attributes in the log message ? would be useful for some systems parsing logs so we could filters logs.

@lyrixx
Copy link
MemberAuthor

What about adding url / method / and other variables as attributes in the log message ? would be useful for some systems parsing logs as we could some of this attributes to filters logs.

I already make app that heavily use an http client with a nice log platform, and I never add such need. So you really think it common to search by verb or URL ?
(Adding things to the context come with the a price: CPU (processing) / network / Storage. This is why I'm a bit reluctant to add it

@lyrixx
Copy link
MemberAuthor

@nicolas-grekas About warning vs debug:

Warning do not spam the logs.

I suppose you are referring to the FingerCrossHandler. But the threshold iserror.
debug < info < notice < warning < error < critical < alert < emerg
Ref

More over:

WARNING (300): Exceptional occurrences that are not errors. Examples: Use of deprecated APIs, poor use of an API, undesirable things that are not necessarily wrong.

So, maybe some warning should goes to debug. But I'm not sure it's the case for all of them.
For exemple the following case if legit to me

$this->logger &&$this->logger->info(sprintf('Rejecting pushed response for "%s": authorization headers don\'t match the request',$url));

Could you re-review this PR with theses new considerations? Thanks

@nicolas-grekas
Copy link
Member

@lyrixx the HTTP/2 spec lists that clients should be defensive against servers that send too many pushes or other frames. That means this is not rare, when it's spamming.

@lyrixx
Copy link
MemberAuthor

@nicolas-grekas Ok. I changed all warning to debug, and updated all"%s" "%s" to"%s %s"

@nicolas-grekas
Copy link
Member

Thank you@lyrixx.

@nicolas-grekasnicolas-grekas merged commit098a7ac intosymfony:masterApr 5, 2019
nicolas-grekas added a commit that referenced this pull requestApr 5, 2019
This PR was squashed before being merged into the 4.3-dev branch (closes#30873).Discussion----------[HttpClient] Adjust logger messages and levels| Q             | A| ------------- | ---| Branch?       | master| Bug fix?      | no| New feature?  | no| BC breaks?    | no| Deprecations? | no| Tests pass?   | yes| Fixed tickets || License       | MIT| Doc PR        |Commits-------098a7ac [HttpClient] Adjust logger messages and levels
@lyrixxlyrixx deleted the http-client branchApril 5, 2019 14:22
@nicolas-grekasnicolas-grekas modified the milestones:next,4.3Apr 30, 2019
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@nicolas-grekasnicolas-grekasnicolas-grekas approved these changes

Assignees

No one assigned

Projects

None yet

Milestone

4.3

Development

Successfully merging this pull request may close these issues.

5 participants

@lyrixx@joelwurtz@nicolas-grekas@javiereguiluz@carsonbot

[8]ページ先頭

©2009-2025 Movatter.jp