Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/phpredis/phpredis.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander Schranz <alexander@sulu.io>2019-06-06 18:59:06 +0300
committerMichael Grunder <michael.grunder@gmail.com>2019-06-06 20:09:42 +0300
commitfa02ddd51d45c2ba6a2bb2d330f54950ddefe2b6 (patch)
tree89535e8da7d07d08975d2089645efa158f2586b5 /README.markdown
parent0c17bd27a03f499f96fad90fb2fec069c3408156 (diff)
Add maxlen and approximate parameter to example of xAdd
Diffstat (limited to 'README.markdown')
-rw-r--r--README.markdown4
1 files changed, 3 insertions, 1 deletions
diff --git a/README.markdown b/README.markdown
index b1693b36..40e52ddc 100644
--- a/README.markdown
+++ b/README.markdown
@@ -3347,7 +3347,7 @@ $obj_redis->xAck('stream', 'group1', ['1530063064286-0', '1530063064286-1']);
##### *Prototype*
~~~php
-$obj_redis->xAdd($str_key, $str_id, $arr_message);
+$obj_redis->xAdd($str_key, $str_id, $arr_message[, $i_maxlen, $boo_approximate]);
~~~
_**Description**_: Add a message to a stream
@@ -3358,6 +3358,8 @@ _**Description**_: Add a message to a stream
##### *Example*
~~~php
$obj_redis->xAdd('mystream', "*", ['field' => 'value']);
+$obj_redis->xAdd('mystream', "*", ['field' => 'value'], 1000); // set max length of stream to 1000
+$obj_redis->xAdd('mystream', "*", ['field' => 'value'], 1000, true); // set max length of stream to ~1000
~~~
### xClaim