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

[DX] Attempt to improve logging messages with parameters#13418

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

Closed
linaori wants to merge4 commits intosymfony:2.7fromlinaori:dx/context-logging
Closed

[DX] Attempt to improve logging messages with parameters#13418

linaori wants to merge4 commits intosymfony:2.7fromlinaori:dx/context-logging

Conversation

@linaori
Copy link
Contributor

QA
Bug fix?no
New feature?no
BC breaks?no
Deprecations?no
Tests pass?yes
Fixed tickets#12594 (comment)
LicenseMIT
Doc PRn/a

This PR is a follow-up of#12594[DX] [HttpKernel] Use "context" argument when logging route in RouterListener.

I have attempted to improve the log messages, as well as updating the usage context. I wasn't sure if the log messages should end with a. or not, if so I can update all messages to confirm a standard.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

What about moving the username as well (same below.) The more static the message is, the better for log aggregators.

Copy link
ContributorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

I wasn't sure as in many cases the message would become borked. I agree that it would be a better solution.

Edit, I can leave the username in the messageand add it to the context.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

"Basic authentication Authorization header found" is enough I think.

@linaori
Copy link
ContributorAuthor

@stof@fabpot I have processed the remarks. While at it, I want to add or remove the trailing.. In exceptions they are present, but not in all the logs. Should I remove them all or add them all? It might be a good idea to add it in this PR as no history will be lost of this change if someone decides to add them later.

@linaori
Copy link
ContributorAuthor

Seems like a flaky test is making this build fail:

1) Symfony\Component\Process\Tests\SimpleProcessTest::testStopWithTimeoutIsActuallyWorkingFailed asserting that 4.0517840385437 is less than 4.

@fabpot
Copy link
Member

I would add dots everywhere (which is what we do for exception messages).

@linaori
Copy link
ContributorAuthor

Dots added and tests updated.

@fabpot
Copy link
Member

👍

@fabpot
Copy link
Member

Thank you@iltar.

@linaorilinaori deleted the dx/context-logging branchApril 15, 2016 13:33
fabpot added a commit that referenced this pull requestSep 21, 2016
…n logging it. (Koc)This PR was merged into the 2.7 branch.Discussion----------[DX] Fixed regression when exception message swallowed when logging it.| Q             | A| ------------- | ---| Branch?       | 2.7| Bug fix?      | yes| New feature?  | no| BC breaks?    | no| Deprecations? | no| Tests pass?   | maybe, wait for Travis| Fixed tickets | fixed regression introduced in#13418| License       | MIT| Doc PR        | -The problem is: after merging referenced PR we cann't understand what error occured and why authentication request failed (see attached screenshot). Previously it displays exception message, but now it only displays class of the exception.![9003644109](https://cloud.githubusercontent.com/assets/191082/18717550/f0df61c4-8028-11e6-8dbb-684e4928e913.jpg)Commits-------042cb6b Fixed regression when exception message swallowed when logging it.
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

3 participants

@linaori@fabpot@stof

[8]ページ先頭

©2009-2025 Movatter.jp