summaryrefslogtreecommitdiff
path: root/src/mongo/dbtests/querytests.cpp
Commit message (Collapse)AuthorAgeFilesLines
* SERVER-69541 Modify Helpers::findById() to accept NamespaceString type ↵Romans Kasperovics2022-09-281-4/+4
| | | | collection name
* SERVER-69581 add performance-for-range-copy check to clang-tidyTrevor Guidry2022-09-201-1/+1
|
* SERVER-67880 : Check BSON column is decompressible in the validate command.Richard Hausman2022-08-191-1/+2
|
* SERVER-68635 Move the whole insert path out of CollectionImplKaloian Manassiev2022-08-151-7/+6
|
* SERVER-65488 Change OldClientContext ctor to take in NamespaceStringSophia Tan2022-07-061-12/+12
|
* SERVER-62918 Change DBLock to use DatabaseNamejannaerin2022-06-271-1/+3
|
* SERVER-66869 Get rid of the multi DB locking capabilityKaloian Manassiev2022-06-201-4/+4
|
* SERVER-62370 Remove the _opCtx from the CollectionWriter and instead use the ↵Shin Yee Tan2022-06-101-1/+1
| | | | passed in opCtx
* SERVER-64609 Rename instances of TenantDatabaseName to DatabaseNameHugh Tong2022-05-091-1/+1
|
* SERVER-64315 Re-enable caching of SBE plans when there is a single query ↵David Storch2022-05-041-42/+6
| | | | | | solution This reverts commit f8589f840c8fee60abc482d2d2c41979e356922a.
* SERVER-65278 added clang-tidy v4 builder and fixed clang-tidy v4 issues.Daniel Moody2022-04-291-1/+1
|
* SERVER-64125 Avoid committing at the stable timestampJordi Olivares Provencio2022-04-011-11/+29
|
* SERVER-61987 Change DatabaseHolder's map to be keyed by TenantDatabaseNameSophia Tan2022-02-031-1/+1
|
* SERVER-58530 Remove unused code related to nReturnedSoFar()David Storch2022-01-191-1/+1
|
* SERVER-61385 Migrate callers of 'DBClientBase::query()' legacy API to the ↵David Storch2021-12-211-181/+118
| | | | | | | | | modern 'find()' API There are a handful of remaining callers of the legacy API, either using the exhaust option or which are involved in a code path which still relies on the OP_QUERY-inspired BSON format. These should be cleaned up as follow-up work.
* SERVER-59512 add new, cleaner query interface to DBClientBaseDavid Storch2021-11-101-46/+59
| | | | | | | | | The new interface uses FindCommandRequest, and avoids any characteristics that relate specifically to the no-longer-supported OP_QUERY wire protocol message. This patch moves all callers of 'findOne()' onto the new API, but more work is required to fully eliminate the old 'query()' API from DBClientBase.
* SERVER-59629 Enable lock-free reads on GetIndexSpecsByUUID dbtest that was ↵Dianna Hohensee2021-09-171-6/+0
| | | | previously temporarily disabled.
* SERVER-59782 migrate makeGuard calls to ScopeGuardBilly Donahue2021-09-081-1/+1
|
* SERVER-59245 Enable lock-free reads on dbtests where they were previously ↵Dianna Hohensee2021-08-261-6/+0
| | | | temporarily disabled.
* SERVER-58670 Tighten up what kind of BSON the 'Query' type can be wrapped aroundIrina Yatsenko2021-08-231-136/+133
| | | | | | | | | This refactor includes: Remove dead code from 'Query' type and reduce it public interface. Split query argument in query/update/removed methods into filter BSON and settings (which are still passed around as 'Query' type). Remove Query(string) constructors. Remove most callers of 'Query(const BSONObj&)'. Replace public 'Query(const BSON&)' and 'Query.obj' with an explicit factory method and a getter.
* SERVER-58735 Repurpose LastError for NotPrimaryError trackerYoonsoo Kim2021-08-041-1/+0
|
* SERVER-57461 Remove SPLIT_LIMITED_SORT and associated QueryPlanner codeEric Cox2021-07-311-6/+10
|
* SERVER-57390 Remove getLastError implementationYoonsoo Kim2021-07-221-6/+1
|
* SERVER-57391 Return error response to OP_QUERY and OP_GET_MORE messagesIrina Yatsenko2021-07-161-15/+15
|
* SERVER-57462 Change the shell to use OP_MSG for exhaust queries instead of ↵Yoonsoo Kim2021-07-151-30/+0
| | | | OP_QUERY
* SERVER-57459 Make dbtests and unittests getLastError-freeIrina Yatsenko2021-06-241-12/+6
|
* SERVER-57265 Migrate tests for deprecated op codes from jstest to C++ ↵Irina Yatsenko2021-06-151-8/+6
| | | | integration
* SERVER-57293 Disable lock-free reads for certain dbtests until later addressedDianna Hohensee2021-06-021-0/+12
|
* SERVER-16049 Replicate capped collection deletesGregory Wlodarek2021-04-231-1/+0
|
* SERVER-52556 Versioned CollectionCatalog. Writes are performed using ↵Henrik Edin2020-11-131-2/+2
| | | | | | | copy-on-write. Internal mutexes when reading CollectionCatalog are removed, just one mutex for writes are needed. Lock-free reads helper AutoGetCollectionForReadLockFree stashes a CollectionCatalog consistent with snapshot on OperationContext
* SERVER-51201 CollectionPtr returned from AutoGetCollectionLockFree is yieldableHenrik Edin2020-10-151-1/+1
|
* SERVER-50984 Add CollectionPtr to replace usage of const Collection*Henrik Edin2020-09-261-3/+3
| | | | | | | | | | | | It implements a yieldable interface that is used to re-load the Collection pointer from the catalog after a yield that released locks. With lock-free reads and copy-on-write on Collection instances releasing locks without notifying an AutoGetCollection at a higher level may cause its pointers to dangle if a MODE_X writer installs a new Collection instance in the catalog. CollectionPtr should be passed by const reference so a yield can notify all the way up.
* SERVER-48433 Remove LogicalClock facadeKevin Pulo2020-09-171-1/+0
|
* SERVER-50928 Remove IndexCatalog* stored in IndexBuildBlockHenrik Edin2020-09-151-1/+1
| | | | | It can go stale when we perform copy-on-write on the Collection. Pass in current Collection where it is needed.
* SERVER-50349 Getting a writable collection now requires the caller to be ↵Henrik Edin2020-09-151-10/+12
| | | | | | | | | | | | | inside a WUOW by default There are three modes when accessing a writable Collection: * Managed in WUOW (default) * Unmanaged (users need to commit/rollback) * Inplace that provides direct access to the Collection in the catalog. (Users need to ensure there's no concurrent operations going on) Added a helper RAII type CollectionWriter that abstract the three modes above and also provides abstraction on different methods of accessing Collections (AutoGetCollection or manual lookups). Writable Collection is aquired lazily when needed (usually inside a WUOW).
* SERVER-48452 Internal readers should default to reading without a timestampLouis Williams2020-09-101-1/+1
| | | | | | | | | | | | Removes ReadSource::kUnset in favor of kNoTimestamp as the default Makes the following behavioral changes to AutoGetCollectionForRead: * Removes special early-return handling for kNoTimestamp * Only user or DBDirectClient operations are eligible to read at kLastApplied. * Operations only read at kLastApplied when in the SECONDARY state, nothing else. This means most internal operations that use DBDirectClient do not need to use a ReadSourceScope to ensure they read at kNoTimestamp.
* SERVER-50317 Const correct uses of CollectionHenrik Edin2020-09-021-1/+2
| | | | | | Most of the code should only need a const Collection now. AutoGetCollection returns a const Collection by default. There is a placeholder getWritableCollection() interface that will handle the necessary steps we need for lock free reads in the future. Added some operators to AutoGetCollection so it behaves more like a smart pointer.
* SERVER-44968 Remove useless BSONVersion enum classFaustoleyva542020-06-261-1/+1
|
* SERVER-48775 Make OpObserverShardingImpl to be part of sharding_runtime_dKaloian Manassiev2020-06-151-24/+24
|
* SERVER-46659 Initial sync will startup two phase index builds during the ↵Gregory Wlodarek2020-04-201-4/+15
| | | | collection cloning phase to prevent a scenario where the commit quorum cannot be satisfied due to the primary node needing the initial syncing nodes vote
* SERVER-46560 Make abort index build deterministicLouis Williams2020-04-101-2/+3
| | | | | | | | | | | | This redesigns user index build abort to have the following behavior: - Take a collection X lock to stop the index build from making progress - If we are no longer primary, return an error - Check whether we can abort the index build (i.e. it is not already committing or aborting) - Delete the index catalog entry and write the abortIndexBuild oplog entry in a WUOW - Interrupt the index builder thread - Wait for the thread to exit - Release locks
* SERVER-41873 Remove most remaining uses of 'oplogReplay' flagDavid Storch2020-03-261-10/+10
| | | | | | | | | | | | | Starting in 4.4, this flag is accepted by the server but does not affect how the query is executed. However, there were several places in the code base where 'oplogReplay' needed to be handled due to the possibility of a mixed version 4.2/4.4 cluster. This logic can now be removed, since a 4.6 node need not be compatible with 4.2. In order to avoid breaking old drivers, the 'oplogReplay' find command option and OP_QUERY flag bit will continue to be accepted but ignored.
* SERVER-44517 Refactor exhaust cursors on top of isMaster code changesTess Avitabile2019-12-201-3/+1
|
* SERVER-43859: Take MODE_IX locks for collection creation.Daniel Gottlieb2019-11-261-2/+3
| | | | | | | | | | | | | | | | | Two concurrent storage transactions can now create collections with the same collection name. These transactions will conflict at commit time; the first committer will win and register their collection into the global catalog. The losing transactions will bubble a WriteConflictException. Top-level callers that should fail if the collection already existed must now check and fail with a NamespaceExists error code. Previously, those callers could rely on lower level code returning the NamespaceExists error. Callers that were implicitly creating a collection may retry the operation, using the now-registered collection. These transaction-local collections (UncommittedCollections) are returned when doing any CollectionCatalog::lookup* call.
* SERVER-44453 Address several orphaned TODOs.David Storch2019-11-061-3/+3
|
* SERVER-44121 MultiIndexBlock::drainBackgroundWrites() accepts drain yield policyBenety Goh2019-10-221-1/+4
|
* SERVER-43272 Implement getDatabaseInfos method (listDatabases) in DBClientVesselina Ratcheva2019-10-171-0/+57
|
* SERVER-39002 MultiIndexBlock::cleanUpAfterBuild() accepts a post-catalog ↵Benety Goh2019-10-081-1/+3
| | | | update callback
* SERVER-43273 Add UUID support to count and getIndexSpecs in DBClientVesselina Ratcheva2019-10-071-17/+82
|
* SERVER-43367 unittest framework refactor/fixesBilly Donahue2019-10-021-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Segregate old-style dbtests into their own Suite initialization system: OldStyleSuiteSpecification. This is where the funky deprecated features can live on without interfering with the Suite API. It also gives us a searchable base class to identify them in the future. OldStyleSuite has `setupTests()` and an `add<T>()` that Suite does not have. Suite API can shrink when it doesn't have to support these dbtest adaptor features. Suite only needs non-template `add(name, callback)`. - Add OldStyleSuiteInitializer to some dbtests that were missing it! These didn't use SuiteInstance to register themselves and were incorrect. They would self register, resulting in _allSuites() holding a std::shared_ptr to a static-duration Suite object! - Change `getSuite()` to return `Suite&` instead of `Suite*`. - No more "self-registering" in Suite constructor. Registration must be done as a separate post-construction step. This removes some unusual lifetime management code and is easier to document. Suite::getSuite(name) is the only way to make a Suite, and it does the make_shared and registration calls with a pseudo-private ConstructorEnable idiom. - Suite->run() returns std::unique_ptr<Result> instead of raw `Result*`. It's virtual to support OldStyleSuite behavior. - Suite._ran does nothing. Removed. - Result.cur does nothing. Removed. - Switch to pass-by-value and std::move for most ctor args. - Add explicit on 1-arg ctors. - Get rid of TestHolder. It's just a 2-field struct. - use fmt instead of snprintf - TEST and TEST_F macros: generate TEST_TYPE once. - TEST and TEST_F macros: inline the _agent variable. - Mark _doRun as `override`. - Terminology: replace CASE_NAME with SUITE_NAME. - rename DeathTestImpl -> DeathTestBase - move getDeathTestPattern into the test as a static member function - refactor out some repetition from the comparator decl macros - use if-constexpr and diamond relops to clean up the ComparisonAssertion class. - dbtests: conditionally skip some add<T> calls - further dedup (DEATH_)TEST(_F) macros