Uploaded image for project: 'Couchbase Server'
  1. Couchbase Server
  2. MB-1170

membase-cli should have nicer error msg when talking to a down cluster

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • 1.6.0 beta3
    • 1.6.0 beta4
    • tools
    • None
    • Operating System: All
      Platform: All

    Description

      if the northscale server is down or stopped, and you try to use the membase-cli, you get an ugly python error msg.

      I would instead expect to see something like...

      ERROR: blah blah some nice err msg

      Here's what's there for 1.6.0a-39...

      [root@Config85VM0 1.6.0a]# ./bin/cli/membase server-list -c 127.0.0.1:8080
      Traceback (most recent call last):
      File "./bin/cli/membase", line 101, in ?
      main()
      File "./bin/cli/membase", line 98, in main
      taskrunner.runCmd(cmd, server, port, user, password, opts)
      File "/opt/NorthScale/1.6.0a/bin/cli/listservers.py", line 56, in runCmd
      password)
      File "/opt/NorthScale/1.6.0a/bin/cli/listservers.py", line 83, in getData
      password)
      File "/opt/NorthScale/1.6.0a/bin/cli/restclient.py", line 91, in sendCmd
      self.bootStrap(headers)
      File "/opt/NorthScale/1.6.0a/bin/cli/restclient.py", line 58, in bootStrap
      self.conn.request('GET', '/pools','',headers)
      File "/usr/lib64/python2.4/httplib.py", line 810, in request
      self._send_request(method, url, body, headers)
      File "/usr/lib64/python2.4/httplib.py", line 833, in _send_request
      self.endheaders()
      File "/usr/lib64/python2.4/httplib.py", line 804, in endheaders
      self._send_output()
      File "/usr/lib64/python2.4/httplib.py", line 685, in _send_output
      self.send(msg)
      File "/usr/lib64/python2.4/httplib.py", line 652, in send
      self.connect()
      File "/usr/lib64/python2.4/httplib.py", line 636, in connect
      raise socket.error, msg
      socket.error: (111, 'Connection refused')

      Attachments

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

        Activity

          People

            steve.yen@northscale.com Steve Yen
            steve.yen@northscale.com Steve Yen
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty