-
Notifications
You must be signed in to change notification settings - Fork 19
Description
Hello.
We catch Invalid arguments
exception on
- 6.2.28 fdb client for ubuntu
- foundationdb@1.1.1
- Docker image based on node:16.13.1
Stack trace:
Error:
Invalid arguments
---------
Invalid argument
---------
/opt/app/node_modules/foundationdb/build/Debug/fdblib.node(_Z16create_backtracev+0x27) [0x7f6f787dd6b1]
/opt/app/node_modules/foundationdb/build/Debug/fdblib.node(_Z14create_tracingP10napi_env__PKc+0x26) [0x7f6f787dd866]
/opt/app/node_modules/foundationdb/build/Debug/fdblib.node(_Z15throw_if_not_okP10napi_env__11napi_status+0x58) [0x7f6f787dd983]
/opt/app/node_modules/foundationdb/build/Debug/fdblib.node(_Z10getWrappedP10napi_env__P20napi_callback_info__+0x87) [0x7f6f787ddc1d]
/opt/app/node_modules/foundationdb/build/Debug/fdblib.node(+0x56c3) [0x7f6f787d86c3]
node() [0xaabfcd]
node() [0xd4a35e]
node(_ZN2v88internal21Builtin_HandleApiCallEiPmPNS0_7IsolateE+0xaf) [0xd4b77f]
node() [0x15e78f9]
at Database.rawCreateTransaction (node_modules/foundationdb/dist/lib/database.js:55:51)
at Database.doTn (node_modules/foundationdb/dist/lib/database.js:39:21)
at Database.doTransaction (node_modules/foundationdb/dist/lib/database.js:43:21)
at Object.doTransaction (node_modules/@deeplay/foundationdb-event-store-core/lib/utils/doTransaction.js:13:10)
at Object.doIdempotentTransaction (node_modules/@deeplay/foundationdb-event-store-core/lib/index.js:68:94)
at writeTransition (build/table/writeTransition.js:26:37)
at writeResult.baseMs (build/table/doTask.js:30:119)
at retry (node_modules/abort-controller-x/lib/retry.js:13:26)
at doTask (build/table/doTask.js:30:66)
at build/table/index.js:129:62
When calling napi_get_cb_info
we obtain a pointer to thisObj
from native code using the callback’s descriptor. After that we try to napi_unwrap
the pointer, but the arguments error appear:
https://github.com/josephg/node-foundationdb/blob/master/src/utils.cpp#L79
I am not sure how to stably reproduce that behaviour.
I was able to check the backtrace when I remove the pod, and the service forcedly stopped.
But we catch same error sometimes while service is working as usual, and in this case all of the new transactions after the error will be completed with the same error.
Could you please help me to dig deeper to find the root of the issue?
Can we somehow get an enriched logging to understand what is wrong and whether the bug is on our side or the native code one?