Package nablarch.core.log.app
Class PerformanceJsonLogFormatter
java.lang.Object
nablarch.core.log.app.PerformanceLogFormatter
nablarch.core.log.app.PerformanceJsonLogFormatter
@Published(tag="architect")
public class PerformanceJsonLogFormatter
extends PerformanceLogFormatter
パフォーマンスログのメッセージをJSON形式でフォーマットするクラス。
PerformanceLogFormatterでは、フォーマットとして出力内容を設定するが、
本クラスでは、 notificationTargets および、analysisTargets プロパティにて、
出力項目を指定する。指定可能な出力項目は下記の通り。
- point: ポイント
- result: 処理結果
- startTime: 開始日時
- endTime: 終了日時
- executionTime: 実行時間
- maxMemory: 最大メモリ量
- startFreeMemory: 開始時の空きメモリ量
- endFreeMemory: 終了時の空きメモリ量
- startUsedMemory: 開始時の使用メモリ量
- endUsedMemory: 終了時の使用メモリ量
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic class終了時の空きメモリ量を処理するクラス。static class終了日時を処理するクラス。static class終了時の使用メモリ量を処理するクラス。static class実行時間を処理するクラス。static class最大メモリ量を処理するクラス。static classポイントを処理するクラス。static class処理結果を処理するクラス。static class開始時の空きメモリ量を処理するクラス。static class開始日時を処理するクラス。static class開始時の使用メモリ量を処理するクラス。Nested classes/interfaces inherited from class nablarch.core.log.app.PerformanceLogFormatter
PerformanceLogFormatter.EndFreeMemoryItem, PerformanceLogFormatter.EndTimeItem, PerformanceLogFormatter.EndUsedMemoryItem, PerformanceLogFormatter.ExecutionTimeItem, PerformanceLogFormatter.MaxMemoryItem, PerformanceLogFormatter.PerformanceLogContext, PerformanceLogFormatter.PointItem, PerformanceLogFormatter.ResultItem, PerformanceLogFormatter.StartFreeMemoryItem, PerformanceLogFormatter.StartTimeItem, PerformanceLogFormatter.StartUsedMemoryItem -
Field Summary
Fields inherited from class nablarch.core.log.app.PerformanceLogFormatter
PROPS_PREFIX -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected JsonSerializationManager変換処理に使用するJsonSerializationManagerを生成する。protected Stringパフォーマンスログのメッセージをフォーマットする。getStructuredTargets(Map<String, String> props) ログ出力項目を取得する。protected void初期化protected final void各種ログのJSONフォーマット支援オブジェクトの初期化protected final voidinitializeTargets(Map<String, String> props) 出力項目の初期化Methods inherited from class nablarch.core.log.app.PerformanceLogFormatter
end, getLogItems, initializeFormat, initializeTargetPoints, isTargetPoint, setContainsMemoryItem, start
-
Constructor Details
-
PerformanceJsonLogFormatter
public PerformanceJsonLogFormatter()
-
-
Method Details
-
initialize
protected void initialize()初期化- Overrides:
initializein classPerformanceLogFormatter
-
initializeFormatterSupport
protected final void initializeFormatterSupport(Map<String, String> props, String prefix, String filePath) 各種ログのJSONフォーマット支援オブジェクトの初期化- Parameters:
props- 各種ログ出力の設定情報
-
createSerializationManager
変換処理に使用するJsonSerializationManagerを生成する。- Parameters:
settings- 各種ログ出力の設定情報- Returns:
JsonSerializationManager
-
initializeTargets
出力項目の初期化- Parameters:
props- 各種ログ出力の設定情報
-
getStructuredTargets
protected List<JsonLogObjectBuilder<PerformanceLogFormatter.PerformanceLogContext>> getStructuredTargets(Map<String, String> props) ログ出力項目を取得する。- Parameters:
props- 各種ログ出力の設定情報- Returns:
- ログ出力項目
-
formatMessage
パフォーマンスログのメッセージをフォーマットする。- Overrides:
formatMessagein classPerformanceLogFormatter- Parameters:
context- パフォーマンスログのコンテキスト情報- Returns:
- フォーマット済みのメッセージ
-