Key not able to be listed in "Documents"

When the page tries to list a particular key, it show “Error (unexpected)”.

From the error.log, I find this:

<0.25045.1236>:menelaus_web:loop:170]Server error during processing: [“web request failed”,
{path,"/pools/default/buckets/iptb/docs"},
{type,throw},
{what,
{invalid_json,
{{error,
{70,
“parse error: unallowed token at this point in JSON text\n”}},
<<"{“meta”:{“id”:“parent_key_eMIiFJbAdy3o5WAUjRJmhudJ1EBNMyHV”},“json”:\v}">>}}},
{trace,
[{ejson,nif_decode,1,
[{file,
"/home/buildbot/buildbot_slave/centos-6-x64-301-builder/build/build/couchdb/src/ejson/ejson.erl"},
{line,50}]},
{capi_utils,couch_doc_to_mochi_json,1,
[{file,“src/capi_utils.erl”},{line,130}]},
{menelaus_web_crud,encode_doc,1,
[{file,“src/menelaus_web_crud.erl”},
{line,156}]},
{menelaus_web_crud,do_handle_limit,3,
[{file,“src/menelaus_web_crud.erl”},
{line,142}]},
{menelaus_web_crud,do_handle_list,4,
[{file,“src/menelaus_web_crud.erl”},
{line,93}]},
{menelaus_web,loop,2,
[{file,“src/menelaus_web.erl”},
{line,147}]},
{mochiweb_http,headers,5,
[{file,
"/home/buildbot/buildbot_slave/centos-6-x64-301-builder/build/build/couchdb/src/mochiweb/mochiweb_http.erl"},
{line,94}]},
{proc_lib,init_p_do_apply,3,
[{file,“proc_lib.erl”},{line,239}]}]}]

The version of my couchbase server is 3.0.1, will this be fixed in 3.0.2?

@alkondratenko does this look like a known issue to you or should we request some additional data?

That looks like yet unknown bug.

Specifically it looks like memcached/ep-engine has marked document as json yet erlang is unable to decode it. It certainly does look like malformed json.

Regarding additional data. Ideally we’d have .couch file with problematic doc. If possible. if not, we’ll have to come up with some kind of /diag/eval snippet to locate it (or them) and print out various diagnostics.

Can you send us your data files somehow ?

actually I was wrong. It cannot be ep-engine or memcached bug. Looks more like something on erlang side.

Still we’ll like to get your data if possible. Or if not, then give us cbcollectinfos and we’ll come up with further diagnostics instructions.

@littlewitchanita note that you can generate a cbcollect_info via the web console. If you do that and then file an issue, you should be able to track it as we see what’s going on. Thanks!

We were able to figure it out. It is caused by myself not fixing https://issues.couchbase.com/browse/MB-11296 properly. We’ve reopened that bug and it will be fixed in what we call “sherlock” release (which would likely be numbered either 3.5 or 4.0).

Until then you won’t be able to use Documents UI on values that are “blank”. (But then note that Documents UI is not production ready anyways, avoid it on larger deployments).

May I know how can I generate the cbcollect_info?

In 3.0 and later it’s integrated into the console. Click on “log” in the web UI, then you can click on the “Collect Information” button below it.