summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Stale replica should allow MULTI/EXECGuy Benoish2020-04-021-3/+3
| | | | | | | | | | | | | | | | | | | Example: Client uses a pipe to send the following to a stale replica: MULTI .. do something ... DISCARD The replica will reply the MUTLI with -MASTERDOWN and execute the rest of the commands... A client using a pipe might not be aware that MULTI failed until it's too late. I can't think of a reason why MULTI/EXEC/DISCARD should not be executed on stale replicas... Also, enable MULTI/EXEC/DISCARD during loading
* Merge pull request #6960 from devnexen/debug_arm_linuxSalvatore Sanfilippo2020-04-021-27/+55
|\ | | | | debug, dump registers on arm too.
| * debug, dump registers on arm too.David Carlier2020-03-071-27/+55
| |
* | Merge pull request #7006 from hwware/fixspellingSalvatore Sanfilippo2020-04-021-1/+1
|\ \ | | | | | | fix spelling in cluster.c clusterDelNode
| * | fix spelling in cluster.chwware2020-03-181-1/+1
| | |
* | | Merge pull request #7029 from valentinogeron/fix-xackSalvatore Sanfilippo2020-04-022-1/+23
|\ \ \ | | | | | | | | XACK should be executed in a "all or nothing" fashion.
| * | | XACK should be executed in a "all or nothing" fashion.Valentino Geron2020-03-262-1/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | First, we must parse the IDs, so that we abort ASAP. The return value of this command cannot be an error if the client successfully acknowledged some messages, so it should be executed in a "all or nothing" fashion.
* | | | Merge pull request #7041 from hwware/trackingfixSalvatore Sanfilippo2020-04-021-0/+19
|\ \ \ \ | | | | | | | | | | CLIENT TRACKING Command Fix: Add More Checking for OPTIN/OPTOUT mode
| * | | | add check for not switching between optin optout mode directlyhwware2020-03-291-1/+12
| | | | |
| * | | | add check for not providing both optin optout flaghwware2020-03-291-0/+8
| | | | |
* | | | | Merge pull request #7039 from guybe7/persist_ksnSalvatore Sanfilippo2020-04-021-0/+1
|\ \ \ \ \ | | | | | | | | | | | | PERSIST should notify a keyspace event
| * | | | | PERSIST should notify a keyspace eventGuy Benoish2020-03-291-0/+1
| | | | | |
* | | | | | Merge pull request #7042 from guybe7/stream_cg_last_id_fixSalvatore Sanfilippo2020-04-021-1/+2
|\ \ \ \ \ \ | | | | | | | | | | | | | | streamReplyWithRange: Redundant XSETIDs to replica
| * | | | | | streamReplyWithRange: Redundant XSETIDs to replicaGuy Benoish2020-03-301-1/+2
| |/ / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | propagate_last_id is declared outside of the loop but used only from within the loop. Once it's '1' it will never go back to '0' and will replicate XSETID even for IDs that don't actually change the last_id. While not a serious bug (XSETID always used group->last_id so there's no risk), it does causes redundant traffic between master and its replicas
* | | | | | Simplify comment in moduleTryServeClientBlockedOnKey().antirez2020-04-021-12/+3
| | | | | |
* | | | | | Merge branch 'unstable' of github.com:/antirez/redis into unstableantirez2020-04-023-46/+149
|\ \ \ \ \ \
| * \ \ \ \ \ Merge pull request #6798 from guybe7/module_circular_blockSalvatore Sanfilippo2020-04-024-47/+150
| |\ \ \ \ \ \ | | | | | | | | | | | | | | | | Fix memory corruption in moduleHandleBlockedClients
| | * | | | | | Fix memory corruption in moduleHandleBlockedClientsGuy Benoish2020-04-014-47/+150
| |/ / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | By using a "circular BRPOPLPUSH"-like scenario it was possible the get the same client on db->blocking_keys twice (See comment in moduleTryServeClientBlockedOnKey) The fix was actually already implememnted in moduleTryServeClientBlockedOnKey but it had a bug: the funxction should return 0 or 1 (not OK or ERR) Other changes: 1. Added two commands to blockonkeys.c test module (To reproduce the case described above) 2. Simplify blockonkeys.c in order to make testing easier 3. cast raxSize() to avoid warning with format spec
* | | | | | | cast raxSize() to avoid warning with format spec.antirez2020-03-311-1/+1
|/ / / / / /
* | | | | | Minor changes to #7037.antirez2020-03-312-5/+14
| | | | | |
* | | | | | Merge pull request #7037 from guybe7/fix_module_replicate_multiSalvatore Sanfilippo2020-03-316-9/+49
|\ \ \ \ \ \ | | | | | | | | | | | | | | Modules: Test MULTI/EXEC replication of RM_Replicate
| * | | | | | Modules: Test MULTI/EXEC replication of RM_ReplicateGuy Benoish2020-03-316-9/+49
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Makse sure call() doesn't wrap replicated commands with a redundant MULTI/EXEC Other, unrelated changes: 1. Formatting compiler warning in INFO CLIENTS 2. Use CLIENT_ID_AOF instead of UINT64_MAX
* | | | | | | Merge pull request #7048 from guybe7/rename_unblock_streamSalvatore Sanfilippo2020-03-313-1/+25
|\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | RENAME can unblock XREADGROUP
| * | | | | | | RENAME can unblock XREADGROUPGuy Benoish2020-03-313-1/+25
| |/ / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | Other changes: Support stream in serverLogObjectDebugInfo
* | | | | | | Merge branch 'pubsub_patterns_boost' of https://github.com/leeyiw/redis into ↵antirez2020-03-313-11/+43
|\ \ \ \ \ \ \ | |/ / / / / / |/| | | | | | | | | | | | | leeyiw-pubsub_patterns_boost
| * | | | | | Boost up performance for redis PUB-SUB patterns matching伯成2018-03-013-12/+48
| | | | | | | | | | | | | | | | | | | | | | | | | | | | If lots of clients PSUBSCRIBE to same patterns, multiple pattens matching will take place. This commit change it into just one single pattern matching by using a `dict *` to store the unique pattern and which clients subscribe to it.
* | | | | | | Fix the propagate Tcl test after module changes.fix-double-multiantirez2020-03-311-1/+1
| | | | | | |
* | | | | | | Modify the propagate unit test to show more cases.antirez2020-03-311-2/+30
| | | | | | |
* | | | | | | Fix module commands propagation double MULTI bug.antirez2020-03-314-8/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 37a10cef introduced automatic wrapping of MULTI/EXEC for the alsoPropagate API. However this collides with the built-in mechanism already present in module.c. To avoid complex changes near Redis 6 GA this commit introduces the ability to exclude call() MUTLI/EXEC wrapping for also propagate in order to continue to use the old code paths in module.c.
* | | | | | | Fix RM_Call() stale comment due to cut&paste.antirez2020-03-311-3/+1
| | | | | | |
* | | | | | | Merge branch 'unstable' of github.com:/antirez/redis into unstableantirez2020-03-302-6/+11
|\ \ \ \ \ \ \ | | |_|/ / / / | |/| | | | |
| * | | | | | Merge pull request #7033 from OMG-By/unstableSalvatore Sanfilippo2020-03-291-1/+1
| |\ \ \ \ \ \ | | | | | | | | | | | | | | | | fix: dict.c->dictResize()->minimal type
| | * | | | | | fix: dict.c->dictResize()->minimal typeOMG-By2020-03-291-1/+1
| | | | | | | |
| * | | | | | | Merge pull request #7032 from soloestoy/psync2-meaningful-offset-bugfixSalvatore Sanfilippo2020-03-281-5/+10
| |\ \ \ \ \ \ \ | | |_|_|/ / / / | |/| | | | | | PSYNC2: reset backlog_idx and master_repl_offset correctly
| | * | | | | | PSYNC2: reset backlog_idx and master_repl_offset correctlyzhaozhao.zz2020-03-281-5/+10
| |/ / / / / /
* | | | | | | Precise timeouts: reference client pointer directly.precise-timeout-2antirez2020-03-301-16/+13
| | | | | | |
* | | | | | | timeout.c created: move client timeouts code there.antirez2020-03-275-167/+198
| | | | | | |
* | | | | | | Precise timeouts: cleaup the table on unblock.antirez2020-03-273-2/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Now that this mechanism is the sole one used for blocked clients timeouts, it is more wise to cleanup the table when the client unblocks for any reason. We use a flag: CLIENT_IN_TO_TABLE, in order to avoid a radix tree lookup when the client was already removed from the table because we processed it by scanning the radix tree.
* | | | | | | Precise timeouts: fix comments after functional change.antirez2020-03-272-6/+6
| | | | | | |
* | | | | | | Precise timeouts: use only radix tree for timeouts.antirez2020-03-273-38/+15
| | | | | | |
* | | | | | | Precise timeouts: fast exit for clientsHandleShortTimeout().antirez2020-03-271-0/+1
| | | | | | |
* | | | | | | Precise timeouts: fix bugs in initial implementation.antirez2020-03-272-1/+5
| | | | | | |
* | | | | | | Precise timeouts: working initial implementation.antirez2020-03-273-28/+110
| | | | | | |
* | | | | | | Precise timeouts: refactor unblocking on timeout.antirez2020-03-272-13/+33
|/ / / / / /
* | | | | | PSYNC2: fix backlog_idx when adjusting for meaningful offsetantirez2020-03-271-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | See #7002.
* | | | | | Merge pull request #6644 from oranagra/stream_aofrwSalvatore Sanfilippo2020-03-262-1/+15
|\ \ \ \ \ \ | |_|_|/ / / |/| | | | | AOFRW on an empty stream created with MKSTREAM loads badkly
| * | | | | AOFRW on an empty stream created with MKSTREAM loads badklyOran Agra2020-03-252-1/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | the AOF will be loaded successfully, but the stream will be missing, i.e inconsistencies with the original db. this was because XADD with id of 0-0 would error. add a test to reproduce.
* | | | | | PSYNC2: meaningful offset test.meaningful-offsetantirez2020-03-252-0/+62
| | | | | |
* | | | | | PSYNC2: meaningful offset implemented.antirez2020-03-253-1/+40
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A very commonly signaled operational problem with Redis master-replicas sets is that, once the master becomes unavailable for some reason, especially because of network problems, many times it wont be able to perform a partial resynchronization with the new master, once it rejoins the partition, for the following reason: 1. The master becomes isolated, however it keeps sending PINGs to the replicas. Such PINGs will never be received since the link connection is actually already severed. 2. On the other side, one of the replicas will turn into the new master, setting its secondary replication ID offset to the one of the last command received from the old master: this offset will not include the PINGs sent by the master once the link was already disconnected. 3. When the master rejoins the partion and is turned into a replica, its offset will be too advanced because of the PINGs, so a PSYNC will fail, and a full synchronization will be required. Related to issue #7002 and other discussion we had in the past around this problem.
* | | | | | Explain why we allow transactions in -BUSY state.antirez2020-03-251-2/+9
| | | | | | | | | | | | | | | | | | | | | | | | Related to #7022.