Uploaded image for project: 'Java Driver'
  1. Java Driver
  2. JAVA-1217

Increase retry frequency of heartbeat only when necessary

    XMLWordPrintableJSON

Details

    • Icon: Improvement Improvement
    • Resolution: Done
    • Icon: Major - P3 Major - P3
    • 2.12.2, 3.0.0
    • 2.12.0
    • Cluster Management
    • None

    Description

      If the driver is unable to connect to a server that it's supposed to be monitoring, the current behavior is to retry with a frequency governed by MongoClientOptions.heartbeatConnectRetryFrequency. But it's not always necessary to do this. For example, it's normal for a server to go down for maintenance, and there is no reason to retry connecting to it so long as there are other servers available that are reachable.

      Instead, the driver should always retry connecting at the normal frequency, governed by MongoClientOptions.heartbeatFrequency, even if the server is unreachable. The driver should then increase the frequency only when it is asked to execute an operation and is unable to find an appropriate server to use.

      Attachments

        Activity

          People

            jeff.yemin@mongodb.com Jeffrey Yemin
            jeff.yemin@mongodb.com Jeffrey Yemin
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: