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

Auto Reconnect

    XMLWordPrintableJSON

Details

    • Icon: Task Task
    • Resolution: Done
    • Icon: Trivial - P5 Trivial - P5
    • None
    • 2.12.3
    • None
    • None

    Description

      I'm currently using the java driver, we've noticed that this is not auto reconnecting to mongodb by default. The below says autoConnectRetry has been deprecated, how can I use the connectTimeout property to have auto retry?

      @Deprecated
      public MongoClientOptions.Builder autoConnectRetry(boolean autoConnectRetry)

      Deprecated. There is no replacement for this method. Use the connectTimeout property to control connection timeout.
      Sets whether auto connect retry is enabled.

      Parameters:
      autoConnectRetry - auto connect retry

      Attachments

        1. MongoDataStore.java
          2 kB
        2. MongoTest.java
          0.6 kB

        Activity

          People

            Unassigned Unassigned
            mnouh Mohamed Nouh
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: