SERVER-14058 Move thread_pool into "foundation" library.
SERVER-14065 use namespace mongo::repl in dbtests pertaining to replication
SERVER-4740 Don't use unsigned for time deltas

Leads to weird bugs when time goes backwards.

This commit doesn't resolve SERVER-4740 (Use monotonic clock sources for
Timer) but lessens the impact of using a non-monotonic clock.
SERVER-13985 Remove old v3 to v4 config metadata upgrade jstests
SERVER-14076 remove replset_remove_node.js as it is redundant and flakey
SERVER-14077 make awaitReplication() change configVersion if it sees a higher one
SERVER-14056 Cross-DB renameCollection needs to call commitIfNeeded

Fixes regression introduced in 0abf27ae.

Before 0abf27a, renameCollection used a DBDirectClient to read objects
from the source namespace.  The call to DBClientCursor::next() would
issue a getmore after finishing each batch, which would reach a commit
point (in DBDirectClient::call()).  The port to the new collection
interface removed the use of DBDirectClient, which removed
renameCollection's commit point.
SERVER-13961 Remove thread-local write intents

This change makes all write intents go straight to the global write
intents list. Cleaning this up is necessary as a step to going to a
per-operation intents list, but it may cause more contention on the global
intents list.
SERVER-13961 Pass LockState to DBWrite and DBRead directly

This is part of the changes to move LockState be part of OperationContext
and not retrieved from TLS.
Revert "SERVER-13961 Pass LockState to DBWrite and DBRead directly"

This reverts commit 0672061deb58aac931912bed68d014247c581968.
SERVER-11776 Replication 'isself' check should allow mapped ports

    'isself' should match the ports only if the hosts are being string matched.
    In cases where an instance is being addressed through a proxy port,
    port matching is an incorrect check - it invalidates a genuine match.

Signed-off-by: Benety Goh <benety@mongodb.com>
SERVER-11776 added scott's replication test for the isself command with mapped ports
SERVER-11776 move port check outside loop
SERVER-8492 SERVER-13893 Test for detecting named/unnamed unix socket

Signed-off-by: Benety Goh <benety@mongodb.com>
SERVER-13022 added option to set permissions on UNIX domain socket file

Signed-off-by: Benety Goh <benety@mongodb.com>
SERVER-13883 findAndModify return null if !new and doc not found

Fixes an edge case where findAndModify would return {} instead of null
if the doc was not found (specifically: if sort was specified and the
update resulted in an upsert).
SERVER-13883 findAndModify command should accept update:{}
SERVER-14073 allow planSummary string to be longer
SERVER-14064 provide planSummary for slow count commands
SERVER-14089 Remove support for schemaVersion24 users.