Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

4xx系のエラーログの出力レベルを見直し検討してもらいたい #4361

Closed
yoshiaki-natsume opened this issue Oct 16, 2019 · 3 comments
Labels
improvement 機能改善
Milestone

Comments

@yoshiaki-natsume
Copy link
Contributor

概要(Overview)

現状4xx系含めてエラーを全てログレベルERRORとして出力していると認識しています(該当コード)
本番環境の監視などを想定した場合、ログレベルのERRORというのは500エラーのように何かしら対応を求められるものという認識なので、404などのユーザー起因のエラーはログレベルを下げたほうが良いのではないでしょうか?

期待する内容(Expect) or 要望 (Requirement)

4xx系のエラーログのレベルをWARNING等に下げる

再現手順(Procedure)

なし

環境 (environment)

  • EC-CUBE: 4.0.0
  • PHP: 7.2.x
  • DB:
    • MySQL 5.7.x

関連情報 (Ref)

@chihiro-adachi chihiro-adachi added the improvement 機能改善 label Oct 18, 2019
@chihiro-adachi chihiro-adachi added this to the 4.0.x milestone Oct 18, 2019
@chihiro-adachi
Copy link
Contributor

@yoshiaki-natsume
ありがとうございます。
確かに400番台でERRORになるのはおかしいですね。
WARNINGか、404等は対応する必要もないですし、INFOレベルでもよいのかな、という気がします。

出力レベルの考え方は以下の指針に沿って作っていたかと。
https://qiita.com/nanasess/items/350e59b29cceb2f122b3

@yoshiaki-natsume
Copy link
Contributor Author

そうですね、自分もINFOレベルで良いと思います。

@genzouw
Copy link
Contributor

genzouw commented Mar 4, 2020

プルリクエストを取り込みました。

@genzouw genzouw closed this as completed Mar 4, 2020
@chihiro-adachi chihiro-adachi modified the milestones: 4.0.x, 4.0.4 May 19, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
improvement 機能改善
Projects
None yet
Development

No branches or pull requests

3 participants