Details
-
Bug
-
Status: Closed
-
Critical
-
Resolution: Fixed
-
6.6.0
-
Triaged
-
1
-
Yes
-
KV Sprint 2020-June
Description
This is a regression that was introduced in MB-40126.
This Java 3.x code replicates:
String docId = docId();
|
|
coll.mutateIn(docId, Collections.singletonList(
|
upsert("foo", "bar").xattr() |
),
|
mutateInOptions().storeSemantics(StoreSemantics.INSERT));
|
|
LookupInResult result = coll.lookupIn(docId, Arrays.asList(
|
LookupInSpec.get("foo").xattr(), |
LookupInSpec.get("") |
));
|
|
assertTrue(result.exists(1)); |
|
This is a Sub-Document insertion (ADD flag) that's only touching XATTRs, it doesn't specify the body and leaves it at whatever the server defaults to.
It passes on 6.5.0-4908 but fails on 6.6.0-7857, on the last line.
So memcached used to create an empty JSON object as the body if none was specified, and now creates the document with a null body instead.
(This change does seem like an improvement to me, but sadly will break existing released transactional code when running on 6.6.)
Attachments
Issue Links
- is caused by
-
MB-40126 Subdoc CreateAsDeleted without any value path can result in non-empty value
-
- Closed
-
Activity
Field | Original Value | New Value |
---|---|---|
Assignee | Dave Rigby [ drigby ] |
Affects Version/s | 6.6.0 [ 16787 ] |
Priority | Major [ 3 ] | Critical [ 2 ] |
Component/s | memcached [ 11621 ] |
Summary | memcached used to create an empty JSON body if a document was created with Sub-Document only specifying xattrs - now creates a null body | Sub-Document mutation only specifying XATTR paths no longer creates an empty JSON body |
Is this a Regression? | Unknown [ 10452 ] | Yes [ 10450 ] |
Triage | Untriaged [ 10351 ] | Triaged [ 10350 ] |
Fix Version/s | 6.6.0 [ 16787 ] |
Summary | Sub-Document mutation only specifying XATTR paths no longer creates an empty JSON body | A Sub-Document insertion only specifying XATTR paths no longer creates an empty JSON body |
Sprint | KV Sprint 2020-June [ 1106 ] |
Rank | Ranked higher |
Status | Open [ 1 ] | In Progress [ 3 ] |
Labels | txn_testing |
Link | This issue blocks MB-38724 [ MB-38724 ] |
Labels | txn_testing | approved-for-6.6.0 txn_testing |
Assignee | Dave Rigby [ drigby ] | Graham Pople [ graham.pople ] |
Resolution | Fixed [ 1 ] | |
Status | In Progress [ 3 ] | Resolved [ 5 ] |
Status | Resolved [ 5 ] | Closed [ 6 ] |