...
Per transaction stats collection can be enabled with the capturePerTransactionStats
configuration property for an application, and configuring a dedicated binary transaction log using the perTransactionStatsLogging
configuration element. Per transaction stats collection collects timestamps that are capture captured when recording message latency stats, ODS store latency stats and transaction latency stats, so those must be enabled as well to be included in per transaction stats. The DDL configuration block below shows a typical set of configuration for collecting all per transaction stats:
Code Block | ||||
---|---|---|---|---|
| ||||
<env>
<nv>
<!-- globally enable message stats latency -->
<msg.latency.stats>true</msg.latency.stats>
<!-- Optionally, bump up the sample size for collected latency stats -->
<stats.latencymanager.samplesize>65536</stats.latencymanager.samplesize>
<!-- globally enable ODS store stats collection -->
<ods.latency.stats>true</ods.latency.stats>
<!-- Enable low level I/O timestamps-->
<link.network.stampiots>true</link.network.stampiots>
</nv>
<env>
<apps>
<app name="processor" mainClass="com.neeve.talon.starter.Application">
<!-- Enable transaction latency stats collection -->
<captureTransactionLatencyStats>true</captureTransactionLatencyStats>
<!-- Capture transaction stats on a per transaction basis -->
<capturePerTransactionStats>true</capturePerTransactionStats>
<!-- Configure Per Transaction Stats Logger -->
<perTransactionStatsLogging policy="UseDedicated">
<flushOnCommit>true</flushOnCommit>\
<detachedWrite enabled="true">
<queueOfferStrategy>SingleThreaded</queueOfferStrategy>
<queueWaitStrategy>Blocking</queueWaitStrategy>
<queueDrainerCpuAffinityMask>0</queueDrainerCpuAffinityMask>
</detachedWrite>
</perTransactionStatsLogging>
</app>
</apps> |
...
Entry | transactionId | simpleClassName | transactionInSequenceNumber | TransactionOutSequenceNumbertransactionOutSequenceNumber |
---|---|---|---|---|
1 | 1 | NewOrderMessage | 1 | 0 |
2 | 1 | NewOrderMessage | 2 | 0 |
3 | 2 | NewOrderMessage | 1 | 0 |
4 | 2 | NewOrderMessage | 2 | 0 |
...
Entry | transactionId | simpleClassName | transactionInSequenceNumber | TransactionOutSequenceNumbertransactionOutSequenceNumber |
---|---|---|---|---|
1 | 1 | NewOrderEventMessage | 1 | 1 |
2 | 1 | NewOrderAckMessage | 1 | 2 |
3 | 1 | NewOrderEventMessage | 2 | 3 |
4 | 1 | NewOrderAckMessage | 2 | 4 |
5 | 2 | NewOrderEventMessage | 1 | 1 |
6 | 2 | NewOrderAckMessage | 1 | 2 |
7 | 2 | NewOrderEventMessage | 2 | 3 |
8 | 2 | NewOrderAckMessage | 2 | 4 |
...
TxnStats logs can be viewed like any other transaction log using the Transaction Log Tool. However because Transaction Log Tool doesn't support the ability to perf perform joins across logs, Talon includes a TransactionStatsLogTool which can be used to join the results of a transaction log query with the stats recorded in txnstats log and output the joined results in a comma separated values file.
...