Is there any way to get a hook to run code before a DO is evicted from memory? Would love to use it

Is there any way to get a hook to run code before a DO is evicted from memory? Would love to use it to flush in memory stuff to sql storage rather than needing to write a value that will be modified often in short bursts.
Was this page helpful?