Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

lower takeover leadership current log level #14379

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions CHANGELOG
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
devel
-----

* Lower log level to warning, when take over shard leadership finds
an agency Current entry is missing the server taking over.

* APM-112: invalid use of OPTIONS in AQL queries will now raise a warning in
the query.
The feature is useful to detect misspelled attribute names in OPTIONS, e.g.
Expand Down Expand Up @@ -255,8 +258,8 @@ devel
this way the system does only need to produce a path that is allowed to
be passed through.
e.g.
FOR v,e,p IN 10 OUTBOUND @start GRAPH "myGraph"

FOR v,e,p IN 10 OUTBOUND @start GRAPH "myGraph"
FILTER v.isRelevant == true
RETURN p

Expand Down
11 changes: 9 additions & 2 deletions arangod/Cluster/FollowerInfo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -317,9 +317,16 @@ void FollowerInfo::takeOverLeadership(std::vector<ServerID> const& previousInsyn
std::make_shared<std::vector<ServerID>>(previousInsyncFollowers);
auto myEntry =
std::find(failoverCandidates->begin(), failoverCandidates->end(), ourselves);

// We expect of course to be one of the fail over candidates. However, if the creation
// of the TakeOverLeadership job and it's start leading here are timewise apart, chances
// are that Current has been changed in the meantime. The assertion should remain here
// to detect any errors during CI.
if (myEntry == failoverCandidates->end()) {
LOG_TOPIC("c9422", ERR, Logger::CLUSTER)
<< "invalid failover candidates for FollowerInfo of shard "
LOG_TOPIC("c9422", WARN, Logger::CLUSTER)
<< "invalid failover candidates for FollowerInfo of shard - "
<< "can happen, when scheduling and starting the leadership "
<< "takeover are timewise apart, so that the Current entry has expired. "
<< _docColl->vocbase().name() << "/" << _docColl->name()
<< ". our id: " << ourselves << ", failover candidates: "
<< *failoverCandidates << ", previous in-sync followers: "
Expand Down