feat(taosc): optimize encoder/decoder logic for SClientHbReq#34880
feat(taosc): optimize encoder/decoder logic for SClientHbReq#34880guanshengliang merged 6 commits into3.0from
Conversation
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
There was a problem hiding this comment.
Pull request overview
This PR aims to optimize the SClientHbReq/SClientHbBatchReq encoding/decoding path (primarily by relying on tStartEncode/tEndEncode framing instead of extra length-calculation logic) and adds unit tests to cover codec + compatibility scenarios.
Changes:
- Refactor
SClientHbReqcodec to usetStartEncode/tStartDecodeframing and adjust fields being encoded/decoded. - Simplify
SClientHbBatchReqcodec loop by removing per-item pre-length computation / sub-decoder logic. - Add new GTest coverage for
SClientHbBatchReqencode/decode and compatibility scenarios.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 7 comments.
| File | Description |
|---|---|
| source/common/src/msg/tmsg.c | Refactors SClientHbReq/SClientHbBatchReq encoding/decoding logic and field layout. |
| source/common/test/tmsgTest.cpp | Pulls new batch HB tests into the existing tmsgTest binary. |
| source/common/test/SClientHbBatchReq.cpp | Adds new unit tests + “old/new” codec helpers for heartbeat batch compatibility. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 3 out of 3 changed files in this pull request and generated 4 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Description
Issue(s)
Checklist
Please check the items in the checklist if applicable.