chengxilo commented on code in PR #1916:
URL: https://github.com/apache/iggy/pull/1916#discussion_r2181550368


##########
foreign/go/binary_serialization/binary_response_deserializer.go:
##########
@@ -107,9 +94,9 @@ func DeserializeToStream(payload []byte, position int) 
(StreamResponse, int) {
        }, readBytes
 }

Review Comment:
   `DeserializeStream` deserializes the payload starting from a given position 
into a `StreamDetails` object, which contains more attributes than `Stream`.
   `DeserializeToStream` deserializes the payload into a `Stream` and returns 
the new position after reading.
   `DeserializeStreams` deserializes the payload into a slice of `Stream` 
objects.
   
   Essentially, `DeserializeToStream` serves as a helper for both 
`DeserializeStream` and `DeserializeStreams`. This kind of layered 
deserialization pattern is common in the serialization layer, and I modified my 
code to follow this established approach.



-- 
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]

Reply via email to