mirror of
https://github.com/fluencelabs/redis
synced 2025-06-16 02:31:20 +00:00
Merge pull request #6547 from guybe7/module_api_streams
Support streams in general module API functions
This commit is contained in:
@ -67,6 +67,12 @@ void freeStream(stream *s) {
|
||||
zfree(s);
|
||||
}
|
||||
|
||||
/* Return the length of a stream. */
|
||||
unsigned long streamLength(const robj *subject) {
|
||||
stream *s = subject->ptr;
|
||||
return s->length;
|
||||
}
|
||||
|
||||
/* Generate the next stream item ID given the previous one. If the current
|
||||
* milliseconds Unix time is greater than the previous one, just use this
|
||||
* as time part and start with sequence part of zero. Otherwise we use the
|
||||
|
Reference in New Issue
Block a user