fix aggregation of death message of SUT in case of instance death #12260
Conversation
@@ -1082,7 +1082,12 @@ function checkArangoAlive (arangod, options) { | |||
const ret = res.status === 'RUNNING' && crashUtils.checkMonitorAlive(ARANGOD_BIN, arangod, options, res); | |||
|
|||
if (!ret) { | |||
print(Date() + ' ArangoD with PID ' + arangod.pid + ' gone:'); | |||
if (!arangod.hasOwnProperty('message')) { | |||
arangod.message = ''; |
} | ||
let msg = ' ArangoD of role [' + arangod.role + '] with PID ' + arangod.pid + ' is gone'; | ||
print(Date() + msg + ':'); | ||
arangod.message += (arangod.message.len === 0) ? '\n' : '' + msg + ' '; |
KVS85
Jul 20, 2020
Contributor
That could leave a comment with the following structure:
LOG:
OTHER LOG
Will OTHER LOG be logically connected to LOG here?
msg = 'health Check Signal(' + res.signal + ') '; | ||
analyzeServerCrash(arangod, options, msg); | ||
serverCrashedLocal = true; | ||
print(Date() + " checkArangoAlive: Marking crashy - " + JSON.stringify(arangod)); | ||
arangod.message += msg; | ||
msg = " checkArangoAlive: Marking crashy"; | ||
arangod.message += msg; | ||
print(Date() + msg + ' - ' + JSON.stringify(arangod)); |
KVS85
Jul 20, 2020
Contributor
Why msg
is reused here?
Initially we will print Date() + ' ArangoD of role [' + arangod.role + '] with PID ' + arangod.pid + ' is gone' + ':'
.
arangod.message
finally will be
' ArangoD of role [' + arangod.role + '] with PID ' + arangod.pid + ' is gone ' + 'health Check Signal(' + res.signal + ') ' + " checkArangoAlive: Marking crashy"
or
'\n ' + 'health Check Signal(' + res.signal + ') ' + " checkArangoAlive: Marking crashy"
Afterwards we print Date() + msg + ' - ' + JSON.stringify(arangod)
. arangod
here will have ' ArangoD of role [' + arangod.role + '] with PID ' + arangod.pid + ' is gone ' + 'health Check Signal(' + res.signal + ') ' + " checkArangoAlive: Marking crashy"
.
What is the logic of interpretation?
dothebart
Jul 21, 2020
Author
Contributor
simply msg is re-used. But its re-assigned a value, so its content doesn't add up.
@@ -2039,6 +2052,7 @@ function startInstance (protocol, options, addArgs, testname, tmpDir) { | |||
let rootDir = fs.join(tmpDir || fs.getTempPath(), testname); | |||
|
|||
let instanceInfo = { | |||
message: '', |
return previous && checkArangoAlive(arangod, options); | ||
let ret = checkArangoAlive(arangod, options); | ||
if (!ret) { | ||
instanceInfo.message += arangod.message; |
KVS85
Jul 20, 2020
Contributor
What's instanceInfo
here? Why would it accumulate all arangods messages of each failed arangod?
dothebart
Jul 21, 2020
Author
Contributor
Instance is the whole instance - data of a full cluster / leader follower.
It contains an array of process instances, which are i.e. db-server.
If one (or more) fail the check, and now got error messages, its collected into the total instance.
results[te] = { | ||
status: false, | ||
message: 'server is dead: + ' + results[te].message | ||
message: 'server is dead: ' + msg + instanceInfo.message |
KVS85
Jul 20, 2020
Contributor
How can results[te].message
not have results[te].message.length > 0
? Where is it set?
dothebart
Jul 21, 2020
Author
Contributor
If there has been a test-result with a failure, this may still be in there.
Co-authored-by: Jan <jsteemann@users.noreply.github.com>
…-test-status-sut-died
…-test-status-sut-died
…2260) * fix aggregation of death message of SUT in case of instance death * Update js/client/modules/@arangodb/process-utils.js Co-authored-by: Jan <jsteemann@users.noreply.github.com> * fix condition Co-authored-by: Jan <jsteemann@users.noreply.github.com>
…2260) * fix aggregation of death message of SUT in case of instance death * Update js/client/modules/@arangodb/process-utils.js Co-authored-by: Jan <jsteemann@users.noreply.github.com> * fix condition Co-authored-by: Jan <jsteemann@users.noreply.github.com>
…2260) * fix aggregation of death message of SUT in case of instance death * Update js/client/modules/@arangodb/process-utils.js Co-authored-by: Jan <jsteemann@users.noreply.github.com> * fix condition Co-authored-by: Jan <jsteemann@users.noreply.github.com>
…2260) (#12284) * fix aggregation of death message of SUT in case of instance death * Update js/client/modules/@arangodb/process-utils.js Co-authored-by: Jan <jsteemann@users.noreply.github.com> * fix condition Co-authored-by: Jan <jsteemann@users.noreply.github.com> Co-authored-by: Jan <jsteemann@users.noreply.github.com>
…2260) (#12282) * fix aggregation of death message of SUT in case of instance death * Update js/client/modules/@arangodb/process-utils.js Co-authored-by: Jan <jsteemann@users.noreply.github.com> * fix condition Co-authored-by: Jan <jsteemann@users.noreply.github.com> Co-authored-by: Jan <jsteemann@users.noreply.github.com> Co-authored-by: KVS85 <vadim@arangodb.com>
…2260) (#12286) * fix aggregation of death message of SUT in case of instance death * Update js/client/modules/@arangodb/process-utils.js Co-authored-by: Jan <jsteemann@users.noreply.github.com> * fix condition Co-authored-by: Jan <jsteemann@users.noreply.github.com> Co-authored-by: Jan <jsteemann@users.noreply.github.com> Co-authored-by: KVS85 <vadim@arangodb.com>
* fix aggregation of death message of SUT in case of instance death (#12260) * fix aggregation of death message of SUT in case of instance death * Update js/client/modules/@arangodb/process-utils.js Co-authored-by: Jan <jsteemann@users.noreply.github.com> * fix condition Co-authored-by: Jan <jsteemann@users.noreply.github.com> * add an exit code that indicates that the ICU-Initialization failed (#12493) * @dothebart * CHANGELOG * Update CHANGELOG Co-authored-by: Jan <jsteemann@users.noreply.github.com> * Update CHANGELOG Co-authored-by: Jan <jsteemann@users.noreply.github.com> Co-authored-by: jsteemann <jan@arangodb.com> Co-authored-by: Vadim <vadim@arangodb.com>
http://jenkins01.arangodb.biz:8080/view/PR/job/arangodb-matrix-pr/11152/