20 Commits

Author SHA1 Message Date
John Sully
c61b6cc8fd Update more slave instances to use replica (Issue #75)
Former-commit-id: 252725d50fc9d4ff2b6e9246a36c38176d61beae
2019-10-13 12:29:20 -04:00
John Sully
d4e4b4f4d1 Update a few uses of slave to use the new replica terminology (Issue #75)
Former-commit-id: c15633ea9e784ef0e12e4015a75245661a8cf1b7
2019-10-13 12:12:05 -04:00
John Sully
08b353cd55 Fix double free in RDB load
Former-commit-id: 070c4818715b56645855abb72af47c846fc63027
2019-09-28 17:38:26 -04:00
John Sully
9f3cbd580e Fix multi master bugs: 1. we fail to create the temp file. 2. We use a master RDB as our backup even though we merged databases (and therefore it is not representitive)
Former-commit-id: e776474f68a2824bb7d4082c41991a9a9f3a9c9d
2019-09-26 20:35:51 -04:00
John Sully
9711895721 Subexpire entries should load/save
Former-commit-id: a55d98043655473ecdd53db2927381635eefc0b8
2019-07-23 18:53:59 -04:00
John Sully
f88592451d Plumb support for sub expires to all expire related code
Former-commit-id: 184abac6942a9a6aa8783741b50b23210afddcc5
2019-07-23 18:53:59 -04:00
John Sully
2a2225d150 Initial prototype of EXPIREMEMBER command
Former-commit-id: 0b3d74ea67d616a6869cbd66198c8dd7ffa72eb7
2019-07-23 18:53:58 -04:00
John Sully
27cb5dba75 New expire datastructure and algorithm. Allows us to expire in sublinear time
Former-commit-id: 3880d2616c882e19169180dc10268564347b0279
2019-07-23 18:30: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
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
2a1d7890f6 Fix compile errors on GCC v5
Former-commit-id: 1f08a0efb33511ddc75c2acc62199bfcd0860137
2019-07-11 20:20:01 -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
John Sully
7b87123505 refactor server global into a pointer (so that threadsafe commands can set this to NULL to prove they don't rely on it
Former-commit-id: 37b2d046bef12c7ee7cac4883f0b64ddde236d74
2019-04-21 14:01:10 -04:00
John Sully
e2e3acf04c Factor out some normally const globals
Former-commit-id: fa2e407873fce7f936943ae1fe162d54d7bedd70
2019-04-21 13:20:45 -04:00
John Sully
a28120cb9e Timestamp writes to objects so we can be smarter about merging databases
Former-commit-id: 5dc9f70386617b02fab7eee1194f321f6b4b25c5
2019-04-20 00:52:07 -04:00
John Sully
d22f1d9481 Additional MVCC work and fix memory leak loading objects from rdb
Former-commit-id: efde2e6be6dc2fc3425a17e2dc146c5b8823730a
2019-04-19 22:54:42 -04:00
John Sully
c32ae00cb8 Add version override command for users that need compatibility with Redis
Former-commit-id: 5a78a3bc46335a844490fe00e657d68313680cbe
2019-04-19 19:57:11 -04:00
John Sully
b5e25f876f Start of MVCC support (and more C++)
Former-commit-id: c4621a5ed2a7d8ca5034f2fbe8b71550f290ea64
2019-04-16 23:16:03 -04:00
John Sully
7859e0562f Move remaning files dependent on server.h over to C++
Former-commit-id: 8c133b605c65212b023d35b3cb71e63b6a4c443a
2019-04-08 01:00:48 -04:00