Query Workbench always hang on in the main admin UI for CBE 4.6.3

env:
Couchbase Server 4.6.3-4136 Enterprise Edition (build-4136) on Ubuntu 12.04.5 LTS
when I run sample N1QL in the main admin UI such as

SELECT COUNT(*) FROM default;

repeatedly, Query Workbench always hang on unless I refresh the page. and I don’t catch any error log in indexer.log.
but when I connect Couchbase server by Query Workbench Developer Preview 1.0.3, it works fine.

Do you see any errors in query.log . Is it works from cbq shell. This special case of query because counting everything in the bucket. So it uses CountScan which uses bucket statistics no index will be used. cc @eben

cbq works fine.
I found the error as following:

_time=2017-10-20T01:37:54.491+08:00 _level=ERROR _msg=PrimaryScan.newIndexConnection  error=System datastore error  - cause: This bucket type is not supported memcached

I do have a Memcached type bucket on the node. when I delete the Memcached bucket.the Query Workbench in the main admin UI works fine.

Thanks @atom_yang. You can track MB-26453

Hi @atom_yang, I started an instance of 4.6.3-4136, and I am not able to reproduce this issue. Can you tell me if there are any errors shown in your browser’s javascript error console? I suspect that there is some problem with how the Query Workbench is handling memcached buckets when it is building the list of buckets. Having a stack trace or error message would help me figure out what is going on.

Thank you!

no error in the browser’s javascript error console.
but I found the following request pending 10s again and again.

http://x.x.x.x:8091/pools/default?etag=91844908&waitChange=10000

The continuing requests are what the UI uses to update itself when things on the server changes, that’s normal.

Too bad that there are no error messages, that would have been helpful! :slight_smile:

Can you describe the steps required to reproduce the issue in more detail? E.g.,

  • How many buckets do you have, of which type?
  • You mentioned that the query works correctly when you removed the memcached bucket. Does the query fail again as soon as the memcached bucket is added back?

Thank you!

2 Couchbase bucket

yes, it works.

and when Query Workbench hang, cancel button can not click.
now it works fine. I will keep monitoring.

when hang, I found the following request after POST http://x.x.x.x:8091/_p/query/query/service

POST /logClientError HTTP/1.1
Host: x.x.x.x:8091
Connection: keep-alive
Content-Length: 826
Pragma: no-cache
Cache-Control: no-cache
Origin: http://x.x.x.x:8091
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/61.0.3163.100 Safari/537.36
Content-Type: application/x-www-form-urlencoded; charset=UTF-8
Accept: application/json, text/plain, */*
ns-server-ui: yes
invalid-auth-response: on
Referer: http://x.x.x.x:8091/ui/index.html
Accept-Encoding: gzip, deflate
Accept-Language: en-US,en;q=0.8,zh-CN;q=0.6,zh;q=0.4,zh-TW;q=0.2
Cookie: ui-auth-x.x.x.x%3A8091=28c1931356679ce94d786c4833c20801

and response

HTTP/1.1 200 OK
Server: Couchbase Server
Pragma: no-cache
Date: Fri, 20 Oct 2017 19:32:19 GMT
Content-Type: text/plain
Content-Length: 0
Cache-Control: no-cache

and form data

Got unhandled javascript error:
name: TypeError;
message: Cannot read property 'elapsedTime' of undefined;
stack: TypeError: Cannot read property 'elapsedTime' of undefined
    at http://x.x.x.x:8091/_p/ui/query/qw_query_service.js:629:46
    at http://x.x.x.x:8091/ui/libs/angular.min.js:87:96
    at http://x.x.x.x:8091/ui/libs/angular.min.js:119:129
    at r.$eval (http://x.x.x.x:8091/ui/libs/angular.min.js:133:313)
    at r.$digest (http://x.x.x.x:8091/ui/libs/angular.min.js:130:412)
    at r.$apply (http://x.x.x.x:8091/ui/libs/angular.min.js:134:78)
    at g (http://x.x.x.x:8091/ui/libs/angular.min.js:87:444)
    at T (http://x.x.x.x:8091/ui/libs/angular.min.js:92:50)
    at XMLHttpRequest.w.onload (http://x.x.x.x:8091/ui/libs/angular.min.js:93:78);
Name

Hi @atom_yang, the exception really has me puzzled, because just above the line where the ‘undefined’ exception is throw is some code that sets a value for the thing that is undefined.

I haven’t yet been able to reproduce the issue on my own machine, if you discover any more details on how to get the bug to happen, let me know.

What browser are you using? That shouldn’t make a difference, but might.

Thanks

I am using Google Chrome version 61.0.3163.100 (64 bit)