10649 Commits

Author SHA1 Message Date
John Sully
08d067fbcf Modules must have execute permissions to load
Former-commit-id: a4efcd35af52227a22daf7f882e8e14db3f8bf57
2019-07-19 01:31:10 -04:00
antirez
1aa5638b93 RDB: make sure to abort on LZF encoding error.
Former-commit-id: 27fe1658a2019bcd5d880e844bac21ccef8303f2
2019-07-19 01:03:16 -04:00
antirez
3e75e77dcd RDB: handle encoding errors with rdbExitReportCorruptRDB().
Without such change, the diskless replicas, when loading RDB files from
the socket will not abort when a broken RDB file gets loaded. This is
potentially unsafe, because right now Redis is not able to guarantee
that encoding errors are safe from the POV of memory corruptions (for
instance the LZF library may not be safe against untrusted data?) so
better to abort when the RDB file we are going to load is corrupted.

Instead I/O errors are still returned to the caller without aborting,
so that in case of short read the diskless replica can try again.


Former-commit-id: 47feb2719ca7fd04e7e108ec1af0f777e536bf8a
2019-07-19 01:02:49 -04:00
John Sully
bb9b8ee164 Fix bad merge in SCAN KEYS command
Former-commit-id: c21af6b351328ffbdb1d1e2a7eed44f8f929f8b2
2019-07-19 00:43:23 -04:00
John Sully
15f5c7ccf7 Merge commit '722446510faf0debf0d309708b2ed4fe4d939319' into unstable
Former-commit-id: 821c12c482d20b15dfb5a6eeab52e167997627d8
2019-07-19 00:32:43 -04:00
John Sully
4088de0ed2 Merge commit '677e95e2f5ee903682ce44a7bfd9558a22577926' into unstable
Former-commit-id: 4602f8c391409e9dd59f1fbee6a5ef011b219ca1
2019-07-19 00:01:56 -04:00
John Sully
e642441354 Fix compile errors from merges
Former-commit-id: 27a927fe0011536c6539d7c2a79ccfdaf78cee22
2019-07-18 23:35:51 -04:00
Angus Pearson
7b615e7274 Add char* typeNameCanonicalize(robj*) to remove duplicate code between SCAN and TYPE commands,
and to keep OBJ_* enum to string canonicalization in one place.


Former-commit-id: 3cdc6e8d846e88cf4e250b2643662bde2a9317c5
2019-07-18 23:31:31 -04:00
John Sully
f84ee30d7d Merge commit '0cabe0cfa7290d9b14596ec38e0d0a22df65d1df' into unstable
Former-commit-id: 89b52da387079fb8693dcbced218b9c6244fb00c
2019-07-18 23:28:56 -04:00
Madelyn Olson
a8fc002adc Fixed some spelling issues in ACL codepath including user facing error
Former-commit-id: 50ad880ad55e7761fe2598e09be43947e88740fe
2019-07-18 23:28:36 -04:00
John Sully
e160fbdeb9 Merge commit 'de035c94816722dd923e4aedd852869de79a5185' into unstable
Former-commit-id: 15bed4bbcc962ec1e8ad5f57653534b721df9a70
2019-07-18 23:26:46 -04:00
John Sully
73df5494a8 Merge commit 'bf963253ecfd367b49081a26c1b5c410558aecfc' into unstable
Former-commit-id: 10986ae3a801c13013ec74880dd1f7969c284d01
2019-07-18 23:22:36 -04:00
John Sully
d129e3df0a Merge commit '7fababd44e8b8b2df53cad0906ec5ab7c678dd44' into unstable
Former-commit-id: 2baa76b2ee6e17c2cc44c559ba58b82875cf8f97
2019-07-18 23:21:13 -04:00
John Sully
f4c0c12e71 Merge commit '074d24df1e82b5c794a5da9fb6cda5b77b60b27b' into unstable
Former-commit-id: ee460301fd160cf3fc82e52cf47d4a5f7503d781
2019-07-18 23:20:46 -04:00
John Sully
c2eba1f742 Merge commit 'caf74e507e6535dab58ce6f3db19f8b594b5f7ca' into unstable
Former-commit-id: 8ebe2fce3da506639acb37fedf1a2d3e47669572
2019-07-18 23:18:42 -04:00
antirez
dec2345007 Test: fix slowlog test false positive.
In fast systems "SLOWLOG RESET" is fast enough to don't be logged even
when the time limit is "1" sometimes. Leading to false positives such
as:

[err]: SLOWLOG - can be disabled in tests/unit/slowlog.tcl
Expected '1' to be equal to '0'


Former-commit-id: 8198a697fd4455c88712099f20632e554fb564d4
2019-07-18 23:12:52 -04:00
antirez
a9dbdb3348 Make comment in getClientOutputBufferMemoryUsage() describing the present.
Former-commit-id: 35acae360a4c3c67370b03b4835c51b08194ca28
2019-07-18 23:12:39 -04:00
antirez
b70266f3d3 Fix test false positive introduced by threaded I/O.
Now clients that are ready to be terminated asynchronously are processed
more often in beforeSleep() instead of being processed in serverCron().
This means that the test will not be able to catch the moment the client
was terminated, also note that the 'omem' figure now changes in big
steps, because of the new client output buffers layout.

So we have to change the test range in order to accomodate for that.
Yet the test is useful enough to be worth taking, even if its precision
is reduced by this commit. Probably if we get more problems, a thing
that makes sense is just to check that the limit is < 200k. That's more
than enough actually.


Former-commit-id: 8aaa8b0b116dc86473b6a94bf2ff330dd4163ca1
2019-07-18 23:12:05 -04:00
John Sully
47e7652611 Active Replicas should always use their own slaveseldb variable when sending/saving rdbs - never those of their masters. This is because the Active Replica is also simultaneously a master
Former-commit-id: bb090b6d20bfc3d5d3ca07270f64bf15fad42681
2019-07-18 20:50:20 -04:00
John Sully
727bda7108 remove unnecessary variables
Former-commit-id: a9c4e3970fd0d00896cb5500b2cc926ec3177bc4
2019-07-18 19:37:49 -04:00
John Sully
2110b84f7e Fix issue #59 - Test replicaof config variable
Former-commit-id: d5ecc2347a717f6e6f938d81325476a9c3dff9a6
2019-07-18 19:22:49 -04:00
John Sully
7ba2941735 Add support for sanitizers and fix issues they have found
Former-commit-id: 58971a430dd3e4e8c39c7b5288211bc2ba7699ed
2019-07-18 18:39:42 -04:00
John Sully
e41ab66722 Resolve race on neterr variable
Former-commit-id: 1512274f4c51dc4e8f4e3d11df2f35e051c0c079
2019-07-18 17:11:28 -04:00
John Sully
aa560582b4 Make object refcounts atomic, technically it doesn't need to be currently but the semantics are complicated and error prone. This is much safer with little performance impact
Former-commit-id: e310d33c121550f69b1c06d101db0c3f944a7fb0
2019-07-18 15:49:12 -04:00
John Sully
afa1a2e023 Suppress initialized data sanitizer warnings
Former-commit-id: ad32ba0343a241c46206ada273b0c0125e9e3101
2019-07-18 15:49:03 -04:00
John Sully
452ace5b95 Another RESP3 regression
Former-commit-id: 4e30a5b4e53a4d1580f8d7cca8a8eac11e36ce4d
2019-07-17 22:57:52 -04:00
John Sully
cb58295ade Fix Issue #58
Former-commit-id: c8516f3dc484920de4fc52acd72f5104d643ca87
2019-07-17 02:34:02 -04:00
John Sully
bc0c9054b2 Shared objects should be marked as such
Former-commit-id: aae0fdc11434fa76a1847eca9292c277b559730a
2019-07-16 18:32:01 -04:00
John Sully
79731e805a Crash when aborting SYNC with a master on a thread other than main
Former-commit-id: a19d0f67b9fffefd9029b9a2ef3358b110302bbf
2019-07-15 14:55:41 -04:00
John Sully
bdc901f01c Implement test mode to make finding bugs easier
Former-commit-id: 971f69fe1ff9cce50492a47f306b312457e50b9f
2019-07-15 14:55:18 -04:00
John Sully
a9500e5483 Blocked clients can stall when under low load
Former-commit-id: 7468c691ad04829c1fd3ae69f206946e8f38254a
2019-07-13 16:44:11 -04:00
John Sully
0dd9a27420 Give the active-rep more time to sync for test reliability
Former-commit-id: 620c2ec1412a3bcea5fecf21238caa065e73f3e9
2019-07-12 23:52:07 -04:00
John Sully
e78ed8cc64 Fix more locking deadlocks
Former-commit-id: 3081b6f98b5e7a9f3ef7cfe040236070398b081c
2019-07-12 23:51:45 -04:00
John Sully
8f1e7d9d5b Fix deadlock with client and ae locks
Former-commit-id: 8630339e43c1de1cd723bdfdca8ab5924e2cb8b0
2019-07-12 20:46:50 -04:00
John Sully
03d41318b0 Add Active Replication tests
Former-commit-id: 528d10091fda0d2c56674e825c4f70467587955f
2019-07-12 03:54:41 -04:00
John Sully
42143ac654 FIX: The dabase count configuration is not respected
Former-commit-id: 149c3cf3dd75e8058c7c560d6a7ffbbb95da3898
2019-07-12 02:13:37 -04:00
John Sully
9dbcfc9d24 Update README.md
Former-commit-id: f12c3cf9ddccedbafd7cde05fcabc5f47e5c58a3
2019-07-11 20:29:47 -04:00
John Sully
2a1d7890f6 Fix compile errors on GCC v5
Former-commit-id: 1f08a0efb33511ddc75c2acc62199bfcd0860137
2019-07-11 20:20:01 -04:00
John Sully
3498002d9e Fix more accounting errors with active replication and the replication offset. Specifically we don't update repl_ack_off as frequently as we do reploff_skipped
Former-commit-id: 6cf85d1d01e56de0bb6e5d34590623cd8dabd32b
2019-07-11 19:20:12 -04:00
John Sully
0db39bcf9d Active Replicas are not slaves
Former-commit-id: b5101a460dba56d6deac5b753d09d47d834eee4a
2019-07-11 18:51:20 -04:00
John Sully
361b7655ef Fix active replication offset synchronization accounting, and enable the wait command
Former-commit-id: a5784ef09e71a9a45780a8f3dbab875b1f1fe1a5
2019-07-11 17:00:23 -04:00
Salvatore Sanfilippo
722446510f
Merge pull request #6116 from AngusP/scan-types
SCAN: New Feature `SCAN cursor [TYPE type]` modifier suggested in issue #6107
2019-07-08 12:53:34 +02:00
Angus Pearson
6eb52e200c Change typeNameCanonicalize -> getObjectTypeName, and other style changes 2019-07-08 11:04:37 +01:00
Salvatore Sanfilippo
4c4b7023dd
Merge pull request #6210 from gkorland/patch-3
fix build tracking.c should be tracking.o
2019-07-07 17:49:17 +02:00
Guy Korland
2d07883cab
fix build tracking.c should be tracking.o
thanks to @rafie
2019-07-07 18:28:15 +03:00
Salvatore Sanfilippo
e8ae07aabf
Merge pull request #6162 from madolson/dev-unstable-config-refactor
Refactored yesno configs so there is less duplication
2019-07-07 17:13:11 +02:00
Salvatore Sanfilippo
677e95e2f5
Merge pull request #6161 from swilly22/redismodule-loading-ctx-flag
Extend REDISMODULE_CTX_FLAGS to indicate if redis is  loading
2019-07-07 17:01:29 +02:00
John Sully
87d57aa265 lazyfree needs to consume more memory to be detectable
Former-commit-id: 122ec25bf0db0b90e7789b1ab90695ac3f9258b7
2019-07-06 00:53:40 -04:00
John Sully
37090db182 Redis only does this in beforeSleep function - doing extra calls like we do causes test issues
Former-commit-id: d013ad9ebaf3c2bf38121349ed9b98e16439c734
2019-07-06 00:53:20 -04:00
John Sully
a43a383361 Add back user space buffering of RDB save
Former-commit-id: d918ca6fa57a6149b86b4effc787dbdde7350133
2019-07-06 00:36:23 -04:00