[SERVER-33889] Remove commands from embedded that shouldn't be available Created: 14/Mar/18  Updated: 29/Oct/23  Resolved: 30/May/18

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 4.0.0-rc2, 4.1.1

Type: Task Priority: Major - P3
Reporter: Henrik Edin Assignee: Henrik Edin
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Depends
depends on SERVER-29908 Libraries db/s/sharding and db/query/... Closed
depends on SERVER-33008 Slice Authorization Framework with vt... Closed
depends on SERVER-34894 Create Embedded-only auth-lite implem... Closed
is depended on by SERVER-34006 Ensure android builds target correct ... Closed
Related
related to SERVER-55034 The profile command should not take S... Closed
Backwards Compatibility: Fully Compatible
Backport Requested:
v4.0
Sprint: Platforms 2018-03-26, Platforms 2018-05-07, Platforms 2018-05-21, Platforms 2018-06-04
Participants:

 Description   

I ran listCommands on embedded and we currently have this set of commands, partitioned here into three groups, depending on what we believe should be the disposition of the command in embedded:

Current:

_hashBSONElement
aggregate
buildInfo
collMod
collStats
configureFailPoint
count
create
createIndexes
currentOp
dataSize
dbStats
delete
distinct
drop
dropDatabase
dropIndexes
echo
explain
find
findAndModify
geoNear
getLastError
getMore
getParameter
getPrevError
getShardMap
insert
isMaster
killCursors
killOp
listCollections
listCommands
listDatabases
listIndexes
lockInfo
ping
planCacheClear
planCacheClearFilters
planCacheListFilters
planCacheListPlans
planCacheListQueryShapes
planCacheSetFilter
reIndex
renameCollection
repairCursor
repairDatabase
replSetGetStatus
resetError
serverStatus
setBatteryLevel
setParameter
sleep
trimMemory
update
validate

Remove:

getShardMap



 Comments   
Comment by Andrew Morrow (Inactive) [ 30/May/18 ]

I've closed this ticket. We still do have one remaining command that shouldn't be there getShardMap, but this will disappear automatically when SERVER-29908 is fixed, so there is no further work to do here.

Comment by Githook User [ 30/May/18 ]

Author:

{'username': 'acmorrow', 'name': 'Andrew Morrow', 'email': 'acm@mongodb.com'}

Message: SERVER-33889 Remove more commands from embedded

(cherry picked from commit d0dfed56a03499e06bdad46c311250f4b987578a)
Branch: v4.0
https://github.com/mongodb/mongo/commit/bf788b744ae063fe648fe9013f3ebfa78a25326d

Comment by Githook User [ 30/May/18 ]

Author:

{'username': 'acmorrow', 'name': 'Andrew Morrow', 'email': 'acm@mongodb.com'}

Message: SERVER-33889 Remove more commands from embedded
Branch: master
https://github.com/mongodb/mongo/commit/d0dfed56a03499e06bdad46c311250f4b987578a

Comment by Andrew Morrow (Inactive) [ 25/May/18 ]

OK, I'm removing buildInfo from the Remove list.

Comment by Githook User [ 25/May/18 ]

Author:

{'username': 'acmorrow', 'name': 'Andrew Morrow', 'email': 'acm@mongodb.com'}

Message: SERVER-33889 Remove auditing command from embedded

(cherry picked from commit b322ee9200172276b8d4935c623728129d62c3ef)
Branch: v4.0
https://github.com/mongodb/mongo/commit/b63adc38fc934def5fd7463e390f21ad3bdedffb

Comment by Githook User [ 25/May/18 ]

Author:

{'username': 'acmorrow', 'name': 'Andrew Morrow', 'email': 'acm@mongodb.com'}

Message: SERVER-33889 Don't link audit commands into embedded

Also, fix a drive by issue where the enterprise and community builds
produced a library with the same name.

(cherry picked from commit 8ca15cd2ee8bccd59c72ff2f5769c5829f026b12)
Branch: v4.0
https://github.com/10gen/mongo-enterprise-modules/commit/a6925057e7c8ac4991a349743733533844939346

Comment by Githook User [ 25/May/18 ]

Author:

{'username': 'acmorrow', 'name': 'Andrew Morrow', 'email': 'acm@mongodb.com'}

Message: SERVER-33889 Remove auditing command from embedded
Branch: master
https://github.com/mongodb/mongo/commit/b322ee9200172276b8d4935c623728129d62c3ef

Comment by Githook User [ 25/May/18 ]

Author:

{'username': 'acmorrow', 'name': 'Andrew Morrow', 'email': 'acm@mongodb.com'}

Message: SERVER-33889 Don't link audit commands into embedded

Also, fix a drive by issue where the enterprise and community builds
produced a library with the same name.
Branch: master
https://github.com/10gen/mongo-enterprise-modules/commit/8ca15cd2ee8bccd59c72ff2f5769c5829f026b12

Comment by Githook User [ 17/May/18 ]

Author:

{'email': 'henrik.edin@mongodb.com', 'username': 'henrikedin', 'name': 'Henrik Edin'}

Message: SERVER-33889 Separate sleep from shell_commands so the capi unittests don't drag in new commands.
Branch: master
https://github.com/mongodb/mongo/commit/53d264b01621f815e1c80673c4cbc874bbd45e32

Comment by Githook User [ 17/May/18 ]

Author:

{'email': 'henrik.edin@mongodb.com', 'username': 'henrikedin', 'name': 'Henrik Edin'}

Message: SERVER-33889 Embedded listcommands test to verify command list.
Branch: master
https://github.com/mongodb/mongo/commit/b5f4020637b6a5a1b18a0735c65212fe03b3a60b

Comment by Henrik Edin [ 03/Apr/18 ]

Added a current section to list our current status as of today.

Comment by Githook User [ 02/Apr/18 ]

Author:

{'email': 'acm@mongodb.com', 'name': 'Andrew Morrow', 'username': 'acmorrow'}

Message: SERVER-33889 Strip out commands and libraries from embedded
Branch: master
https://github.com/mongodb/mongo/commit/9055e4ea0230952af52e8cd396c63a8b407fdbf9

Comment by Githook User [ 02/Apr/18 ]

Author:

{'email': 'acm@mongodb.com', 'name': 'Andrew Morrow', 'username': 'acmorrow'}

Message: SERVER-33889 Catch up with library graph dependencies on community master
Branch: master
https://github.com/10gen/mongo-enterprise-modules/commit/a732e1e77019e248d1eaeabc7cfb42c725bfdcb4

Comment by Andrew Morrow (Inactive) [ 30/Mar/18 ]

Updating with current state of commands emperically found to be in embedded, and some additional steps on research.

Comment by Githook User [ 23/Mar/18 ]

Author:

{'email': 'henrik.edin@mongodb.com', 'name': 'Henrik Edin', 'username': 'henrikedin'}

Message: SERVER-33889 Split dcommands and core into libraries for embedded vs standalone process applications. Refactored commands libraries throughout the codebase and made their uses be LIBDEPS_PRIVATE when possible as most commands don't export any symbols and don't even have headerfiles.
Branch: master
https://github.com/mongodb/mongo/commit/49138e688e51b8397bc32d8c875ea10ef968af4c

Comment by Githook User [ 23/Mar/18 ]

Author:

{'email': 'henrik.edin@mongodb.com', 'name': 'Henrik Edin', 'username': 'henrikedin'}

Message: SERVER-33889 Update dependencies for the new command libraries.
Branch: master
https://github.com/10gen/mongo-enterprise-modules/commit/d8e89ec992d4e5240753ab17659a0a3fe0311732

Comment by Jeffrey Yemin [ 16/Mar/18 ]

The driver will call endSessions when the MongoClient is closed, but in practice if endSessions fails it's fine. I just checked the spec and it requires that endSessions errors are ignored.

The more important part is that it remains ok to include lsid with every command.

Comment by Henrik Edin [ 16/Mar/18 ]

Is endSessions required for you to work with the embedded library right now? If that's the case and we're removing sessions for embedded, we need to make a noop endSessions command for embedded. That might be better than to only rely on logicalSessionTimeoutMinutes ?

Comment by Jeffrey Yemin [ 15/Mar/18 ]

I prefer that we keep endSessions. Standalone mongod supports it, and drivers will call endSessions as part of normal operation, due to the implicit session support added in 3.6 driver releases.

If you really want to get rid of sessions in embedded, the way we could make it work is to remove logicalSessionTimeoutMinutes from the ismaster response, as that's what drivers use to determine whether sessions are supported.

CC behackett I talked to Kal about this and he says that standalones can and will continue to support sessions, hence the above comment.

Comment by Andrew Morrow (Inactive) [ 15/Mar/18 ]

Moved 'eval' out of keep. We definitely don't want it.

Comment by Henrik Edin [ 15/Mar/18 ]

I corrected renameCollection and getnonce. Feel free to move commands if you see errors. Drop a comment so we can track it easily.

Comment by Andrew Morrow (Inactive) [ 15/Mar/18 ]

I moved the partitioned list up to the description so we can edit it as we sort things into buckets.

Comment by Bernie Hackett [ 14/Mar/18 ]

Since the remove list includes things like saslSart, authenticate, etc., it seems safe to move getnonce and anything user or role related from the unsure list to the remove list as well.

Comment by Jeffrey Yemin [ 14/Mar/18 ]

Why does renameCollection need to go?

Comment by Andrew Morrow (Inactive) [ 14/Mar/18 ]

Neat! Do you want to start to break this list down into three groups: obviously remove, obviously keep, needs research?

Generated at Thu Feb 08 04:34:53 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.