src/mongo/shell/replsettest.js
/**
     * Returns 'true' if the "conn" has been configured to run without journaling enabled.
     */
Returns 'true' if the "conn" has been configured to run without journaling enabled.
Returns ' true ' if the " conn " has been configured to run without journaling enabled .
function _isRunningWithoutJournaling(conn) {
        var result = asCluster(conn, function() {
            var serverStatus = assert.commandWorked(conn.adminCommand({serverStatus: 1}));
            if (serverStatus.storageEngine.hasOwnProperty('persistent')) {
                if (!serverStatus.storageEngine.persistent) {
                    return true;
                }
            } else if (serverStatus.storageEngine.name == 'inMemory') {
                return true;
            }
            var cmdLineOpts = assert.commandWorked(conn.adminCommand({getCmdLineOpts: 1}));
            var getWithDefault = function(dict, key, dflt) {
                if (dict[key] === undefined)
                    return dflt;
                return dict[key];
            };
            return !getWithDefault(
                getWithDefault(getWithDefault(cmdLineOpts.parsed, "storage", {}), "journal", {}),
                "enabled",
                true);
        });
        return result;
    }
function _isRunningWithoutJournaling ( conn ) { var result = asCluster ( conn , function ( ) { var serverStatus = assert . commandWorked ( conn . adminCommand ( { serverStatus : 1 } ) ) ; if ( serverStatus . storageEngine . hasOwnProperty ( 'persistent' ) ) { if ( ! serverStatus . storageEngine . persistent ) { return true ; } } else if ( serverStatus . storageEngine . name == 'inMemory' ) { return true ; } var cmdLineOpts = assert . commandWorked ( conn . adminCommand ( { getCmdLineOpts : 1 } ) ) ; var getWithDefault = function ( dict , key , dflt ) { if ( dict [ key ] === undefined ) return dflt ; return dict [ key ] ; } ; return ! getWithDefault ( getWithDefault ( getWithDefault ( cmdLineOpts . parsed , "storage" , { } ) , "journal" , { } ) , "enabled" , true ) ; } ) ; return result ; }
Returns 'true' if the "conn" has been configured to run without journaling enabled.
Returns ' true ' if the " conn " has been configured to run without journaling enabled .