You could also split up the responsibility between the exception filter and the execution logic;
Performing some kind of :
try {
await sayhello()
} catch (e)
throw e // This will call the exception filter
} finally {
await writeToElastic()
}