Uploaded image for project: 'Couchbase Java Client'
  1. Couchbase Java Client
  2. JCBC-999

Timeout Error in bucketManager.Info() when One Node is Down

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Major
    • 2.4.1, 2.3.7
    • 2.3.2
    • Core
    • None
    • CB 4.5.0

    Description

      Problem

      bucketManager.Info() consistently returns a timeout exception when one of the cluster nodes is down but not yet failed over.

      Request

      The method should return the information on the bucket if at least one of the healthy nodes is in the client bootstrap list.

      Steps to Reproduce

      Create a test directory and make it the current working directory

      Get the latest Couchbase Java SDK:

      wget http://packages.couchbase.com/clients/java/2.3.2/Couchbase-Java-Client-2.3.2.zip

      Unzip the file

      Change directory to ./Couchbase-Java-Client-2.3.2

      Copy the attached App.java to this location

      Edit App.java to include the required IP addresses for the Couchbase cluster

      Compile and run with the following:

      javac -cp couchbase-java-client-2.3.2.jar:rxjava-1.1.8.jar:couchbase-core-io-1.3.2.jar: App.java

      java -cp .:couchbase-java-client-2.3.2.jar:rxjava-1.1.8.jar:couchbase-core-io-1.3.2.jar: App

      Note the timeout exception if one of the nodes is down (and not yet failed over). The expectation is that the call would return info on bucket if one of the bootstrap nodes is available.

      Exception in thread "main" java.lang.RuntimeException: com.couchbase.client.deps.io.netty.channel.ConnectTimeoutException: connection timed out: /10.111.150.102:8091
      at com.couchbase.client.java.util.Blocking.blockForSingle(Blocking.java:82)
      at com.couchbase.client.java.bucket.DefaultBucketManager.info(DefaultBucketManager.java:122)
      at App.main(App.java:45)
      Caused by: com.couchbase.client.deps.io.netty.channel.ConnectTimeoutException: connection timed out: /10.111.150.102:8091
      at com.couchbase.client.deps.io.netty.channel.nio.AbstractNioChannel$AbstractNioUnsafe$1.run(AbstractNioChannel.java:216)
      at com.couchbase.client.deps.io.netty.util.concurrent.PromiseTask$RunnableAdapter.call(PromiseTask.java:38)
      at com.couchbase.client.deps.io.netty.util.concurrent.ScheduledFutureTask.run(ScheduledFutureTask.java:120)
      at com.couchbase.client.deps.io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:408)
      at com.couchbase.client.deps.io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:402)
      at com.couchbase.client.deps.io.netty.util.concurrent.SingleThreadEventExecutor$2.run(SingleThreadEventExecutor.java:140)
      at com.couchbase.client.deps.io.netty.util.concurrent.DefaultThreadFactory$DefaultRunnableDecorator.run(DefaultThreadFactory.java:144)
      at java.lang.Thread.run(Thread.java:745)

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            daschl Michael Nitschinger
            jdillon Jeff Dillon (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty