magic $flags and $expiration vars show up in view but not doc
i noticed that if you query a view that emits the document, you get properties like $flag and $expiration, but if you query the http interface for the document url itself, it only shows _rev and _id, not any of the dollar sign magic variables. is there a reason behind that difference?
curl "http://192.168.96.128:8092/default/_design/test/_view/all?key=%22test%2Fquery-1324052106.5247-11152826%22"
{"total_rows":39,"rows":[
{"id":"test/query-1324052106.5247-11152826","key":"test/query-1324052106.5247-11152826","value":{"_id":"test/query-1324052106.5247-11152826","_rev":"1-00009fddf9213ed70000000d00000000","$flags":0,"$expiration":1324055706,"foo":"bar"}}
]}
curl "http://192.168.96.128:8092/default/test%2Fquery-1324052106.5247-11152826"
{"_id":"test/query-1324052106.5247-11152826","_rev":"1-00009fddf9213ed70000000d00000000","foo":"bar"}
Matt have opened bug on that: http://www.couchbase.org/issues/browse/MB-4549
We're going to fix it by always returning memcached-level metadata in reply. Also note that memcached API is main CRUD (create, read, update, delete) API. CouchAPI for CRUD is not fully supported.
Thanks, that's the behavior I would have expected.
That's a situation where you're emitting the whole document in the view, is that correct?
It probably shouldn't do so, but it's pretty harmless. Thanks for raising it.