[JCBC-120] NPE when connecting to memcached bucket without configured password Created: 28/Sep/12  Updated: 31/Jan/13  Resolved: 09/Oct/12

Status: Resolved
Project: Couchbase Java Client
Component/s: Core
Affects Version/s: 1.1-dp3
Fix Version/s: 1.1-dp4
Security Level: Public

Type: Bug Priority: Minor
Reporter: Mark Nunberg Assignee: Michael Nitschinger
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment: This happens when connecting to a memcached bucket which is not configured with a password, and no password is specified to the ctor.

Tested with the beta cluster

2012-09-28 09:53:31.562 INFO com.couchbase.client.CouchbaseMemcachedConnection: Added {QA sa=/, #Rops=0, #Wops=0, #iq=0, topRop=null, topWop=null, toWrite=0, interested=0} to connect queue
        at net.spy.memcached.auth.PlainCallbackHandler.<init>(PlainCallbackHandler.java:50)
        at com.couchbase.client.CouchbaseConnectionFactory.getAuthDescriptor(CouchbaseConnectionFactory.java:187)
        at net.spy.memcached.MemcachedClient.<init>(MemcachedClient.java:197)
        at com.couchbase.client.CouchbaseClient.<init>(CouchbaseClient.java:230)
        at com.couchbase.client.CouchbaseClient.<init>(CouchbaseClient.java:200)
        at com.couchbase.cbc.App.main(App.java:69)


        CouchbaseClient cli = null;
        LinkedList<URI> uriList = new LinkedList<URI>();
        try {
            uriList.add(new URI("http://" + options.hostname + "/pools"));
            cli = new CouchbaseClient(
                    options.bucket, options.username, options.password);
        } catch (Exception ex) {

Comment by Mark Nunberg [ 08/Oct/12 ]
This is not a duplicate of JCBC-70. Specifically JCBC-70 relates to issues about memcached buckets during failover. This bug has nothing to do with failover and has to do with connecting to a memcached bucket without a configured SASL password (which the admin console lets you do).
Comment by Matt Ingenthron [ 08/Oct/12 ]
Yes, just noticed that it's not a dupe. Sorry about that. I was about to reopen it. Note, this could be related to JCBC-70 though.
Comment by Michael Nitschinger [ 09/Oct/12 ]
Generated at Wed Nov 26 11:35:27 CST 2014 using JIRA 5.2.4#845-sha1:c9f4cc41abe72fb236945343a1f485c2c844dac9.