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

Add Closeable to Cluster

    XMLWordPrintable

Details

    • Improvement
    • Resolution: Fixed
    • Major
    • 3.3.4
    • None
    • None
    • None
    • 1

    Description

      This is a simple quality of life improvement if a user only needs to execute a handful of operations we can perform the disconnect operation on behalf of them. This enables try-with-resource like this:

      try (Cluster cluster = Cluster.connect("127.0.0.1", "user", "password")) {
        Bucket bucket = cluster.bucket("travel-sample");
        bucket.waitUntilReady(Duration.ofSeconds(10));
      }
      

      Attachments

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

        Activity

          People

            daschl Michael Nitschinger
            daschl Michael Nitschinger
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty