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

アプリケーションアーキテクチャ概要編にログ出力方針について追記する #88

Closed
tsuna-can-se opened this issue Jul 6, 2022 · 2 comments · Fixed by #890
Assignees
Labels
target: アーキテクチャ/概要 ドキュメントのアプリケーションアーキテクチャ/概要編に関係がある
Milestone

Comments

@tsuna-can-se
Copy link
Contributor

tsuna-can-se commented Jul 6, 2022

#7 から独立。

実装の話ではなく、ログレベルや出力先、環境ごとの出力打ち分け方針など、概念レベルの話を書く。

@ShumpeiYamada36
Copy link
Contributor

5/8の定例の議論内容を転記
LogicExceptionのハンドリング方針について、現在ドキュメント内に2種類の記載が見られる。

  1. プレゼンテーション層でキャッチしてハンドリングする。(⇒ ハンドリングされずに集約例外ハンドラまで来たものは、ERRORログを出力して一律エラーコード500を返す。)
    https://www.maiaossedition.org/app-architecture/overview/java-application-processing-system/
  2. どの層でハンドリングしてもよい。(⇒集約例外ハンドラでハンドリングしてもよく、その際のエラーコードも任意。ログレベルも精々WARN程度でよい。)
    https://www.maiaossedition.org/app-architecture/client-side-rendering/backend-application/presentation/#exception-handling

これらの方針はドキュメント全体およびサンプルアプリの実装内で不整合がないよう統一させる必要がある。
ver 1.0のリリースに当たっては一旦1. の方式に合わせることにしたが、以下の懸念もあり、リリース後改めて方針を検討する機会を設けたい。

  • コントローラーですべての業務例外のハンドリングを実装するのは負荷が大きく、煩雑ではないか。
  • ハンドリング漏れで発生した業務例外は、本当にシステム例外相当(≒ERRORログが出力され、本番障害として現場が即時対応を求められるほど)の緊急度・危険性を持つものなのか。

@tsuna-can-se
Copy link
Contributor Author

Java アプリケーションの処理方式
ここのファイル分割をMaris同様に変えていく作業もあわせてお願いします。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
target: アーキテクチャ/概要 ドキュメントのアプリケーションアーキテクチャ/概要編に関係がある
Projects
None yet
3 participants