All the views processing is broken in Couchbase 7

Hi,
I get that you are trying to deprecate views, but either you remove it completely to make it clear it is unsupported or you don’t touch it at all, if you continue to make it available at least make it usable.
At the moment there is no replacement for views that is comparable in terms of performance, not even remotely.
Other than the node js sdk bug that I already reported the web ui is totally unusable for views right now.
1-The “Show results” button often stop working without reason, not refreshing the results.
2-The http rest link next to results uses the wrong port, 8091 instead of 8092.
3-Even if you change the port manually it will start complain about permissions.
4-Even if you grant the permissions it will still return “{“error”:“not_found”,“reason”:“missing”}”
5-The parameters Startkey and Endkey are ignored

And these are the one on top of my mind. I am sure there are more I forgot.
Another thing, I read the page that says views are going to be deprecated, but it doesn’t says it’s going to deprecated for all engines but only for the magma engine, so if you continue to make it available please make it so.
For now I’ll go back to Couchbase 6.something, need to find the latest usable one.

What version so I can investigate?

Latest. Couchbase 7.2.2 community edition on Windows which is my development machine. Not sure about the startkey/endkey issue, but I noticed the other problems even with previous 7.x versions.
I rolled back to 6.6 and it seem to work properly.

1-The “Show results” button often stop working without reason, not refreshing the results.

It does feel a bit wonky - I think because it just updates quickly and silently. If you use the forward/backward arrows there is a “waiting for hostname…” message. But if you just click on “Show Results”, it just updates the results quickly and silently - and unless you’ve changed your data, looks like nothing happened.

2-The http rest link next to results uses the wrong port, 8091 instead of 8092.

8091 works for me.

$ curl "http://localhost:8091/couchBase/my_bucket/_design/dev_ddoc/_view/my_view?stale=false&inclusive_end=true&connection_timeout=60000" -u Administrator:password

{"total_rows":1001,"rows":[

{"id":"00000000000000000000","key":"00000000000000000000","value":null},
{"id":"00000000000000000001","key":"00000000000000000001","value":null},
{"id":"00000000000000000002","key":"00000000000000000002","value":null},
{"id":"00000000000000000003","key":"00000000000000000003","value":null},

3-Even if you change the port manually it will start complain about permissions.

You will need a -u username:password for curl. Or BasicAuth for REST. But see (2) and (4).

4-Even if you grant the permissions it will still return “{“error”:“not_found”,“reason”:“missing”}”

Yes - because views are on port 8091; 8092 is a different service and will have nothing mapped to the url for the view.

5-The parameters Startkey and Endkey are ignored

The url provided by the webui has them as startKey and endKey. But they are actually startkey and endkey (all lower case). They also need the double-quotes. If the shell makes it difficult to get double-quotes in the command-line, you can use the url-encoded form (%22 is a double quote)

% curl -u Administrator:password ‘http://localhost:8091/couchBase/my_bucket/_design/dev_ddoc/_view/my_view?startkey=“00000000000000000006”&endkey=“00000000000000000009”&stale=false&inclusive_end=true&connection_timeout=60000
{“total_rows”:1001,“rows”:[
{“id”:“00000000000000000006”,“key”:“00000000000000000006”,“value”:null},
{“id”:“00000000000000000007”,“key”:“00000000000000000007”,“value”:null},
{“id”:“00000000000000000008”,“key”:“00000000000000000008”,“value”:null},
{“id”:“00000000000000000009”,“key”:“00000000000000000009”,“value”:null}
]
}

It stops working, not at the first try of course. Sometime when you put some wrong value like forgetting double quotes and then you fix it, it won’t refresh the data. It is not immediate to reproduce.
Regarding the rest, I was using the browser to test, if I need to fire a command line I can directly use the node sdk. The purpose was to use the browser when developing views, one doesn’t want to go back and forth between UI and command line. Plus changing the query values in a text field is much faster than a shell.
Regarding point 5, again talking of the web interface, maybe it works in the shell, but not in the web interface, including double quotes.

RIght. Because it uses the wrong parameter names. I’ve opened Loading... for the webui folks too look at all your issues.

The startKey and endKey parameters are the wrong names, so regardless of how you change their values, or add double quotes, or specify them at all or not - the output is always the same.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.