xichen01 opened a new pull request, #5660:
URL: https://github.com/apache/ozone/pull/5660
## What changes were proposed in this pull request?
Add a performance audit log for slow requests on the Datanode, which will be
output if the request processing time exceeds the threshold(500ms by default).
Example:
```shell
2023-1-1 17:01:59,134 | INFO | DNAudit |
[bTxId:e82fc88abef1427faec04e7473a33f8e, bSpanId:efa32ade0866e39d] user=null |
ip=null | op=GET_BLOCK {blockData=conID: 674595 locID: 109611023645035393
bcsId: 1506141102} performance={opLatencyMs=1724, preOpLatencyMS=0} | ret=null |
2023-1-1 17:01:59,134 | INFO | DNAudit | [bTxId:, bSpanId:] user=null |
ip=null | op=GET_BLOCK {blockData=conID: 674595 locID: 109611023645332310
bcsId: 1506237580} performance={opLatencyMs=1953, preOpLatencyMS=0} | ret=null |
2023-1-1 17:02:56,288 | INFO | DNAudit |
[bTxId:099d6fc1228e468aac59ed0cce13ce66, bSpanId:efa3ea780866e83b] user=null |
ip=null | op=GET_BLOCK {blockData=conID: 674595 locID: 109611023645245975
bcsId: 1506209514} performance={opLatencyMs=882, preOpLatencyMS=0} | ret=null |
2023-1-1 17:12:15,903 | INFO | DNAudit | [bTxId:, bSpanId:] user=null |
ip=null | op=READ_CHUNK {blockData=conID: 661896 locID: 109611023348686704
bcsId: 1400692708, blockDataSize=749} performance={opLatencyMs=502,
preOpLatencyMS=0} | ret=null |
```
## What is the link to the Apache JIRA
https://issues.apache.org/jira/browse/HDDS-9719
## How was this patch tested?
Manual test
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]