API 参考
    正在准备搜索索引...

    Representation of a deployment of servers

    索引

    构造函数

    • Create a TopologyDescription

      参数

      返回 TopologyDescription

    属性

    commonWireVersion: number
    compatibilityError?: string
    compatible: boolean
    heartbeatFrequencyMS: number
    localThresholdMS: number
    logicalSessionTimeoutMinutes: null | number
    maxElectionId: null | ObjectId
    maxSetVersion: null | number
    servers: Map<string, ServerDescription>
    setName: null | string
    stale: boolean

    访问器

    • get error(): null | MongoServerError

      返回 null | MongoServerError

    • get hasDataBearingServers(): boolean

      Determines if this topology description has a data-bearing server available.

      返回 boolean

    • get hasKnownServers(): boolean

      Determines if the topology description has any known servers

      返回 boolean