Skip to content

[Enhancement] Implement FastCodesHeader encode/decode for PullMessageRequestHeader/ResponseHeader #10534

Description

@wang-jiahua

Before Creating the Enhancement Request

  • I have confirmed that this should be classified as an enhancement rather than a bug/feature.

Summary

Implement FastCodesHeader.encode()/decode() for PullMessageRequestHeader and PullMessageResponseHeader to eliminate reflection-based header serialization.

Motivation

PullMessageRequestHeader and PullMessageResponseHeader already implement FastCodesHeader but their decode() methods use Map<String, String> instead of HashMap<String, String>, causing compilation issues with the interface. Additionally, their encode() methods can leverage R1's writeLong/writeInt helpers for numeric fields.

Describe the Solution You'd Like

Fix decode() signatures and optimize encode() methods on:

  • PullMessageRequestHeader — 15 fields including Long/Integer types
  • PullMessageResponseHeader — 4 fields

Additional Context

Depends on R1 (#10522, merged). Related PRs: #10443, #10526.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions