Documentation Request Summary:
Document $listSessions and $listLocalSessions aggregation stages.
$listSessions must be run against the admin.system.sessions collection.
$listLocalSessions must not be run against a collection. e.g. db.aggregate([{$listLocalSessions, {}}]);
Both stages must appear first in an aggregation pipeline if used.
Engineering Ticket Description:
Two aggregation stages:
$listLocalSessions - Ennumerate sessions in the node's LogicalSessionsCache
$listSessions - Ennumerate sessions recorded in the admin.system.sessions collection
Each stage accepts the following spec:
{
allUsers: true|false,
users: [
{user:"name", db: "dbname"}
, ... ],
}
allUsers == true will ennumerate all users from the specified source and requires ActionType::listSessions. Specifying a list of users with allUsers==true is an error.
allUsers == false with no users explicitly specified will default to the currently authenticated user (or non-user if auth is not enabled). If any user is specified in the users array who is NOT the currently logged in user, then ActionType::listSessions is required.
|