Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add ConsensusMessageChunkInfo data to the topics REST API response #2178

Closed
gregscullard opened this issue Jun 25, 2021 · 0 comments · Fixed by #3105
Closed

Add ConsensusMessageChunkInfo data to the topics REST API response #2178

gregscullard opened this issue Jun 25, 2021 · 0 comments · Fixed by #3105
Assignees
Labels
enhancement Type: New feature P1 rest Area: REST API
Milestone

Comments

@gregscullard
Copy link
Contributor

Problem
Large HCS messages may be sent in several chunks to Hedera, the protobuf message may optionally include information such as the total number of chunks and the current chunk number in a HCS Message.

This information is not relayed by the REST api when present, making it impossible to reliably reassemble large messages by clients.

reference: https://github.com/hashgraph/hedera-protobufs/blob/main/services/ConsensusSubmitMessage.proto

Solution
If present in the transaction's protobuf, include the ConsensusMessageChunkInfo data along with the message and its attributes.

Alternatives
A client may include a size indicator at the start of every large message they send, look for this information on messages returned by the REST api and reconstitute messages that way, however this is re-inventing the wheel and could go wrong if several large consensus messages are sent at the same time by different clients to the same topic.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Type: New feature P1 rest Area: REST API
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants