summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* [SQUERGE] Initial internal replication testsCOUCHDB-3326-clustered-purge-davisp-refactor-2Paul J. Davis2018-05-032-17/+185
|
* [SQUERGE] mem3 internal replication bug fixesPaul J. Davis2018-05-032-9/+8
|
* [SQUERGE] Don't bump update_seq if all replicated purges are filtered outPaul J. Davis2018-05-031-38/+43
|
* [SQUERGE] Fix eunit testsPaul J. Davis2018-05-012-10/+37
|
* [SQUERGE] Fix tests and code for fabric_doc_purgePaul J. Davis2018-04-301-235/+394
|
* enable purge.jsjiangphcn2018-04-301-2/+2
| | | | COUCHDB-3326
* [SQUERGE] Attempt to duplicate bug from JiangPaul J. Davis2018-04-271-18/+5
|
* [SQUERGE] Update tests to check the changes feedPaul J. Davis2018-04-271-4/+33
|
* [SQUERGE] Fix handling of duplicated doc idsPaul J. Davis2018-04-271-37/+49
| | | | | | Turns out we weren't properly handling when a document id was being repeated in a single purge batch. This fixes that. Squerge to implementing the APIs bit
* [SQUERGE] couch_db_purge_docs_tests cleanupPaul J. Davis2018-04-271-538/+654
| | | | | | | | | | | | I've taken some liberty cleaning up the tests for purges in this module by using a few helper functions and some minor reformatting. Currently the repeated docid test is failing because there's a bug in the purge_docs logic in couch_db_updater where its not accounting for the fact that a user may have specified a doc id multiple times. As for doc updates we'll have to apply purges from the first purge infos and return responses that correspond to which updates actually took effect.
* [SQUERGE] Fix function name in couch_db_enginePaul J. Davis2018-04-271-1/+1
| | | | Silly me. Squerge to couch_db_engine API change
* [SQUERGE] Fix load_purge_infos API usagePaul J. Davis2018-04-271-1/+1
| | | | Messed up the name and the return value. Squery to implement APIs
* [SQUERGE] Throw error on duplicate UUIDsPaul J. Davis2018-04-271-2/+15
| | | | | Unless we're replicating purge infos its an error to repeat a UUID. Squerge to implement APIs
* [SQUERGE] Record all purge infos regardless of effectPaul J. Davis2018-04-271-1/+1
| | | | | We need to record all purge info requests even if they don't actually remove any revisions. Squerge to implementing the APIs commit
* Unable to reproduce doc creation bugPaul J. Davis2018-04-271-8/+26
|
* Test test_purge_repeated_rev/1jiangphcn2018-04-271-5/+11
| | | | COUCHDB-3326
* Fix UUID testPaul J. Davis2018-04-261-26/+27
|
* Add test compact with broken purge checkpoint docjiangphcn2018-04-262-2/+241
| | | | COUCHDB-3326
* Add more test casesjiangphcn2018-04-263-6/+141
| | | | COUCHDB-3326
* Update tests for new PSE test suitePaul J. Davis2018-04-265-156/+113
|
* Update HTTP JS tests for clustered purgePaul J. Davis2018-04-262-21/+11
|
* Implement HTTP endpoints for clustered purgePaul J. Davis2018-04-262-11/+214
|
* Fix read-repair for new clustered purgePaul J. Davis2018-04-263-132/+241
|
* Add clustered purge API to fabricPaul J. Davis2018-04-267-39/+600
|
* Implement internal replication of purge requestsPaul J. Davis2018-04-262-14/+262
|
* Update the view engine to use the new purge APIsPaul J. Davis2018-04-2610-23/+684
|
* Add EPI hook for creating purge docs on compactionPaul J. Davis2018-04-262-1/+25
|
* Update the purge eunit test suitesPaul J. Davis2018-04-268-21/+1158
|
* Implement new purge APIs for couch_bt_enignePaul J. Davis2018-04-264-67/+334
|
* Implement new node local purge APIsPaul J. Davis2018-04-264-94/+258
| | | | | Rewrite purge logic to use the new couch_db_engine purge APIs. This work will allow for the new purge behaviors to enable clustered purge.
* Define new couch_db_engine purge APIPaul J. Davis2018-04-261-32/+130
|
* Simplify logic in mem3_repPaul J. Davis2018-04-261-9/+8
| | | | | | Previously there were two separate database references and it was not clear which was used where. This simplifies things by reducing it to a single instance so that the logic is simpler.
* Rewrite the PSE test suite to use couch_serverPaul J. Davis2018-04-2611-749/+716
| | | | | | | It turns out that if any storage engine has to open itself during a callback it would end up violating the guarantee of a single writer. This change in the test suite changes things to use couch_server so that storage engines are now free to do as they want reopening themselves.
* Fix race on couch_db:reopen/1Paul J. Davis2018-04-261-2/+5
| | | | | | This fixes a minor race by opening the database before closing it. This was never found to be an issue in production and was just caught while contemplating the PSE test suite.
* Fix default security object handlingPaul J. Davis2018-04-261-1/+1
| | | | | | | | There's a race where if a database is opened with a default_security set and it crashes before first compact, and is then reopened after the default_security option has changed that it will pick the second security option. This ensures change closes that relatively obscure bug that was only found during testing.
* Fix bug during purgePaul J. Davis2018-04-261-1/+1
|
* Fix typos in couch_db_engine.erlPaul J. Davis2018-04-261-5/+5
|
* Fix length badarg error in mp parserNick Vatamaniuc2018-04-171-1/+2
| | | | | | | | This was introduced in: https://github.com/apache/couchdb/commit/083239353e919e897b97e8a96ee07cb42ca4eccd Issue #1286
* Fix mem3 tests (#1285)Eric Avdey2018-04-174-93/+36
| | | | | | | | | | | | | | | | The changes listener started in setup of mem3_shards test was crashing when tried to register on unstarted couch_event server, so the test was either fast enough to do assertions before of that or failed on dead listener process. This change removes dependency on mocking and uses a standard test_util's star and stop of couch. Module start moved into the test body to avoid masking potential failure in a setup. Also the tests mem3_sync_security_test and mem3_util_test been modified to avoid setup and teardown side effects.
* Document enable_database_recovery ini optionJoan Touzet2018-04-131-0/+6
|
* Merge pull request #1273 from cloudant/adopt-fake_db-to-PSEEric Avdey2018-04-131-2/+24
|\ | | | | Adopt fake_db to PSE changes
| * Adopt fake_db to PSE changesEric Avdey2018-04-131-2/+24
|/ | | | | | | | | | With db headers moved into engine's state, any fake_db call, that's trying to setup sequences for tests (e.g. in mem3_shards) crashing with context setup failed. It's not trivial to compose a proper `engine` field outside of couch app, so instead this fix makes fake_db to set engine transparently, unless it was provided in a payload.
* In _scheduler/docs fix `crashing` state showing as `pending` sometimesNick Vatamaniuc2018-04-121-4/+78
| | | | | | | | | | | | | | | | | | | | | Replication jobs are backed off based on the number of consecutive crashes, that is, we count the number of crashes in a row and then penalize jobs with an exponential wait based that number. After a job runs without crashing for 2 minutes, we consider it healthy and stop going back in its history and looking for crashes. Previously a job's state was set to `crashing` only if there were any consecutive errors. So it could have ran for 3 minutes, then user deletes the source database, job crashes and stops. Until it runs again the state would have been shown as `pending`. For internal accounting purposes that's correct but it is confusing for the user because the last event in its history is a crash. This commit makes sure that if the last even in job's history is a crash user will see the jobs as `crashing` with the respective crash reason. The scheduling algorithm didn't change. Fixes #1276
* Merge pull request #1281 from apache/commit_data_pseRobert Newson2018-04-121-8/+9
|\ | | | | call commit_data where needed
| * call commit_data where neededRobert Newson2018-04-121-8/+9
|/ | | | Regression since introduction of PSE
* Set update_lru_on_read=false as defaultJoan Touzet2018-04-102-3/+6
|
* Minor documentation cleanup for couch_replicatorKyle Snavely2018-04-091-20/+21
|
* Switch to using a mirrored triq dependencyNick Vatamaniuc2018-04-091-2/+1
|
* Do not drop updated httpdb record after auth headers are updatedNick Vatamaniuc2018-04-061-4/+4
| | | | | | | | | | In replicator, after client auth plugin updates headers it could also update its private context. Make sure to pass the updated httpdb record along to response processing code. For example, session plugin updates the epoch number in its context, and it needs the epoch number later in response processing to make the decision whether to refresh the cookie or not.
* Kill fabric attachment receiver when middleman times outNick Vatamaniuc2018-04-041-2/+3
| | | | | | | | Attachment receiver process is started with a plain spawn. If middleman process dies, receiver would hang forever waiting on receive. After a long enough time quite a few of these receiver processes could accumulate on a server. Fixes #1264