Custom Panic Handler
webfolderio opened this issue · 0 comments
Hi,
Akumuli terminates the process if a non-recoverable error occurs.
This might be ok for embedded C/C++ usage (libakumuli) or daemon (akumulid) applications.
But this usage is not suitable if libakumuli used from managed environments (JVM, .NET).
We overide the default aku_panic_handler_t
with our custom implementation but libakumuli still terminates the process.
If panic occurs, our custom aku_panic_handler_t
throws JVM Exception from JNI. But caller couldn't catch the exception because of the termination.
Is it possible to add an additonal logic to invoke_panic_handler so that library user decide if application should be crashed or not.
Beside this, caller might initialize the Akumuli so that all states will be cleared. If this new feature will be introduced, libakumuli might be recover the error and will be continue to run.