Commit Graph

8083 Commits

Author SHA1 Message Date
antirez
3b420034bb RESP3: allow HELLO to be used with version = 2. 2019-02-25 16:41:00 +01:00
antirez
36d1588215 ACL: authCommand() refactored into ACLAuthenticateUser(). 2019-02-25 16:39:44 +01:00
antirez
87594a7470 ACL: move AUTH implementation in acl.c. 2019-02-25 16:33:38 +01:00
antirez
e247c9ac6a Gopher: don't add the Lastline. 2019-02-24 21:38:15 +01:00
antirez
07473feaeb ACL: fix ACLSaveToFile() return value. 2019-02-22 12:45:13 +01:00
antirez
2bea3929d0 ACL: less error prone error handling in ACLSaveToFile(). 2019-02-22 12:43:08 +01:00
antirez
8b087dff34 Gopher: TODO list. 2019-02-22 11:17:39 +01:00
Salvatore Sanfilippo
2d3cad684c
Merge pull request #5850 from artix75/dev
Cluster Manager: fix replica assignment anti-affinity (create)
2019-02-22 10:28:31 +01:00
Salvatore Sanfilippo
21b8560e95
Merge pull request #5858 from madolson/dev-unstable-acl-deluser
Making deleting users better defined and update documentation
2019-02-22 10:27:37 +01:00
Salvatore Sanfilippo
3a7fd48e30
Merge pull request #5859 from madolson/dev-unstable-networking-cleanup
Refactored manual computation of object length
2019-02-22 10:25:17 +01:00
antirez
f94d711c83 Gopher: basic serving of string type. 2019-02-22 10:21:24 +01:00
antirez
e00b22e090 Gopher: initial request handling. 2019-02-21 23:13:08 +01:00
Madelyn Olson
9131fc56d6 Refactored manual computation of object length 2019-02-21 21:35:00 +00:00
Madelyn Olson
fdc4003d23 Making deleting users better defined and update documentation 2019-02-21 21:34:14 +00:00
antirez
3de9ccf190 Gopher: config setting to turn support on/off. 2019-02-21 17:28:53 +01:00
antirez
624568ae3f Merge branch 'unstable' of github.com:/antirez/redis into unstable 2019-02-21 17:03:19 +01:00
antirez
291e6bccf3 ACL: remove leak in ACLLoadFromFile(). 2019-02-21 17:03:06 +01:00
antirez
91aecf0138 ACL: implement ACL SAVE. 2019-02-21 17:01:08 +01:00
antirez
484af7aa7a ACL: ACLSaveToFile() implemented. 2019-02-21 16:50:28 +01:00
antirez
e4f3a2eecd ACL: add LOAD subcommand to ACL HELP. 2019-02-21 16:31:33 +01:00
Salvatore Sanfilippo
967a98f570
Merge pull request #4811 from oranagra/cli-diskless-repl
Add redis-cli support for diskless replication (CAPA EOF)
2019-02-21 12:54:15 +01:00
Salvatore Sanfilippo
a8921c062d
Merge pull request #5856 from oranagra/cli-bigkeys
redis-cli add support for --memkeys, fix --bigkeys for module types
2019-02-21 12:22:09 +01:00
Oran Agra
b6de51206e redis-cli add support for --memkeys, fix --bigkeys for module types
* bigkeys used to fail on databases with module type keys
* new code adds more types when it discovers them, but has no way to know element count in modules types yet
* bigkeys was missing XLEN command for streams
* adding --memkeys and --memkeys-samples to make use of the MEMORY USAGE command

see #5167, #5175
2019-02-21 12:18:20 +02:00
artix
0f28754021 Cluster Manager: fix replica assigment anti-affinity (create)
Fix issue #5849
2019-02-20 15:36:15 +01:00
antirez
35ffbead5c Use dictGetFairRandomKey() for RANDOMKEY as well. 2019-02-19 17:29:51 +01:00
antirez
25b392f90c Set dictGetFairRandomKey() samples to 20 for final version.
Distribution improves dramatically: tests show it clearly. Better to
have a slower implementation than a wrong one, because random member
extraction should be correct or tends to be useless for a number of
tasks.
2019-02-19 17:27:42 +01:00
antirez
f284e37f24 showfreq.rb: collect more data for better graphs. 2019-02-19 17:25:58 +01:00
antirez
f1b3a485b4 Improve README of better-random-member directory. 2019-02-19 12:01:26 +01:00
antirez
a317349cb2 Add showfreq.rb to SRANDMEMBER analysis tools. 2019-02-18 18:47:49 +01:00
antirez
1613f7a572 Limit sampling size in dictGetFairRandomKey().
This way the implementation is almost as fast as the original one, but
the distribution is not too bad.
2019-02-18 18:38:40 +01:00
antirez
61a01793ed Better distribution for set get-random-element operations. 2019-02-18 18:27:18 +01:00
antirez
e6948b8f28 showdist.rb utility for SRANDMEMBER analysis added. 2019-02-18 12:39:07 +01:00
antirez
86802d4f26 redis-benchmark: default precision=1, integer ms after 2 milliseconds.
Reltaed to discussion and PR #5840.
2019-02-14 13:19:51 +01:00
Salvatore Sanfilippo
da86481e5b
Merge pull request #5840 from madolson/dev-unstable-benchmark-latency
Updated redis benchmark with us precision support
2019-02-14 13:01:26 +01:00
Madelyn Olson
f9bababaa7 Rename variable 2019-02-13 21:03:31 +00:00
Madelyn Olson
93640b0a9d Updated redis benchmark with us precision support 2019-02-13 19:52:48 +00:00
Salvatore Sanfilippo
fd7484cde2
Merge pull request #5836 from soloestoy/fix-acl-warning
ACL: show categories in COMMAND reply
2019-02-13 18:59:59 +01:00
zhaozhao.zz
14507457a0 ACL: show categories in COMMAND reply
Adding another new filed categories at the end of
command reply, it's easy to read and distinguish
flags and categories, also compatible with old format.
2019-02-14 00:13:01 +08:00
antirez
e819c2ef5b ACL: tag LASTSAVE as dangerous.
That's not REALLY needed, but... right now with LASTSAVE being the only
command tagged as "admin" but not "dangerous" what happens is that after
rewrites the rewrite engine will produce from the rules:

    user default on +@all ~* -@dangerous nopass

The rewrite:

    user default on nopass ~* +@all -@admin -@dangerous +lastsave

Which is correct but will have users wondering about why LASTSAVE has
something special.

Since LASTSAVE after all also leaks information about the underlying
server configuration, that may not be great for SAAS vendors, let's tag
it as dangerous as well and forget about this issue :-)
2019-02-13 16:30:44 +01:00
zhaozhao.zz
a65094dae8 ACL: fix cat type format warning 2019-02-13 11:47:10 +08:00
antirez
fb7bfc17cd ACL: Document masteruser option in redis.conf. 2019-02-12 18:23:00 +01:00
antirez
bfdcfbb3ed ACL: fix setting of FAST flag. 2019-02-12 17:06:26 +01:00
antirez
b9c97c0b2e ACL: CAT subcommand implemented. 2019-02-12 17:02:45 +01:00
Guy Benoish
bdd9a8002a Trim SDS free space of retained module strings
In some cases processMultibulkBuffer uses sdsMakeRoomFor to
expand the querybuf, but later in some cases it uses that query
buffer as is for an argv element (see "Optimization"), which means
that the sds in argv may have a lot of wasted space, and then in case
modules keep that argv RedisString inside their data structure, this
space waste will remain for long (until restarted from rdb).
2019-02-12 14:21:21 +01:00
Salvatore Sanfilippo
a22815b4e9
Merge pull request #5833 from soloestoy/masteruser
ACL: add masteruser configuration for replication
2019-02-12 10:27:59 +01:00
zhaozhao.zz
ea9d3aefec ACL: add masteruser configuration for replication
In mostly production environment, normal user's behavior should be
limited.

Now in redis ACL mechanism we can do it like that:

    user default on +@all ~* -@dangerous nopass
    user admin on +@all ~* >someSeriousPassword

Then the default normal user can not execute dangerous commands like
FLUSHALL/KEYS.

But some admin commands are in dangerous category too like PSYNC,
and the configurations above will forbid replica from sync with master.

Finally I think we could add a new configuration for replication,
it is masteruser option, like this:

    masteruser admin
    masterauth someSeriousPassword

Then replica will try AUTH admin someSeriousPassword and get privilege
to execute PSYNC. If masteruser is NULL, replica would AUTH with only
masterauth like before.
2019-02-12 17:12:37 +08:00
antirez
d5e4a7f439 ACL: when client->user is NULL the client is a superuser.
Related to #5832.
2019-02-12 09:44:30 +01:00
antirez
cc6d05a1f7 Merge branch 'unstable' of github.com:/antirez/redis into unstable 2019-02-12 09:43:50 +01:00
Salvatore Sanfilippo
efeebb616f
Merge pull request #5832 from soloestoy/show-client-user
ACL: show client's user
2019-02-12 09:42:14 +01:00
zhaozhao.zz
0f42447a0e ACL: show client's user 2019-02-12 16:03:58 +08:00