8000 Bug fix/begin trx disjoint (#14641) (#14648) · arangodb/arangodb@a457b96 · GitHub
[go: up one dir, main page]

Skip to content

Commit a457b96

Browse files
mchackiKVS85
andauthored
Bug fix/begin trx disjoint (#14641) (#14648)
* Bug fix/begin trx disjoint (#14641) * Revert JSUnity improvement, testCase names now need to be unique per file again. :sad: (#14659) Co-authored-by: Vadim <vadim@arangodb.com>
1 parent f890a13 commit a457b96

File tree

2 files changed

+14
-9
lines changed

2 files changed

+14
-9
lines changed

CHANGELOG

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
v3.8.1 (XXXX-XX-XX)
22
-------------------
33

4+
* Fixed: _api/transaction/begin called on edge collections of disjoint
5+
SmartGraphs falsely returned CollectionNotFound errors.
6+
47
* Bug-Fix: In more complex queries there was a code-path where a (Disjoint-)
58
Smart graph access was not properly optimized.
69

arangod/Transaction/Manager.cpp

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -489,15 +489,17 @@ Result Manager::lockCollections(TRI_vocbase_t& vocbase,
489489
if (res.fail()) {
490490
return false;
491491
}
492-
res.reset(state->addCollection(theEdge->getFromCid(), "_from_" + cname,
493-
mode, /*lockUsage*/ false));
494-
if (res.fail()) {
495-
return false;
496-
}
497-
res.reset(state->addCollection(theEdge->getToCid(), "_to_" + cname,
498-
mode, /*lockUsage*/ false));
499-
if (res.fail()) {
500-
return false;
492+
if (!col->isDisjoint()) {
493+
res.reset(state->addCollection(theEdge->getFromCid(), "_from_" + cname,
494+
mode, /*lockUsage*/ false));
495+
if (res.fail()) {
496+
return false;
497+
}
498+
res.reset(state->addCollection(theEdge->getToCid(), "_to_" + cname,
499+
mode, /*lockUsage*/ false));
500+
if (res.fail()) {
501+
return false;
502+
}
501503
}
502504
}
503505
} catch (basics::Exception const& ex) {

0 commit comments

Comments
 (0)
0