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

DefaultConfigFactory attempts to create VBucket with master == -1

    XMLWordPrintable

Details

    • Bug
    • Resolution: Duplicate
    • Major
    • 1.1-beta
    • 1.1dp
    • Core
    • Security Level: Public
    • None
    • all java

    Description

      Caused by: java.lang.ArrayIndexOutOfBoundsException: -1
      at java.util.ArrayList.get(ArrayList.java:324)
      at com.couchbase.client.vbucket.config.DefaultConfig.getServer(DefaultConfig.java:81)
      at com.couchbase.client.vbucket.VBucketNodeLocator.getPrimary(VBucketNodeLocator.java:74)
      at com.couchbase.client.CouchbaseConnection.addOperation(CouchbaseConnection.java:140)
      at net.spy.memcached.MemcachedConnection.enqueueOperation(MemcachedConnection.java:639)
      at net.spy.memcached.MemcachedClient.asyncStore(MemcachedClient.java:296)
      at net.spy.memcached.MemcachedClient.set(MemcachedClient.java:727)
      at net.spy.memcached.MemcachedClient.set(MemcachedClient.java:125)
      at sun.reflect.GeneratedMethodAccessor6.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:597)

      Possible steps to reproduce:
      1) populate bucket from load file
      2) delete bucket
      3) create new bucket with same name
      4) repopulate bucket with same keys, same order, slightly different values

      The -1 value looks like it is being set when the VBucket object is created. Would it make sense to check for illegal arguments in the constructor and make the object immutable, i.e. no setMaster?

      Attachments

        Issue Links

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

          Activity

            People

              daschl Michael Nitschinger
              SteveC Steven Cooke
              Votes:
              1 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes

                  PagerDuty