jihuayu commented on code in PR #2190:
URL: https://github.com/apache/kvrocks/pull/2190#discussion_r1545868977
##########
src/types/redis_stream.h:
##########
@@ -66,6 +66,8 @@ class Stream : public SubKeyScanner {
rocksdb::Status GetLastGeneratedID(const Slice &stream_name, StreamEntryID
*id);
rocksdb::Status SetId(const Slice &stream_name, const StreamEntryID
&last_generated_id,
std::optional<uint64_t> entries_added,
std::optional<StreamEntryID> max_deleted_id);
+ rocksdb::Status GetPendingEntries(StreamPendingOptions &options,
StreamGetPendingEntryResult &pending_infos,
+
std::vector<StreamGetExtPendingEntryResult> &ext_results);
Review Comment:
`options` here can be const.
The signature of this function is different from what we are accustomed to.
1. We are accustomed to using pointers instead of references to represent
return values.
2. In general, we usually have only one return value.
3. We usually place the key name(here is stream_name), group_name,
consumer_name outside instead of inside the options.
--
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]